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YAAYM,GAAGE,KAAOL,EAASK,GAAI,CAC1ClB,KAAKU,YAAYM,GAAGS,MAAQZ,EAASY,SACjCC,KAAUb,EAASY,OACnBzB,KAAKU,YAAYM,GAAGS,MACxBzB,KAAKU,YAAYM,GAAGW,QAAOD,KAAUb,EAASc,MAC9C,MAGN,CAACC,kDA3DUhC,GAAkBiC,4DAAlBjC,EAAkBkC,igBFd/BtC,iBAA8B,yBAA9BA,CAA8B,WAGxBA,gCAKAA,gCAOFA,QAEAA,uBAKAA,gCAUAA,uCAIEA,6CAAqBuC,8BAAiC,GACvDvC,mBAlCgBA,iCAKAA,kCASXA,iCAKSA,kCAWbA,0DAAyC,cAAzCA,CAAyC,isNEnBlCI,CAAkB,ODCxB,IAAMoC,EAAmB,MAA1B,MAAOA,EAAmBJ,kDAAnBI,EAAmB,sCAAnBA,IAAmBJ,wCAHpBK,cAAsBxC,GACtBwC,eAECD,CAAmB,KERhC,MAEME,EAAU,CAACC,KAAcH,EAAqBI,KAO7C,IAAMC,EAAY,MAAnB,MAAOA,EAAYT,kDAAZS,EAAY,sCAAZA,IAAYT,wCAHVM,EAJEC,KAAcH,EAAqBI,cAOvCC,CAAY","names":["i0","routes","path","component","DashboardComponent","constructor","hs","dts","this","ClientDashboardGraphTypes","ClientDashboardGraphSubTypes","ngOnInit","Promise","allSettled","_this","getUserAssignedDashboardTiles","navTiles","gridTiles","dialogTiles","loading","dialogSelectEventListener","gridItem","len","length","i","dialogTile","id","dialogSelectedItem","console","log","dialogChangeEventListener","change","initializeDialogDataEventListener","title","cloneDeep","data","static","core","selectors","ctx","ClientRoutingModule","RouterModule","modules","CommonModule","NowaccountSharedModule","ClientModule"],"sourceRoot":"webpack:///","sources":["./src/app/pages/nowaccount/client/dashboard/dashboard.component.html","./src/app/pages/nowaccount/client/client-routing.module.ts","./src/app/pages/nowaccount/client/dashboard/dashboard.component.ts","./src/app/pages/nowaccount/client/client.module.ts"],"sourcesContent":["
\r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n\r\n
\r\n \r\n \r\n \r\n
\r\n \r\n \r\n \r\n\r\n \r\n
\r\n
","import { NgModule } from '@angular/core';\r\nimport { RouterModule, Routes } from '@angular/router';\r\nimport { DashboardComponent } from './dashboard/dashboard.component';\r\n\r\nconst routes: Routes = [\r\n {\r\n path: 'Dashboard/Client',\r\n component: DashboardComponent,\r\n },\r\n];\r\n\r\n@NgModule({\r\n imports: [RouterModule.forChild(routes)],\r\n exports: [RouterModule],\r\n})\r\nexport class ClientRoutingModule {}\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { cloneDeep } from 'lodash-es';\r\nimport { ClientDashboardGraphSubTypes } from 'src/app/core/enums/client-dashboard-graph-sub-types.enum';\r\nimport { ClientDashboardGraphTypes } from 'src/app/core/enums/client-dashboard-graph-types.enum';\r\nimport { HydrationService } from 'src/app/core/services/login/hydration.service';\r\nimport { DashboardTilesService } from 'src/app/core/services/nowaccount/dashboard/dashboard-tiles.service';\r\nimport { Alert } from 'src/app/core/types/alert.type';\r\nimport { DashboardGridItem } from 'src/app/core/types/dashboard-grid-item.type';\r\n\r\n@Component({\r\n selector: 'app-dashboard',\r\n templateUrl: './dashboard.component.html',\r\n styleUrls: ['./dashboard.component.scss'],\r\n})\r\nexport class DashboardComponent implements OnInit {\r\n navTiles: { title: string; alert: Alert; routerHref: string }[] = [];\r\n gridTiles: DashboardGridItem[] = [];\r\n dialogTiles: DashboardGridItem[] = [];\r\n graphTypesEnum = ClientDashboardGraphTypes;\r\n graphSubTypesEnum = ClientDashboardGraphSubTypes;\r\n dialogSelectedItem: DashboardGridItem | null = null;\r\n loading = true;\r\n\r\n constructor(\r\n private hs: HydrationService,\r\n private dts: DashboardTilesService,\r\n ) {}\r\n\r\n async ngOnInit(): Promise {\r\n //console.log('DashboardComponent HydrateAccountStore');\r\n await Promise.allSettled([\r\n this.dts.getUserAssignedDashboardTiles('Client'),\r\n ]);\r\n\r\n this.navTiles = this.dts.navTiles;\r\n this.gridTiles = this.dts.gridTiles;\r\n this.dialogTiles = this.dts.dialogTiles;\r\n this.loading = false;\r\n }\r\n\r\n dialogSelectEventListener(gridItem: DashboardGridItem) {\r\n // grab dialog's version of selected grid tile\r\n // eslint-disable-next-line prefer-destructuring\r\n const len = this.dialogTiles.length;\r\n for (let i = 0; i < len; i += 1) {\r\n const dialogTile = this.dialogTiles[i];\r\n if (dialogTile.id === gridItem.id) {\r\n this.dialogSelectedItem = dialogTile;\r\n break;\r\n }\r\n }\r\n console.log('new dialogSelectedItem, ', this.dialogSelectedItem);\r\n }\r\n\r\n dialogChangeEventListener(change: any) {\r\n this.dialogSelectedItem = change;\r\n }\r\n\r\n initializeDialogDataEventListener(gridItem: {\r\n id: string;\r\n title: string;\r\n data: any;\r\n }) {\r\n const len = this.dialogTiles.length;\r\n for (let i = 0; i < len; i += 1) {\r\n if (this.dialogTiles[i].id === gridItem.id) {\r\n this.dialogTiles[i].title = gridItem.title\r\n ? cloneDeep(gridItem.title)\r\n : this.dialogTiles[i].title;\r\n this.dialogTiles[i].data = cloneDeep(gridItem.data);\r\n break;\r\n }\r\n }\r\n }\r\n}\r\n","import { CommonModule } from '@angular/common';\r\nimport { NgModule } from '@angular/core';\r\n\r\nimport { NowaccountSharedModule } from 'src/app/shared/nowaccount/nowaccount-shared.module';\r\nimport { ClientRoutingModule } from './client-routing.module';\r\nimport { DashboardComponent } from './dashboard/dashboard.component';\r\n\r\nconst components = [DashboardComponent];\r\n\r\nconst modules = [CommonModule, ClientRoutingModule, NowaccountSharedModule];\r\n\r\n@NgModule({\r\n declarations: [...components],\r\n imports: [...modules],\r\n exports: [...components, ...modules],\r\n})\r\nexport class ClientModule {}\r\n"],"x_google_ignoreList":[]}