common-header-lib 0.0.20 → 0.20.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (98) hide show
  1. package/README.md +143 -24
  2. package/assets/i18n/ar.json +4 -1
  3. package/assets/i18n/de.json +4 -1
  4. package/assets/i18n/en.json +4 -1
  5. package/assets/i18n/es.json +4 -1
  6. package/assets/i18n/fr.json +4 -1
  7. package/assets/i18n/hi.json +4 -1
  8. package/assets/i18n/ja.json +4 -1
  9. package/assets/i18n/ko.json +4 -1
  10. package/fesm2022/common-header-lib.mjs +3380 -0
  11. package/fesm2022/common-header-lib.mjs.map +1 -0
  12. package/index.d.ts +459 -5
  13. package/package.json +20 -31
  14. package/src/assets/i18n/ar.json +4 -1
  15. package/src/assets/i18n/de.json +4 -1
  16. package/src/assets/i18n/en.json +4 -1
  17. package/src/assets/i18n/es.json +4 -1
  18. package/src/assets/i18n/fr.json +4 -1
  19. package/src/assets/i18n/hi.json +4 -1
  20. package/src/assets/i18n/ja.json +4 -1
  21. package/src/assets/i18n/ko.json +4 -1
  22. package/assets/scss/_sidebar.scss +0 -267
  23. package/assets/scss/styles.scss +0 -577
  24. package/esm2020/common-header-lib.mjs +0 -5
  25. package/esm2020/lib/Validators/noSpaceAllowed.mjs +0 -16
  26. package/esm2020/lib/common-header-lib.component.mjs +0 -629
  27. package/esm2020/lib/common-header-lib.module.mjs +0 -174
  28. package/esm2020/lib/common-header-lib.service.mjs +0 -200
  29. package/esm2020/lib/components/confirm-dialog/confirm-dialog.component.mjs +0 -49
  30. package/esm2020/lib/components/general-configuration/general-configuration.component.mjs +0 -399
  31. package/esm2020/lib/components/general-configuration/landingpg-config/landingpg-config.component.mjs +0 -124
  32. package/esm2020/lib/components/general-configuration/timezone-configuration/timezone-configuration.component.mjs +0 -137
  33. package/esm2020/lib/components/grid-pagination/grid-pagination.component.mjs +0 -38
  34. package/esm2020/lib/components/ng-translation/ng-translation.component.mjs +0 -82
  35. package/esm2020/lib/components/no-service-my-access-pg/no-service-my-access-pg.component.mjs +0 -19
  36. package/esm2020/lib/components/notification-sidebar/notification-sidebar.component.mjs +0 -40
  37. package/esm2020/lib/components/side-popup/side-popup.component.mjs +0 -34
  38. package/esm2020/lib/components/user-mailbox/user-mailbox.component.mjs +0 -168
  39. package/esm2020/lib/components/user-sidebar/user-sidebar.component.mjs +0 -254
  40. package/esm2020/lib/components/viewpassword-popup/viewpassword-popup.component.mjs +0 -197
  41. package/esm2020/lib/model/data_model.mjs +0 -229
  42. package/esm2020/lib/pipes/custome-dateformat.pipe.mjs +0 -27
  43. package/esm2020/lib/pipes/date-diff.pipe.mjs +0 -55
  44. package/esm2020/lib/pipes/slice-to-two.pipe.mjs +0 -34
  45. package/esm2020/lib/services/EncrypDecryp_RSA.service.mjs +0 -100
  46. package/esm2020/lib/services/async-passwordcheck.service.mjs +0 -70
  47. package/esm2020/lib/services/cookie-storage-manager.service.mjs +0 -78
  48. package/esm2020/lib/services/encrpdata.service.mjs +0 -55
  49. package/esm2020/lib/services/encrydecrydata.service.mjs +0 -205
  50. package/esm2020/lib/services/event.service.mjs +0 -132
  51. package/esm2020/lib/services/http/http-common.service.mjs +0 -245
  52. package/esm2020/lib/services/http/http-general-config.service.mjs +0 -84
  53. package/esm2020/lib/services/rest-login-form.service.mjs +0 -294
  54. package/esm2020/lib/services/rest-signalr.service.mjs +0 -104
  55. package/esm2020/lib/services/storage.service.mjs +0 -33
  56. package/esm2020/lib/services/toast-msg.service.mjs +0 -101
  57. package/esm2020/lib/services/vapt-validation.service.mjs +0 -31
  58. package/esm2020/public-api.mjs +0 -13
  59. package/fesm2015/common-header-lib.mjs +0 -4182
  60. package/fesm2015/common-header-lib.mjs.map +0 -1
  61. package/fesm2020/common-header-lib.mjs +0 -4162
  62. package/fesm2020/common-header-lib.mjs.map +0 -1
  63. package/lib/Validators/noSpaceAllowed.d.ts +0 -2
  64. package/lib/common-header-lib.component.d.ts +0 -149
  65. package/lib/common-header-lib.module.d.ts +0 -55
  66. package/lib/common-header-lib.service.d.ts +0 -25
  67. package/lib/components/confirm-dialog/confirm-dialog.component.d.ts +0 -13
  68. package/lib/components/general-configuration/general-configuration.component.d.ts +0 -86
  69. package/lib/components/general-configuration/landingpg-config/landingpg-config.component.d.ts +0 -37
  70. package/lib/components/general-configuration/timezone-configuration/timezone-configuration.component.d.ts +0 -38
  71. package/lib/components/grid-pagination/grid-pagination.component.d.ts +0 -20
  72. package/lib/components/ng-translation/ng-translation.component.d.ts +0 -21
  73. package/lib/components/no-service-my-access-pg/no-service-my-access-pg.component.d.ts +0 -8
  74. package/lib/components/notification-sidebar/notification-sidebar.component.d.ts +0 -16
  75. package/lib/components/side-popup/side-popup.component.d.ts +0 -14
  76. package/lib/components/user-mailbox/user-mailbox.component.d.ts +0 -40
  77. package/lib/components/user-sidebar/user-sidebar.component.d.ts +0 -60
  78. package/lib/components/viewpassword-popup/viewpassword-popup.component.d.ts +0 -47
  79. package/lib/model/data_model.d.ts +0 -185
  80. package/lib/pipes/custome-dateformat.pipe.d.ts +0 -8
  81. package/lib/pipes/date-diff.pipe.d.ts +0 -9
  82. package/lib/pipes/slice-to-two.pipe.d.ts +0 -7
  83. package/lib/services/EncrypDecryp_RSA.service.d.ts +0 -15
  84. package/lib/services/async-passwordcheck.service.d.ts +0 -18
  85. package/lib/services/cookie-storage-manager.service.d.ts +0 -16
  86. package/lib/services/encrpdata.service.d.ts +0 -12
  87. package/lib/services/encrydecrydata.service.d.ts +0 -33
  88. package/lib/services/event.service.d.ts +0 -30
  89. package/lib/services/http/http-common.service.d.ts +0 -40
  90. package/lib/services/http/http-general-config.service.d.ts +0 -15
  91. package/lib/services/rest-login-form.service.d.ts +0 -39
  92. package/lib/services/rest-signalr.service.d.ts +0 -23
  93. package/lib/services/storage.service.d.ts +0 -11
  94. package/lib/services/toast-msg.service.d.ts +0 -23
  95. package/lib/services/vapt-validation.service.d.ts +0 -7
  96. package/public-api.d.ts +0 -8
  97. package/src/assets/scss/_sidebar.scss +0 -267
  98. package/src/assets/scss/styles.scss +0 -577
@@ -1,4182 +0,0 @@
1
- import * as i0 from '@angular/core';
2
- import { Injectable, EventEmitter, Component, Output, Input, Pipe, ViewEncapsulation, ViewChild, NgModule } from '@angular/core';
3
- import { map, catchError, debounceTime, take, switchMap, takeUntil, finalize } from 'rxjs/operators';
4
- import * as i1 from '@angular/common/http';
5
- import { HttpParams, HttpClientModule } from '@angular/common/http';
6
- import { throwError, BehaviorSubject, Subject, map as map$1, catchError as catchError$1, of, takeUntil as takeUntil$1, finalize as finalize$1, forkJoin } from 'rxjs';
7
- import { __awaiter } from 'tslib';
8
- import * as i10$1 from 'primeng/overlaypanel';
9
- import { OverlayPanel, OverlayPanelModule } from 'primeng/overlaypanel';
10
- import * as signalR from '@microsoft/signalr';
11
- import * as i1$1 from 'ngx-cookie-service';
12
- import * as i4 from '@ngx-translate/core';
13
- import { TranslateModule } from '@ngx-translate/core';
14
- import * as i1$2 from 'ngx-toastr';
15
- import * as i6 from '@angular/common';
16
- import { DatePipe, CommonModule } from '@angular/common';
17
- import * as i2 from '@angular/forms';
18
- import { FormGroup, Validators, ReactiveFormsModule } from '@angular/forms';
19
- import * as i8 from 'primeng/dropdown';
20
- import { DropdownModule } from 'primeng/dropdown';
21
- import * as i9 from 'primeng/api';
22
- import { ConfirmationService } from 'primeng/api';
23
- import * as i11 from 'primeng/badge';
24
- import { BadgeModule } from 'primeng/badge';
25
- import * as i9$1 from 'primeng/skeleton';
26
- import { SkeletonModule } from 'primeng/skeleton';
27
- import * as i1$3 from 'primeng/dynamicdialog';
28
- import { DialogService } from 'primeng/dynamicdialog';
29
- import * as CryptoJS from 'crypto-js';
30
- import JSEncrypt from 'jsencrypt';
31
- import { decode } from '@msgpack/msgpack';
32
- import * as bigintCryptoUtils from 'bigint-crypto-utils';
33
- import * as i13 from 'primeng/inputtext';
34
- import { InputTextModule } from 'primeng/inputtext';
35
- import * as i10 from 'primeng/button';
36
- import { ButtonModule } from 'primeng/button';
37
- import * as i3 from '@angular/router';
38
- import * as i1$4 from 'primeng/dialog';
39
- import { DialogModule } from 'primeng/dialog';
40
- import * as i9$2 from 'primeng/table';
41
- import { TableModule } from 'primeng/table';
42
- import * as i1$5 from 'primeng/paginator';
43
- import { PaginatorModule } from 'primeng/paginator';
44
- import * as i2$1 from 'primeng/confirmdialog';
45
- import { ConfirmDialogModule } from 'primeng/confirmdialog';
46
- import { NgbModule } from '@ng-bootstrap/ng-bootstrap';
47
-
48
- class GlobalConstants {
49
- }
50
- GlobalConstants.COOKIEDELETEVENT = 'd';
51
- GlobalConstants.ALLCOOKIEDELET = '-100';
52
- GlobalConstants.TimeForEncToken = 30;
53
- GlobalConstants.AgGridPaginationSize = 50;
54
- GlobalConstants.reconcileServiceLimit = 100;
55
- GlobalConstants.applicationName = 'Converged IAM';
56
- GlobalConstants.publicKey = '';
57
- GlobalConstants.PAMPluginURL = 'http://localhost:55755/';
58
- GlobalConstants.APPName = 'workspace';
59
- GlobalConstants.PlugInDownloadURL = 'https://hfarcon.arconnet.com/helppageui/';
60
- GlobalConstants.cipluginversion = '';
61
- GlobalConstants.localInstalledCIPluginVersion = ''; // to store installed CI plugin version
62
- GlobalConstants.PCI_DSS_Standard = false;
63
- GlobalConstants.TOKENTIME = 30;
64
- GlobalConstants.LOGOUTIMER = 60;
65
- GlobalConstants.PAGEROW = 10;
66
- GlobalConstants.CONFIGCONNECTORS = false;
67
- GlobalConstants.USERLANGUAGES = [
68
- { langKey: 'en', langName: 'English' },
69
- { langKey: 'hi', langName: 'हिन्दी' },
70
- { langKey: 'mr', langName: 'मराठी' },
71
- { langKey: 'ar', langName: 'العربية' },
72
- { langKey: 'fr', langName: 'Français' },
73
- { langKey: 'es', langName: 'Español' },
74
- { langKey: 'de', langName: 'Deutsch' },
75
- { langKey: 'ja', langName: '日本語' },
76
- { langKey: 'ko', langName: '한국어' },
77
- { langKey: 'zh', langName: '中文' },
78
- { langKey: 'ru', langName: 'Русский' },
79
- { langKey: 'pt', langName: 'Português' },
80
- { langKey: 'it', langName: 'Italiano' },
81
- { langKey: 'nl', langName: 'Nederlands' },
82
- { langKey: 'tr', langName: 'Türkçe' },
83
- { langKey: 'sv', langName: 'Svenska' },
84
- { langKey: 'pl', langName: 'Polski' },
85
- { langKey: 'th', langName: 'ไทย' },
86
- { langKey: 'vi', langName: 'Tiếng Việt' },
87
- ];
88
- GlobalConstants.USERFILTEREDLANGUAGES = [];
89
- GlobalConstants.DEFAULTLANG = { langKey: 'en', langName: 'English' };
90
- GlobalConstants.DEFAULTLANGKEY = 'en';
91
- GlobalConstants.DEFAULT_IMGPATH = 'assets/images/';
92
- GlobalConstants.DEFAULT_BGIMG = `${GlobalConstants.DEFAULT_IMGPATH}login-bg/default_bg.svg`;
93
- GlobalConstants.DEFAULT_LOGO = `${GlobalConstants.DEFAULT_IMGPATH}default_logo.svg`;
94
- GlobalConstants.IMG_CODE = 'data:image/png;base64,';
95
- GlobalConstants.DYNAMIC_LOGO = '';
96
- GlobalConstants.DYNAMIC_BGIMG = '';
97
- GlobalConstants.APP_VERSION = '';
98
- class LoggedInUserInfo {
99
- static setPrivateKeyFromBigInts(arr) {
100
- this.privateKey = arr.map((b) => b.toString()).join(',');
101
- }
102
- }
103
- LoggedInUserInfo.domainName = null;
104
- LoggedInUserInfo.domainId = 0;
105
- class RoutePaths {
106
- }
107
- RoutePaths.LOGINPG_PATH = 'login';
108
- RoutePaths.WINDOW_AUTH = 'domainauth';
109
- RoutePaths.OTHER_METHODS_PATH = 'othermethods';
110
- RoutePaths.MY_ACCESS_PATH = 'my-access';
111
- RoutePaths.FORGOT_PASSWORD_PATH = 'forgotpassword';
112
- RoutePaths.AUTH_STATUS_PATH = 'auth-status';
113
- RoutePaths.LOGOUT_PATH = 'logout';
114
- RoutePaths.PAGE_NOT_FOUND_PATH = 'page-not-found';
115
- RoutePaths.INTERNAL_SERVER_ERROR_PATH = 'internal-server-error';
116
- RoutePaths.ERROR_PATH = 'error';
117
- RoutePaths.AUTH_LOADING = 'session-verify';
118
- class errorMsg {
119
- }
120
- errorMsg.NOASSET = `No assets have been assigned to the user in the selected LOB. Please select a different LOB.`;
121
- errorMsg.NORECENTASSET = `No recently accessed Asset found.`;
122
- errorMsg.NOSEARCHRESULT = `We couldn't find any service matching your search within the chosen LOB. Try refining your keywords or choosing a different LOB for better results'`;
123
- errorMsg.NOMAILFOUND = `We couldn't find any mails assigned to you`;
124
- errorMsg.SERVERDOWN = `Something Went Wrong, Please Try Again later`;
125
- errorMsg.NOCIPLUGIN = `Install the CI Plugin or Contact Administrator`;
126
- errorMsg.CIPLUGINVERSIONISSUE = `Kindly Install latest version of CI Plugin`;
127
- errorMsg.ADMINMSG = `Kindly Contact Administrator`;
128
- errorMsg.PLUGINMSG = `Kindly check below link for downloadables.`;
129
- errorMsg.PAMPLUGINBTN = `Install the CI Plugin or Contact Administrator`;
130
- errorMsg.USERNOTFOUND = `Invalid User Details`;
131
- errorMsg.TIMEZONESUCCESS = `Time Zone Updated SuccessFully`;
132
- errorMsg.TIMEZONERROR = `Time Zone Updated Couldn't Update`;
133
- errorMsg.LOGOUTERROR = 'Logout Attempt Failed';
134
- errorMsg.ASSETSTATUS = 'Asset Under Maintenance';
135
- errorMsg.REFERENCEPOPUPTITLE = 'Reference Case ID for Accessing Asset';
136
- errorMsg.DICREDENTIALINFO = 'Digital Identity Credentials Updated Successfully';
137
- errorMsg.DICREDENTIALERROR = "Digital Identity Credentials Couldn't updated";
138
- errorMsg.PATHSUCCESS = 'Preference Path Updated SuccessFully';
139
- errorMsg.PATHERROR = "Preference Path Couldn't Update";
140
- errorMsg.USERCREDENIALERROR = 'Configure Credentials';
141
- errorMsg.CREDENIALERROR = 'Kindly Configure Credentials';
142
- errorMsg.ADMINCREDENIALERROR = 'The credentials have yet to be configured by the Admin';
143
- errorMsg.COMMONError = 'Something Went Wrong !';
144
- errorMsg.NODIGITALIDENTITES = 'There are no digital identities assigned. Kindly contact administrator.';
145
- errorMsg.SEARCHTEXT = 'Search Results';
146
- errorMsg.MFACONFIGUREERROR = 'MFA is not configured for the user, Please contact the system administrator';
147
- errorMsg.SESSIONIDERROR = 'Session Service ID not found';
148
- errorMsg.CHROMEEXTENSIONERROR = 'Kindly Install the CI Extension or Contact Administrator';
149
- errorMsg.WINDOW_DOMAIN_LOGINERR = 'Please wait, Domain Authentication is in progress for your login';
150
- errorMsg.LANDINGPGSUCCESS = `Landing Page Configured SuccessFully`;
151
- errorMsg.LANDINGPGERROR = `Landing Page Configuration Couldn't Update`;
152
- errorMsg.SCRIPTERROR = `Unexpected Script Detected`;
153
- class COOKIECONSTANT {
154
- }
155
- COOKIECONSTANT.LOBNAME = 'lobdata';
156
- COOKIECONSTANT.DOMAINAME = 'domainname';
157
- COOKIECONSTANT.DOMAINID = 'domainid';
158
- COOKIECONSTANT.USERDETAILS = 'UserDetail';
159
- COOKIECONSTANT.SESSIONID = 'userSessionId';
160
- COOKIECONSTANT.USERNAME = 'username';
161
- COOKIECONSTANT.USERID = 'userId';
162
- COOKIECONSTANT._AT = '_AT';
163
- COOKIECONSTANT._RT = '_RT';
164
- COOKIECONSTANT.USERDISPLAYNAME = 'userDisplayName';
165
- COOKIECONSTANT.ENCRYPTEDKEY = 'EncryptedKey';
166
- COOKIECONSTANT.MFASTATUS = 'MFAStatus';
167
- COOKIECONSTANT.EVENTNAME = 'Event';
168
- COOKIECONSTANT.MACHINEDETAILS = 'machinedetails';
169
- COOKIECONSTANT.COOKIEDELETEVENT = 'd';
170
- COOKIECONSTANT.COOKIECREATEEVENT = 'c';
171
- COOKIECONSTANT.COOKIEUPDATEEVENT = 'c';
172
- COOKIECONSTANT.ALLCOOKIEDELET = '-100';
173
- COOKIECONSTANT.NEWUSER = '003-NU-GEC';
174
- COOKIECONSTANT.UNLOCKACC = 'Unlock';
175
- COOKIECONSTANT.ERRORCODE = '001-SAC-GEC';
176
- COOKIECONSTANT.PUBLICCODE = '001-PUB-GEC';
177
- COOKIECONSTANT.USERLANG = 'lang';
178
- COOKIECONSTANT.MFATIMEOUT = 180000; //3 mins
179
- COOKIECONSTANT.MFASTATUSCHECK = '_ssmf';
180
- COOKIECONSTANT.MFASTATUSCHECKFAIL = '_ssmff';
181
- COOKIECONSTANT.MFACLI = '_SSIDMFACLI';
182
- COOKIECONSTANT.WINDOWAUTH_HEADER = 'Authentication-Window';
183
- COOKIECONSTANT.SIGNALR_INDEX = '002-SR-NO';
184
- COOKIECONSTANT.ONETIME_TOKEN = 'state';
185
- COOKIECONSTANT.THICKCLIENT_KEY = 'APP_VER';
186
- const EXCLUDED_URLS = [
187
- 'http://localhost:55755/',
188
- 'workflow/api/Workflow/Workflow/GetWorkFlowTicketCount',
189
- 'workflow/api/Workflow/Workflow/GetWorkFlowTicketCountEventWise',
190
- 'xaccess/api/SecureAccess/GetBackgroundImage',
191
- 'xaccess/api/SecureAccess/UpdateLogoutTimer',
192
- ];
193
- class MFAEvent {
194
- }
195
- MFAEvent.ForgotPwd = 1;
196
- MFAEvent.unlockAcc = 2;
197
- MFAEvent.Login = 3;
198
- class BrowserName {
199
- }
200
- BrowserName.Chrome = 'Chrome';
201
- BrowserName.Firefox = 'Firefox';
202
- BrowserName.Edge = 'Edge';
203
- BrowserName.Safari = 'Safari';
204
- BrowserName.Opera = 'Opera';
205
- BrowserName.InterNetExp = 'Internet Explorer';
206
- // GetLocalIPAddress
207
- // GetLocalMACAddress
208
- // GetProcessorID
209
- // GetBIOSSerialID
210
- // GetDomainName
211
- // GetPAMPluginInstalledVersion
212
- //GetLocalHostName
213
- class PAMParameter {
214
- constructor() {
215
- this.ipAddress = '';
216
- this.macAddress = '';
217
- this.processorID = '';
218
- this.bIOSSerialID = '';
219
- this.domainName = '';
220
- this.hostname = '';
221
- this.pAMPluginInstalledVersion = '';
222
- }
223
- }
224
- // "Status : for user status
225
- // Active = 0,
226
- // NewUserCreated = 1,
227
- // ResetbyAdmin = 2,
228
- // LockedOut = 5,
229
- // Dormant = 4,
230
- // Disabled = 3
231
- // Suspended = 6,
232
- // Sabbatical = 7 ,
233
- // ACMO CLI Priviledge not assigned=9"
234
- // export const loginStatusMsg = {
235
- // 0: {
236
- // status: 'Active',
237
- // msg: 'Successfull login',
238
- // },
239
- // 1: {
240
- // status: 'NewUserCreated',
241
- // msg: 'New Created User',
242
- // },
243
- // 2: {
244
- // status: 'ResetbyAdmin',
245
- // msg: 'Password Is Reset By Admin',
246
- // },
247
- // 3: {
248
- // status: 'Disabled',
249
- // msg: 'User is Disabled',
250
- // },
251
- // 4: {
252
- // status: 'Dormant',
253
- // msg: 'User is Dormant',
254
- // },
255
- // 5: {
256
- // status: 'LockedOut',
257
- // msg: 'User is Locked Out',
258
- // },
259
- // 6: {
260
- // status: 'Suspended',
261
- // msg: 'User is Suspended',
262
- // },
263
- // 7: {
264
- // status: 'Sabbatical',
265
- // msg: 'User is Sabbatical',
266
- // },
267
- // 9: {
268
- // status: 'ACMO CLI Priviledge not assigned',
269
- // msg: '',
270
- // },
271
- // 11: {
272
- // status: 'Invalid User',
273
- // msg: 'Invalid User Name OR Password',
274
- // },
275
- // };
276
-
277
- class CommonHeaderLibService {
278
- constructor(http) {
279
- this.http = http;
280
- this.apiUrl = '';
281
- }
282
- getGlobalTimeZone() {
283
- return this.http
284
- .get(GlobalConstants.baseURL + 'xaccess/api/SecureAccess/GetSystemTimeZones')
285
- .pipe(map((response) => {
286
- if (response && response['success']) {
287
- return response['result'];
288
- }
289
- else {
290
- return [];
291
- }
292
- }));
293
- }
294
- getLoggedInUserDetails(url) {
295
- return this.http
296
- .post(url + 'xaccess/api/SecureAccess/GetUsersDetailsById', {})
297
- .pipe(map((response) => {
298
- // return response['result'];
299
- return response;
300
- }));
301
- }
302
- getLOBList(url) {
303
- return this.http.get(url + 'meta/api/metadata/Lobs').pipe(map((response) => {
304
- let result = [];
305
- if (response['statusCode'] === 200) {
306
- // let result = response['result'];
307
- let result = response;
308
- return result;
309
- }
310
- }));
311
- }
312
- getUserAssignedApps(url) {
313
- return this.http
314
- .post(url + 'xaccess/api/SecureAccess/GetUserPriviledgesList', {})
315
- .pipe(map((response) => {
316
- if (response && response['success']) {
317
- return response['result'].filter((x) => x.appCode != null
318
- // (x) => x.appCode !== 'APP026' && x.appCode != null
319
- );
320
- }
321
- else {
322
- return [];
323
- }
324
- }));
325
- }
326
- getUnreadUserEmailsCount(url) {
327
- return this.http.get(url + 'xservice/api/CIInfraAsset/MailBoxCount').pipe(map((response) => {
328
- if (response && response['success'] && response['result'] > 0) {
329
- return response['result'];
330
- }
331
- else {
332
- return 0;
333
- }
334
- }));
335
- }
336
- getUserAssignedMails(userDetails, url) {
337
- return this.http
338
- .post(url + 'xservice/api/CIInfraAsset/MailBox', userDetails)
339
- .pipe(map((response) => {
340
- if (response && response['success']) {
341
- return response['result'];
342
- }
343
- else {
344
- return [];
345
- }
346
- }));
347
- }
348
- getWorkFlowTicketEventwiseCount(userDetails, url) {
349
- return this.http
350
- .post(url + 'workflow/api/Workflow/Workflow/GetWorkFlowTicketCountEventWise', userDetails)
351
- .pipe(map((response) => {
352
- if (response && response[0]['Success']) {
353
- return response[0]['Data'];
354
- }
355
- else {
356
- return [];
357
- }
358
- }), catchError((e) => throwError(this.errorHandler(e))));
359
- }
360
- errorHandler(e) {
361
- throw new Error('Method not implemented.');
362
- }
363
- getUserPreferredAssetTypeDetails(url) {
364
- return this.http
365
- .get(url + 'xaccess/api/PagePreference/GetAssetTypeDetails')
366
- .pipe(map((response) => {
367
- if (response && response['success']) {
368
- return response['result'];
369
- }
370
- else {
371
- return [];
372
- }
373
- }), catchError((e) => throwError(this.errorHandler(e))));
374
- }
375
- getUserPreferredAssetName(payload, url) {
376
- return this.http
377
- .post(url + 'xaccess/api/PagePreference/GetAssetName', payload)
378
- .pipe(map((response) => {
379
- if (response && response['success']) {
380
- return response['result'];
381
- }
382
- else {
383
- return [];
384
- }
385
- }), catchError((e) => throwError(this.errorHandler(e))));
386
- }
387
- getServiceNameByAssetTypeEvent(payload, url) {
388
- return this.http
389
- .post(url + 'xaccess/api/PagePreference/GetServiceDetails', payload)
390
- .pipe(map((response) => {
391
- if (response && response['success']) {
392
- return response['result'];
393
- }
394
- else {
395
- return [];
396
- }
397
- }), catchError((e) => throwError(this.errorHandler(e))));
398
- }
399
- getPreferencePathDetails(payload, url) {
400
- return this.http
401
- .post(url + 'xaccess/api/PagePreference/CurrentPreferencepathDetails', payload)
402
- .pipe(map((response) => {
403
- if (response && response['success']) {
404
- return response['result'];
405
- }
406
- else {
407
- return {};
408
- }
409
- }), catchError((e) => throwError(this.errorHandler(e))));
410
- }
411
- updatePreferencePath(payload, url) {
412
- return this.http
413
- .post(url + 'xaccess/api/PagePreference/UpdatePreferencePath', payload)
414
- .pipe(map((response) => {
415
- if (response && response['success']) {
416
- return true;
417
- }
418
- else {
419
- return false;
420
- }
421
- }), catchError((e) => throwError(this.errorHandler(e))));
422
- }
423
- updateUserTimeZone(tz, url) {
424
- const params = new HttpParams().set('timezone', tz);
425
- return this.http
426
- .post(url + 'xaccess/api/SecureAccess/UpdateTimeZone', {}, { params: params })
427
- .pipe(map((response) => {
428
- if (response && response['success']) {
429
- return response['result'];
430
- }
431
- else {
432
- return '';
433
- }
434
- }), catchError((e) => throwError(this.errorHandler(e))));
435
- }
436
- setLandingPgPreference(moduleId, url) {
437
- return this.http
438
- .post(url + 'xaccess/api/SecureAccess/SetLandingPage', {
439
- moduleId: moduleId,
440
- })
441
- .pipe(map((response) => {
442
- if (response && response['success']) {
443
- return response['result'];
444
- }
445
- else {
446
- return '';
447
- }
448
- }), catchError((e) => throwError(this.errorHandler(e))));
449
- }
450
- getInitiateUserLogout() {
451
- return this.http.post(GlobalConstants.baseURL + 'xaccess/api/SecureAccess/logout', {}).pipe(map((response) => {
452
- if (response && response['success']) {
453
- return response['result'];
454
- }
455
- else {
456
- return {};
457
- }
458
- }), catchError((e) => throwError(this.errorHandler(e))));
459
- }
460
- }
461
- CommonHeaderLibService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: CommonHeaderLibService, deps: [{ token: i1.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable });
462
- CommonHeaderLibService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: CommonHeaderLibService, providedIn: 'root' });
463
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: CommonHeaderLibService, decorators: [{
464
- type: Injectable,
465
- args: [{
466
- providedIn: 'root',
467
- }]
468
- }], ctorParameters: function () { return [{ type: i1.HttpClient }]; } });
469
-
470
- class StorageService {
471
- constructor() { }
472
- saveData(key, value) {
473
- localStorage.setItem(key, value);
474
- }
475
- getData(key) {
476
- return localStorage.getItem(key);
477
- }
478
- removeData(key) {
479
- localStorage.removeItem(key);
480
- }
481
- clearData() {
482
- localStorage.clear();
483
- }
484
- checkData(key) {
485
- const data = localStorage.getItem(key);
486
- if (data) {
487
- return true;
488
- }
489
- return false;
490
- }
491
- }
492
- StorageService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: StorageService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
493
- StorageService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: StorageService, providedIn: 'root' });
494
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: StorageService, decorators: [{
495
- type: Injectable,
496
- args: [{
497
- providedIn: 'root',
498
- }]
499
- }], ctorParameters: function () { return []; } });
500
-
501
- class EncrpdataService {
502
- constructor() {
503
- // private publicKey: string =
504
- // '10234186980819816859565723471972110581900468266056266385607156653250136308259057583501560583440295112186917105135474383769292631464432088817050933329522683,65537';
505
- this.privateKey = "";
506
- }
507
- getASCIIValue(text) {
508
- let charCodeArr = [];
509
- for (let i = 0; i < text.length; i++) {
510
- let code = text.charCodeAt(i);
511
- charCodeArr.push(BigInt(code));
512
- }
513
- return charCodeArr;
514
- }
515
- getModuleValue(arr, num1, num2) {
516
- let numArr = [];
517
- for (let i = 0; i < arr.length; i++) {
518
- let code = Math.pow(arr[i], num2) % num1;
519
- numArr.push(code);
520
- }
521
- return numArr;
522
- }
523
- getEncrpytedData(text) {
524
- this.privateKey = LoggedInUserInfo.privateKey;
525
- let key = this.privateKey.split(',');
526
- const num1 = BigInt(key[0]);
527
- const num2 = BigInt(key[1]);
528
- //1. Convert string to phiN
529
- let asciiValue = this.getASCIIValue(text);
530
- //2. Get Mod of All Value
531
- let ModValue = this.getModuleValue(asciiValue, num1, num2);
532
- //3. Convert Arr to String
533
- // let encodedText = ModValue.join('-');
534
- const encodedText = ModValue.map(b => b.toString()).join('-');
535
- return encodedText;
536
- }
537
- encodeToBase64(text) {
538
- return btoa(text);
539
- }
540
- decodeToBase64(text) {
541
- return atob(text);
542
- }
543
- }
544
- EncrpdataService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: EncrpdataService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
545
- EncrpdataService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: EncrpdataService, providedIn: 'root' });
546
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: EncrpdataService, decorators: [{
547
- type: Injectable,
548
- args: [{
549
- providedIn: 'root',
550
- }]
551
- }], ctorParameters: function () { return []; } });
552
-
553
- // import { CookieStorageManagerService } from '../cookie-storage-manager.service';
554
- class RestSignalRService {
555
- constructor(_localStorage, _encrpdataService) {
556
- this._localStorage = _localStorage;
557
- this._encrpdataService = _encrpdataService;
558
- this.eventMsg = new BehaviorSubject({});
559
- this.AuthToken = '';
560
- this.hubURLS = [];
561
- //Method: Established the Connection With SignalR to get RealTime Data
562
- this.establishedConnection = () => __awaiter(this, void 0, void 0, function* () {
563
- this.hubConnection = new signalR.HubConnectionBuilder()
564
- .withUrl(`${GlobalConstants.signalRURL}/chatHub`, {
565
- skipNegotiation: true,
566
- transport: signalR.HttpTransportType.WebSockets,
567
- headers: { Authorization: `Bearer ${this.AuthToken}` },
568
- })
569
- .build();
570
- try {
571
- yield this.hubConnection.start();
572
- //* SignalR connection established successfully
573
- this.addMessageListener();
574
- }
575
- catch (error) {
576
- console.error('Error establishing SignalR connection:', error);
577
- throw error;
578
- }
579
- });
580
- }
581
- initializeSignalRConnection() {
582
- return __awaiter(this, void 0, void 0, function* () {
583
- if (!GlobalConstants.signalRURL) {
584
- throw new Error('No hub URLs provided');
585
- }
586
- this.hubURLS = GlobalConstants.signalRURL
587
- ? GlobalConstants.signalRURL.split(',')
588
- : [];
589
- if (this.hubURLS.length === 1) {
590
- GlobalConstants.signalRURL = this.hubURLS[0];
591
- yield this.establishedConnection();
592
- return;
593
- }
594
- let lastUsedIndex = this.getLastUsedIndex();
595
- for (let i = 0; i < this.hubURLS.length; i++) {
596
- const index = (lastUsedIndex + i) % this.hubURLS.length;
597
- GlobalConstants.signalRURL = this.hubURLS[index];
598
- try {
599
- yield this.establishedConnection();
600
- this.setLastUsedIndex(index + 1); // Update for next round
601
- break; // Exit the loop if connection is successful
602
- }
603
- catch (error) {
604
- console.error(`Error connecting to hub ${this.hubURLS[index]}:`, error);
605
- }
606
- }
607
- if (!this.hubConnection) {
608
- throw new Error('All SignalR connections failed');
609
- }
610
- });
611
- }
612
- addMessageListener() {
613
- this.hubConnection.on('ReceiveMessage', (user, data) => {
614
- data = JSON.parse(data);
615
- this.emitEventMsg(data);
616
- });
617
- }
618
- emitEventMsg(data) {
619
- this.eventMsg.next(data);
620
- }
621
- listenerEventMsg() {
622
- return this.eventMsg.asObservable();
623
- }
624
- getLastUsedIndexv1() {
625
- const lastIndex = this._localStorage.getData(COOKIECONSTANT.SIGNALR_INDEX);
626
- return lastIndex
627
- ? Number(this._encrpdataService.decodeToBase64(lastIndex)) || 0
628
- : 0;
629
- }
630
- getLastUsedIndex() {
631
- const lastIndex = this._localStorage.getData(COOKIECONSTANT.SIGNALR_INDEX);
632
- return lastIndex
633
- ? Number(this._encrpdataService.decodeToBase64(lastIndex)) || 0
634
- : 0;
635
- }
636
- setLastUsedIndex(index) {
637
- const lastIndex = this._encrpdataService.encodeToBase64(index.toString());
638
- this._localStorage.saveData(COOKIECONSTANT.SIGNALR_INDEX, lastIndex);
639
- }
640
- }
641
- RestSignalRService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: RestSignalRService, deps: [{ token: StorageService }, { token: EncrpdataService }], target: i0.ɵɵFactoryTarget.Injectable });
642
- RestSignalRService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: RestSignalRService, providedIn: 'root' });
643
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: RestSignalRService, decorators: [{
644
- type: Injectable,
645
- args: [{
646
- providedIn: 'root',
647
- }]
648
- }], ctorParameters: function () { return [{ type: StorageService }, { type: EncrpdataService }]; } });
649
-
650
- class EventService {
651
- constructor(_cookie) {
652
- this._cookie = _cookie;
653
- this.getUserLOB = new BehaviorSubject({});
654
- this.getAssetType = new BehaviorSubject({});
655
- this.refreshSidebar = new BehaviorSubject({});
656
- this.filterRecords = new Subject();
657
- this.AuthMethods = new BehaviorSubject([]);
658
- this.refreshEmails = new BehaviorSubject({});
659
- this.timeZone = new BehaviorSubject({});
660
- }
661
- emitLOBEvent(data) {
662
- this.getUserLOB.next(data);
663
- }
664
- listenerLOBEvent() {
665
- return this.getUserLOB.asObservable();
666
- }
667
- emitAssetTypeEvent(data) {
668
- this.getAssetType.next(data);
669
- }
670
- listenerAssetTypeEvent() {
671
- return this.getAssetType.asObservable();
672
- }
673
- emitrefreshSidebar(data) {
674
- this.refreshSidebar.next(data);
675
- }
676
- listenerrefreshSidebar() {
677
- return this.refreshSidebar.asObservable();
678
- }
679
- emitFilterRecords(data) {
680
- this.filterRecords.next(data);
681
- }
682
- listenerFilterEvent() {
683
- return this.filterRecords.asObservable();
684
- }
685
- emitAuthMethod(data) {
686
- this.AuthMethods.next(data);
687
- }
688
- listenerAuthMethod() {
689
- return this.AuthMethods.asObservable();
690
- }
691
- emitUserEmail(data) {
692
- this.refreshEmails.next(data);
693
- }
694
- listenerUserEmail() {
695
- return this.refreshEmails.asObservable();
696
- }
697
- emitTimezone(data) {
698
- this.timeZone.next(data);
699
- }
700
- listenerTimezone() {
701
- return this.timeZone.asObservable();
702
- }
703
- // checkMFAv1(mfaUrl: string) {
704
- // return new Promise((resolve, reject) => {
705
- // const params = `scrollbars=no,resizable=no,status=no,location=no,toolbar=no,menubar=no,
706
- // width=600,height=500,left=350,top=150`;
707
- // const mfaWindow = open(mfaUrl, 'CI Authentication', params);
708
- // //setInterval to check cookie every second
709
- // const interval = setInterval(() => {
710
- // if (this._cookie.get(COOKIECONSTANT.MFASTATUSCHECK)) {
711
- // clearInterval(interval);
712
- // // clearTimeout(timeout);
713
- // mfaWindow.close();
714
- // resolve(true);
715
- // }
716
- // else if (this._cookie.get(COOKIECONSTANT.MFASTATUSCHECKFAIL)) {
717
- // clearInterval(interval);
718
- // mfaWindow.close();
719
- // reject(false);
720
- // }
721
- // }, 1000);
722
- // //when use close window manually
723
- // let flag = false;
724
- // mfaWindow.onunload = () => {
725
- // if (flag) {
726
- // clearInterval(interval);
727
- // // clearTimeout(timeout);
728
- // reject(false);
729
- // }
730
- // flag = true;
731
- // }
732
- // })
733
- // }
734
- checkMFA(mfaUrl) {
735
- return new Promise((resolve, reject) => {
736
- const params = `scrollbars=no,resizable=no,status=no,location=no,toolbar=no,menubar=no,
737
- width=600,height=500,left=350,top=150`;
738
- const mfaWindow = window.open(mfaUrl, 'CI Authentication', params);
739
- if (!mfaWindow) {
740
- reject(new Error('Failed to open MFA window. Popup blocked?'));
741
- return;
742
- }
743
- // Polling interval to check cookie every second
744
- const interval = setInterval(() => {
745
- if (this._cookie.get(COOKIECONSTANT.MFASTATUSCHECK)) {
746
- clearInterval(interval);
747
- mfaWindow.close();
748
- resolve(true);
749
- }
750
- else if (this._cookie.get(COOKIECONSTANT.MFASTATUSCHECKFAIL)) {
751
- clearInterval(interval);
752
- mfaWindow.close();
753
- reject(false);
754
- }
755
- }, 1000);
756
- // Detect manual close of popup window
757
- const checkPopupClosed = setInterval(() => {
758
- if (mfaWindow.closed) {
759
- clearInterval(interval);
760
- clearInterval(checkPopupClosed);
761
- reject(false);
762
- }
763
- }, 500);
764
- });
765
- }
766
- }
767
- EventService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: EventService, deps: [{ token: i1$1.CookieService }], target: i0.ɵɵFactoryTarget.Injectable });
768
- EventService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: EventService, providedIn: 'root' });
769
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: EventService, decorators: [{
770
- type: Injectable,
771
- args: [{
772
- providedIn: 'root',
773
- }]
774
- }], ctorParameters: function () { return [{ type: i1$1.CookieService }]; } });
775
-
776
- class HttpCommonService {
777
- constructor(http) {
778
- this.http = http;
779
- this.xAccessAPIUrl = '/xaccess/api/SecureAccess/';
780
- this.metaAPIUrl = '/meta/api/metadata/';
781
- this.metaAPIUrl1 = '/meta/api/Metadata/';
782
- this.xServiceAPIUrl = '/xservice/api/CIInfraAsset/';
783
- this.workflowAPIUrl = '/workflow/api/Workflow/Workflow/';
784
- }
785
- getLogo() {
786
- return this.http
787
- .get(`${GlobalConstants.baseURL}${this.xAccessAPIUrl}BackgroundLogo`)
788
- .pipe(map$1((response) => {
789
- return response['result'];
790
- }));
791
- }
792
- getGlobalTimeZone() {
793
- return this.http
794
- .get(`${GlobalConstants.baseURL}${this.xAccessAPIUrl}GetSystemTimeZones`)
795
- .pipe(map$1((response) => {
796
- if (response && response['success']) {
797
- return response['result'];
798
- }
799
- else {
800
- return [];
801
- }
802
- }));
803
- }
804
- updateUserTimeZone(tz) {
805
- const params = new HttpParams().set('timezone', tz);
806
- return this.http
807
- .post(`${GlobalConstants.baseURL}${this.xAccessAPIUrl}UpdateTimeZone`, {}, { params: params })
808
- .pipe(map$1((response) => {
809
- if (response && response['success']) {
810
- return response['result'];
811
- }
812
- else {
813
- return '';
814
- }
815
- }));
816
- }
817
- getLOBList() {
818
- return this.http
819
- .get(`${GlobalConstants.baseURL}${this.metaAPIUrl}Lobs`)
820
- .pipe(map$1((response) => {
821
- return response;
822
- }));
823
- }
824
- getUnreadUserEmailsCount() {
825
- return this.http
826
- .get(`${GlobalConstants.baseURL}${this.xServiceAPIUrl}MailBoxCount`)
827
- .pipe(map$1((response) => {
828
- if (response && response['success'] && response['result'] > 0) {
829
- return response['result'];
830
- }
831
- else {
832
- return 0;
833
- }
834
- }));
835
- }
836
- getUserAssignedMails(userDetails) {
837
- return this.http
838
- .post(`${GlobalConstants.baseURL}${this.xServiceAPIUrl}MailBox`, userDetails)
839
- .pipe(map$1((response) => {
840
- if (response && response['success']) {
841
- return response['result'];
842
- }
843
- else {
844
- return [];
845
- }
846
- }));
847
- }
848
- /*Method : GET
849
- Action : Get Application Password */
850
- getAccessToViewServicePassword(mailDetails) {
851
- return this.http
852
- .post(`${GlobalConstants.baseURL}${this.xServiceAPIUrl}OpenServicePwd`, mailDetails)
853
- .pipe(map$1((response) => {
854
- if (response && response['success']) {
855
- response['result'][1] = response['message'];
856
- return response['result'];
857
- }
858
- else {
859
- return [];
860
- }
861
- }), catchError$1((e) => throwError(this.errorHandler(e))));
862
- }
863
- getUserAssignedApps() {
864
- return this.http
865
- .post(`${GlobalConstants.baseURL}${this.xAccessAPIUrl}GetUserPriviledgesList`, {})
866
- .pipe(map$1((response) => {
867
- if (response && response['success']) {
868
- return response['result'].filter((x) => x.appCode != null);
869
- }
870
- else {
871
- return [];
872
- }
873
- }));
874
- }
875
- getLoggedInUserDetails() {
876
- return this.http
877
- .post(`${GlobalConstants.baseURL}${this.xAccessAPIUrl}GetUsersDetailsById`, {})
878
- .pipe(map$1((response) => {
879
- return response;
880
- }));
881
- }
882
- //Method: Used to Total Notification count of user
883
- //Action: It used get all notification count
884
- getWorkFlowTicketCount(userDetails) {
885
- return this.http
886
- .post(`${GlobalConstants.baseURL}${this.workflowAPIUrl}GetWorkFlowTicketCount`, userDetails)
887
- .pipe(map$1((response) => {
888
- if (response && response[0]['Success']) {
889
- if (response[0]['Data'][0]) {
890
- return response[0]['Data'][0];
891
- }
892
- else {
893
- return {};
894
- }
895
- }
896
- else {
897
- return {};
898
- }
899
- }), catchError$1((e) => throwError(this.errorHandler(e))));
900
- }
901
- getWorkFlowTicketEventwiseCount(userDetails) {
902
- return this.http
903
- .post(`${GlobalConstants.baseURL}${this.workflowAPIUrl}GetWorkFlowTicketCountEventWise`, userDetails)
904
- .pipe(map$1((response) => {
905
- if (response && response[0]['Success']) {
906
- return response[0]['Data'];
907
- // return [];
908
- }
909
- else {
910
- return [];
911
- }
912
- }));
913
- }
914
- setLandingPgPreference(moduleId) {
915
- return this.http
916
- .post(`${GlobalConstants.baseURL}${this.xAccessAPIUrl}SetLandingPage`, {
917
- moduleId: moduleId,
918
- })
919
- .pipe(map$1((response) => {
920
- if (response && response['success']) {
921
- return response['result'];
922
- }
923
- else {
924
- return '';
925
- }
926
- }));
927
- }
928
- /*Method : POST
929
- Action :Will validate User entered PWD as
930
- per Password Policy Set
931
- */
932
- validatePassword(userDetails) {
933
- return this.http
934
- .post(`${GlobalConstants.baseURL}${this.xAccessAPIUrl}ValidatePassword`, userDetails)
935
- .pipe(catchError$1((e) => throwError(this.errorHandler(e))));
936
- }
937
- /*Method : POST
938
- Action : RESET Password for First Time User
939
- */
940
- setNewpassword(loggedInUserDetails) {
941
- return this.http
942
- .post(`${GlobalConstants.baseURL}${this.xAccessAPIUrl}ChangeUserArcXwdManually`, loggedInUserDetails)
943
- .pipe(catchError$1((e) => throwError(this.errorHandler(e))));
944
- }
945
- errorHandler(e) {
946
- throw new Error('Method not implemented.');
947
- }
948
- /*Method : GET
949
- Action : Get hiding the password for a service. */
950
- getProtectedServiceCredentials(mailDetails) {
951
- return this.http
952
- .post(`${GlobalConstants.baseURL}${this.xServiceAPIUrl}GetServicePasswordClose`, mailDetails)
953
- .pipe(map$1((response) => {
954
- if (response && response['success']) {
955
- return response['result'];
956
- }
957
- else {
958
- return false;
959
- }
960
- }), catchError$1((e) => throwError(this.errorHandler(e))));
961
- }
962
- /*Method : POST
963
- Parameter : subID , id
964
- Action : Get configuration ID based on to show hide DOMAIN dropdown
965
- */
966
- getglobalConfigDetails(subid, id) {
967
- return this.http
968
- .post(`${GlobalConstants.baseURL}${this.metaAPIUrl1}GetArcosConfigsValues?subId=${subid}`, id)
969
- .pipe(map$1((response) => {
970
- if (response['statusCode'] === 200) {
971
- let result = response['result'];
972
- return result;
973
- }
974
- }), catchError$1((e) => throwError(this.errorHandler(e))));
975
- }
976
- getInitiateUserLogout() {
977
- return this.http
978
- .post(`${GlobalConstants.baseURL}${this.xAccessAPIUrl}logout`, {})
979
- .pipe(map$1((response) => {
980
- if (response && response['success']) {
981
- return response['result'];
982
- }
983
- else {
984
- return {};
985
- }
986
- }), catchError$1((e) => throwError(this.errorHandler(e))));
987
- }
988
- //Method: Open the OAuth connection window for the given application
989
- openAppConnection(appCode) {
990
- const url = GlobalConstants.baseURL + '/xauth/api/Token/AppOAuth?appcode=' + appCode;
991
- window.open(url, '_blank');
992
- }
993
- //Method: Validate MFA / SAML configuration before establishing the APP032 connection
994
- checkMFAConfiguration() {
995
- return this.http
996
- .get(`${GlobalConstants.baseURL}/xaccess/api/Token/getMfaSamlConfig`)
997
- .pipe(catchError$1((e) => throwError(this.errorHandler(e))));
998
- }
999
- //Method: Validate internal SAML app configuration before establishing the connection (e.g. APP033)
1000
- getInternalAppConfig(appCode) {
1001
- return this.http
1002
- .get(`${GlobalConstants.baseURL}/xaccess/api/Token/getInternalAppConfig?appCode=${appCode}`)
1003
- .pipe(catchError$1((e) => throwError(this.errorHandler(e))));
1004
- }
1005
- }
1006
- HttpCommonService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: HttpCommonService, deps: [{ token: i1.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable });
1007
- HttpCommonService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: HttpCommonService, providedIn: 'root' });
1008
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: HttpCommonService, decorators: [{
1009
- type: Injectable,
1010
- args: [{
1011
- providedIn: 'root',
1012
- }]
1013
- }], ctorParameters: function () { return [{ type: i1.HttpClient }]; } });
1014
-
1015
- class ToastMsgService {
1016
- constructor(toastr, translateService) {
1017
- this.toastr = toastr;
1018
- this.translateService = translateService;
1019
- this.toastType_sucess = 'toast-success';
1020
- this.toastType_info = 'toast-info';
1021
- this.toastType_error = 'toast-error';
1022
- this.toastType_warning = 'toast-warn';
1023
- }
1024
- success(textMessage, title) {
1025
- const heading = title || this.translateService.instant('Generic_lib.Successful');
1026
- if (this.isToastMsgActive()) {
1027
- if (this.checkActiveToastMessagesByType(this.toastType_sucess)) {
1028
- this.updateActiveToastMessage(heading, textMessage, this.toastType_sucess);
1029
- }
1030
- else {
1031
- this.toastr.success(textMessage, heading);
1032
- }
1033
- }
1034
- else {
1035
- this.toastr.success(textMessage, heading);
1036
- }
1037
- }
1038
- error(textMessage, title) {
1039
- const heading = title || this.translateService.instant('Generic_lib.Error');
1040
- if (this.isToastMsgActive()) {
1041
- if (this.checkActiveToastMessagesByType(this.toastType_error)) {
1042
- this.updateActiveToastMessage(heading, textMessage, this.toastType_error);
1043
- }
1044
- else {
1045
- this.toastr.error(textMessage, heading);
1046
- }
1047
- }
1048
- else {
1049
- this.toastr.error(textMessage, heading);
1050
- }
1051
- }
1052
- info(textMessage, title) {
1053
- const heading = title || this.translateService.instant('Generic_lib.Information');
1054
- if (this.isToastMsgActive()) {
1055
- if (this.checkActiveToastMessagesByType(this.toastType_info)) {
1056
- this.updateActiveToastMessage(heading, textMessage, this.toastType_info);
1057
- }
1058
- else {
1059
- this.toastr.info(textMessage, heading);
1060
- }
1061
- }
1062
- else {
1063
- this.toastr.info(textMessage, heading);
1064
- }
1065
- }
1066
- warning(textMessage, title) {
1067
- const heading = title || this.translateService.instant('Generic_lib.Warning');
1068
- if (this.isToastMsgActive()) {
1069
- if (this.checkActiveToastMessagesByType(this.toastType_warning)) {
1070
- this.updateActiveToastMessage(heading, textMessage, this.toastType_warning);
1071
- }
1072
- else {
1073
- this.toastr.warning(textMessage, heading);
1074
- }
1075
- }
1076
- else {
1077
- this.toastr.warning(textMessage, heading);
1078
- }
1079
- }
1080
- updateActiveToastMessage(title, textMessage, ToastType) {
1081
- const activeToasts = this.getActiveToastMessagesByType(ToastType);
1082
- if (activeToasts.length > 0) {
1083
- const toastObj = activeToasts[0];
1084
- toastObj.toastRef.componentInstance.title = title;
1085
- toastObj.toastRef.componentInstance.message = textMessage;
1086
- }
1087
- }
1088
- isToastMsgActive() {
1089
- return this.toastr.currentlyActive ? true : false;
1090
- }
1091
- getActiveToastMessagesByType(type) {
1092
- return this.toastr.toasts.filter((toastItem) => toastItem.toastRef.componentInstance.toastPackage.toastType.includes(type));
1093
- }
1094
- checkActiveToastMessagesByType(type) {
1095
- return this.toastr.toasts.some((toastItem) => toastItem.toastRef.componentInstance.toastPackage.toastType == type);
1096
- }
1097
- clear() {
1098
- this.toastr.clear();
1099
- }
1100
- }
1101
- ToastMsgService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ToastMsgService, deps: [{ token: i1$2.ToastrService }, { token: i4.TranslateService }], target: i0.ɵɵFactoryTarget.Injectable });
1102
- ToastMsgService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ToastMsgService, providedIn: 'root' });
1103
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ToastMsgService, decorators: [{
1104
- type: Injectable,
1105
- args: [{
1106
- providedIn: 'root',
1107
- }]
1108
- }], ctorParameters: function () { return [{ type: i1$2.ToastrService }, { type: i4.TranslateService }]; } });
1109
-
1110
- class EncrydecryRSAdataService {
1111
- generateAESKey() {
1112
- const publicKey = this.getPublicKey();
1113
- const symmetricKey = this.generateKeyAndIV();
1114
- const gkey = symmetricKey.key.toString();
1115
- const giv = symmetricKey.iv.toString();
1116
- const key = gkey + ',' + giv;
1117
- const encryptedSymmetricKey = this.encryptSymmetricKey(gkey, publicKey);
1118
- const encryptedSymmetriciv = this.encryptSymmetricKey(giv, publicKey);
1119
- return String(encryptedSymmetricKey + ',' + encryptedSymmetriciv);
1120
- }
1121
- encryptViaRSA(simpleText) {
1122
- const { symmKey, symmIV } = this.getRSAsymmetricKeyIV();
1123
- const encryptedText = this.encryptText(simpleText, symmKey, symmIV);
1124
- return encryptedText;
1125
- }
1126
- decryptViaRSA(encrpyText) {
1127
- const { symmKey, symmIV } = this.getRSAsymmetricKeyIV();
1128
- const decryptedText = this.decryptText(encrpyText, symmKey, symmIV);
1129
- return decryptedText;
1130
- }
1131
- generateKeyAndIV() {
1132
- const key = CryptoJS.lib.WordArray.random(32); // 32 bytes for AES-256
1133
- const iv = CryptoJS.lib.WordArray.random(16); // 16 bytes IV
1134
- return { key, iv };
1135
- }
1136
- encryptText(plaintext, hkey, hiv) {
1137
- //* If the data is Object then converting the object into JSON.stringify()
1138
- if (typeof plaintext === 'object' && plaintext !== null) {
1139
- plaintext = JSON.stringify(plaintext);
1140
- }
1141
- const key = CryptoJS.enc.Hex.parse(hkey);
1142
- const iv = CryptoJS.enc.Hex.parse(hiv);
1143
- const encrypted = CryptoJS.AES.encrypt(plaintext, key, {
1144
- iv: iv,
1145
- mode: CryptoJS.mode.CBC,
1146
- padding: CryptoJS.pad.Pkcs7,
1147
- });
1148
- return encrypted.toString();
1149
- }
1150
- encryptSymmetricKey(key, publicKey) {
1151
- try {
1152
- const rsa = new JSEncrypt();
1153
- rsa.setPublicKey(publicKey);
1154
- const encryptedKey = rsa.encrypt(key);
1155
- if (!encryptedKey)
1156
- throw new Error('Encryption failed. The key might be improperly formatted.');
1157
- return encryptedKey;
1158
- }
1159
- catch (error) {
1160
- console.error(`Encryption error: ${error.message}`);
1161
- return '';
1162
- }
1163
- }
1164
- decryptText(encryptedBase64, hkey, hiv) {
1165
- const key = CryptoJS.enc.Hex.parse(hkey);
1166
- const iv = CryptoJS.enc.Hex.parse(hiv);
1167
- const decrypted = CryptoJS.AES.decrypt(encryptedBase64, key, {
1168
- iv: iv,
1169
- mode: CryptoJS.mode.CBC,
1170
- padding: CryptoJS.pad.Pkcs7,
1171
- });
1172
- return decrypted.toString(CryptoJS.enc.Utf8);
1173
- }
1174
- getPublicKey() {
1175
- const publicKey = this.base64ToPem(localStorage.getItem('001-SAC-GEC') || '');
1176
- return publicKey;
1177
- }
1178
- getRSAsymmetricKeyIV() {
1179
- let symmKey = '';
1180
- let symmIV = '';
1181
- const key = localStorage.getItem('001-SAC-GEC');
1182
- if (key === null || key === void 0 ? void 0 : key.includes(',')) {
1183
- const syymArr = key.split(',');
1184
- symmKey = syymArr[0];
1185
- symmIV = syymArr[1];
1186
- }
1187
- return { symmKey, symmIV };
1188
- }
1189
- base64ToPem(base64Key) {
1190
- var _a;
1191
- const pemHeader = '-----BEGIN PUBLIC KEY-----';
1192
- const pemFooter = '-----END PUBLIC KEY-----';
1193
- const chunkSize = 64; // Standard line length for PEM files
1194
- const formattedKey = ((_a = base64Key.match(new RegExp(`.{1,${chunkSize}}`, 'g'))) === null || _a === void 0 ? void 0 : _a.join('\n')) || '';
1195
- return `${pemHeader}\n${formattedKey}\n${pemFooter}`;
1196
- }
1197
- }
1198
- EncrydecryRSAdataService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: EncrydecryRSAdataService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
1199
- EncrydecryRSAdataService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: EncrydecryRSAdataService, providedIn: 'root' });
1200
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: EncrydecryRSAdataService, decorators: [{
1201
- type: Injectable,
1202
- args: [{
1203
- providedIn: 'root',
1204
- }]
1205
- }] });
1206
-
1207
- class ASYNCPasswordcheckService {
1208
- constructor(httpCommonService, encryptService) {
1209
- this.httpCommonService = httpCommonService;
1210
- this.encryptService = encryptService;
1211
- this.pwdErrorMsg = '';
1212
- this.pwdValidation = new Subject();
1213
- }
1214
- createValidator() {
1215
- return (control) => {
1216
- //For AES Encrp/Dec
1217
- const userPassword = this.encryptService.encryptViaRSA(control.value);
1218
- let useDetails = {
1219
- userARCXWD: userPassword,
1220
- // userId: LoggedInUserInfo.userId,
1221
- // userName: LoggedInUserInfo.userName,
1222
- };
1223
- return control.valueChanges.pipe(debounceTime(500), take(1), switchMap((_) => this.httpCommonService.validatePassword(useDetails).pipe(map((data) => {
1224
- if (data['success']) {
1225
- this.pwdErrorMsg = data['message'];
1226
- this.emitValidationMsg(this.pwdErrorMsg);
1227
- return null;
1228
- }
1229
- else {
1230
- this.pwdErrorMsg = data['errorMessage'];
1231
- this.emitValidationMsg(this.pwdErrorMsg);
1232
- return { pwdInvalid: true };
1233
- }
1234
- }), catchError(() => of({ pwdInvalid: true })))));
1235
- };
1236
- }
1237
- emitValidationMsg(msg) {
1238
- this.pwdValidation.next(msg);
1239
- }
1240
- listValidationMsg() {
1241
- return this.pwdValidation.asObservable();
1242
- }
1243
- }
1244
- ASYNCPasswordcheckService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ASYNCPasswordcheckService, deps: [{ token: HttpCommonService }, { token: EncrydecryRSAdataService }], target: i0.ɵɵFactoryTarget.Injectable });
1245
- ASYNCPasswordcheckService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ASYNCPasswordcheckService, providedIn: 'root' });
1246
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ASYNCPasswordcheckService, decorators: [{
1247
- type: Injectable,
1248
- args: [{
1249
- providedIn: 'root',
1250
- }]
1251
- }], ctorParameters: function () { return [{ type: HttpCommonService }, { type: EncrydecryRSAdataService }]; } });
1252
- function ConfirmedValidator(controlName, matchingControlName) {
1253
- return (formGroup) => {
1254
- const control = formGroup.controls[controlName];
1255
- const matchingControl = formGroup.controls[matchingControlName];
1256
- if (matchingControl.errors &&
1257
- !matchingControl.errors['confirmedValidator']) {
1258
- return;
1259
- }
1260
- if (control.value !== matchingControl.value) {
1261
- matchingControl.setErrors({ confirmedValidator: true });
1262
- }
1263
- else {
1264
- matchingControl.setErrors(null);
1265
- }
1266
- };
1267
- }
1268
-
1269
- function noSpaceAllowed() {
1270
- return (control) => {
1271
- const value = control.value;
1272
- if (!value) {
1273
- return null; // No value is not an error here
1274
- }
1275
- // Check if the value starts with a space or contains any space
1276
- const hasLeadingSpace = value.startsWith(' ');
1277
- // const hasAnySpace = value.includes(' ');
1278
- if (hasLeadingSpace) {
1279
- return { noSpace: true };
1280
- }
1281
- return null;
1282
- };
1283
- }
1284
-
1285
- class CookieStorageManagerService {
1286
- constructor(cookie, _http) {
1287
- this.cookie = cookie;
1288
- this._http = _http;
1289
- }
1290
- //Check if cookies is set or not
1291
- checksetCookies(cookiesParam1) {
1292
- let status = this.cookie.check(cookiesParam1);
1293
- if (status) {
1294
- return true;
1295
- }
1296
- else {
1297
- return false;
1298
- }
1299
- }
1300
- //get cookies value
1301
- getCookieValue(cookiesParam) {
1302
- let status = this.cookie.check(cookiesParam);
1303
- if (status) {
1304
- let cookieValue = this.cookie.get(cookiesParam);
1305
- return cookieValue;
1306
- }
1307
- //What if cookies not found
1308
- else {
1309
- return '';
1310
- }
1311
- }
1312
- //Set cookies value
1313
- setCookiesValue(key, value) {
1314
- this.cookie.set(key, value);
1315
- }
1316
- //Delete a specific cookie
1317
- deleteCookie(cookieKey) {
1318
- this.cookie.delete(cookieKey);
1319
- }
1320
- //Delete All cookie
1321
- clearAllCookies() {
1322
- const cookies = this.cookie.getAll();
1323
- for (const cookieName in cookies) {
1324
- if (cookies.hasOwnProperty(cookieName)) {
1325
- this.cookie.delete(cookieName);
1326
- }
1327
- }
1328
- }
1329
- //Delete All cookie
1330
- // clearCookiesByAPI(payload: any) {
1331
- // const delCookieEndpoint = `${GlobalConstants.baseURL}/xaccess/api/SecureAccess/cookiesUpdation`;
1332
- // return this._http.post(delCookieEndpoint, payload).pipe(map((response:any)=>{
1333
- // if (response && response['success']) {
1334
- // return response['result'];
1335
- // } else {
1336
- // return null;
1337
- // }
1338
- // }));
1339
- // }
1340
- //Set Long cookies
1341
- setLongCookie(name, value, maxChunkSize) {
1342
- for (let i = 0; i < Math.ceil(value.length / maxChunkSize); i++) {
1343
- const chunk = value.substring(i * maxChunkSize, (i + 1) * maxChunkSize);
1344
- this.setCookiesValue(`${name}_${i}`, chunk);
1345
- }
1346
- }
1347
- }
1348
- CookieStorageManagerService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: CookieStorageManagerService, deps: [{ token: i1$1.CookieService }, { token: i1.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable });
1349
- CookieStorageManagerService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: CookieStorageManagerService, providedIn: 'root' });
1350
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: CookieStorageManagerService, decorators: [{
1351
- type: Injectable,
1352
- args: [{
1353
- providedIn: 'root',
1354
- }]
1355
- }], ctorParameters: function () { return [{ type: i1$1.CookieService }, { type: i1.HttpClient }]; } });
1356
-
1357
- class EncrydecrydataService {
1358
- constructor(_storageService) {
1359
- this._storageService = _storageService;
1360
- this.phiN = BigInt('1439652808780798693078119762209596147168096953796219172262910821317967061987350219660913015278464376519592636923598633193936864497263640780784805168728449');
1361
- this.m = BigInt('1439652808780798693078119762209596147168096953796219172262910821317967061987270868696269635759315523684521986922202953647194318017157636815317250179926320');
1362
- this.Genrator = 5;
1363
- this.min = 10000000;
1364
- this.max = 10000000 * 10000000;
1365
- }
1366
- generate() {
1367
- this.randomPrime = this.generateRandomPrime(this.min, this.max);
1368
- let code = bigintCryptoUtils.modPow(this.Genrator, BigInt(this.randomPrime), this.phiN);
1369
- return code;
1370
- }
1371
- process(key) {
1372
- let secretcode = bigintCryptoUtils.modPow(BigInt(key), BigInt(this.randomPrime), this.phiN);
1373
- this._storageService.saveData(COOKIECONSTANT.ERRORCODE, secretcode.toString());
1374
- }
1375
- encryptViaCrypto(normalText) {
1376
- const code = this.getSecretCode();
1377
- const encryptedMessagedata = this.encryptMessage(normalText, code);
1378
- return encryptedMessagedata;
1379
- }
1380
- decryptViaCrypto(cipherText) {
1381
- const decryptedData = this.base64ToUint8Array(cipherText);
1382
- const code = this.getSecretCode();
1383
- let decryptdata = this.decrypt(decryptedData, code);
1384
- let decryptdatastr = this.bytesToString(decryptdata);
1385
- return decryptdatastr;
1386
- }
1387
- decryptResponseViaCrypto(cipherText) {
1388
- const code = String(this.getPublicKey());
1389
- const decryptdata = this.decrypt123(cipherText, code);
1390
- return decryptdata;
1391
- }
1392
- //todo amit
1393
- // private decrypt123(messageme: string, key: string): string {
1394
- // let bigKey: bigint = BigInt(key);
1395
- // let bytes: string = atob(messageme);
1396
- // let decryptedBytes: number[] = [];
1397
- // for (let i = 0; i < bytes.length; i++) {
1398
- // let byteValue: bigint = BigInt(bytes.charCodeAt(i));
1399
- // byteValue = (byteValue - bigKey) % 256n;
1400
- // if (byteValue < 0n) {
1401
- // byteValue = 256n + byteValue;
1402
- // }
1403
- // decryptedBytes.push(Number(byteValue));
1404
- // }
1405
- // let decryptedMessage: string = String.fromCharCode.apply(
1406
- // null,
1407
- // decryptedBytes
1408
- // );
1409
- // return decryptedMessage;
1410
- // }
1411
- //new amit
1412
- decrypt123(messageme, key) {
1413
- const bigKey = BigInt(key);
1414
- const bytes = atob(messageme);
1415
- const decryptedBytes = [];
1416
- for (let i = 0; i < bytes.length; i++) {
1417
- let byteValue = BigInt(bytes.charCodeAt(i));
1418
- byteValue = (byteValue - bigKey) % BigInt(256);
1419
- if (byteValue < BigInt(0)) {
1420
- byteValue = BigInt(256) + byteValue;
1421
- }
1422
- decryptedBytes.push(Number(byteValue));
1423
- }
1424
- return String.fromCharCode(...decryptedBytes);
1425
- }
1426
- encryptMessage(message, sharedSecret) {
1427
- const messageBytes = new TextEncoder().encode(message);
1428
- const encryptedMessage = this.encrypt(messageBytes, sharedSecret);
1429
- return this.encryptMessageToBase64(encryptedMessage);
1430
- //return encryptedMessage;
1431
- }
1432
- base64ToUint8Array(base64String) {
1433
- const decodedString = atob(base64String);
1434
- const uint8Array = new Uint8Array(decodedString.length);
1435
- for (let i = 0; i < decodedString.length; i++) {
1436
- uint8Array[i] = decodedString.charCodeAt(i);
1437
- }
1438
- return uint8Array;
1439
- }
1440
- bytesToString(bytes) {
1441
- let str = '';
1442
- for (let i = 0; i < bytes.length; i++) {
1443
- str += String.fromCharCode(bytes[i]);
1444
- }
1445
- return str;
1446
- }
1447
- encryptMessageToBase64(encryptedMessage) {
1448
- const encryptedArray = Array.from(encryptedMessage);
1449
- const messageString = String.fromCharCode.apply(null, encryptedArray);
1450
- const base64String = btoa(messageString);
1451
- return base64String;
1452
- }
1453
- bigintToBytes(key) {
1454
- const hexString = key.toString(16);
1455
- const byteLength = Math.ceil(hexString.length / 2);
1456
- const bytes = new Uint8Array(byteLength);
1457
- let i = hexString.length;
1458
- let j = 0;
1459
- while (i > 0) {
1460
- bytes[j++] = parseInt(hexString.substring(Math.max(i - 2, 0), i), 16);
1461
- i -= 2;
1462
- }
1463
- return bytes;
1464
- }
1465
- encrypt(data, key) {
1466
- const keyBytes = this.bigintToBytes(key);
1467
- const encryptedData = new Uint8Array(data.length);
1468
- for (let i = 0; i < data.length; i++) {
1469
- encryptedData[i] = data[i] ^ keyBytes[i % keyBytes.length];
1470
- }
1471
- return encryptedData;
1472
- }
1473
- decrypt(data, key) {
1474
- return this.encrypt(data, key);
1475
- }
1476
- generateRandomPrime(min, max) {
1477
- const isPrime = (num) => {
1478
- if (num <= 1)
1479
- return false;
1480
- if (num <= 3)
1481
- return true;
1482
- if (num % 2 === 0 || num % 3 === 0)
1483
- return false;
1484
- let i = 5;
1485
- while (i * i <= num) {
1486
- if (num % i === 0 || num % (i + 2) === 0)
1487
- return false;
1488
- i += 6;
1489
- }
1490
- return true;
1491
- };
1492
- let prime;
1493
- do {
1494
- prime = Math.floor(Math.random() * (max - min + 1)) + min;
1495
- } while (!isPrime(prime));
1496
- return prime;
1497
- }
1498
- getSecretCode() {
1499
- var _a;
1500
- //todo Amit -
1501
- // const key = this._storageService.getData(COOKIECONSTANT.ERRORCODE);
1502
- const key = (_a = this._storageService.getData(COOKIECONSTANT.ERRORCODE)) !== null && _a !== void 0 ? _a : '0000';
1503
- return this.convertToBigInt(key);
1504
- }
1505
- convertToBigInt(value) {
1506
- try {
1507
- return BigInt(value);
1508
- }
1509
- catch (_a) {
1510
- return BigInt('0000');
1511
- }
1512
- }
1513
- getPublicKey() {
1514
- const publicKey = LoggedInUserInfo.privateKey;
1515
- // Check if publicKey is undefined, null, or empty
1516
- if (!publicKey) {
1517
- console.error('Public key is missing.');
1518
- return this.convertToBigInt('0');
1519
- }
1520
- const KeyArr = publicKey.split(',');
1521
- if (KeyArr.length === 0 || !KeyArr[0]) {
1522
- return this.convertToBigInt('0');
1523
- }
1524
- const keySegment = KeyArr[0];
1525
- // const keySegment = KeyArr[0].slice(0, 10);
1526
- // const keySegment = this.getSlicePublicKey(KeyArr[0]);
1527
- if (!keySegment) {
1528
- return this.convertToBigInt('0');
1529
- }
1530
- try {
1531
- return this.convertToBigInt(keySegment);
1532
- }
1533
- catch (error) {
1534
- return this.convertToBigInt('0');
1535
- }
1536
- }
1537
- getSlicePublicKey(key) {
1538
- const subString = key.length >= 20 ? key.substring(0, 20) : key;
1539
- const uniqueKey = this.getUniqueLetter(subString);
1540
- return uniqueKey;
1541
- }
1542
- getUniqueLetter(text) {
1543
- const textSet = new Set(text);
1544
- const uniqueString = [...textSet].join('');
1545
- return uniqueString;
1546
- }
1547
- }
1548
- EncrydecrydataService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: EncrydecrydataService, deps: [{ token: StorageService }], target: i0.ɵɵFactoryTarget.Injectable });
1549
- EncrydecrydataService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: EncrydecrydataService, providedIn: 'root' });
1550
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: EncrydecrydataService, decorators: [{
1551
- type: Injectable,
1552
- args: [{
1553
- providedIn: 'root',
1554
- }]
1555
- }], ctorParameters: function () { return [{ type: StorageService }]; } });
1556
-
1557
- class RESTLoginFormService {
1558
- constructor(_http, cookieService, _encryptDec) {
1559
- this._http = _http;
1560
- this.cookieService = cookieService;
1561
- this._encryptDec = _encryptDec;
1562
- }
1563
- /*Method : GET
1564
- Action : Fetch Domain List */
1565
- fetchDomainList() {
1566
- return this._http
1567
- .get(GlobalConstants.baseURL + 'meta/api/Metadata/Domains')
1568
- .pipe(map((response) => {
1569
- let result = [];
1570
- if (response['statusCode'] === 200) {
1571
- if (response['result'].length > 0) {
1572
- let result = response['result'];
1573
- return result;
1574
- }
1575
- else {
1576
- return [];
1577
- }
1578
- }
1579
- }), catchError((e) => throwError(this.errorHandler(e))));
1580
- }
1581
- errorHandler(e) {
1582
- throw new Error('Method not implemented.');
1583
- }
1584
- /*Method : POST
1585
- Parameter : subID , id
1586
- Action : Get configuration ID based on to show hide DOMAIN dropdown
1587
- */
1588
- getglobalConfigDetails(subid, id) {
1589
- return this._http
1590
- .post(GlobalConstants.baseURL +
1591
- 'meta/api/Metadata/GetArcosConfigsValues?subId=' +
1592
- subid, id)
1593
- .pipe(map((response) => {
1594
- let result = [];
1595
- if (response['statusCode'] === 200) {
1596
- let result = response['result'];
1597
- return result;
1598
- }
1599
- }), catchError((e) => throwError(this.errorHandler(e))));
1600
- }
1601
- /*Method : POST
1602
- Action : get login to user
1603
- */
1604
- // userAuthentication(userDetails: any) {
1605
- // return this._http
1606
- // .post(
1607
- // GlobalConstants.baseURL + 'xaccess/api/SecureAccess/Authenticate',
1608
- // userDetails
1609
- // )
1610
- // .pipe(
1611
- // map((response: any) => {
1612
- // if (response && response['data']) {
1613
- // return this.getDecryptAPIResponse(response['data']);
1614
- // }
1615
- // }),
1616
- // catchError((e) => throwError(this.errorHandler(e)))
1617
- // );
1618
- // }
1619
- /*Method : POST
1620
- Action : RESET Password for First Time User
1621
- */
1622
- setNewpassword(loggedInUserDetails) {
1623
- return this._http
1624
- .post(GlobalConstants.baseURL +
1625
- 'xaccess/api/SecureAccess/ChangeUserArcXwdManually', loggedInUserDetails)
1626
- .pipe(catchError((e) => throwError(this.errorHandler(e))));
1627
- }
1628
- /*Method : POST
1629
- Action :Will validate User entered PWD as
1630
- per Password Policy Set
1631
- */
1632
- validatePassword(userDetails) {
1633
- return this._http
1634
- .post(GlobalConstants.baseURL + 'xaccess/api/SecureAccess/ValidatePassword', userDetails)
1635
- .pipe(catchError((e) => throwError(this.errorHandler(e))));
1636
- }
1637
- /*Method : POST
1638
- Action : Get Public Key for encryption of Data */
1639
- getPrivateKey(params) {
1640
- return this._http
1641
- .post(GlobalConstants.baseURL + 'xaccess/api/SecureAccess/XKEDSync', params)
1642
- .pipe(catchError((e) => throwError(this.errorHandler(e))));
1643
- }
1644
- /* Method : POST
1645
- Action : Send request for OTP of MFA Authenticator */
1646
- sendMFAOTPRequest(mfaDetails) {
1647
- return this._http
1648
- .post(GlobalConstants.baseURL + 'xmfa/api/Mfa/mfa', mfaDetails)
1649
- .pipe(map((response) => {
1650
- let result = [];
1651
- if (response['success']) {
1652
- let result = response['result'];
1653
- return result;
1654
- }
1655
- }), catchError((e) => throwError(this.errorHandler(e))));
1656
- }
1657
- /* Method : POST
1658
- Action : Submit User Enter OTP of MFA Authenticator */
1659
- submitOtpForMfaVerification(mfaDetails) {
1660
- return this._http
1661
- .post(GlobalConstants.baseURL + 'xmfa/api/Mfa/mfavalidation', mfaDetails)
1662
- .pipe(map((response) => {
1663
- let result = [];
1664
- if (response['success']) {
1665
- let result = response['result'];
1666
- return result;
1667
- }
1668
- }), catchError((e) => throwError(this.errorHandler(e))));
1669
- }
1670
- /*Method : POST
1671
- Action : It will provide Token which used for multiple Application access */
1672
- getAuthToken(userDetails) {
1673
- return this._http
1674
- .post(GlobalConstants.baseURL + 'xauth/api/Token/GenerateJwtTokenApplication', userDetails)
1675
- .pipe(map((response) => {
1676
- if (response) {
1677
- return response;
1678
- }
1679
- else {
1680
- return '';
1681
- }
1682
- }), catchError((e) => throwError(this.errorHandler(e))));
1683
- }
1684
- /* Method : GET
1685
- Action : It will provide Token which used to established MFA Method */
1686
- // getMFAAccessTokenKey() {
1687
- // return this._http
1688
- // .get<any>(GlobalConstants.baseURL + 'xaccess/api/SecureAccess/GetMfaDetails')
1689
- // .pipe(
1690
- // map((response) => {
1691
- // if (response && response['data']) {
1692
- // return this.getDecryptAPIResponse(response['data']);
1693
- // }
1694
- // return {};
1695
- // }),
1696
- // catchError((e) => throwError(this.errorHandler(e)))
1697
- // );
1698
- // }
1699
- /* Method : POST
1700
- Action : It will check Valida User or not */
1701
- // checkUserExists(userDetails: any) {
1702
- // return this._http
1703
- // .post(
1704
- // GlobalConstants.baseURL + 'xaccess/api/SecureAccess/ValidateUser',
1705
- // userDetails
1706
- // )
1707
- // .pipe(
1708
- // map((response: any) => {
1709
- // if (response && response['data']) {
1710
- // return this.getDecryptAPIResponse(response['data']);
1711
- // }
1712
- // return {};
1713
- // }),
1714
- // catchError((e) => throwError(this.errorHandler(e)))
1715
- // );
1716
- // }
1717
- /* Method : POST
1718
- Action : Unlock User to enable login process */
1719
- unlockUserAccount(userDetails) {
1720
- return this._http
1721
- .post(GlobalConstants.baseURL + 'xaccess/api/SecureAccess/ValidateUser', userDetails)
1722
- .pipe(map((result) => {
1723
- return result;
1724
- }), catchError((e) => throwError(this.errorHandler(e))));
1725
- }
1726
- /* Method : GET
1727
- Action : It will provide Third Parth AUth Method etc. Google, Okta, Microsoft */
1728
- // getThirdPartySignInMethods() {
1729
- // return this._http
1730
- // .get(
1731
- // GlobalConstants.baseURL + 'xaccess/api/SecureAccess/GetThirdPartyDetail'
1732
- // )
1733
- // .pipe(
1734
- // map((response: any) => {
1735
- // let result: any = [];
1736
- // if (response['success']) {
1737
- // return response['result'];
1738
- // }
1739
- // return result;
1740
- // }),
1741
- // catchError((error: any) => throwError(this.errorHandler(error)))
1742
- // );
1743
- // }
1744
- /* Method : POST
1745
- Action : It will Verify plugin version is correct or not */
1746
- // public verifyUserInstalledPluginVersion(pluginInfo: any) {
1747
- // return this._http
1748
- // .post(GlobalConstants.baseURL + 'xaccess/api/SecureAccess/CheckAutoUpdatePAMPlugin',
1749
- // pluginInfo).pipe(
1750
- // map((response: any) => {
1751
- // return response['result'];
1752
- // }),
1753
- // catchError((error: any) => throwError(this.errorHandler(error)))
1754
- // );
1755
- // }
1756
- /**
1757
- * Verifies user authentication using Windows credentials.
1758
- */
1759
- // public checkAuthenticateWithWindowsCredentials(pluginInfo: any) {
1760
- // return this._http
1761
- // .post(GlobalConstants.baseURL + 'xdomainauth/api/DomainAuthentication/DomainAuth',
1762
- // // .post(GlobalConstants.baseURL + 'xaccess/api/SecureAccess/DomainAuth',
1763
- // pluginInfo).pipe(
1764
- // map((response: any) => {
1765
- // if (response && response['data']) {
1766
- // return this.getDecryptAPIResponse(response['data']);
1767
- // }
1768
- // return {};
1769
- // }),
1770
- // catchError((error: any) => throwError(this.errorHandler(error)))
1771
- // );
1772
- // }
1773
- /*Method : GET
1774
- Action : Get User Background Image and Logo */
1775
- getUserBackgroundImageAndLogo() {
1776
- return this._http
1777
- .get(GlobalConstants.baseURL + 'xaccess/api/SecureAccess/GetBackgroundImage')
1778
- .pipe(map((response) => {
1779
- return response;
1780
- }), catchError((error) => throwError(this.errorHandler(error))));
1781
- }
1782
- // public getVerifiedUserSessionDetails(authToken: string) {
1783
- // return this._http.post(
1784
- // GlobalConstants.baseURL + 'xaccess/api/SecureAccess/ValidateUserSessionDetail', { state: authToken }).pipe(
1785
- // map((response: any) => {
1786
- // if (response && response['data']) {
1787
- // return this.getDecryptAPIResponse(response['data']);
1788
- // }
1789
- // return {};
1790
- // }),
1791
- // catchError((error: any) => throwError(this.errorHandler(error)))
1792
- // );
1793
- // }
1794
- deleteCookieData(payload) {
1795
- const url = this.cookieService.getCookieValue('baseurl');
1796
- const delCookieEndpoint = `${url}xaccess/api/SecureAccess/cookiesUpdation`;
1797
- return this._http.post(delCookieEndpoint, payload);
1798
- }
1799
- /**
1800
- * Decrypts a base64-encoded, MessagePack-encoded ciphertext into its original tuple form.
1801
- *
1802
- * @param cipherText - The encrypted string received from the API.
1803
- * @returns The decoded tuple [key, value] if decryption is successful; otherwise, an empty object.
1804
- *
1805
- * Steps:
1806
- * 1. Decrypts the cipherText using custom crypto method.
1807
- * 2. Decodes the base64 response into a binary Uint8Array.
1808
- * 3. Deserializes the binary using MessagePack's decode to get the original data.
1809
- */
1810
- // private getDecryptAPIResponse_old(cipherText: string): any {
1811
- // if (cipherText) {
1812
- // const responseString =
1813
- // this._encryptDec.decryptResponseViaCrypto(cipherText);
1814
- // const binary = Uint8Array.from(atob(responseString), c => c.charCodeAt(0));
1815
- // const decodedArray = decode(binary) as [string, string];
1816
- // return decodedArray
1817
- // }
1818
- // return {};
1819
- // }
1820
- getDecryptAPIResponse(cipherText) {
1821
- return __awaiter(this, void 0, void 0, function* () {
1822
- if (cipherText) {
1823
- const responseString = yield this._encryptDec.decryptResponseViaCrypto(cipherText); // await here
1824
- const binary = Uint8Array.from(atob(responseString), (c) => c.charCodeAt(0));
1825
- const decodedArray = decode(binary);
1826
- return decodedArray;
1827
- }
1828
- return {};
1829
- });
1830
- }
1831
- }
1832
- RESTLoginFormService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: RESTLoginFormService, deps: [{ token: i1.HttpClient }, { token: CookieStorageManagerService }, { token: EncrydecrydataService }], target: i0.ɵɵFactoryTarget.Injectable });
1833
- RESTLoginFormService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: RESTLoginFormService, providedIn: 'root' });
1834
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: RESTLoginFormService, decorators: [{
1835
- type: Injectable,
1836
- args: [{
1837
- providedIn: 'root',
1838
- }]
1839
- }], ctorParameters: function () { return [{ type: i1.HttpClient }, { type: CookieStorageManagerService }, { type: EncrydecrydataService }]; } });
1840
-
1841
- class VaptValidationService {
1842
- constructor() { }
1843
- hasUnsafeInput(formData) {
1844
- const dangerousPattern = /<\s*(script|iframe|object|embed|link|style)\b[^>]*>(.*?)<\s*\/\s*\1\s*>|<\s*(script|iframe|object|embed|link|style)\b[^>]*\/?>|<[^>]+>/gi;
1845
- function checkValue(value) {
1846
- if (typeof value === 'string') {
1847
- return dangerousPattern.test(value);
1848
- }
1849
- if (Array.isArray(value)) {
1850
- return value.some(checkValue);
1851
- }
1852
- if (typeof value === 'object' && value !== null) {
1853
- return Object.values(value).some(checkValue);
1854
- }
1855
- // If it's a number, boolean, null, or undefined, ignore
1856
- return false;
1857
- }
1858
- return checkValue(formData);
1859
- }
1860
- }
1861
- VaptValidationService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: VaptValidationService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
1862
- VaptValidationService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: VaptValidationService, providedIn: 'root' });
1863
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: VaptValidationService, decorators: [{
1864
- type: Injectable,
1865
- args: [{
1866
- providedIn: 'root'
1867
- }]
1868
- }], ctorParameters: function () { return []; } });
1869
-
1870
- class HttpGeneralConfigurationService {
1871
- constructor(http) {
1872
- this.http = http;
1873
- this.xPageRefAPIUrl = '/xaccess/api/PagePreference/';
1874
- }
1875
- getUserPreferredAssetTypeDetails() {
1876
- return this.http
1877
- .get(`${GlobalConstants.baseURL}${this.xPageRefAPIUrl}GetAssetTypeDetails`)
1878
- .pipe(map$1((response) => {
1879
- if (response && response['success']) {
1880
- return response['result'];
1881
- }
1882
- else {
1883
- return [];
1884
- }
1885
- }), catchError$1((e) => throwError(this.errorHandler(e))));
1886
- }
1887
- getUserPreferredAssetName(payload) {
1888
- return this.http
1889
- .post(`${GlobalConstants.baseURL}${this.xPageRefAPIUrl}GetAssetName`, payload)
1890
- .pipe(map$1((response) => {
1891
- if (response && response['success']) {
1892
- return response['result'];
1893
- }
1894
- else {
1895
- return [];
1896
- }
1897
- }), catchError$1((e) => throwError(this.errorHandler(e))));
1898
- }
1899
- getServiceNameByAssetTypeEvent(payload) {
1900
- return this.http
1901
- .post(`${GlobalConstants.baseURL}${this.xPageRefAPIUrl}GetServiceDetails`, payload)
1902
- .pipe(map$1((response) => {
1903
- if (response && response['success']) {
1904
- return response['result'];
1905
- }
1906
- else {
1907
- return [];
1908
- }
1909
- }), catchError$1((e) => throwError(this.errorHandler(e))));
1910
- }
1911
- getPreferencePathDetails(payload) {
1912
- return this.http
1913
- .post(`${GlobalConstants.baseURL}${this.xPageRefAPIUrl}CurrentPreferencepathDetails`, payload)
1914
- .pipe(map$1((response) => {
1915
- if (response && response['success']) {
1916
- return response['result'];
1917
- }
1918
- else {
1919
- return {};
1920
- }
1921
- }), catchError$1((e) => throwError(this.errorHandler(e))));
1922
- }
1923
- updatePreferencePath(payload) {
1924
- return this.http
1925
- .post(`${GlobalConstants.baseURL}${this.xPageRefAPIUrl}UpdatePreferencePath`, payload)
1926
- .pipe(map$1((response) => {
1927
- if (response && response['success']) {
1928
- return true;
1929
- }
1930
- else {
1931
- return false;
1932
- }
1933
- }), catchError$1((e) => throwError(this.errorHandler(e))));
1934
- }
1935
- errorHandler(e) {
1936
- throw new Error('Method not implemented.');
1937
- }
1938
- }
1939
- HttpGeneralConfigurationService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: HttpGeneralConfigurationService, deps: [{ token: i1.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable });
1940
- HttpGeneralConfigurationService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: HttpGeneralConfigurationService, providedIn: 'root' });
1941
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: HttpGeneralConfigurationService, decorators: [{
1942
- type: Injectable,
1943
- args: [{
1944
- providedIn: 'root',
1945
- }]
1946
- }], ctorParameters: function () { return [{ type: i1.HttpClient }]; } });
1947
-
1948
- class TimezoneConfigurationComponent {
1949
- constructor(fb, msgService, _storageService, _eventService, translateService, httpCommonService) {
1950
- this.fb = fb;
1951
- this.msgService = msgService;
1952
- this._storageService = _storageService;
1953
- this._eventService = _eventService;
1954
- this.translateService = translateService;
1955
- this.httpCommonService = httpCommonService;
1956
- this.timeZoneForm = new FormGroup({}); //user Reset Password Form
1957
- this.ListOfTimeZones = [];
1958
- this.isTimezoneLoading = false;
1959
- this.isTimezoneupdate = false;
1960
- this.unsubscribeAPIEventListenerData = new Subject();
1961
- this.tzSuccessMsg = errorMsg.TIMEZONESUCCESS;
1962
- this.tzErrorMsg = errorMsg.TIMEZONERROR;
1963
- this.apiUrl = '';
1964
- this.closepopup = new EventEmitter();
1965
- }
1966
- ngAfterViewInit() {
1967
- this.getTranslateContent();
1968
- }
1969
- ngOnInit() {
1970
- this.getListofTimeZones();
1971
- this.getInitalizeForm();
1972
- }
1973
- getInitalizeForm() {
1974
- this.timeZoneForm = this.fb.group({
1975
- timezone: [null, Validators.required], // Add Validators.required
1976
- });
1977
- }
1978
- //Method: Convert text one Lang. to another
1979
- getTranslateContent() {
1980
- this.translateService
1981
- .get(['Generic_lib.TimeZoneSuccessMsg', 'Generic_lib.TimeZoneErrorMsg'])
1982
- .pipe(takeUntil(this.unsubscribeAPIEventListenerData))
1983
- .subscribe((trans) => {
1984
- this.tzSuccessMsg = trans['Generic_lib.TimeZoneSuccessMsg'];
1985
- this.tzErrorMsg = trans['Generic_lib.TimeZoneErrorMsg'];
1986
- });
1987
- }
1988
- /*Method : GET
1989
- Action : Get List of Time Zone*/
1990
- getListofTimeZones() {
1991
- this.isTimezoneLoading = true;
1992
- this.httpCommonService
1993
- .getGlobalTimeZone()
1994
- .pipe(takeUntil(this.unsubscribeAPIEventListenerData), finalize(() => {
1995
- this.isTimezoneLoading = false;
1996
- }))
1997
- .subscribe((result) => {
1998
- if (result && result['timelist']) {
1999
- this.ListOfTimeZones = result['timelist'];
2000
- }
2001
- if (result && result['userTimeZone']) {
2002
- let userTz = result['userTimeZone'];
2003
- const selectedTZ = this.ListOfTimeZones.find((tz) => tz.id === userTz);
2004
- this.setTimezoneOptionValue(selectedTZ);
2005
- }
2006
- });
2007
- }
2008
- /*Method : POST
2009
- Action : Used to Update User Selected TimeZone*/
2010
- setUserTimeZone() {
2011
- var _a;
2012
- const tz = (_a = this.timeZoneForm.get('timezone')) === null || _a === void 0 ? void 0 : _a.value;
2013
- let tzName = tz['id'];
2014
- this.showBtnLoadder(true);
2015
- this.httpCommonService
2016
- .updateUserTimeZone(tzName)
2017
- .pipe(takeUntil(this.unsubscribeAPIEventListenerData), finalize(() => {
2018
- this.showBtnLoadder(false);
2019
- }))
2020
- .subscribe((result) => {
2021
- if (result) {
2022
- setTimeout(() => {
2023
- this.setTimezoneOptionValue(tz);
2024
- }, 10);
2025
- this.msgService.success(this.tzSuccessMsg);
2026
- this._storageService.removeData(COOKIECONSTANT.NEWUSER);
2027
- this._eventService.emitTimezone({
2028
- component: 'timezone',
2029
- usertimezoneAbbreviations: result,
2030
- userTimeZoneFullForm: '',
2031
- id: tz['id'],
2032
- timelist: this.ListOfTimeZones,
2033
- });
2034
- this.closepopup.emit(true);
2035
- this.timeZoneForm.reset();
2036
- }
2037
- else {
2038
- this.msgService.error(this.tzErrorMsg);
2039
- }
2040
- });
2041
- }
2042
- setTimezoneOptionValue(selectedTZ) {
2043
- var _a;
2044
- if (selectedTZ) {
2045
- this.selectedTimeZone = selectedTZ;
2046
- (_a = this.timeZoneForm.get('timezone')) === null || _a === void 0 ? void 0 : _a.setValue(this.selectedTimeZone);
2047
- }
2048
- }
2049
- showBtnLoadder(flag) {
2050
- this.isTimezoneupdate = flag;
2051
- }
2052
- ngOnDestroy() {
2053
- this.unsubscribeAPIEventListenerData.next(true);
2054
- this.unsubscribeAPIEventListenerData.complete();
2055
- }
2056
- }
2057
- TimezoneConfigurationComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: TimezoneConfigurationComponent, deps: [{ token: i2.FormBuilder }, { token: ToastMsgService }, { token: StorageService }, { token: EventService }, { token: i4.TranslateService }, { token: HttpCommonService }], target: i0.ɵɵFactoryTarget.Component });
2058
- TimezoneConfigurationComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: TimezoneConfigurationComponent, selector: "app-timezone-configuration", outputs: { closepopup: "closepopup" }, ngImport: i0, template: "<div class=\"preference-container\">\r\n <form [formGroup]=\"timeZoneForm\">\r\n <div class=\"mt-2\">\r\n <div class=\"form-group\">\r\n <div class=\"d-flex\">\r\n <div class=\"label-name\">{{\"Generic_lib.PreferredTimezone\" | translate }}</div>\r\n <span class=\"madontary-icon\">*</span>\r\n </div>\r\n <div class=\" timezone-dropdown\">\r\n <p-dropdown [options]=\"ListOfTimeZones\" filterPlaceholder='{{ \"Generic_lib.Search\" | translate }}'\r\n placeholder='{{\"Generic_lib.TimeZonePlaceHolder\" | translate}}' formControlName=\"timezone\"\r\n [(ngModel)]=\"selectedTimeZone\" [filter]=\"!isTimezoneLoading ? true:false\" optionLabel=\"displayName\"\r\n filterBy=\"displayName\" [showClear]=\"false\" panelStyleClass=\"{'dropdown-loader': isTimezoneLoading}\">\r\n\r\n <ng-template pTemplate=\"header\">\r\n <div *ngIf=\"isTimezoneLoading\" class=\"dropdown-loader-container\">\r\n <i class=\"pi pi-spin pi-spinner\"></i>\r\n </div>\r\n </ng-template></p-dropdown>\r\n </div>\r\n <ng-container *ngIf=\"\r\n timeZoneForm.get('timezone')?.invalid &&\r\n timeZoneForm.get('timezone')?.touched\r\n \">\r\n <span class=\"error-msg mt-1\">{{'Generic_lib.TimeZoneFieldValidation' | translate}}</span>\r\n </ng-container>\r\n </div>\r\n </div>\r\n <div class=\"mt-2 update-btn\">\r\n <p-button class=\"submit-btn\" label=\"{{'Generic_lib.Update' | translate}}\" [disabled]=\"timeZoneForm.invalid\"\r\n iconPos=\"right\" [loading]=\"isTimezoneupdate\" (onClick)=\"setUserTimeZone()\"></p-button>\r\n </div>\r\n </form>\r\n</div>", styles: [".preference-container .path-title{font-size:20px;color:#292f4c}.preference-container .form-group{margin-bottom:15px}.preference-container .label-name{font-size:12px;color:#292f4c;line-height:26px;font-weight:600}.preference-container .cur-text{font-size:12px;color:#676879;line-height:26px;font-weight:600}\n"], dependencies: [{ kind: "directive", type: i6.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "component", type: i8.Dropdown, selector: "p-dropdown", inputs: ["scrollHeight", "filter", "name", "style", "panelStyle", "styleClass", "panelStyleClass", "readonly", "required", "editable", "appendTo", "tabindex", "placeholder", "filterPlaceholder", "filterLocale", "inputId", "selectId", "dataKey", "filterBy", "autofocus", "resetFilterOnHide", "dropdownIcon", "optionLabel", "optionValue", "optionDisabled", "optionGroupLabel", "optionGroupChildren", "autoDisplayFirst", "group", "showClear", "emptyFilterMessage", "emptyMessage", "lazy", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "overlayOptions", "ariaFilterLabel", "ariaLabel", "ariaLabelledBy", "filterMatchMode", "maxlength", "tooltip", "tooltipPosition", "tooltipPositionStyle", "tooltipStyleClass", "autofocusFilter", "overlayDirection", "disabled", "itemSize", "autoZIndex", "baseZIndex", "showTransitionOptions", "hideTransitionOptions", "options", "filterValue"], outputs: ["onChange", "onFilter", "onFocus", "onBlur", "onClick", "onShow", "onHide", "onClear", "onLazyLoad"] }, { kind: "directive", type: i9.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "component", type: i10.Button, selector: "p-button", inputs: ["type", "iconPos", "icon", "badge", "label", "disabled", "loading", "loadingIcon", "style", "styleClass", "badgeClass", "ariaLabel"], outputs: ["onClick", "onFocus", "onBlur"] }, { kind: "pipe", type: i4.TranslatePipe, name: "translate" }] });
2059
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: TimezoneConfigurationComponent, decorators: [{
2060
- type: Component,
2061
- args: [{ selector: 'app-timezone-configuration', template: "<div class=\"preference-container\">\r\n <form [formGroup]=\"timeZoneForm\">\r\n <div class=\"mt-2\">\r\n <div class=\"form-group\">\r\n <div class=\"d-flex\">\r\n <div class=\"label-name\">{{\"Generic_lib.PreferredTimezone\" | translate }}</div>\r\n <span class=\"madontary-icon\">*</span>\r\n </div>\r\n <div class=\" timezone-dropdown\">\r\n <p-dropdown [options]=\"ListOfTimeZones\" filterPlaceholder='{{ \"Generic_lib.Search\" | translate }}'\r\n placeholder='{{\"Generic_lib.TimeZonePlaceHolder\" | translate}}' formControlName=\"timezone\"\r\n [(ngModel)]=\"selectedTimeZone\" [filter]=\"!isTimezoneLoading ? true:false\" optionLabel=\"displayName\"\r\n filterBy=\"displayName\" [showClear]=\"false\" panelStyleClass=\"{'dropdown-loader': isTimezoneLoading}\">\r\n\r\n <ng-template pTemplate=\"header\">\r\n <div *ngIf=\"isTimezoneLoading\" class=\"dropdown-loader-container\">\r\n <i class=\"pi pi-spin pi-spinner\"></i>\r\n </div>\r\n </ng-template></p-dropdown>\r\n </div>\r\n <ng-container *ngIf=\"\r\n timeZoneForm.get('timezone')?.invalid &&\r\n timeZoneForm.get('timezone')?.touched\r\n \">\r\n <span class=\"error-msg mt-1\">{{'Generic_lib.TimeZoneFieldValidation' | translate}}</span>\r\n </ng-container>\r\n </div>\r\n </div>\r\n <div class=\"mt-2 update-btn\">\r\n <p-button class=\"submit-btn\" label=\"{{'Generic_lib.Update' | translate}}\" [disabled]=\"timeZoneForm.invalid\"\r\n iconPos=\"right\" [loading]=\"isTimezoneupdate\" (onClick)=\"setUserTimeZone()\"></p-button>\r\n </div>\r\n </form>\r\n</div>", styles: [".preference-container .path-title{font-size:20px;color:#292f4c}.preference-container .form-group{margin-bottom:15px}.preference-container .label-name{font-size:12px;color:#292f4c;line-height:26px;font-weight:600}.preference-container .cur-text{font-size:12px;color:#676879;line-height:26px;font-weight:600}\n"] }]
2062
- }], ctorParameters: function () { return [{ type: i2.FormBuilder }, { type: ToastMsgService }, { type: StorageService }, { type: EventService }, { type: i4.TranslateService }, { type: HttpCommonService }]; }, propDecorators: { closepopup: [{
2063
- type: Output
2064
- }] } });
2065
-
2066
- class LandingpgConfigComponent {
2067
- constructor(libService, fb, msgService, translateService, _encryptRSAService, httpCommonService) {
2068
- this.libService = libService;
2069
- this.fb = fb;
2070
- this.msgService = msgService;
2071
- this.translateService = translateService;
2072
- this._encryptRSAService = _encryptRSAService;
2073
- this.httpCommonService = httpCommonService;
2074
- this.AppNameForm = new FormGroup({});
2075
- this.ListofApplicationNames = [];
2076
- this.isAppNameLoading = false;
2077
- this.isAppNameUpdate = false;
2078
- this.updateSuccess = errorMsg.LANDINGPGSUCCESS;
2079
- this.updateError = errorMsg.LANDINGPGERROR;
2080
- this.userConfiguredApp = {};
2081
- this.unsubscribeAPIEventListenerData = new Subject();
2082
- this.apiUrl = '';
2083
- }
2084
- ngAfterViewInit() {
2085
- this.getTranslateContent();
2086
- }
2087
- ngOnInit() {
2088
- this.getListofApplications();
2089
- this.getInitalizeForm();
2090
- }
2091
- getInitalizeForm() {
2092
- this.AppNameForm = this.fb.group({
2093
- userApp: [null, Validators.required],
2094
- });
2095
- }
2096
- //Method: Convert text one Lang. to another
2097
- getTranslateContent() {
2098
- this.translateService
2099
- .get([
2100
- 'Generic_lib.LandingPageSuccessMsg',
2101
- 'Generic_lib.LandingPageErrorMsg',
2102
- ])
2103
- .pipe(takeUntil(this.unsubscribeAPIEventListenerData))
2104
- .subscribe((trans) => {
2105
- this.updateSuccess = trans['Generic_lib.LandingPageSuccessMsg'];
2106
- this.updateError = trans['Generic_lib.LandingPageErrorMsg'];
2107
- });
2108
- }
2109
- /*Method : GET
2110
- Action : Get List of User Assign Application*/
2111
- getListofApplications() {
2112
- this.isAppNameLoading = true;
2113
- this.httpCommonService
2114
- .getUserAssignedApps()
2115
- .pipe(takeUntil(this.unsubscribeAPIEventListenerData), finalize(() => {
2116
- this.isAppNameLoading = false;
2117
- }))
2118
- .subscribe((response) => {
2119
- this.ListofApplicationNames = response;
2120
- this.userConfiguredApp = this.ListofApplicationNames.find((app) => app.isAssignedLanding);
2121
- this.setPostLoginModuleOption(this.userConfiguredApp);
2122
- });
2123
- }
2124
- /*Method : POST
2125
- Action : Used to Update User Preferred Landing App Name*/
2126
- getUpdateLandingPgPreference() {
2127
- var _a;
2128
- const userApp = (_a = this.AppNameForm.get('userApp')) === null || _a === void 0 ? void 0 : _a.value;
2129
- const moduleId = this._encryptRSAService.encryptViaRSA(userApp['appCode']);
2130
- this.showBtnLoadder(true);
2131
- this.httpCommonService
2132
- .setLandingPgPreference(moduleId)
2133
- .pipe(takeUntil(this.unsubscribeAPIEventListenerData), finalize(() => {
2134
- this.showBtnLoadder(false);
2135
- }))
2136
- .subscribe((result) => {
2137
- if (result) {
2138
- setTimeout(() => {
2139
- this.setPostLoginModuleOption(userApp);
2140
- }, 10);
2141
- this.msgService.success(this.updateSuccess);
2142
- this.AppNameForm.reset();
2143
- }
2144
- else {
2145
- this.msgService.error(this.updateError);
2146
- }
2147
- });
2148
- }
2149
- setPostLoginModuleOption(userConfiguredApp) {
2150
- var _a;
2151
- if (userConfiguredApp) {
2152
- (_a = this.AppNameForm.get('userApp')) === null || _a === void 0 ? void 0 : _a.setValue(userConfiguredApp);
2153
- }
2154
- }
2155
- showBtnLoadder(flag) {
2156
- this.isAppNameUpdate = flag;
2157
- }
2158
- ngOnDestroy() {
2159
- this.unsubscribeAPIEventListenerData.next(true);
2160
- this.unsubscribeAPIEventListenerData.complete();
2161
- }
2162
- }
2163
- LandingpgConfigComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: LandingpgConfigComponent, deps: [{ token: CommonHeaderLibService }, { token: i2.FormBuilder }, { token: ToastMsgService }, { token: i4.TranslateService }, { token: EncrydecryRSAdataService }, { token: HttpCommonService }], target: i0.ɵɵFactoryTarget.Component });
2164
- LandingpgConfigComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: LandingpgConfigComponent, selector: "app-landingpg-config", ngImport: i0, template: "<div class=\"preference-container\">\r\n <form [formGroup]=\"AppNameForm\">\r\n <div class=\"mt-2\">\r\n <div class=\"form-group\">\r\n <div class=\"d-flex\">\r\n <div class=\"label-name\">{{ \"Generic_lib.LandingPageConfig\" | translate }}</div>\r\n <span class=\"madontary-icon\">*</span>\r\n </div>\r\n <div class=\" timezone-dropdown\">\r\n <p-dropdown [options]=\"ListofApplicationNames\"\r\n placeholder='{{\"Generic_lib.LandingPagePlaceHolder\" | translate}}'\r\n filterPlaceholder='{{\"Generic_lib.Search\" | translate }}' formControlName=\"userApp\"\r\n [filter]=\"!isAppNameLoading ? true:false\" optionLabel=\"applicationName\" filterBy=\"applicationName\"\r\n [showClear]=\"false\" panelStyleClass=\"{'dropdown-loader': isAppNameLoading}\">\r\n\r\n <ng-template pTemplate=\"header\">\r\n <div *ngIf=\"isAppNameLoading\" class=\"dropdown-loader-container\">\r\n <i class=\"pi pi-spin pi-spinner\"></i>\r\n </div>\r\n </ng-template>\r\n </p-dropdown>\r\n </div>\r\n <ng-container *ngIf=\"AppNameForm.get('userApp')?.invalid && AppNameForm.get('userApp')?.touched\">\r\n <span class=\"error-msg mt-1\">{{'Generic_lib.LandingPageValidation' | translate}}</span>\r\n </ng-container>\r\n </div>\r\n </div>\r\n <div class=\"mt-2 update-btn\">\r\n <p-button class=\"submit-btn\" label=\"{{'Generic_lib.Update' | translate}}\" [disabled]=\"AppNameForm.invalid\"\r\n iconPos=\"right\" [loading]=\"isAppNameUpdate\" (onClick)=\"getUpdateLandingPgPreference()\"></p-button>\r\n </div>\r\n </form>\r\n</div>", styles: [".preference-container .path-title{font-size:20px;color:#292f4c}.preference-container .form-group{margin-bottom:15px}.preference-container .label-name{font-size:12px;color:#292f4c;line-height:26px;font-weight:600}.preference-container .cur-text{font-size:12px;color:#676879;line-height:26px;font-weight:600}\n"], dependencies: [{ kind: "directive", type: i6.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "component", type: i8.Dropdown, selector: "p-dropdown", inputs: ["scrollHeight", "filter", "name", "style", "panelStyle", "styleClass", "panelStyleClass", "readonly", "required", "editable", "appendTo", "tabindex", "placeholder", "filterPlaceholder", "filterLocale", "inputId", "selectId", "dataKey", "filterBy", "autofocus", "resetFilterOnHide", "dropdownIcon", "optionLabel", "optionValue", "optionDisabled", "optionGroupLabel", "optionGroupChildren", "autoDisplayFirst", "group", "showClear", "emptyFilterMessage", "emptyMessage", "lazy", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "overlayOptions", "ariaFilterLabel", "ariaLabel", "ariaLabelledBy", "filterMatchMode", "maxlength", "tooltip", "tooltipPosition", "tooltipPositionStyle", "tooltipStyleClass", "autofocusFilter", "overlayDirection", "disabled", "itemSize", "autoZIndex", "baseZIndex", "showTransitionOptions", "hideTransitionOptions", "options", "filterValue"], outputs: ["onChange", "onFilter", "onFocus", "onBlur", "onClick", "onShow", "onHide", "onClear", "onLazyLoad"] }, { kind: "directive", type: i9.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "component", type: i10.Button, selector: "p-button", inputs: ["type", "iconPos", "icon", "badge", "label", "disabled", "loading", "loadingIcon", "style", "styleClass", "badgeClass", "ariaLabel"], outputs: ["onClick", "onFocus", "onBlur"] }, { kind: "pipe", type: i4.TranslatePipe, name: "translate" }] });
2165
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: LandingpgConfigComponent, decorators: [{
2166
- type: Component,
2167
- args: [{ selector: 'app-landingpg-config', template: "<div class=\"preference-container\">\r\n <form [formGroup]=\"AppNameForm\">\r\n <div class=\"mt-2\">\r\n <div class=\"form-group\">\r\n <div class=\"d-flex\">\r\n <div class=\"label-name\">{{ \"Generic_lib.LandingPageConfig\" | translate }}</div>\r\n <span class=\"madontary-icon\">*</span>\r\n </div>\r\n <div class=\" timezone-dropdown\">\r\n <p-dropdown [options]=\"ListofApplicationNames\"\r\n placeholder='{{\"Generic_lib.LandingPagePlaceHolder\" | translate}}'\r\n filterPlaceholder='{{\"Generic_lib.Search\" | translate }}' formControlName=\"userApp\"\r\n [filter]=\"!isAppNameLoading ? true:false\" optionLabel=\"applicationName\" filterBy=\"applicationName\"\r\n [showClear]=\"false\" panelStyleClass=\"{'dropdown-loader': isAppNameLoading}\">\r\n\r\n <ng-template pTemplate=\"header\">\r\n <div *ngIf=\"isAppNameLoading\" class=\"dropdown-loader-container\">\r\n <i class=\"pi pi-spin pi-spinner\"></i>\r\n </div>\r\n </ng-template>\r\n </p-dropdown>\r\n </div>\r\n <ng-container *ngIf=\"AppNameForm.get('userApp')?.invalid && AppNameForm.get('userApp')?.touched\">\r\n <span class=\"error-msg mt-1\">{{'Generic_lib.LandingPageValidation' | translate}}</span>\r\n </ng-container>\r\n </div>\r\n </div>\r\n <div class=\"mt-2 update-btn\">\r\n <p-button class=\"submit-btn\" label=\"{{'Generic_lib.Update' | translate}}\" [disabled]=\"AppNameForm.invalid\"\r\n iconPos=\"right\" [loading]=\"isAppNameUpdate\" (onClick)=\"getUpdateLandingPgPreference()\"></p-button>\r\n </div>\r\n </form>\r\n</div>", styles: [".preference-container .path-title{font-size:20px;color:#292f4c}.preference-container .form-group{margin-bottom:15px}.preference-container .label-name{font-size:12px;color:#292f4c;line-height:26px;font-weight:600}.preference-container .cur-text{font-size:12px;color:#676879;line-height:26px;font-weight:600}\n"] }]
2168
- }], ctorParameters: function () { return [{ type: CommonHeaderLibService }, { type: i2.FormBuilder }, { type: ToastMsgService }, { type: i4.TranslateService }, { type: EncrydecryRSAdataService }, { type: HttpCommonService }]; } });
2169
-
2170
- class GeneralConfigurationComponent {
2171
- constructor(libService, fb, msgService, encryptService, loginService, _validatePwdService, translateService, _vaptService, config, httpCommonService, httpGeneralConfigService) {
2172
- this.libService = libService;
2173
- this.fb = fb;
2174
- this.msgService = msgService;
2175
- this.encryptService = encryptService;
2176
- this.loginService = loginService;
2177
- this._validatePwdService = _validatePwdService;
2178
- this.translateService = translateService;
2179
- this._vaptService = _vaptService;
2180
- this.config = config;
2181
- this.httpCommonService = httpCommonService;
2182
- this.httpGeneralConfigService = httpGeneralConfigService;
2183
- // export class GeneralConfigurationComponent {
2184
- this.ShowPreferencePathScreen = true;
2185
- this.ShowUserProfileScreen = false;
2186
- this.ShowChangePasswordScreen = false;
2187
- this.ShowTimeZoneScreen = false;
2188
- this.ShowLandinPgScreen = false;
2189
- this.ShowTimeZoneBtn = false;
2190
- this.showStatus = false;
2191
- this.userAssetTypeList = [];
2192
- this.userAssetNameList = [];
2193
- this.userServiceList = [];
2194
- this.userSelectedTimezone = '';
2195
- // private domainName: string = '';
2196
- // private domainID: number;
2197
- // private LoggedInUserID: number;
2198
- // private username: string;
2199
- this.filePathName = '';
2200
- this.lastUpdatedFileStatus = '';
2201
- this.appSettingForm = new FormGroup({}); // Define form group
2202
- this.userResetPasswordForm = new FormGroup({}); //user Reset Password Form
2203
- this.timeZoneForm = new FormGroup({}); //user Reset Password Form
2204
- this.unsubscribeAPIEventListenerData = new Subject();
2205
- this.makeNewPwdVisible = true;
2206
- this.makeOldPwdVisible = true;
2207
- this.makeCnfrmPwdVisible = true;
2208
- this.isAssetTypeLoading = false;
2209
- this.isAssetNameLoading = false;
2210
- this.isConnectionMethodLoading = false;
2211
- this.isPathUpdated = false;
2212
- this.pwderrorMsg = '';
2213
- this.AssetTypeEvent = 'AssetType';
2214
- this.AssetNameEvent = 'AssetName';
2215
- this.ConnectionMethodEvent = 'ConnectionMethod';
2216
- this.pathSuccessMsg = errorMsg.PATHSUCCESS;
2217
- this.pathErrorMsg = errorMsg.PATHERROR;
2218
- this.apiURL = '';
2219
- }
2220
- ngOnInit() {
2221
- //Get Initalize Form
2222
- this.getInitalizeForm();
2223
- this.OpenPreferencePathScreen();
2224
- }
2225
- ngAfterViewInit() {
2226
- this.getTranslateContent();
2227
- // Get PWD Validation MSg From Validation Service
2228
- this._validatePwdService.listValidationMsg().subscribe((msg) => {
2229
- this.pwderrorMsg = msg;
2230
- });
2231
- }
2232
- getInitalizeForm() {
2233
- this.appSettingForm = this.fb.group({
2234
- AssetType: ['', Validators.required],
2235
- AssetName: ['', Validators.required],
2236
- ServiceName: ['', Validators.required],
2237
- filePathName: ['', [Validators.required, noSpaceAllowed()]],
2238
- });
2239
- this.timeZoneForm = this.fb.group({
2240
- timezone: ['', Validators.required],
2241
- });
2242
- // Password Reset Form
2243
- this.userResetPasswordForm = this.fb.group({
2244
- oldUserARCXWD: ['', [Validators.required]],
2245
- newUserARCXWD: [
2246
- '',
2247
- [Validators.required],
2248
- [this._validatePwdService.createValidator()],
2249
- ],
2250
- crnmNewUserARCXWD: ['', [Validators.required]],
2251
- }, {
2252
- validator: ConfirmedValidator('newUserARCXWD', 'crnmNewUserARCXWD'),
2253
- });
2254
- }
2255
- // //Method: Convert text one Lang. to another
2256
- getTranslateContent() {
2257
- this.translateService
2258
- .get([
2259
- 'Generic_lib.PreferencePathSuccessMsg',
2260
- 'Generic_lib.PreferencePathErrorMsg',
2261
- ])
2262
- .pipe(takeUntil(this.unsubscribeAPIEventListenerData))
2263
- .subscribe((trans) => {
2264
- this.pathSuccessMsg = trans['Generic_lib.PreferencePathSuccessMsg'];
2265
- this.pathErrorMsg = trans['Generic_lib.PreferencePathErrorMsg'];
2266
- });
2267
- }
2268
- OpenPreferencePathScreen() {
2269
- this.closeAllScreen();
2270
- setTimeout(() => {
2271
- this.ShowPreferencePathScreen = true;
2272
- this.appSettingForm.reset();
2273
- this.userAssetTypeList = [];
2274
- this.userAssetNameList = [];
2275
- this.userServiceList = [];
2276
- this.getServiceAssetDetails();
2277
- }, 10);
2278
- }
2279
- OpenUserProfileScreen() {
2280
- this.closeAllScreen();
2281
- this.ShowUserProfileScreen = true;
2282
- }
2283
- OpenChangePasswordScreen() {
2284
- this.closeAllScreen();
2285
- this.ShowChangePasswordScreen = true;
2286
- this.userResetPasswordForm.reset();
2287
- // this.getEncryptKey();
2288
- }
2289
- OpenTimezoneScreen() {
2290
- this.closeAllScreen();
2291
- this.ShowTimeZoneScreen = true;
2292
- }
2293
- OpenLandingPgConfig() {
2294
- this.closeAllScreen();
2295
- this.ShowLandinPgScreen = true;
2296
- }
2297
- closeAllScreen() {
2298
- this.ShowPreferencePathScreen = false;
2299
- this.ShowUserProfileScreen = false;
2300
- this.ShowChangePasswordScreen = false;
2301
- this.ShowTimeZoneScreen = false;
2302
- this.ShowLandinPgScreen = false;
2303
- }
2304
- preferencePathValueChange(eventName) {
2305
- var _a, _b, _c;
2306
- if (eventName === this.AssetTypeEvent) {
2307
- const assetType = (_a = this.appSettingForm.get('AssetType')) === null || _a === void 0 ? void 0 : _a.value;
2308
- this.showStatus = false;
2309
- this.resetFormfields(['AssetName', 'ServiceName', 'filePathName']);
2310
- this.userAssetNameList = [];
2311
- this.userServiceList = [];
2312
- this.getServiceAssetName(assetType['assetTypeID']);
2313
- }
2314
- else if (eventName === this.AssetNameEvent) {
2315
- const assetName = (_b = this.appSettingForm.get('AssetName')) === null || _b === void 0 ? void 0 : _b.value;
2316
- this.showStatus = false;
2317
- this.resetFormfields(['ServiceName', 'filePathName']);
2318
- this.userServiceList = [];
2319
- this.fetchServiceNameByAssetTypeEvent(assetName['assetName']);
2320
- }
2321
- else if (eventName === this.ConnectionMethodEvent) {
2322
- const ServiceDetails = (_c = this.appSettingForm.get('ServiceName')) === null || _c === void 0 ? void 0 : _c.value;
2323
- this.showStatus = false;
2324
- this.resetFormfields(['filePathName']);
2325
- this.getFilePathDetails(ServiceDetails['serviceTypeId']);
2326
- }
2327
- }
2328
- // /*Action : Used to Get Asset Type to update Prefrence Path of Connectors */
2329
- getServiceAssetDetails() {
2330
- this.isAssetTypeLoading = true;
2331
- this.httpGeneralConfigService
2332
- .getUserPreferredAssetTypeDetails()
2333
- .pipe(takeUntil(this.unsubscribeAPIEventListenerData), finalize(() => {
2334
- this.isAssetTypeLoading = false;
2335
- }))
2336
- .subscribe((data) => {
2337
- this.userAssetTypeList = data;
2338
- });
2339
- }
2340
- // /*Action : Used to Get Asset Name to update Prefrence Path of that Asset's Connectors */
2341
- getServiceAssetName(assetTypeID) {
2342
- this.isAssetNameLoading = true;
2343
- let payload = {
2344
- assetTypeId: assetTypeID,
2345
- };
2346
- this.httpGeneralConfigService
2347
- .getUserPreferredAssetName(payload)
2348
- .pipe(takeUntil(this.unsubscribeAPIEventListenerData), finalize(() => {
2349
- this.isAssetNameLoading = false;
2350
- }))
2351
- .subscribe((data) => {
2352
- this.userAssetNameList = data;
2353
- });
2354
- }
2355
- // /*Method : GET
2356
- // Action : get User Assigned ServiceName By AssetTypeEvent */
2357
- fetchServiceNameByAssetTypeEvent(assetName) {
2358
- this.isConnectionMethodLoading = true;
2359
- let payload = {
2360
- assetName: assetName,
2361
- };
2362
- this.httpGeneralConfigService
2363
- .getServiceNameByAssetTypeEvent(payload)
2364
- .pipe(takeUntil(this.unsubscribeAPIEventListenerData), finalize(() => {
2365
- this.isConnectionMethodLoading = false;
2366
- }))
2367
- .subscribe((data) => {
2368
- this.userServiceList = data;
2369
- });
2370
- }
2371
- // /*Method : GET
2372
- // Action : Fetch User's File Path Details and Status already set or not */
2373
- getFilePathDetails(serviceID) {
2374
- let payload = {
2375
- // userId: this.LoggedInUserID,
2376
- serviceTypeId: serviceID,
2377
- };
2378
- this.httpGeneralConfigService
2379
- .getPreferencePathDetails(payload)
2380
- .pipe(takeUntil(this.unsubscribeAPIEventListenerData))
2381
- .subscribe((res) => {
2382
- this.preferencePathID = res['spmId'];
2383
- if (res && res['currentSetting'] && res['lastUpdate']) {
2384
- this.showStatus = true;
2385
- this.filePathName = res['currentSetting'];
2386
- this.lastUpdatedFileStatus = res['lastUpdate'];
2387
- }
2388
- else {
2389
- this.filePathName = '';
2390
- this.showStatus = false;
2391
- this.lastUpdatedFileStatus = '';
2392
- }
2393
- });
2394
- }
2395
- // /*Action : It saves or updates a preference path of user */
2396
- setUserPreferencePath(appSettingForm) {
2397
- this.toggleBtnLoadder(true);
2398
- const userpath = String(appSettingForm.value['filePathName']).trim();
2399
- let payload = {
2400
- // userId: this.LoggedInUserID,
2401
- // userLogTime: this._cookieService.getCookieValue(COOKIECONSTANT.SESSIONID),
2402
- serviceTypeId: appSettingForm.value['ServiceName']['serviceTypeId'],
2403
- supDescription: userpath,
2404
- spmId: this.preferencePathID,
2405
- };
2406
- this.httpGeneralConfigService
2407
- .updatePreferencePath(payload)
2408
- .pipe(takeUntil(this.unsubscribeAPIEventListenerData), finalize(() => {
2409
- this.toggleBtnLoadder(false);
2410
- }))
2411
- .subscribe((res) => {
2412
- if (res) {
2413
- this.resetForm();
2414
- this.showStatus = false;
2415
- this.msgService.success(this.pathSuccessMsg);
2416
- }
2417
- else {
2418
- this.msgService.error(this.pathErrorMsg);
2419
- }
2420
- });
2421
- }
2422
- // //Method : Used to perform password reset of User
2423
- resetLoggedInPwd() {
2424
- if (this._vaptService.hasUnsafeInput(this.userResetPasswordForm.value)) {
2425
- this.msgService.error(errorMsg.SCRIPTERROR);
2426
- return;
2427
- }
2428
- this.userResetPasswordForm.markAllAsTouched();
2429
- if (this.userResetPasswordForm.valid) {
2430
- this.changeLoggedInPwd();
2431
- }
2432
- }
2433
- // /*Method: will User New Password to API */
2434
- changeLoggedInPwd() {
2435
- //For Encrp/Dec
2436
- let oldUserARCXWD = this.encryptService.encryptViaRSA(this.userResetPasswordForm.value['oldUserARCXWD']);
2437
- //For Encrp/Dec
2438
- let newUserARCXWD = this.encryptService.encryptViaRSA(this.userResetPasswordForm.value['newUserARCXWD']);
2439
- let userPwdDetails = {
2440
- ipAddress: '',
2441
- oldUserARCXWD: oldUserARCXWD,
2442
- newUserARCXWD: newUserARCXWD,
2443
- authenticationType: 0,
2444
- };
2445
- this.toggleBtnLoadder(true);
2446
- this.httpCommonService
2447
- .setNewpassword(userPwdDetails)
2448
- .pipe(takeUntil(this.unsubscribeAPIEventListenerData), finalize(() => {
2449
- this.toggleBtnLoadder(false);
2450
- }))
2451
- .subscribe((data) => {
2452
- if (data['success']) {
2453
- this.msgService.success(data['message']);
2454
- this.userResetPasswordForm.reset();
2455
- }
2456
- else if (!data['success']) {
2457
- this.msgService.error(data['errorMessage']);
2458
- }
2459
- });
2460
- }
2461
- // /*Method:
2462
- // Action : Get Public Key for encryption of User Details */
2463
- getEncryptKey() {
2464
- let params = {
2465
- type: 0,
2466
- };
2467
- this.loginService
2468
- .getPrivateKey(params)
2469
- .pipe(takeUntil(this.unsubscribeAPIEventListenerData))
2470
- .subscribe((data) => {
2471
- if (data['success'] === true) {
2472
- LoggedInUserInfo.privateKey = data['result'];
2473
- }
2474
- else if (data['success'] === false) {
2475
- this.msgService.error('Session Token Error !');
2476
- }
2477
- });
2478
- }
2479
- // /*Method : POST
2480
- // Action : Get configuration ID based on to show hide Time Zone*/
2481
- getglobalConfigDetails() {
2482
- this.loginService
2483
- .getglobalConfigDetails('1', [336])
2484
- .pipe(takeUntil(this.unsubscribeAPIEventListenerData))
2485
- .subscribe((data) => {
2486
- if (data && data.length > 0) {
2487
- data.forEach((element) => {
2488
- if (element && element['id'] === 336 && element['value'] === '0') {
2489
- this.ShowTimeZoneBtn = true;
2490
- }
2491
- else {
2492
- this.ShowTimeZoneBtn = false;
2493
- }
2494
- });
2495
- }
2496
- });
2497
- }
2498
- // // Show/Hide Password Fileds of Change Pwd form
2499
- togglePasswordVisibility(flag) {
2500
- if (flag === 1) {
2501
- this.makeOldPwdVisible = !this.makeOldPwdVisible;
2502
- }
2503
- else if (flag === 2) {
2504
- this.makeNewPwdVisible = !this.makeNewPwdVisible;
2505
- }
2506
- else if (flag === 3) {
2507
- this.makeCnfrmPwdVisible = !this.makeCnfrmPwdVisible;
2508
- }
2509
- }
2510
- resetForm() {
2511
- this.appSettingForm.reset();
2512
- }
2513
- resetFormfields(fields) {
2514
- fields.forEach((fieldsName) => {
2515
- var _a;
2516
- (_a = this.appSettingForm.get(fieldsName)) === null || _a === void 0 ? void 0 : _a.reset();
2517
- });
2518
- }
2519
- toggleBtnLoadder(flag) {
2520
- this.isPathUpdated = flag;
2521
- }
2522
- ngOnDestroy() {
2523
- this.unsubscribeAPIEventListenerData.next(true);
2524
- this.unsubscribeAPIEventListenerData.complete();
2525
- }
2526
- }
2527
- GeneralConfigurationComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: GeneralConfigurationComponent, deps: [{ token: CommonHeaderLibService }, { token: i2.FormBuilder }, { token: ToastMsgService }, { token: EncrydecryRSAdataService }, { token: RESTLoginFormService }, { token: ASYNCPasswordcheckService }, { token: i4.TranslateService }, { token: VaptValidationService }, { token: i1$3.DynamicDialogConfig }, { token: HttpCommonService }, { token: HttpGeneralConfigurationService }], target: i0.ɵɵFactoryTarget.Component });
2528
- GeneralConfigurationComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: GeneralConfigurationComponent, selector: "app-general-configuration", providers: [DialogService], ngImport: i0, template: "<div class=\"row my-3\">\r\n <!-- Left_Card_Started -->\r\n <div class=\"col-lg-4 pl-0\">\r\n <div class=\"left-card\">\r\n <div class=\"p-3\">\r\n <div\r\n class=\"profile-card\"\r\n [ngClass]=\"{ active: ShowPreferencePathScreen }\"\r\n (click)=\"OpenPreferencePathScreen()\"\r\n >\r\n <div class=\"p-2\">\r\n <div class=\"profile-label\">\r\n {{ \"Generic_lib.PreferencePath\" | translate }}\r\n </div>\r\n </div>\r\n </div>\r\n <div\r\n class=\"profile-card\"\r\n [ngClass]=\"{ active: ShowChangePasswordScreen }\"\r\n (click)=\"OpenChangePasswordScreen()\"\r\n >\r\n <div class=\"p-2\">\r\n <div class=\"profile-label\">\r\n {{ \"Generic_lib.ChangePassword\" | translate }}\r\n </div>\r\n </div>\r\n </div>\r\n <div\r\n class=\"profile-card\"\r\n [ngClass]=\"{ active: ShowTimeZoneScreen }\"\r\n (click)=\"OpenTimezoneScreen()\"\r\n >\r\n <div class=\"p-2\">\r\n <div class=\"profile-label\">\r\n {{ \"Generic_lib.PreferredTimezone\" | translate }}\r\n </div>\r\n </div>\r\n </div>\r\n <div\r\n class=\"profile-card\"\r\n [ngClass]=\"{ active: ShowLandinPgScreen }\"\r\n (click)=\"OpenLandingPgConfig()\"\r\n >\r\n <div class=\"p-2\">\r\n <div class=\"profile-label\">\r\n {{ \"Generic_lib.LandingPageConfig\" | translate }}\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n <!-- Left_Card_Ended -->\r\n\r\n <!--User Profile -->\r\n <ng-container *ngIf=\"ShowUserProfileScreen\">\r\n <div class=\"col-lg-6\">\r\n <div class=\"initial-text\">\r\n {{ \"AK\" }}\r\n </div>\r\n <div class=\"preference-container\">\r\n <!--Card-->\r\n <div class=\"mt-3\">\r\n <div class=\"form-group\">\r\n <div class=\"label-name\">\r\n {{ \"Generic_lib.UserName\" | translate }}\r\n </div>\r\n <div class=\"input-dropdown d-flex align-items-center\">\r\n <input\r\n type=\"text\"\r\n pInputText\r\n formControlName=\"text\"\r\n placeholder=\"{{ 'Generic_lib.UserName' | translate }}\"\r\n autocomplete=\"off\"\r\n />\r\n <img\r\n src=\"assets/common-header-lib/images/images/user-name.svg\"\r\n alt=\"Icon\"\r\n class=\"position-absolute px-2\"\r\n />\r\n </div>\r\n </div>\r\n\r\n <div class=\"form-group\">\r\n <div class=\"label-name\">{{ \"Generic_lib.Email\" | translate }}</div>\r\n <div class=\"input-dropdown d-flex align-items-center\">\r\n <input\r\n type=\"text\"\r\n pInputText\r\n formControlName=\"text\"\r\n placeholder=\"{{ 'Generic_lib.EmailAddress' | translate }}\"\r\n autocomplete=\"off\"\r\n />\r\n <img\r\n src=\"assets/common-header-lib/images/gc-mail.svg\"\r\n alt=\"Icon\"\r\n class=\"position-absolute px-2\"\r\n />\r\n </div>\r\n </div>\r\n <div class=\"mt-4\">\r\n <p-button class=\"submit-btn\" label=\"Submit\"></p-button>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n </ng-container>\r\n\r\n <!-- Preference PathScreen -->\r\n <ng-container>\r\n <!-- <ng-container *ngIf=\"ShowPreferencePathScreen\"> -->\r\n <div class=\"col-lg-6\" [hidden]=\"!ShowPreferencePathScreen\">\r\n <div class=\"preference-container\">\r\n <div class=\"mt-3\">\r\n <form [formGroup]=\"appSettingForm\">\r\n <div class=\"form-group\">\r\n <div class=\"d-flex\">\r\n <div class=\"label-name\">\r\n {{ \"Generic_lib.AssetType\" | translate }}\r\n </div>\r\n <span class=\"madontary-icon\">*</span>\r\n </div>\r\n <div class=\"assets-dropdown\">\r\n <p-dropdown\r\n [options]=\"userAssetTypeList\"\r\n formControlName=\"AssetType\"\r\n placeholder=\"{{\r\n 'Generic_lib.AssetTypePlaceholder' | translate\r\n }}\"\r\n filterPlaceholder=\"{{ 'Generic_lib.Search' | translate }}\"\r\n (onChange)=\"preferencePathValueChange(AssetTypeEvent)\"\r\n optionLabel=\"assetType\"\r\n [filter]=\"!isAssetTypeLoading ? true : false\"\r\n filterBy=\"assetType\"\r\n [showClear]=\"false\"\r\n [resetFilterOnHide]=\"true\"\r\n panelStyleClass=\"{'dropdown-loader': isAssetTypeLoading}\"\r\n >\r\n <ng-template pTemplate=\"header\">\r\n <div\r\n *ngIf=\"isAssetTypeLoading\"\r\n class=\"dropdown-loader-container\"\r\n >\r\n <i class=\"pi pi-spin pi-spinner\"></i>\r\n </div>\r\n </ng-template>\r\n </p-dropdown>\r\n </div>\r\n <ng-container\r\n *ngIf=\"\r\n appSettingForm.get('AssetType')?.invalid &&\r\n appSettingForm.get('AssetType')?.touched\r\n \"\r\n >\r\n <span class=\"error-msg mt-2\">{{\r\n \"Generic_lib.AssetTypeFieldValidation\" | translate\r\n }}</span>\r\n </ng-container>\r\n </div>\r\n <div class=\"form-group\">\r\n <div class=\"d-flex\">\r\n <div class=\"label-name\">\r\n {{ \"Generic_lib.AssetName\" | translate }}\r\n </div>\r\n <span class=\"madontary-icon\">*</span>\r\n </div>\r\n <div class=\"assets-dropdown\">\r\n <p-dropdown\r\n [options]=\"userAssetNameList\"\r\n formControlName=\"AssetName\"\r\n placeholder=\"{{\r\n 'Generic_lib.AssetNamePlaceholder' | translate\r\n }}\"\r\n filterPlaceholder=\"{{ 'Generic_lib.Search' | translate }}\"\r\n optionLabel=\"assetName\"\r\n [filter]=\"!isAssetNameLoading ? true : false\"\r\n filterBy=\"assetType\"\r\n (onChange)=\"preferencePathValueChange(AssetNameEvent)\"\r\n filterBy=\"assetName\"\r\n panelStyleClass=\"{'dropdown-loader': isAssetNameLoading}\"\r\n [showClear]=\"false\"\r\n >\r\n <ng-template pTemplate=\"header\">\r\n <div\r\n *ngIf=\"isAssetNameLoading\"\r\n class=\"dropdown-loader-container\"\r\n >\r\n <i class=\"pi pi-spin pi-spinner\"></i>\r\n </div>\r\n </ng-template>\r\n </p-dropdown>\r\n </div>\r\n <ng-container\r\n *ngIf=\"\r\n appSettingForm.get('AssetName')?.invalid &&\r\n appSettingForm.get('AssetName')?.touched\r\n \"\r\n >\r\n <span class=\"error-msg mt-2\">{{\r\n \"Generic_lib.AssetNameFieldValidation\" | translate\r\n }}</span>\r\n </ng-container>\r\n </div>\r\n <div class=\"form-group\">\r\n <div class=\"d-flex\">\r\n <div class=\"label-name\">\r\n {{ \"Generic_lib.ConnectionMethod\" | translate }}\r\n </div>\r\n <span class=\"madontary-icon\">*</span>\r\n </div>\r\n <div class=\"assets-dropdown\">\r\n <p-dropdown\r\n [options]=\"userServiceList\"\r\n formControlName=\"ServiceName\"\r\n filterPlaceholder=\"{{ 'Generic_lib.Search' | translate }}\"\r\n placeholder=\"{{\r\n 'Generic_lib.ConnectionMethodPlaceholder' | translate\r\n }}\"\r\n optionLabel=\"tbvDescrption\"\r\n [filter]=\"true\"\r\n filterBy=\"tbvDescrption\"\r\n (onChange)=\"preferencePathValueChange(ConnectionMethodEvent)\"\r\n [filter]=\"!isConnectionMethodLoading ? true : false\"\r\n [showClear]=\"false\"\r\n panelStyleClass=\"{'dropdown-loader': isConnectionMethodLoading}\"\r\n >\r\n <ng-template pTemplate=\"header\">\r\n <div\r\n *ngIf=\"isConnectionMethodLoading\"\r\n class=\"dropdown-loader-container\"\r\n >\r\n <i class=\"pi pi-spin pi-spinner\"></i>\r\n </div> </ng-template\r\n ></p-dropdown>\r\n </div>\r\n <ng-container\r\n *ngIf=\"\r\n appSettingForm.get('ServiceName')?.invalid &&\r\n appSettingForm.get('ServiceName')?.touched\r\n \"\r\n >\r\n <span class=\"error-msg mt-2\">{{\r\n \"Generic_lib.ConnectionMethodFieldValidation\" | translate\r\n }}</span>\r\n </ng-container>\r\n </div>\r\n <div class=\"form-group position-relative\">\r\n <div class=\"d-flex\">\r\n <div class=\"label-name\">\r\n {{ \"Generic_lib.PreferencePath\" | translate }}\r\n </div>\r\n <span class=\"madontary-icon\">*</span>\r\n </div>\r\n <div class=\"input-dropdown d-flex align-items-center\">\r\n <input\r\n type=\"text\"\r\n placeholder=\"{{ 'Generic_lib.PreferencePath' | translate }}\"\r\n pInputText\r\n formControlName=\"filePathName\"\r\n id=\"filepath\"\r\n name=\"filepath\"\r\n autocomplete=\"off\"\r\n />\r\n <img\r\n src=\"assets/common-header-lib/images/filepath.svg\"\r\n alt=\"path Icon\"\r\n class=\"position-absolute mx-2 img-lock ext\"\r\n />\r\n </div>\r\n <ng-container\r\n *ngIf=\"\r\n appSettingForm.get('filePathName')?.invalid &&\r\n (appSettingForm.get('filePathName')?.touched ||\r\n appSettingForm.get('filePathName')?.dirty)\r\n \"\r\n >\r\n <ng-container\r\n *ngIf=\"\r\n appSettingForm.controls['filePathName'].errors?.['required']\r\n \"\r\n >\r\n <span class=\"error-msg mt-2\">{{\r\n \"Generic_lib.PreferencePathFieldValidation\" | translate\r\n }}</span>\r\n </ng-container>\r\n <ng-container\r\n *ngIf=\"\r\n appSettingForm.controls['filePathName'].errors?.['noSpace']\r\n \"\r\n >\r\n <span class=\"error-msg mt-2\">{{\r\n \"Generic_lib.PreferencePathFieldSpaceValidation\" | translate\r\n }}</span>\r\n </ng-container>\r\n </ng-container>\r\n </div>\r\n <ng-container *ngIf=\"showStatus\">\r\n <div class=\"form-group d-flex align-items-center\">\r\n <div class=\"label-name\">\r\n {{ \"Generic_lib.CurrentSetting\" | translate }} :\r\n </div>\r\n <div class=\"cur-text mx-2\">{{ filePathName }}</div>\r\n </div>\r\n <div class=\"form-group d-flex align-items-center\">\r\n <div class=\"label-name\">\r\n {{ \"Generic_lib.LastUpdated\" | translate }}\r\n </div>\r\n <div class=\"cur-text mx-2\">{{ lastUpdatedFileStatus }}</div>\r\n </div>\r\n </ng-container>\r\n <div class=\"mt-4\">\r\n <p-button\r\n class=\"submit-btn\"\r\n label=\"{{ 'Generic_lib.Update' | translate }}\"\r\n [disabled]=\"appSettingForm.invalid\"\r\n (onClick)=\"setUserPreferencePath(appSettingForm)\"\r\n iconPos=\"right\"\r\n [loading]=\"isPathUpdated\"\r\n ></p-button>\r\n </div>\r\n </form>\r\n </div>\r\n </div>\r\n </div>\r\n </ng-container>\r\n\r\n <!-- TimeZone Screen -->\r\n <ng-container *ngIf=\"ShowTimeZoneScreen\">\r\n <div class=\"col-lg-6\">\r\n <app-timezone-configuration></app-timezone-configuration>\r\n </div>\r\n </ng-container>\r\n\r\n <!-- LandingPg Config Screen -->\r\n <ng-container *ngIf=\"ShowLandinPgScreen\">\r\n <div class=\"col-lg-6\">\r\n <app-landingpg-config></app-landingpg-config>\r\n </div>\r\n </ng-container>\r\n\r\n <!--Change Password Screen -->\r\n <!-- <ng-container *ngIf=\"ShowChangePasswordScreen\"> -->\r\n <ng-container>\r\n <div class=\"col-lg-6\" [hidden]=\"!ShowChangePasswordScreen\">\r\n <div class=\"preference-container\">\r\n <div class=\"mt-3\">\r\n <form [formGroup]=\"userResetPasswordForm\">\r\n <div class=\"form-group\">\r\n <div class=\"d-flex\">\r\n <div class=\"label-name\">\r\n {{ \"Generic_lib.CurrentPassword\" | translate }}\r\n </div>\r\n <span class=\"madontary-icon\">*</span>\r\n </div>\r\n <div\r\n class=\"input-dropdown d-flex align-items-center position-relative\"\r\n >\r\n <div class=\"password-checkbox-right\">\r\n <div class=\"checkbox-visibility-icon\">\r\n <input\r\n type=\"checkbox\"\r\n (click)=\"togglePasswordVisibility(1)\"\r\n autocomplete=\"off\"\r\n />\r\n <span></span>\r\n </div>\r\n </div>\r\n <input\r\n type=\"{{ makeOldPwdVisible ? 'password' : 'text' }}\"\r\n placeholder=\"{{\r\n 'Generic_lib.PasswordPlaceholder' | translate\r\n }}\"\r\n pInputText\r\n formControlName=\"oldUserARCXWD\"\r\n autocomplete=\"off\"\r\n id=\"oldpwd\"\r\n name=\"oldpwd\"\r\n autocomplete=\"off\"\r\n />\r\n\r\n <img\r\n src=\"assets/common-header-lib/images/lock-pass.svg\"\r\n alt=\"lock Icon\"\r\n class=\"position-absolute mx-2 img-lock\"\r\n />\r\n </div>\r\n <ng-container\r\n *ngIf=\"\r\n userResetPasswordForm.get('oldUserARCXWD')?.invalid &&\r\n userResetPasswordForm.get('oldUserARCXWD')?.touched\r\n \"\r\n >\r\n <span class=\"error-msg mt-2\">{{\r\n \"Generic_lib.PasswordFieldValidation\" | translate\r\n }}</span>\r\n </ng-container>\r\n </div>\r\n <div class=\"form-group\">\r\n <div class=\"d-flex\">\r\n <div class=\"label-name\">\r\n {{ \"Generic_lib.NewPassword\" | translate }}\r\n </div>\r\n <span class=\"madontary-icon\">*</span>\r\n </div>\r\n <div\r\n class=\"input-dropdown d-flex align-items-center position-relative\"\r\n >\r\n <div class=\"password-checkbox-right\">\r\n <div class=\"checkbox-visibility-icon\">\r\n <input\r\n type=\"checkbox\"\r\n (click)=\"togglePasswordVisibility(2)\"\r\n autocomplete=\"off\"\r\n />\r\n <span></span>\r\n </div>\r\n </div>\r\n <input\r\n type=\"{{ makeNewPwdVisible ? 'password' : 'text' }}\"\r\n placeholder=\"{{\r\n 'Generic_lib.NewPasswordPlaceholder' | translate\r\n }}\"\r\n pInputText\r\n formControlName=\"newUserARCXWD\"\r\n id=\"newpwd\"\r\n autocomplete=\"off\"\r\n name=\"newpwd\"\r\n autocomplete=\"off\"\r\n />\r\n\r\n <img\r\n src=\"assets/common-header-lib/images/lock-pass.svg\"\r\n alt=\"lock Icon\"\r\n class=\"position-absolute mx-2 img-lock\"\r\n />\r\n </div>\r\n <ng-container\r\n *ngIf=\"\r\n userResetPasswordForm\r\n .get('newUserARCXWD')\r\n ?.hasError('required') &&\r\n userResetPasswordForm.get('newUserARCXWD')?.touched\r\n \"\r\n >\r\n <span class=\"error-msg mt-2\">{{\r\n \"Generic_lib.NewPasswordFieldValidation\" | translate\r\n }}</span>\r\n </ng-container>\r\n <ng-container\r\n *ngIf=\"\r\n userResetPasswordForm\r\n .get('newUserARCXWD')\r\n ?.hasError('pwdInvalid') &&\r\n userResetPasswordForm.get('newUserARCXWD')?.touched\r\n \"\r\n >\r\n <span class=\"error-msg mt-2\">{{ pwderrorMsg }}</span>\r\n </ng-container>\r\n </div>\r\n <div class=\"form-group\">\r\n <div class=\"d-flex\">\r\n <div class=\"label-name\">\r\n {{ \"Generic_lib.ConfirmPassword\" | translate }}\r\n </div>\r\n <span class=\"madontary-icon\">*</span>\r\n </div>\r\n <div\r\n class=\"input-dropdown d-flex align-items-center position-relative\"\r\n >\r\n <div class=\"password-checkbox-right\">\r\n <div class=\"checkbox-visibility-icon\">\r\n <input\r\n type=\"checkbox\"\r\n (click)=\"togglePasswordVisibility(3)\"\r\n autocomplete=\"off\"\r\n />\r\n <span></span>\r\n </div>\r\n </div>\r\n <input\r\n type=\"{{ makeCnfrmPwdVisible ? 'password' : 'text' }}\"\r\n placeholder=\"{{\r\n 'Generic_lib.ConfirmPasswordPlaceholder' | translate\r\n }}\"\r\n pInputText\r\n formControlName=\"crnmNewUserARCXWD\"\r\n autocomplete=\"off\"\r\n id=\"crnmnewpwd\"\r\n name=\"crnmnewpwd\"\r\n />\r\n\r\n <img\r\n src=\"assets/common-header-lib/images/lock-pass.svg\"\r\n alt=\"eye Icon\"\r\n class=\"position-absolute mx-2 img-lock\"\r\n />\r\n </div>\r\n <ng-container\r\n *ngIf=\"\r\n userResetPasswordForm\r\n .get('crnmNewUserARCXWD')\r\n ?.hasError('required') &&\r\n userResetPasswordForm.get('crnmNewUserARCXWD')?.touched\r\n \"\r\n >\r\n <span class=\"error-msg mt-2\">{{\r\n \"Generic_lib.ConfirmPasswordFieldValidation\" | translate\r\n }}</span>\r\n </ng-container>\r\n <span\r\n class=\"error-msg mt-2\"\r\n *ngIf=\"\r\n userResetPasswordForm\r\n .get('crnmNewUserARCXWD')\r\n ?.hasError('confirmedValidator')\r\n \"\r\n >\r\n {{\r\n \"Generic_lib.ConfirmPasswordFieldNewValidation\" | translate\r\n }}\r\n </span>\r\n </div>\r\n\r\n <div class=\"mt-4\">\r\n <p-button\r\n class=\"submit-btn\"\r\n label=\"{{ 'Generic_lib.Update' | translate }}\"\r\n iconPos=\"right\"\r\n [loading]=\"isPathUpdated\"\r\n label=\"Update\"\r\n (onClick)=\"resetLoggedInPwd()\"\r\n ></p-button>\r\n </div>\r\n </form>\r\n </div>\r\n </div>\r\n </div>\r\n </ng-container>\r\n</div>\r\n", styles: [".pl{padding-left:0!important}.left-card{height:450px!important;background:#f6f7fb!important;border-radius:8px!important}.left-card .profile-label{font-size:13px!important;color:#292f4c!important;font-weight:600!important}.left-card .profile-text{color:#676879!important;font-size:12px!important;font-weight:400!important;line-height:20px!important}.initial-text{width:50px;height:50px;display:flex;align-items:center;justify-content:center;font-size:15px;border-radius:50%;color:#fff;background-color:#8e562e}.preference-container .path-title{font-size:20px;color:#292f4c}.preference-container .form-group{margin-bottom:15px}.preference-container .label-name{font-size:12px;color:#292f4c;line-height:26px;font-weight:600}.preference-container .cur-text{font-size:12px;color:#676879;line-height:26px;font-weight:600}.checkbox-visibility-icon{position:relative}.checkbox-visibility-icon input[type=checkbox]{opacity:0;position:absolute;top:4px;left:5px;transform:scale(1.7);z-index:2;cursor:pointer}.checkbox-visibility-icon input[type=checkbox]:checked+span{background:url(assets/common-header-lib/images/login-bg/visibility.svg);background-repeat:no-repeat;background-position:0px;height:12px;width:18px;display:block;background-size:17px}@media (min-width: 992px){.checkbox-visibility-icon input[type=checkbox]:checked+span{height:12px;width:18px;background-size:17px}}.checkbox-visibility-icon input[type=checkbox]+span{background:url(assets/common-header-lib/images/login-bg/visibility_off.svg);background-repeat:no-repeat;background-position:0px;height:12px;width:18px;display:block;background-size:17px}@media (min-width: 992px){.checkbox-visibility-icon input[type=checkbox]+span{height:24px;width:18px;background-size:17px}}.input-dropdown .p-inputtext{width:100%!important;border-radius:4px!important;font-size:12px!important;padding-left:28px!important;height:38px!important;border:1px solid #ced4da!important}.p-dropdown-filter-container input{border:1px solid #ced4da!important}.profile-card{cursor:pointer}.profile-card:hover{background:#e9ecef;color:#292f4c;border-radius:4px}.profile-card.active{border-radius:4px;cursor:pointer;background:#dcdfec url(assets/common-header-lib/images/grey-arrow.svg) no-repeat 96%}\n"], dependencies: [{ kind: "directive", type: i6.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i6.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: i13.InputText, selector: "[pInputText]" }, { kind: "component", type: i8.Dropdown, selector: "p-dropdown", inputs: ["scrollHeight", "filter", "name", "style", "panelStyle", "styleClass", "panelStyleClass", "readonly", "required", "editable", "appendTo", "tabindex", "placeholder", "filterPlaceholder", "filterLocale", "inputId", "selectId", "dataKey", "filterBy", "autofocus", "resetFilterOnHide", "dropdownIcon", "optionLabel", "optionValue", "optionDisabled", "optionGroupLabel", "optionGroupChildren", "autoDisplayFirst", "group", "showClear", "emptyFilterMessage", "emptyMessage", "lazy", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "overlayOptions", "ariaFilterLabel", "ariaLabel", "ariaLabelledBy", "filterMatchMode", "maxlength", "tooltip", "tooltipPosition", "tooltipPositionStyle", "tooltipStyleClass", "autofocusFilter", "overlayDirection", "disabled", "itemSize", "autoZIndex", "baseZIndex", "showTransitionOptions", "hideTransitionOptions", "options", "filterValue"], outputs: ["onChange", "onFilter", "onFocus", "onBlur", "onClick", "onShow", "onHide", "onClear", "onLazyLoad"] }, { kind: "directive", type: i9.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "component", type: i10.Button, selector: "p-button", inputs: ["type", "iconPos", "icon", "badge", "label", "disabled", "loading", "loadingIcon", "style", "styleClass", "badgeClass", "ariaLabel"], outputs: ["onClick", "onFocus", "onBlur"] }, { kind: "component", type: TimezoneConfigurationComponent, selector: "app-timezone-configuration", outputs: ["closepopup"] }, { kind: "component", type: LandingpgConfigComponent, selector: "app-landingpg-config" }, { kind: "pipe", type: i4.TranslatePipe, name: "translate" }] });
2529
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: GeneralConfigurationComponent, decorators: [{
2530
- type: Component,
2531
- args: [{ selector: 'app-general-configuration', providers: [DialogService], template: "<div class=\"row my-3\">\r\n <!-- Left_Card_Started -->\r\n <div class=\"col-lg-4 pl-0\">\r\n <div class=\"left-card\">\r\n <div class=\"p-3\">\r\n <div\r\n class=\"profile-card\"\r\n [ngClass]=\"{ active: ShowPreferencePathScreen }\"\r\n (click)=\"OpenPreferencePathScreen()\"\r\n >\r\n <div class=\"p-2\">\r\n <div class=\"profile-label\">\r\n {{ \"Generic_lib.PreferencePath\" | translate }}\r\n </div>\r\n </div>\r\n </div>\r\n <div\r\n class=\"profile-card\"\r\n [ngClass]=\"{ active: ShowChangePasswordScreen }\"\r\n (click)=\"OpenChangePasswordScreen()\"\r\n >\r\n <div class=\"p-2\">\r\n <div class=\"profile-label\">\r\n {{ \"Generic_lib.ChangePassword\" | translate }}\r\n </div>\r\n </div>\r\n </div>\r\n <div\r\n class=\"profile-card\"\r\n [ngClass]=\"{ active: ShowTimeZoneScreen }\"\r\n (click)=\"OpenTimezoneScreen()\"\r\n >\r\n <div class=\"p-2\">\r\n <div class=\"profile-label\">\r\n {{ \"Generic_lib.PreferredTimezone\" | translate }}\r\n </div>\r\n </div>\r\n </div>\r\n <div\r\n class=\"profile-card\"\r\n [ngClass]=\"{ active: ShowLandinPgScreen }\"\r\n (click)=\"OpenLandingPgConfig()\"\r\n >\r\n <div class=\"p-2\">\r\n <div class=\"profile-label\">\r\n {{ \"Generic_lib.LandingPageConfig\" | translate }}\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n <!-- Left_Card_Ended -->\r\n\r\n <!--User Profile -->\r\n <ng-container *ngIf=\"ShowUserProfileScreen\">\r\n <div class=\"col-lg-6\">\r\n <div class=\"initial-text\">\r\n {{ \"AK\" }}\r\n </div>\r\n <div class=\"preference-container\">\r\n <!--Card-->\r\n <div class=\"mt-3\">\r\n <div class=\"form-group\">\r\n <div class=\"label-name\">\r\n {{ \"Generic_lib.UserName\" | translate }}\r\n </div>\r\n <div class=\"input-dropdown d-flex align-items-center\">\r\n <input\r\n type=\"text\"\r\n pInputText\r\n formControlName=\"text\"\r\n placeholder=\"{{ 'Generic_lib.UserName' | translate }}\"\r\n autocomplete=\"off\"\r\n />\r\n <img\r\n src=\"assets/common-header-lib/images/images/user-name.svg\"\r\n alt=\"Icon\"\r\n class=\"position-absolute px-2\"\r\n />\r\n </div>\r\n </div>\r\n\r\n <div class=\"form-group\">\r\n <div class=\"label-name\">{{ \"Generic_lib.Email\" | translate }}</div>\r\n <div class=\"input-dropdown d-flex align-items-center\">\r\n <input\r\n type=\"text\"\r\n pInputText\r\n formControlName=\"text\"\r\n placeholder=\"{{ 'Generic_lib.EmailAddress' | translate }}\"\r\n autocomplete=\"off\"\r\n />\r\n <img\r\n src=\"assets/common-header-lib/images/gc-mail.svg\"\r\n alt=\"Icon\"\r\n class=\"position-absolute px-2\"\r\n />\r\n </div>\r\n </div>\r\n <div class=\"mt-4\">\r\n <p-button class=\"submit-btn\" label=\"Submit\"></p-button>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n </ng-container>\r\n\r\n <!-- Preference PathScreen -->\r\n <ng-container>\r\n <!-- <ng-container *ngIf=\"ShowPreferencePathScreen\"> -->\r\n <div class=\"col-lg-6\" [hidden]=\"!ShowPreferencePathScreen\">\r\n <div class=\"preference-container\">\r\n <div class=\"mt-3\">\r\n <form [formGroup]=\"appSettingForm\">\r\n <div class=\"form-group\">\r\n <div class=\"d-flex\">\r\n <div class=\"label-name\">\r\n {{ \"Generic_lib.AssetType\" | translate }}\r\n </div>\r\n <span class=\"madontary-icon\">*</span>\r\n </div>\r\n <div class=\"assets-dropdown\">\r\n <p-dropdown\r\n [options]=\"userAssetTypeList\"\r\n formControlName=\"AssetType\"\r\n placeholder=\"{{\r\n 'Generic_lib.AssetTypePlaceholder' | translate\r\n }}\"\r\n filterPlaceholder=\"{{ 'Generic_lib.Search' | translate }}\"\r\n (onChange)=\"preferencePathValueChange(AssetTypeEvent)\"\r\n optionLabel=\"assetType\"\r\n [filter]=\"!isAssetTypeLoading ? true : false\"\r\n filterBy=\"assetType\"\r\n [showClear]=\"false\"\r\n [resetFilterOnHide]=\"true\"\r\n panelStyleClass=\"{'dropdown-loader': isAssetTypeLoading}\"\r\n >\r\n <ng-template pTemplate=\"header\">\r\n <div\r\n *ngIf=\"isAssetTypeLoading\"\r\n class=\"dropdown-loader-container\"\r\n >\r\n <i class=\"pi pi-spin pi-spinner\"></i>\r\n </div>\r\n </ng-template>\r\n </p-dropdown>\r\n </div>\r\n <ng-container\r\n *ngIf=\"\r\n appSettingForm.get('AssetType')?.invalid &&\r\n appSettingForm.get('AssetType')?.touched\r\n \"\r\n >\r\n <span class=\"error-msg mt-2\">{{\r\n \"Generic_lib.AssetTypeFieldValidation\" | translate\r\n }}</span>\r\n </ng-container>\r\n </div>\r\n <div class=\"form-group\">\r\n <div class=\"d-flex\">\r\n <div class=\"label-name\">\r\n {{ \"Generic_lib.AssetName\" | translate }}\r\n </div>\r\n <span class=\"madontary-icon\">*</span>\r\n </div>\r\n <div class=\"assets-dropdown\">\r\n <p-dropdown\r\n [options]=\"userAssetNameList\"\r\n formControlName=\"AssetName\"\r\n placeholder=\"{{\r\n 'Generic_lib.AssetNamePlaceholder' | translate\r\n }}\"\r\n filterPlaceholder=\"{{ 'Generic_lib.Search' | translate }}\"\r\n optionLabel=\"assetName\"\r\n [filter]=\"!isAssetNameLoading ? true : false\"\r\n filterBy=\"assetType\"\r\n (onChange)=\"preferencePathValueChange(AssetNameEvent)\"\r\n filterBy=\"assetName\"\r\n panelStyleClass=\"{'dropdown-loader': isAssetNameLoading}\"\r\n [showClear]=\"false\"\r\n >\r\n <ng-template pTemplate=\"header\">\r\n <div\r\n *ngIf=\"isAssetNameLoading\"\r\n class=\"dropdown-loader-container\"\r\n >\r\n <i class=\"pi pi-spin pi-spinner\"></i>\r\n </div>\r\n </ng-template>\r\n </p-dropdown>\r\n </div>\r\n <ng-container\r\n *ngIf=\"\r\n appSettingForm.get('AssetName')?.invalid &&\r\n appSettingForm.get('AssetName')?.touched\r\n \"\r\n >\r\n <span class=\"error-msg mt-2\">{{\r\n \"Generic_lib.AssetNameFieldValidation\" | translate\r\n }}</span>\r\n </ng-container>\r\n </div>\r\n <div class=\"form-group\">\r\n <div class=\"d-flex\">\r\n <div class=\"label-name\">\r\n {{ \"Generic_lib.ConnectionMethod\" | translate }}\r\n </div>\r\n <span class=\"madontary-icon\">*</span>\r\n </div>\r\n <div class=\"assets-dropdown\">\r\n <p-dropdown\r\n [options]=\"userServiceList\"\r\n formControlName=\"ServiceName\"\r\n filterPlaceholder=\"{{ 'Generic_lib.Search' | translate }}\"\r\n placeholder=\"{{\r\n 'Generic_lib.ConnectionMethodPlaceholder' | translate\r\n }}\"\r\n optionLabel=\"tbvDescrption\"\r\n [filter]=\"true\"\r\n filterBy=\"tbvDescrption\"\r\n (onChange)=\"preferencePathValueChange(ConnectionMethodEvent)\"\r\n [filter]=\"!isConnectionMethodLoading ? true : false\"\r\n [showClear]=\"false\"\r\n panelStyleClass=\"{'dropdown-loader': isConnectionMethodLoading}\"\r\n >\r\n <ng-template pTemplate=\"header\">\r\n <div\r\n *ngIf=\"isConnectionMethodLoading\"\r\n class=\"dropdown-loader-container\"\r\n >\r\n <i class=\"pi pi-spin pi-spinner\"></i>\r\n </div> </ng-template\r\n ></p-dropdown>\r\n </div>\r\n <ng-container\r\n *ngIf=\"\r\n appSettingForm.get('ServiceName')?.invalid &&\r\n appSettingForm.get('ServiceName')?.touched\r\n \"\r\n >\r\n <span class=\"error-msg mt-2\">{{\r\n \"Generic_lib.ConnectionMethodFieldValidation\" | translate\r\n }}</span>\r\n </ng-container>\r\n </div>\r\n <div class=\"form-group position-relative\">\r\n <div class=\"d-flex\">\r\n <div class=\"label-name\">\r\n {{ \"Generic_lib.PreferencePath\" | translate }}\r\n </div>\r\n <span class=\"madontary-icon\">*</span>\r\n </div>\r\n <div class=\"input-dropdown d-flex align-items-center\">\r\n <input\r\n type=\"text\"\r\n placeholder=\"{{ 'Generic_lib.PreferencePath' | translate }}\"\r\n pInputText\r\n formControlName=\"filePathName\"\r\n id=\"filepath\"\r\n name=\"filepath\"\r\n autocomplete=\"off\"\r\n />\r\n <img\r\n src=\"assets/common-header-lib/images/filepath.svg\"\r\n alt=\"path Icon\"\r\n class=\"position-absolute mx-2 img-lock ext\"\r\n />\r\n </div>\r\n <ng-container\r\n *ngIf=\"\r\n appSettingForm.get('filePathName')?.invalid &&\r\n (appSettingForm.get('filePathName')?.touched ||\r\n appSettingForm.get('filePathName')?.dirty)\r\n \"\r\n >\r\n <ng-container\r\n *ngIf=\"\r\n appSettingForm.controls['filePathName'].errors?.['required']\r\n \"\r\n >\r\n <span class=\"error-msg mt-2\">{{\r\n \"Generic_lib.PreferencePathFieldValidation\" | translate\r\n }}</span>\r\n </ng-container>\r\n <ng-container\r\n *ngIf=\"\r\n appSettingForm.controls['filePathName'].errors?.['noSpace']\r\n \"\r\n >\r\n <span class=\"error-msg mt-2\">{{\r\n \"Generic_lib.PreferencePathFieldSpaceValidation\" | translate\r\n }}</span>\r\n </ng-container>\r\n </ng-container>\r\n </div>\r\n <ng-container *ngIf=\"showStatus\">\r\n <div class=\"form-group d-flex align-items-center\">\r\n <div class=\"label-name\">\r\n {{ \"Generic_lib.CurrentSetting\" | translate }} :\r\n </div>\r\n <div class=\"cur-text mx-2\">{{ filePathName }}</div>\r\n </div>\r\n <div class=\"form-group d-flex align-items-center\">\r\n <div class=\"label-name\">\r\n {{ \"Generic_lib.LastUpdated\" | translate }}\r\n </div>\r\n <div class=\"cur-text mx-2\">{{ lastUpdatedFileStatus }}</div>\r\n </div>\r\n </ng-container>\r\n <div class=\"mt-4\">\r\n <p-button\r\n class=\"submit-btn\"\r\n label=\"{{ 'Generic_lib.Update' | translate }}\"\r\n [disabled]=\"appSettingForm.invalid\"\r\n (onClick)=\"setUserPreferencePath(appSettingForm)\"\r\n iconPos=\"right\"\r\n [loading]=\"isPathUpdated\"\r\n ></p-button>\r\n </div>\r\n </form>\r\n </div>\r\n </div>\r\n </div>\r\n </ng-container>\r\n\r\n <!-- TimeZone Screen -->\r\n <ng-container *ngIf=\"ShowTimeZoneScreen\">\r\n <div class=\"col-lg-6\">\r\n <app-timezone-configuration></app-timezone-configuration>\r\n </div>\r\n </ng-container>\r\n\r\n <!-- LandingPg Config Screen -->\r\n <ng-container *ngIf=\"ShowLandinPgScreen\">\r\n <div class=\"col-lg-6\">\r\n <app-landingpg-config></app-landingpg-config>\r\n </div>\r\n </ng-container>\r\n\r\n <!--Change Password Screen -->\r\n <!-- <ng-container *ngIf=\"ShowChangePasswordScreen\"> -->\r\n <ng-container>\r\n <div class=\"col-lg-6\" [hidden]=\"!ShowChangePasswordScreen\">\r\n <div class=\"preference-container\">\r\n <div class=\"mt-3\">\r\n <form [formGroup]=\"userResetPasswordForm\">\r\n <div class=\"form-group\">\r\n <div class=\"d-flex\">\r\n <div class=\"label-name\">\r\n {{ \"Generic_lib.CurrentPassword\" | translate }}\r\n </div>\r\n <span class=\"madontary-icon\">*</span>\r\n </div>\r\n <div\r\n class=\"input-dropdown d-flex align-items-center position-relative\"\r\n >\r\n <div class=\"password-checkbox-right\">\r\n <div class=\"checkbox-visibility-icon\">\r\n <input\r\n type=\"checkbox\"\r\n (click)=\"togglePasswordVisibility(1)\"\r\n autocomplete=\"off\"\r\n />\r\n <span></span>\r\n </div>\r\n </div>\r\n <input\r\n type=\"{{ makeOldPwdVisible ? 'password' : 'text' }}\"\r\n placeholder=\"{{\r\n 'Generic_lib.PasswordPlaceholder' | translate\r\n }}\"\r\n pInputText\r\n formControlName=\"oldUserARCXWD\"\r\n autocomplete=\"off\"\r\n id=\"oldpwd\"\r\n name=\"oldpwd\"\r\n autocomplete=\"off\"\r\n />\r\n\r\n <img\r\n src=\"assets/common-header-lib/images/lock-pass.svg\"\r\n alt=\"lock Icon\"\r\n class=\"position-absolute mx-2 img-lock\"\r\n />\r\n </div>\r\n <ng-container\r\n *ngIf=\"\r\n userResetPasswordForm.get('oldUserARCXWD')?.invalid &&\r\n userResetPasswordForm.get('oldUserARCXWD')?.touched\r\n \"\r\n >\r\n <span class=\"error-msg mt-2\">{{\r\n \"Generic_lib.PasswordFieldValidation\" | translate\r\n }}</span>\r\n </ng-container>\r\n </div>\r\n <div class=\"form-group\">\r\n <div class=\"d-flex\">\r\n <div class=\"label-name\">\r\n {{ \"Generic_lib.NewPassword\" | translate }}\r\n </div>\r\n <span class=\"madontary-icon\">*</span>\r\n </div>\r\n <div\r\n class=\"input-dropdown d-flex align-items-center position-relative\"\r\n >\r\n <div class=\"password-checkbox-right\">\r\n <div class=\"checkbox-visibility-icon\">\r\n <input\r\n type=\"checkbox\"\r\n (click)=\"togglePasswordVisibility(2)\"\r\n autocomplete=\"off\"\r\n />\r\n <span></span>\r\n </div>\r\n </div>\r\n <input\r\n type=\"{{ makeNewPwdVisible ? 'password' : 'text' }}\"\r\n placeholder=\"{{\r\n 'Generic_lib.NewPasswordPlaceholder' | translate\r\n }}\"\r\n pInputText\r\n formControlName=\"newUserARCXWD\"\r\n id=\"newpwd\"\r\n autocomplete=\"off\"\r\n name=\"newpwd\"\r\n autocomplete=\"off\"\r\n />\r\n\r\n <img\r\n src=\"assets/common-header-lib/images/lock-pass.svg\"\r\n alt=\"lock Icon\"\r\n class=\"position-absolute mx-2 img-lock\"\r\n />\r\n </div>\r\n <ng-container\r\n *ngIf=\"\r\n userResetPasswordForm\r\n .get('newUserARCXWD')\r\n ?.hasError('required') &&\r\n userResetPasswordForm.get('newUserARCXWD')?.touched\r\n \"\r\n >\r\n <span class=\"error-msg mt-2\">{{\r\n \"Generic_lib.NewPasswordFieldValidation\" | translate\r\n }}</span>\r\n </ng-container>\r\n <ng-container\r\n *ngIf=\"\r\n userResetPasswordForm\r\n .get('newUserARCXWD')\r\n ?.hasError('pwdInvalid') &&\r\n userResetPasswordForm.get('newUserARCXWD')?.touched\r\n \"\r\n >\r\n <span class=\"error-msg mt-2\">{{ pwderrorMsg }}</span>\r\n </ng-container>\r\n </div>\r\n <div class=\"form-group\">\r\n <div class=\"d-flex\">\r\n <div class=\"label-name\">\r\n {{ \"Generic_lib.ConfirmPassword\" | translate }}\r\n </div>\r\n <span class=\"madontary-icon\">*</span>\r\n </div>\r\n <div\r\n class=\"input-dropdown d-flex align-items-center position-relative\"\r\n >\r\n <div class=\"password-checkbox-right\">\r\n <div class=\"checkbox-visibility-icon\">\r\n <input\r\n type=\"checkbox\"\r\n (click)=\"togglePasswordVisibility(3)\"\r\n autocomplete=\"off\"\r\n />\r\n <span></span>\r\n </div>\r\n </div>\r\n <input\r\n type=\"{{ makeCnfrmPwdVisible ? 'password' : 'text' }}\"\r\n placeholder=\"{{\r\n 'Generic_lib.ConfirmPasswordPlaceholder' | translate\r\n }}\"\r\n pInputText\r\n formControlName=\"crnmNewUserARCXWD\"\r\n autocomplete=\"off\"\r\n id=\"crnmnewpwd\"\r\n name=\"crnmnewpwd\"\r\n />\r\n\r\n <img\r\n src=\"assets/common-header-lib/images/lock-pass.svg\"\r\n alt=\"eye Icon\"\r\n class=\"position-absolute mx-2 img-lock\"\r\n />\r\n </div>\r\n <ng-container\r\n *ngIf=\"\r\n userResetPasswordForm\r\n .get('crnmNewUserARCXWD')\r\n ?.hasError('required') &&\r\n userResetPasswordForm.get('crnmNewUserARCXWD')?.touched\r\n \"\r\n >\r\n <span class=\"error-msg mt-2\">{{\r\n \"Generic_lib.ConfirmPasswordFieldValidation\" | translate\r\n }}</span>\r\n </ng-container>\r\n <span\r\n class=\"error-msg mt-2\"\r\n *ngIf=\"\r\n userResetPasswordForm\r\n .get('crnmNewUserARCXWD')\r\n ?.hasError('confirmedValidator')\r\n \"\r\n >\r\n {{\r\n \"Generic_lib.ConfirmPasswordFieldNewValidation\" | translate\r\n }}\r\n </span>\r\n </div>\r\n\r\n <div class=\"mt-4\">\r\n <p-button\r\n class=\"submit-btn\"\r\n label=\"{{ 'Generic_lib.Update' | translate }}\"\r\n iconPos=\"right\"\r\n [loading]=\"isPathUpdated\"\r\n label=\"Update\"\r\n (onClick)=\"resetLoggedInPwd()\"\r\n ></p-button>\r\n </div>\r\n </form>\r\n </div>\r\n </div>\r\n </div>\r\n </ng-container>\r\n</div>\r\n", styles: [".pl{padding-left:0!important}.left-card{height:450px!important;background:#f6f7fb!important;border-radius:8px!important}.left-card .profile-label{font-size:13px!important;color:#292f4c!important;font-weight:600!important}.left-card .profile-text{color:#676879!important;font-size:12px!important;font-weight:400!important;line-height:20px!important}.initial-text{width:50px;height:50px;display:flex;align-items:center;justify-content:center;font-size:15px;border-radius:50%;color:#fff;background-color:#8e562e}.preference-container .path-title{font-size:20px;color:#292f4c}.preference-container .form-group{margin-bottom:15px}.preference-container .label-name{font-size:12px;color:#292f4c;line-height:26px;font-weight:600}.preference-container .cur-text{font-size:12px;color:#676879;line-height:26px;font-weight:600}.checkbox-visibility-icon{position:relative}.checkbox-visibility-icon input[type=checkbox]{opacity:0;position:absolute;top:4px;left:5px;transform:scale(1.7);z-index:2;cursor:pointer}.checkbox-visibility-icon input[type=checkbox]:checked+span{background:url(assets/common-header-lib/images/login-bg/visibility.svg);background-repeat:no-repeat;background-position:0px;height:12px;width:18px;display:block;background-size:17px}@media (min-width: 992px){.checkbox-visibility-icon input[type=checkbox]:checked+span{height:12px;width:18px;background-size:17px}}.checkbox-visibility-icon input[type=checkbox]+span{background:url(assets/common-header-lib/images/login-bg/visibility_off.svg);background-repeat:no-repeat;background-position:0px;height:12px;width:18px;display:block;background-size:17px}@media (min-width: 992px){.checkbox-visibility-icon input[type=checkbox]+span{height:24px;width:18px;background-size:17px}}.input-dropdown .p-inputtext{width:100%!important;border-radius:4px!important;font-size:12px!important;padding-left:28px!important;height:38px!important;border:1px solid #ced4da!important}.p-dropdown-filter-container input{border:1px solid #ced4da!important}.profile-card{cursor:pointer}.profile-card:hover{background:#e9ecef;color:#292f4c;border-radius:4px}.profile-card.active{border-radius:4px;cursor:pointer;background:#dcdfec url(assets/common-header-lib/images/grey-arrow.svg) no-repeat 96%}\n"] }]
2532
- }], ctorParameters: function () { return [{ type: CommonHeaderLibService }, { type: i2.FormBuilder }, { type: ToastMsgService }, { type: EncrydecryRSAdataService }, { type: RESTLoginFormService }, { type: ASYNCPasswordcheckService }, { type: i4.TranslateService }, { type: VaptValidationService }, { type: i1$3.DynamicDialogConfig }, { type: HttpCommonService }, { type: HttpGeneralConfigurationService }]; } });
2533
-
2534
- class NgTranslationComponent {
2535
- constructor(_translate, _localstorage, msgService) {
2536
- this._translate = _translate;
2537
- this._localstorage = _localstorage;
2538
- this.msgService = msgService;
2539
- /* Languages provided by the host app (single source of truth — populated
2540
- from languages.json by the host's APP_INITIALIZER and forwarded down
2541
- through <lib-common-header-lib> → <app-user-sidebar> → here).
2542
- Falls back to GlobalConstants.USERFILTEREDLANGUAGES when not supplied
2543
- so the component remains usable in legacy contexts. */
2544
- this.languages = [];
2545
- this.selectedLang = {};
2546
- }
2547
- ngOnInit() {
2548
- this.loadLanguages();
2549
- }
2550
- ngOnChanges(changes) {
2551
- if (changes['languages'] && !changes['languages'].firstChange) {
2552
- this.loadLanguages();
2553
- }
2554
- }
2555
- loadLanguages() {
2556
- /* 1. Use @Input languages if provided; fall back to GlobalConstants
2557
- for backward compatibility. */
2558
- if (!this.languages || this.languages.length === 0) {
2559
- this.languages = GlobalConstants.USERFILTEREDLANGUAGES || [];
2560
- }
2561
- /* 2. Read saved language */
2562
- const savedLang = this._localstorage.getData(COOKIECONSTANT.USERLANG);
2563
- if (savedLang) {
2564
- try {
2565
- const parsed = JSON.parse(savedLang);
2566
- const validLang = this.languages.find((x) => x.langKey === (parsed === null || parsed === void 0 ? void 0 : parsed.langKey));
2567
- this.selectedLang = validLang || GlobalConstants.DEFAULTLANG;
2568
- }
2569
- catch (_a) {
2570
- this.selectedLang = GlobalConstants.DEFAULTLANG;
2571
- }
2572
- }
2573
- else {
2574
- this.selectedLang = GlobalConstants.DEFAULTLANG;
2575
- }
2576
- }
2577
- /* Language Change */
2578
- selectLang(event) {
2579
- this.selectedLang = event === null || event === void 0 ? void 0 : event.value;
2580
- this.useTranslate(this.selectedLang);
2581
- }
2582
- useTranslate(selectedLang) {
2583
- this._translate.use(selectedLang.langKey).subscribe({
2584
- next: () => {
2585
- this.saveUserLanguage(selectedLang);
2586
- },
2587
- error: () => {
2588
- this.msgService.error(this._translate.instant('Generic_lib.FailedToLoadLanguageFile'));
2589
- },
2590
- });
2591
- }
2592
- saveUserLanguage(lang) {
2593
- this._localstorage.saveData(COOKIECONSTANT.USERLANG, JSON.stringify(lang));
2594
- }
2595
- }
2596
- NgTranslationComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: NgTranslationComponent, deps: [{ token: i4.TranslateService }, { token: StorageService }, { token: ToastMsgService }], target: i0.ɵɵFactoryTarget.Component });
2597
- NgTranslationComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: NgTranslationComponent, selector: "ng-translation", inputs: { languages: "languages" }, usesOnChanges: true, ngImport: i0, template: "<p-dropdown [options]=\"languages\" optionLabel=\"langName\" placeholder='{{ \"Generic_lib.SelectLanguage\" | translate }}'\r\n (onChange)=\"selectLang($event)\" [filter]=\"true\" filterBy=\"langName\"\r\n filterPlaceholder='{{ \"Generic_lib.Search\" | translate }}' [showClear]=\"false\"\r\n [(ngModel)]=\"selectedLang\"></p-dropdown>\r\n", styles: [""], dependencies: [{ kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "component", type: i8.Dropdown, selector: "p-dropdown", inputs: ["scrollHeight", "filter", "name", "style", "panelStyle", "styleClass", "panelStyleClass", "readonly", "required", "editable", "appendTo", "tabindex", "placeholder", "filterPlaceholder", "filterLocale", "inputId", "selectId", "dataKey", "filterBy", "autofocus", "resetFilterOnHide", "dropdownIcon", "optionLabel", "optionValue", "optionDisabled", "optionGroupLabel", "optionGroupChildren", "autoDisplayFirst", "group", "showClear", "emptyFilterMessage", "emptyMessage", "lazy", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "overlayOptions", "ariaFilterLabel", "ariaLabel", "ariaLabelledBy", "filterMatchMode", "maxlength", "tooltip", "tooltipPosition", "tooltipPositionStyle", "tooltipStyleClass", "autofocusFilter", "overlayDirection", "disabled", "itemSize", "autoZIndex", "baseZIndex", "showTransitionOptions", "hideTransitionOptions", "options", "filterValue"], outputs: ["onChange", "onFilter", "onFocus", "onBlur", "onClick", "onShow", "onHide", "onClear", "onLazyLoad"] }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "pipe", type: i4.TranslatePipe, name: "translate" }] });
2598
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: NgTranslationComponent, decorators: [{
2599
- type: Component,
2600
- args: [{ selector: 'ng-translation', standalone: false, template: "<p-dropdown [options]=\"languages\" optionLabel=\"langName\" placeholder='{{ \"Generic_lib.SelectLanguage\" | translate }}'\r\n (onChange)=\"selectLang($event)\" [filter]=\"true\" filterBy=\"langName\"\r\n filterPlaceholder='{{ \"Generic_lib.Search\" | translate }}' [showClear]=\"false\"\r\n [(ngModel)]=\"selectedLang\"></p-dropdown>\r\n" }]
2601
- }], ctorParameters: function () { return [{ type: i4.TranslateService }, { type: StorageService }, { type: ToastMsgService }]; }, propDecorators: { languages: [{
2602
- type: Input
2603
- }] } });
2604
-
2605
- class SliceToTwoPipe {
2606
- transform(textName) {
2607
- if (textName === null || textName === '') {
2608
- return 'NA';
2609
- }
2610
- textName = textName === null || textName === void 0 ? void 0 : textName.trim();
2611
- let result = '';
2612
- if (textName && textName.includes(' ')) {
2613
- let splitStringArr = textName.split(' ');
2614
- result =
2615
- splitStringArr[0][0] + splitStringArr[splitStringArr.length - 1][0];
2616
- }
2617
- else if (textName && textName.includes('_')) {
2618
- let splitStringArr = textName.split('_');
2619
- result =
2620
- splitStringArr[0][0] + splitStringArr[splitStringArr.length - 1][0];
2621
- }
2622
- else {
2623
- result = textName[0] + textName[1];
2624
- }
2625
- return result.toLocaleUpperCase();
2626
- }
2627
- }
2628
- SliceToTwoPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: SliceToTwoPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
2629
- SliceToTwoPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.3.0", ngImport: i0, type: SliceToTwoPipe, name: "sliceToTwo" });
2630
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: SliceToTwoPipe, decorators: [{
2631
- type: Pipe,
2632
- args: [{
2633
- name: 'sliceToTwo',
2634
- }]
2635
- }] });
2636
-
2637
- class UserSidebarComponent {
2638
- constructor(dialogService, _cookieService, route, msgService, _localStorage, translateService, httpCommonService) {
2639
- this.dialogService = dialogService;
2640
- this._cookieService = _cookieService;
2641
- this.route = route;
2642
- this.msgService = msgService;
2643
- this._localStorage = _localStorage;
2644
- this.translateService = translateService;
2645
- this.httpCommonService = httpCommonService;
2646
- this.userDetails = {};
2647
- this.showProfile = false;
2648
- this.userdisplayName = '';
2649
- this.userFirstName = '';
2650
- this.userLastName = '';
2651
- this.userLastLoggedIn = '';
2652
- // private LoggedInUserID: string = '';
2653
- this.unsubscribeAPIEventListenerData = new Subject();
2654
- /* Forwarded down to <ng-translation> so the language list is sourced
2655
- from the host app instead of a separate library API call. */
2656
- this.languages = [];
2657
- this.closeDialogBox = new EventEmitter();
2658
- // public userSessionID: string = '';
2659
- this.sec = 1;
2660
- this.min = 2;
2661
- this.Hr = 30;
2662
- this.isOpenSidePopup = false;
2663
- this.showUserDetails = false;
2664
- // private themeService: ThemeService,
2665
- // private fontService: FontService,
2666
- // private cookieService: CookieService,
2667
- // this.fetchedSavedData();
2668
- }
2669
- ngOnInit() {
2670
- this.getLoggedInuserDteils();
2671
- }
2672
- //Method: Open User Setting Panel
2673
- openUserSettingPanel() {
2674
- this.ref = this.dialogService.open(GeneralConfigurationComponent, {
2675
- header: this.translateService.instant('Generic_lib.GeneralConfiguration'),
2676
- styleClass: 'general-configuration',
2677
- // data: {
2678
- // apiURL: this.apiURL,
2679
- // },
2680
- });
2681
- }
2682
- getLoggedInuserDteils() {
2683
- this.httpCommonService
2684
- .getLoggedInUserDetails()
2685
- .pipe(takeUntil$1(this.unsubscribeAPIEventListenerData))
2686
- .subscribe((result) => {
2687
- if (result && result['success'] && result['result']) {
2688
- this.userDetails = result['result'];
2689
- this.userdisplayName = this.userDetails['userDisplayName'];
2690
- this.showProfile = true;
2691
- this.getTotalSessionTime();
2692
- this.setLoggedInUserName(this.userdisplayName);
2693
- }
2694
- else {
2695
- this.showProfile = false;
2696
- this.userDetails = {};
2697
- }
2698
- });
2699
- }
2700
- setLoggedInUserName(userdisplayName) {
2701
- if (userdisplayName && userdisplayName.includes(' ')) {
2702
- let splitStringArr = userdisplayName.split(' ');
2703
- this.userFirstName = splitStringArr[0];
2704
- this.userLastName = splitStringArr[1];
2705
- }
2706
- else {
2707
- this.userdisplayName = userdisplayName;
2708
- }
2709
- }
2710
- getcloseDialogBox() {
2711
- this.closeDialogBox.emit(true);
2712
- }
2713
- getUserLoggedInTime() {
2714
- let LastLoggedIn = this.convertUTCToLocal(this.userDetails['lastLogIn']);
2715
- let LastLoggedInDate = new Date(LastLoggedIn);
2716
- this.userLastLoggedIn = LastLoggedInDate.toLocaleString();
2717
- }
2718
- logoutCurrentUser() {
2719
- this.httpCommonService
2720
- .getInitiateUserLogout()
2721
- .pipe()
2722
- .subscribe((res) => {
2723
- if (res) {
2724
- this._cookieService.clearAllCookies();
2725
- this._localStorage.clearData();
2726
- if (res && res['spLogoutUrls'] && res['spLogoutUrls'].length > 0) {
2727
- this.destoryAllSessions(res['spLogoutUrls']);
2728
- }
2729
- if (res === null || res === void 0 ? void 0 : res['identity']) {
2730
- this.userWithWindowAuthentication();
2731
- }
2732
- else {
2733
- const path = '/' + RoutePaths.LOGINPG_PATH;
2734
- const urlnew = new URL(window.location.href).origin + '/#' + path;
2735
- window.location.href = urlnew;
2736
- }
2737
- }
2738
- else {
2739
- this.msgService.error(errorMsg.LOGOUTERROR);
2740
- // window.location.href = new URL(window.location.href).origin + '/#/login';
2741
- }
2742
- });
2743
- }
2744
- /**
2745
- * This function destroys all user sessions by opening multiple SAML logout URLs in new browser tabs.
2746
- */
2747
- destoryAllSessions(samlUrls) {
2748
- samlUrls.forEach((url) => {
2749
- window.open(url, '_blank');
2750
- });
2751
- }
2752
- userWithWindowAuthentication() {
2753
- const path = '/' + RoutePaths.LOGOUT_PATH;
2754
- this.route.navigateByUrl(path);
2755
- }
2756
- getTotalSessionTime() {
2757
- let loginTime = this.convertUTCToLocal(this.userDetails['currentLogIn']);
2758
- let loginTimeDate = new Date(loginTime);
2759
- let currentTime = new Date();
2760
- let milliseconds = currentTime.valueOf() - loginTimeDate.valueOf();
2761
- let seconds = Math.floor(milliseconds / 1000);
2762
- let minutes = Math.floor(seconds / 60);
2763
- let hours = Math.floor(minutes / 60);
2764
- seconds = seconds % 60;
2765
- minutes = minutes % 60;
2766
- this.Hr = hours;
2767
- this.min = minutes;
2768
- this.sec = seconds;
2769
- setInterval(() => {
2770
- this.updateTimer();
2771
- }, 1000);
2772
- }
2773
- updateTimer() {
2774
- if (this.sec < 59) {
2775
- this.sec += 1;
2776
- }
2777
- else {
2778
- this.sec = 0;
2779
- if (this.min < 59) {
2780
- this.min += 1;
2781
- }
2782
- else {
2783
- this.min = 0;
2784
- this.Hr += 1;
2785
- }
2786
- }
2787
- }
2788
- convertUTCToLocal(newdate) {
2789
- let localDate = newdate + 'Z';
2790
- localDate = localDate.toLocaleString();
2791
- return localDate;
2792
- }
2793
- OpenArconLearningCenter() {
2794
- const url = GlobalConstants.PlugInDownloadURL;
2795
- window.open(url, '_blank');
2796
- }
2797
- //close Popup
2798
- closeUserSettingPanel() {
2799
- if (this.ref) {
2800
- this.ref.close();
2801
- }
2802
- }
2803
- // languageChange(event: any) {
2804
- // if (!event) return;
2805
- // // this.langChange.emit(event);
2806
- // }
2807
- //*Global Font and Theme
2808
- getRedTheme() {
2809
- // const active = this.themeService.getActiveTheme();
2810
- // if (
2811
- // active.name === "blue" ||
2812
- // active.name === "black" ||
2813
- // active.name === "red"
2814
- // ) {
2815
- // this.themeService.setTheme("red");
2816
- // this.cookieService.set("themeColor", "red");
2817
- // }
2818
- }
2819
- getBlackTheme() {
2820
- // const active = this.themeService.getActiveTheme();
2821
- // if (
2822
- // active.name === "blue" ||
2823
- // active.name === "black" ||
2824
- // active.name === "red"
2825
- // ) {
2826
- // this.themeService.setTheme("blue");
2827
- // this.cookieService.set("themeColor", "blue");
2828
- // }
2829
- }
2830
- getBlueTheme() {
2831
- // const active = this.themeService.getActiveTheme();
2832
- // if (
2833
- // active.name === "blue" ||
2834
- // active.name === "black" ||
2835
- // active.name === "red"
2836
- // ) {
2837
- // this.themeService.setTheme("black");
2838
- // this.cookieService.set("themeColor", "black");
2839
- // }
2840
- }
2841
- // Accessibility Fonts sizes
2842
- getSmallFont() {
2843
- // this.fontService.setFont("smFont");
2844
- }
2845
- getMediumFont() {
2846
- // this.fontService.setFont("mdFont");
2847
- }
2848
- getLargeFont() {
2849
- // this.fontService.setFont("lgFont");
2850
- }
2851
- ngOnDestroy() {
2852
- this.closeUserSettingPanel();
2853
- this.unsubscribeAPIEventListenerData.next(true);
2854
- this.unsubscribeAPIEventListenerData.complete();
2855
- }
2856
- }
2857
- UserSidebarComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: UserSidebarComponent, deps: [{ token: i1$3.DialogService }, { token: CookieStorageManagerService }, { token: i3.Router }, { token: ToastMsgService }, { token: StorageService }, { token: i4.TranslateService }, { token: HttpCommonService }], target: i0.ɵɵFactoryTarget.Component });
2858
- UserSidebarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: UserSidebarComponent, selector: "app-user-sidebar", inputs: { languages: "languages" }, outputs: { closeDialogBox: "closeDialogBox" }, providers: [DialogService], ngImport: i0, template: "<div class=\"white-bg\">\r\n <div class=\" sidebar-outer white-bg\">\r\n <div class=\"sidebar-header grey-background\">\r\n <div class=\"sh-top\">\r\n <div class=\"sh-top-left d-flex\">\r\n <img src=\"assets/common-header-lib/images/logout.svg\" class=\"imgs\" alt=\"user\">\r\n <div class=\"mx-2 log-text\" (click)=\"logoutCurrentUser()\">{{\"Generic_lib.Logout\" | translate}}</div>\r\n </div>\r\n <div class=\"sh-top-right\">\r\n <button type=\"button\" class=\"common-bn tertiary-btn\">\r\n <img src=\"assets/common-header-lib/images/close.svg\" class=\"imgs\" alt=\"close icon\" title=\"Close\"\r\n (click)=\"getcloseDialogBox()\">\r\n </button>\r\n </div>\r\n </div>\r\n <ng-container *ngIf=\"showProfile; else LoadingAnimation\">\r\n <div class=\"sh-bottom d-flex pt-3\">\r\n <ng-container *ngIf=\"userdisplayName && userdisplayName.length > 0; else defaultName\">\r\n <div class=\"initial-text\">\r\n {{ userdisplayName | sliceToTwo }}\r\n </div>\r\n </ng-container>\r\n <ng-template #defaultName>\r\n <div class=\"initial-text\">\r\n {{ 'NA' }}\r\n </div>\r\n </ng-template>\r\n <div class=\"sh-bottom-content\">\r\n <h4 class=\"title\">{{ userDetails['userDisplayName']}}</h4>\r\n <p>{{ userDetails['emailID']}}</p>\r\n <div class=\"sh-bottom-content-ls\">\r\n <ng-container\r\n *ngIf=\"userDetails['lastLogIn'] && !userDetails['lastLogIn'].includes('NA'); else InvalidDate\">\r\n <p style=\"margin-right: 5px;\">{{\"Generic_lib.LastSession\" | translate}} : </p>\r\n <p>{{userDetails['lastLogIn']}}</p>\r\n </ng-container>\r\n <ng-template #InvalidDate>\r\n <p style=\"margin-right: 5px;\">{{\"Generic_lib.LastSession\" | translate}} : </p>\r\n <p>NA</p>\r\n </ng-template>\r\n </div>\r\n <div class=\"sh-bottom-content-ls session-content\">\r\n <p tyle=\"margin-right: 5px;\">{{\"Generic_lib.CurrentSession\" | translate}} : </p>\r\n <p>{{Hr}} {{\"Generic_lib.hrs\" | translate}} {{min}} {{\"Generic_lib.min\" | translate}} {{sec}}\r\n {{\"Generic_lib.secs\" | translate}}</p>\r\n </div>\r\n </div>\r\n </div>\r\n </ng-container>\r\n <ng-template #LoadingAnimation>\r\n <div class=\"loading-skeleton d-flex p-3\">\r\n <p-skeleton shape=\"circle\" size=\"4rem\" styleClass=\"mr-2\"></p-skeleton>\r\n <div class=\"ms-1\">\r\n <p-skeleton width=\"10rem\" styleClass=\"mb-2\"></p-skeleton>\r\n <p-skeleton width=\"8rem\" height=\".7rem\" styleClass=\"mb-2\"></p-skeleton>\r\n <p-skeleton width=\"5rem\" styleClass=\"mb-2\"></p-skeleton>\r\n <p-skeleton height=\".5rem\"></p-skeleton>\r\n </div>\r\n </div>\r\n </ng-template>\r\n </div>\r\n <div class=\"sidebar-body\">\r\n <div class=\"sb-list pb-20px\">\r\n <ul>\r\n <li class=\"grey-bg-hover\">\r\n <img src=\"assets/common-header-lib/images/domain_img.svg\" loading=\"lazy\">\r\n <div class=\"mx-2 lang-dropdown\">\r\n <ng-translation [languages]=\"languages\"></ng-translation> <!-- (langChange)=\"languageChange($event)\" -->\r\n </div>\r\n </li>\r\n <li class=\"grey-bg-hover\" (click)=\"OpenArconLearningCenter()\">\r\n <img src=\"assets/common-header-lib/images/local.svg\" class=\"imgs\" alt=\"Arcon\">\r\n <p class=\"mx-2\">{{\"Generic_lib.ArconLearningCenter\" | translate}}</p>\r\n </li>\r\n\r\n <li class=\"grey-bg-hover\">\r\n <img src=\"assets/common-header-lib/images/settings.svg\" alt=\"settings\">\r\n <p class=\"mx-2\" (click)=\"openUserSettingPanel()\">{{\"Generic_lib.GeneralConfiguration\" | translate}}</p>\r\n </li>\r\n </ul>\r\n </div>\r\n </div>\r\n </div>\r\n <!-- Global Font and Theme -->\r\n <!-- <div class=\"accessibility-container d-flex justify-content-between\">\r\n <div class=\"d-flex\">\r\n <button class=\"btn btn-light btn-small rounded-circle\" (click)=\"getSmallFont()\">\r\n <span>A-</span>\r\n </button>\r\n <button class=\"btn btn-light btn-small rounded-circle\" (click)=\"getMediumFont()\">\r\n <span>A</span>\r\n </button>\r\n <button class=\"btn btn-light btn-small rounded-circle\" (click)=\"getLargeFont()\">\r\n <span>A+</span>\r\n </button>\r\n </div>\r\n <div class=\"d-flex\">\r\n <button class=\"btn btn-light btn-small rounded-circle\" (click)=\"getRedTheme()\">\r\n <span class=\"theme theme-red\"></span>\r\n </button>\r\n <button class=\"btn btn-light btn-small rounded-circle\" (click)=\"getBlackTheme()\">\r\n <span class=\"theme theme-black\"></span>\r\n </button>\r\n <button class=\"btn btn-light btn-small rounded-circle\" (click)=\"getBlueTheme()\">\r\n <span class=\"theme theme-blue\"></span>\r\n </button>\r\n </div>\r\n </div> -->\r\n</div>\r\n", styles: [".white-bg{background-color:#fff!important;width:100%!important}.grey-background{background-color:#f6f7fb!important}.imgs{width:20px!important}.cursor-pointer{cursor:pointer}.sidebar-outer{width:100%!important;float:left!important}.sidebar-outer .sidebar-header{padding:12px 15px!important}.sidebar-outer .sidebar-header .sh-top{display:flex!important;align-items:center!important;justify-content:space-between!important}.sidebar-outer .sidebar-header .sh-top .sh-top-left{display:flex!important;align-items:center!important}.sidebar-outer .sidebar-header .sh-top .sh-top-left .log-text{font-size:14px!important;font-weight:500!important;cursor:pointer!important}.sidebar-outer .sidebar-header .sh-top .sh-top-right button{height:24px!important;border:none!important;background-color:transparent!important}.sidebar-outer .sidebar-header .sh-bottom{display:flex!important;padding-top:16px!important}.sidebar-outer .sidebar-header .sh-bottom .initial-text{width:40px;height:40px;display:flex;align-items:center;justify-content:center;font-size:15px;border-radius:50%;color:#fff;background-color:#8e562e}.sidebar-outer .sidebar-header .sh-bottom .sh-bottom-content{padding-left:14px!important}.sidebar-outer .sidebar-header .sh-bottom .sh-bottom-content .title{font-size:17px!important;font-weight:600!important;height:21px!important;margin-bottom:2px!important;line-height:26px!important;color:#292f4c!important}.sidebar-outer .sidebar-header .sh-bottom .sh-bottom-content p{font-size:14px!important;line-height:22px!important;color:#676879!important;margin-bottom:0!important}.sidebar-outer .sidebar-header .sh-bottom .sh-bottom-content .sh-bottom-content-ls{display:flex!important;align-items:center!important;font-size:12px!important}.sidebar-outer .sidebar-header .sh-bottom .sh-bottom-content .session-content{position:relative!important;bottom:2px!important}.sidebar-outer .sidebar-body{padding:12px 20px!important;width:100%!important}.sidebar-outer .sidebar-body .sb-list{width:100%!important}.sidebar-outer .sidebar-body .sb-list ul{width:100%!important;list-style:none;padding-left:0;margin:0}.sidebar-outer .sidebar-body .sb-list ul li{display:flex!important;align-items:center!important;padding:8px 2px!important;cursor:pointer!important}.sidebar-outer .sidebar-body .sb-list ul li img{width:18px}.sidebar-outer .sidebar-body .sb-list ul li p{margin:0 0 0 8px!important;font-size:14px!important}.sidebar-outer .sidebar-body .sb-list ul li .lang-dropdown{margin-left:8px!important}.accessibility-container{background-color:#eee;padding:7px 20px}.accessibility-container .btn{align-content:center;align-items:center;border:1px solid #9e9e9e;color:#707070;display:flex;font-size:10px;height:20px;justify-content:center;padding:0;width:20px;margin-right:5px;overflow:hidden}.accessibility-container .btn:last-child{margin-right:0}.accessibility-container .btn .theme{display:block;height:100%;margin-left:-50%;width:60%}.accessibility-container .btn .theme-red{background-color:#d4231d}.accessibility-container .btn .theme-black{background-color:#212121}.accessibility-container .btn .theme-blue{background-color:#4d91ea}\n"], dependencies: [{ kind: "directive", type: i6.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i9$1.Skeleton, selector: "p-skeleton", inputs: ["styleClass", "style", "shape", "animation", "borderRadius", "size", "width", "height"] }, { kind: "component", type: NgTranslationComponent, selector: "ng-translation", inputs: ["languages"] }, { kind: "pipe", type: i4.TranslatePipe, name: "translate" }, { kind: "pipe", type: SliceToTwoPipe, name: "sliceToTwo" }] });
2859
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: UserSidebarComponent, decorators: [{
2860
- type: Component,
2861
- args: [{ selector: 'app-user-sidebar', providers: [DialogService], template: "<div class=\"white-bg\">\r\n <div class=\" sidebar-outer white-bg\">\r\n <div class=\"sidebar-header grey-background\">\r\n <div class=\"sh-top\">\r\n <div class=\"sh-top-left d-flex\">\r\n <img src=\"assets/common-header-lib/images/logout.svg\" class=\"imgs\" alt=\"user\">\r\n <div class=\"mx-2 log-text\" (click)=\"logoutCurrentUser()\">{{\"Generic_lib.Logout\" | translate}}</div>\r\n </div>\r\n <div class=\"sh-top-right\">\r\n <button type=\"button\" class=\"common-bn tertiary-btn\">\r\n <img src=\"assets/common-header-lib/images/close.svg\" class=\"imgs\" alt=\"close icon\" title=\"Close\"\r\n (click)=\"getcloseDialogBox()\">\r\n </button>\r\n </div>\r\n </div>\r\n <ng-container *ngIf=\"showProfile; else LoadingAnimation\">\r\n <div class=\"sh-bottom d-flex pt-3\">\r\n <ng-container *ngIf=\"userdisplayName && userdisplayName.length > 0; else defaultName\">\r\n <div class=\"initial-text\">\r\n {{ userdisplayName | sliceToTwo }}\r\n </div>\r\n </ng-container>\r\n <ng-template #defaultName>\r\n <div class=\"initial-text\">\r\n {{ 'NA' }}\r\n </div>\r\n </ng-template>\r\n <div class=\"sh-bottom-content\">\r\n <h4 class=\"title\">{{ userDetails['userDisplayName']}}</h4>\r\n <p>{{ userDetails['emailID']}}</p>\r\n <div class=\"sh-bottom-content-ls\">\r\n <ng-container\r\n *ngIf=\"userDetails['lastLogIn'] && !userDetails['lastLogIn'].includes('NA'); else InvalidDate\">\r\n <p style=\"margin-right: 5px;\">{{\"Generic_lib.LastSession\" | translate}} : </p>\r\n <p>{{userDetails['lastLogIn']}}</p>\r\n </ng-container>\r\n <ng-template #InvalidDate>\r\n <p style=\"margin-right: 5px;\">{{\"Generic_lib.LastSession\" | translate}} : </p>\r\n <p>NA</p>\r\n </ng-template>\r\n </div>\r\n <div class=\"sh-bottom-content-ls session-content\">\r\n <p tyle=\"margin-right: 5px;\">{{\"Generic_lib.CurrentSession\" | translate}} : </p>\r\n <p>{{Hr}} {{\"Generic_lib.hrs\" | translate}} {{min}} {{\"Generic_lib.min\" | translate}} {{sec}}\r\n {{\"Generic_lib.secs\" | translate}}</p>\r\n </div>\r\n </div>\r\n </div>\r\n </ng-container>\r\n <ng-template #LoadingAnimation>\r\n <div class=\"loading-skeleton d-flex p-3\">\r\n <p-skeleton shape=\"circle\" size=\"4rem\" styleClass=\"mr-2\"></p-skeleton>\r\n <div class=\"ms-1\">\r\n <p-skeleton width=\"10rem\" styleClass=\"mb-2\"></p-skeleton>\r\n <p-skeleton width=\"8rem\" height=\".7rem\" styleClass=\"mb-2\"></p-skeleton>\r\n <p-skeleton width=\"5rem\" styleClass=\"mb-2\"></p-skeleton>\r\n <p-skeleton height=\".5rem\"></p-skeleton>\r\n </div>\r\n </div>\r\n </ng-template>\r\n </div>\r\n <div class=\"sidebar-body\">\r\n <div class=\"sb-list pb-20px\">\r\n <ul>\r\n <li class=\"grey-bg-hover\">\r\n <img src=\"assets/common-header-lib/images/domain_img.svg\" loading=\"lazy\">\r\n <div class=\"mx-2 lang-dropdown\">\r\n <ng-translation [languages]=\"languages\"></ng-translation> <!-- (langChange)=\"languageChange($event)\" -->\r\n </div>\r\n </li>\r\n <li class=\"grey-bg-hover\" (click)=\"OpenArconLearningCenter()\">\r\n <img src=\"assets/common-header-lib/images/local.svg\" class=\"imgs\" alt=\"Arcon\">\r\n <p class=\"mx-2\">{{\"Generic_lib.ArconLearningCenter\" | translate}}</p>\r\n </li>\r\n\r\n <li class=\"grey-bg-hover\">\r\n <img src=\"assets/common-header-lib/images/settings.svg\" alt=\"settings\">\r\n <p class=\"mx-2\" (click)=\"openUserSettingPanel()\">{{\"Generic_lib.GeneralConfiguration\" | translate}}</p>\r\n </li>\r\n </ul>\r\n </div>\r\n </div>\r\n </div>\r\n <!-- Global Font and Theme -->\r\n <!-- <div class=\"accessibility-container d-flex justify-content-between\">\r\n <div class=\"d-flex\">\r\n <button class=\"btn btn-light btn-small rounded-circle\" (click)=\"getSmallFont()\">\r\n <span>A-</span>\r\n </button>\r\n <button class=\"btn btn-light btn-small rounded-circle\" (click)=\"getMediumFont()\">\r\n <span>A</span>\r\n </button>\r\n <button class=\"btn btn-light btn-small rounded-circle\" (click)=\"getLargeFont()\">\r\n <span>A+</span>\r\n </button>\r\n </div>\r\n <div class=\"d-flex\">\r\n <button class=\"btn btn-light btn-small rounded-circle\" (click)=\"getRedTheme()\">\r\n <span class=\"theme theme-red\"></span>\r\n </button>\r\n <button class=\"btn btn-light btn-small rounded-circle\" (click)=\"getBlackTheme()\">\r\n <span class=\"theme theme-black\"></span>\r\n </button>\r\n <button class=\"btn btn-light btn-small rounded-circle\" (click)=\"getBlueTheme()\">\r\n <span class=\"theme theme-blue\"></span>\r\n </button>\r\n </div>\r\n </div> -->\r\n</div>\r\n", styles: [".white-bg{background-color:#fff!important;width:100%!important}.grey-background{background-color:#f6f7fb!important}.imgs{width:20px!important}.cursor-pointer{cursor:pointer}.sidebar-outer{width:100%!important;float:left!important}.sidebar-outer .sidebar-header{padding:12px 15px!important}.sidebar-outer .sidebar-header .sh-top{display:flex!important;align-items:center!important;justify-content:space-between!important}.sidebar-outer .sidebar-header .sh-top .sh-top-left{display:flex!important;align-items:center!important}.sidebar-outer .sidebar-header .sh-top .sh-top-left .log-text{font-size:14px!important;font-weight:500!important;cursor:pointer!important}.sidebar-outer .sidebar-header .sh-top .sh-top-right button{height:24px!important;border:none!important;background-color:transparent!important}.sidebar-outer .sidebar-header .sh-bottom{display:flex!important;padding-top:16px!important}.sidebar-outer .sidebar-header .sh-bottom .initial-text{width:40px;height:40px;display:flex;align-items:center;justify-content:center;font-size:15px;border-radius:50%;color:#fff;background-color:#8e562e}.sidebar-outer .sidebar-header .sh-bottom .sh-bottom-content{padding-left:14px!important}.sidebar-outer .sidebar-header .sh-bottom .sh-bottom-content .title{font-size:17px!important;font-weight:600!important;height:21px!important;margin-bottom:2px!important;line-height:26px!important;color:#292f4c!important}.sidebar-outer .sidebar-header .sh-bottom .sh-bottom-content p{font-size:14px!important;line-height:22px!important;color:#676879!important;margin-bottom:0!important}.sidebar-outer .sidebar-header .sh-bottom .sh-bottom-content .sh-bottom-content-ls{display:flex!important;align-items:center!important;font-size:12px!important}.sidebar-outer .sidebar-header .sh-bottom .sh-bottom-content .session-content{position:relative!important;bottom:2px!important}.sidebar-outer .sidebar-body{padding:12px 20px!important;width:100%!important}.sidebar-outer .sidebar-body .sb-list{width:100%!important}.sidebar-outer .sidebar-body .sb-list ul{width:100%!important;list-style:none;padding-left:0;margin:0}.sidebar-outer .sidebar-body .sb-list ul li{display:flex!important;align-items:center!important;padding:8px 2px!important;cursor:pointer!important}.sidebar-outer .sidebar-body .sb-list ul li img{width:18px}.sidebar-outer .sidebar-body .sb-list ul li p{margin:0 0 0 8px!important;font-size:14px!important}.sidebar-outer .sidebar-body .sb-list ul li .lang-dropdown{margin-left:8px!important}.accessibility-container{background-color:#eee;padding:7px 20px}.accessibility-container .btn{align-content:center;align-items:center;border:1px solid #9e9e9e;color:#707070;display:flex;font-size:10px;height:20px;justify-content:center;padding:0;width:20px;margin-right:5px;overflow:hidden}.accessibility-container .btn:last-child{margin-right:0}.accessibility-container .btn .theme{display:block;height:100%;margin-left:-50%;width:60%}.accessibility-container .btn .theme-red{background-color:#d4231d}.accessibility-container .btn .theme-black{background-color:#212121}.accessibility-container .btn .theme-blue{background-color:#4d91ea}\n"] }]
2862
- }], ctorParameters: function () { return [{ type: i1$3.DialogService }, { type: CookieStorageManagerService }, { type: i3.Router }, { type: ToastMsgService }, { type: StorageService }, { type: i4.TranslateService }, { type: HttpCommonService }]; }, propDecorators: { languages: [{
2863
- type: Input
2864
- }], closeDialogBox: [{
2865
- type: Output
2866
- }] } });
2867
-
2868
- class SidePopupComponent {
2869
- constructor() {
2870
- this.closeDialogBox = new EventEmitter();
2871
- this.visible = false;
2872
- this.position = 'right';
2873
- this.header = 'Details';
2874
- }
2875
- //Method: Close the Side Panel
2876
- getcloseDialogBox() {
2877
- this.visible = false;
2878
- this.closeDialogBox.emit(true);
2879
- }
2880
- ngOnDestroy() {
2881
- this.visible = false;
2882
- }
2883
- }
2884
- SidePopupComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: SidePopupComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
2885
- SidePopupComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: SidePopupComponent, selector: "app-side-popup", inputs: { visible: "visible", position: "position", header: "header" }, outputs: { closeDialogBox: "closeDialogBox" }, ngImport: i0, template: "<p-dialog [header]=\"header\" (onHide)=\"getcloseDialogBox()\" [modal]=\"true\" [draggable]=\"false\" [(visible)]=\"visible\"\r\n [position]=\"position\" [style]=\"{\r\n width: '40vw',\r\n minHeight: '100vh',\r\n right: '-15px',\r\n position: 'absolute'\r\n }\">\r\n <!-- Dynamically Change the Content of Sidebar -->\r\n <ng-content></ng-content>\r\n</p-dialog>\r\n", styles: [""], dependencies: [{ kind: "component", type: i1$4.Dialog, selector: "p-dialog", inputs: ["header", "draggable", "resizable", "positionLeft", "positionTop", "contentStyle", "contentStyleClass", "modal", "closeOnEscape", "dismissableMask", "rtl", "closable", "responsive", "appendTo", "breakpoints", "styleClass", "maskStyleClass", "showHeader", "breakpoint", "blockScroll", "autoZIndex", "baseZIndex", "minX", "minY", "focusOnShow", "maximizable", "keepInViewport", "focusTrap", "transitionOptions", "closeIcon", "closeAriaLabel", "closeTabindex", "minimizeIcon", "maximizeIcon", "visible", "style", "position"], outputs: ["onShow", "onHide", "visibleChange", "onResizeInit", "onResizeEnd", "onDragEnd", "onMaximize"] }] });
2886
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: SidePopupComponent, decorators: [{
2887
- type: Component,
2888
- args: [{ selector: 'app-side-popup', template: "<p-dialog [header]=\"header\" (onHide)=\"getcloseDialogBox()\" [modal]=\"true\" [draggable]=\"false\" [(visible)]=\"visible\"\r\n [position]=\"position\" [style]=\"{\r\n width: '40vw',\r\n minHeight: '100vh',\r\n right: '-15px',\r\n position: 'absolute'\r\n }\">\r\n <!-- Dynamically Change the Content of Sidebar -->\r\n <ng-content></ng-content>\r\n</p-dialog>\r\n" }]
2889
- }], ctorParameters: function () { return []; }, propDecorators: { closeDialogBox: [{
2890
- type: Output
2891
- }], visible: [{
2892
- type: Input
2893
- }], position: [{
2894
- type: Input
2895
- }], header: [{
2896
- type: Input
2897
- }] } });
2898
-
2899
- class DateDiffPipe {
2900
- constructor() { } // Inject service
2901
- transform(date) {
2902
- if (date != null) {
2903
- const localDate = this.convertUTCToLocal(date);
2904
- let date2 = new Date(localDate);
2905
- let date1 = new Date();
2906
- if (date2 > date1) {
2907
- // Calculate the absolute difference in milliseconds between the two dates
2908
- const diffTime = Math.abs(date2.getTime() - date1.getTime());
2909
- // Calculate the number of days
2910
- const diffDays = Math.floor(diffTime / (1000 * 60 * 60 * 24));
2911
- // Calculate the remaining time after removing the days
2912
- const remainingTime = diffTime % (1000 * 60 * 60 * 24);
2913
- // Calculate the number of hours
2914
- const diffHours = Math.floor(remainingTime / (1000 * 60 * 60));
2915
- // Calculate the remaining time after removing the hours
2916
- const remainingMinutes = remainingTime % (1000 * 60 * 60);
2917
- // Calculate the number of minutes
2918
- const diffMinutes = Math.floor(remainingMinutes / (1000 * 60));
2919
- let result = '';
2920
- if (diffDays > 0) {
2921
- result += `${diffDays} days `;
2922
- }
2923
- if (diffHours > 0) {
2924
- result += `${diffHours} hours `;
2925
- }
2926
- if (diffMinutes > 0) {
2927
- result += `${diffMinutes} minutes`;
2928
- }
2929
- return result.trim();
2930
- }
2931
- else {
2932
- return '00:00:00';
2933
- }
2934
- }
2935
- return '';
2936
- }
2937
- convertUTCToLocal(newdate) {
2938
- let localDate = newdate + 'Z';
2939
- localDate = localDate.toLocaleString();
2940
- return localDate;
2941
- }
2942
- }
2943
- DateDiffPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: DateDiffPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
2944
- DateDiffPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.3.0", ngImport: i0, type: DateDiffPipe, name: "dateDiff" });
2945
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: DateDiffPipe, decorators: [{
2946
- type: Pipe,
2947
- args: [{
2948
- name: 'dateDiff',
2949
- }]
2950
- }], ctorParameters: function () { return []; } });
2951
-
2952
- class ViewpasswordPopupComponent {
2953
- constructor(dialogService,
2954
- // private readonly _RESTService: RESTMyaccessService,
2955
- msgService, _eventService, translateService, httpCommonService) {
2956
- this.dialogService = dialogService;
2957
- this.msgService = msgService;
2958
- this._eventService = _eventService;
2959
- this.translateService = translateService;
2960
- this.httpCommonService = httpCommonService;
2961
- this.servicePassword = 'Password';
2962
- this.showVaultBtn = false;
2963
- this.isContentLoaded = false;
2964
- this.isValueUpdated = false;
2965
- this.OpenTillDate = '';
2966
- this.unsubscribeAPIEventListenerData = new Subject();
2967
- this.totalEmails = '';
2968
- this.SSHFileType = '';
2969
- this.SSHFileName = '';
2970
- this.isSSHKey = false;
2971
- this.isPasswordVisible = true;
2972
- this.PasswordViewSuccessMsg = '';
2973
- this.SSHPasswordViewSuccessMsg = '';
2974
- this.SSHPasswordViewErrorMsg = '';
2975
- this.sshKeyForDownload = '';
2976
- this.getSelectedGridData(dialogService.data); //Getting Data from popup
2977
- }
2978
- ngAfterViewInit() {
2979
- this.getTranslateContent();
2980
- }
2981
- ngOnInit() {
2982
- this.getAccessServicePassword();
2983
- // this.getCurrentEmailsCount()
2984
- }
2985
- getSelectedGridData(gridData) {
2986
- if (gridData && gridData['payload']) {
2987
- this.mailDetails = gridData['payload'];
2988
- this.SSHFileType = gridData['SSHfileType'];
2989
- this.showVaultBtn = gridData['btnStatus'];
2990
- this.OpenTillDate = this.mailDetails['spv_Opentildate'];
2991
- this.isSSHKey = this.mailDetails['sshkey_isenabled'];
2992
- }
2993
- }
2994
- //Method: Convert text one Lang. to another
2995
- getTranslateContent() {
2996
- this.translateService
2997
- .get([
2998
- 'Generic_lib.PasswordViewSuccessMsg',
2999
- 'Generic_lib.SSHPasswordViewSuccessMsg',
3000
- 'Generic_lib.SSHPasswordViewErrorMsg',
3001
- ])
3002
- .pipe(takeUntil$1(this.unsubscribeAPIEventListenerData))
3003
- .subscribe((trans) => {
3004
- this.PasswordViewSuccessMsg =
3005
- trans['Generic_lib.PasswordViewSuccessMsg'];
3006
- this.SSHPasswordViewSuccessMsg =
3007
- trans['Generic_lib.SSHPasswordViewSuccessMsg'];
3008
- this.SSHPasswordViewErrorMsg =
3009
- trans['Generic_lib.SSHPasswordViewErrorMsg'];
3010
- });
3011
- }
3012
- //Method: Grants access to the View password for a service
3013
- getAccessServicePassword() {
3014
- this.isContentLoaded = false;
3015
- let mailDetails = {
3016
- mailid: String(this.mailDetails['smi_SpvId']),
3017
- // userid: this.userId,
3018
- // userSessionID: this.userSessionId,
3019
- };
3020
- this.httpCommonService
3021
- .getAccessToViewServicePassword(mailDetails)
3022
- .pipe(takeUntil$1(this.unsubscribeAPIEventListenerData), finalize$1(() => {
3023
- this.isContentLoaded = true;
3024
- }))
3025
- .subscribe((result) => {
3026
- this.servicePassword = result === null || result === void 0 ? void 0 : result.sshKeyPassPhrase;
3027
- this.SSHFileName = result === null || result === void 0 ? void 0 : result.sshFileName;
3028
- this.sshKeyForDownload = result === null || result === void 0 ? void 0 : result.sshKey;
3029
- this.getCurrentEmailsCount();
3030
- });
3031
- }
3032
- //Method: Hide password of a service
3033
- getHideServicePassword() {
3034
- this.isValueUpdated = true;
3035
- let mailDetails = {
3036
- spvId: String(this.mailDetails['smi_SpvId']),
3037
- // userId: this.userId,
3038
- };
3039
- this.httpCommonService
3040
- .getProtectedServiceCredentials(mailDetails)
3041
- .pipe(takeUntil$1(this.unsubscribeAPIEventListenerData), finalize$1(() => {
3042
- this.isValueUpdated = false;
3043
- }))
3044
- .subscribe((result) => {
3045
- if (result) {
3046
- this._eventService.emitUserEmail({
3047
- component: 'view-pwd',
3048
- refreshGrid: true,
3049
- });
3050
- }
3051
- });
3052
- }
3053
- /*Method : GET
3054
- Action : Fetch User Mails Count */
3055
- getCurrentEmailsCount() {
3056
- this.httpCommonService
3057
- .getUnreadUserEmailsCount()
3058
- .pipe(takeUntil$1(this.unsubscribeAPIEventListenerData))
3059
- .subscribe((count) => {
3060
- if (count <= 0) {
3061
- this.totalEmails = '';
3062
- }
3063
- else if (count > 99) {
3064
- this.totalEmails = '99+';
3065
- }
3066
- else {
3067
- this.totalEmails = String(count);
3068
- }
3069
- this.updateMailCount();
3070
- });
3071
- }
3072
- getGenerateFile() {
3073
- this.generateSSHKeyFile();
3074
- this.getHideServicePassword();
3075
- }
3076
- generateSSHKeyFile() {
3077
- try {
3078
- const blob = new Blob([this.sshKeyForDownload], { type: '' });
3079
- const url = window.URL.createObjectURL(blob);
3080
- const a = document.createElement('a');
3081
- a.href = url;
3082
- a.download = `${this.SSHFileName}.${this.SSHFileType}`;
3083
- document.body.appendChild(a);
3084
- a.click();
3085
- document.body.removeChild(a);
3086
- window.URL.revokeObjectURL(url);
3087
- this.msgService.success(this.SSHPasswordViewSuccessMsg);
3088
- }
3089
- catch (error) {
3090
- console.error('Error generating SSH key file:', error);
3091
- this.msgService.error(this.SSHPasswordViewErrorMsg);
3092
- }
3093
- }
3094
- updateMailCount() {
3095
- this._eventService.emitUserEmail({
3096
- component: 'email-count',
3097
- mailCount: this.totalEmails,
3098
- });
3099
- }
3100
- copyToClipboard(text) {
3101
- navigator.clipboard
3102
- .writeText(text)
3103
- .then(() => {
3104
- this.msgService.success(this.PasswordViewSuccessMsg);
3105
- })
3106
- .catch((error) => {
3107
- console.error('Error copying text to clipboard: ', error);
3108
- });
3109
- }
3110
- togglePasswordVisibility() {
3111
- this.isPasswordVisible = !this.isPasswordVisible;
3112
- }
3113
- showPassword() {
3114
- if (this.isSSHKey && !this.servicePassword) {
3115
- return false;
3116
- }
3117
- return true;
3118
- }
3119
- ngOnDestroy() {
3120
- // Unsubscribing All the Observer
3121
- this.unsubscribeAPIEventListenerData.next(true);
3122
- this.unsubscribeAPIEventListenerData.complete();
3123
- }
3124
- }
3125
- ViewpasswordPopupComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ViewpasswordPopupComponent, deps: [{ token: i1$3.DynamicDialogConfig }, { token: ToastMsgService }, { token: EventService }, { token: i4.TranslateService }, { token: HttpCommonService }], target: i0.ɵɵFactoryTarget.Component });
3126
- ViewpasswordPopupComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: ViewpasswordPopupComponent, selector: "app-viewpassword-popup", ngImport: i0, template: "<div class=\"view-pass-detail\">\r\n <!-- <div class=\"title\">{{\"Generic.Password\" | translate}}</div> -->\r\n <div class=\"mt-4 position-relative px-4\">\r\n <ng-container *ngIf=\"isContentLoaded; else LoadingAnimation\">\r\n <ng-container *ngIf=\"isSSHKey\">\r\n <div class=\"title\">{{ mailDetails[\"smi_MailSubject\"] }}</div>\r\n <p class=\"note-text mt-2\">\r\n {{ \"Generic_lib.DownloadSSHNote\" | translate }}\r\n </p>\r\n </ng-container>\r\n\r\n <ng-container *ngIf=\"showPassword()\">\r\n <div class=\"d-flex align-items-center\">\r\n <div class=\"password-checkbox-right\">\r\n <div class=\"checkbox-visibility-icon\">\r\n <input type=\"checkbox\" (click)=\"togglePasswordVisibility()\" />\r\n <span></span>\r\n </div>\r\n </div>\r\n <input\r\n class=\"form-control view-pass\"\r\n [ngClass]=\"isSSHKey === true ? 'ssh' : ''\"\r\n readonly\r\n type=\"{{ isPasswordVisible ? 'password' : 'text' }}\"\r\n [value]=\"servicePassword\"\r\n placeholder=\"\"\r\n autocomplete=\"off\"\r\n />\r\n <button\r\n (click)=\"copyToClipboard(servicePassword)\"\r\n type=\"button\"\r\n class=\"btn btn-primary d-flex align-items-center copy-btn\"\r\n title=\"Copy To Clipboard\"\r\n >\r\n <img\r\n src=\"assets/common-header-lib/images/copy-img.svg\"\r\n alt=\"copy Icon\"\r\n class=\"mx-2\"\r\n />{{ \"Generic_lib.Copy\" | translate }}\r\n </button>\r\n <img\r\n *ngIf=\"!isSSHKey\"\r\n src=\"assets/common-header-lib/images/pass-img.svg\"\r\n alt=\"Icon\"\r\n class=\"position-absolute mx-2\"\r\n />\r\n <p *ngIf=\"isSSHKey\" class=\"position-absolute mx-2\">\r\n {{ \"Generic_lib.KeyPassphrase\" | translate }}:\r\n </p>\r\n </div>\r\n </ng-container>\r\n </ng-container>\r\n </div>\r\n\r\n <!-- LODDER -->\r\n <ng-template #LoadingAnimation>\r\n <div class=\"row w-100\">\r\n <div class=\"col-12\">\r\n <p-skeleton height=\"1.5rem\" styleClass=\"mb-2\"></p-skeleton>\r\n </div>\r\n <div class=\"col-12\">\r\n <p-skeleton height=\"1.5rem\" styleClass=\"mb-2\"></p-skeleton>\r\n </div>\r\n <div class=\"col-12\">\r\n <p-skeleton\r\n height=\"1.5rem\"\r\n width=\"30%\"\r\n styleClass=\"float-end mb-2\"\r\n ></p-skeleton>\r\n </div>\r\n </div>\r\n </ng-template>\r\n <!-- /LODDER -->\r\n\r\n <!-- MAIN-CONTENT -->\r\n <ng-container *ngIf=\"isContentLoaded\">\r\n <div class=\"d-flex mt-2 my-4 gap-1 px-4\">\r\n <div class=\"label-text\">\r\n {{ \"Generic_lib.RemainingTime\" | translate }} :\r\n </div>\r\n <div class=\"time-text\">{{ OpenTillDate | dateDiff }}</div>\r\n </div>\r\n\r\n <!-- <ng-container *ngIf=\"showVaultBtn\"> -->\r\n <!-- ! AMIT: Check showVaultBtn condition -->\r\n <ng-container *ngIf=\"true\">\r\n <div class=\"border-bottom\"></div>\r\n <div class=\"d-flex mt-4 justify-content-end gap-1 ms-auto px-4 mb-2\">\r\n <ng-container *ngIf=\"isSSHKey; else downloadbtn\">\r\n <p-button\r\n type=\"button\"\r\n label=\"{{ 'Generic_lib.DownloadKey' | translate }}\"\r\n [iconPos]=\"'right'\"\r\n [loading]=\"isValueUpdated\"\r\n class=\"submit-btn view-btn\"\r\n (click)=\"getGenerateFile()\"\r\n ></p-button>\r\n </ng-container>\r\n <ng-template #downloadbtn>\r\n <p-button\r\n type=\"button\"\r\n label=\"{{ 'Generic_lib.VaultCredentials' | translate }}\"\r\n [iconPos]=\"'right'\"\r\n [loading]=\"isValueUpdated\"\r\n class=\"submit-btn view-btn\"\r\n (click)=\"getHideServicePassword()\"\r\n ></p-button>\r\n </ng-template>\r\n </div>\r\n </ng-container>\r\n </ng-container>\r\n <!-- /MAIN-CONTENT -->\r\n</div>\r\n", styles: [".view-pass-detail .key-icon{position:fixed;top:134px;left:35px}.view-pass-detail .title{font-size:15px;font-weight:700;color:var(--primary-text)}.view-pass-detail .note-text{font-size:14px!important}.view-pass-detail .view-pass{border-radius:4px 0 0 4px;padding-left:40px;height:40px;font-size:14px}.view-pass-detail .view-pass.ssh{padding-left:115px;padding-right:40px;margin:10px 0}.view-pass-detail .copy-btn{border-radius:0 4px 4px 0;height:40px;font-size:14px}.view-pass-detail .label-text{color:var(--secondary-text);font-size:13px}.view-pass-detail .time-text{font-size:13px;font-weight:600}.view-pass-detail .view-btn{border-radius:4px;height:35px;font-size:14px;text-align:center;margin-top:4px}.view-pass-detail .border-bottom{position:relative;top:13px}.view-pass-detail p{font-size:14px!important;margin-bottom:1px}.password-checkbox-right{right:120px;position:absolute}.checkbox-visibility-icon{position:relative}.checkbox-visibility-icon input[type=checkbox]{opacity:0;position:absolute;top:4px;left:5px;transform:scale(1.7);z-index:2;cursor:pointer}.checkbox-visibility-icon input[type=checkbox]:checked+span{background:url(assets/common-header-lib/images/login-bg/visibility.svg);background-repeat:no-repeat;background-position:0px;height:12px;width:18px;display:block;background-size:17px}@media (min-width: 992px){.checkbox-visibility-icon input[type=checkbox]:checked+span{height:12px;width:18px;background-size:17px}}.checkbox-visibility-icon input[type=checkbox]+span{background:url(assets/common-header-lib/images/login-bg/visibility_off.svg);background-repeat:no-repeat;background-position:0px;height:12px;width:18px;display:block;background-size:17px}@media (min-width: 992px){.checkbox-visibility-icon input[type=checkbox]+span{height:24px;width:18px;background-size:17px}}\n"], dependencies: [{ kind: "directive", type: i6.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i6.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i9$1.Skeleton, selector: "p-skeleton", inputs: ["styleClass", "style", "shape", "animation", "borderRadius", "size", "width", "height"] }, { kind: "component", type: i10.Button, selector: "p-button", inputs: ["type", "iconPos", "icon", "badge", "label", "disabled", "loading", "loadingIcon", "style", "styleClass", "badgeClass", "ariaLabel"], outputs: ["onClick", "onFocus", "onBlur"] }, { kind: "pipe", type: i4.TranslatePipe, name: "translate" }, { kind: "pipe", type: DateDiffPipe, name: "dateDiff" }] });
3127
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ViewpasswordPopupComponent, decorators: [{
3128
- type: Component,
3129
- args: [{ selector: 'app-viewpassword-popup', template: "<div class=\"view-pass-detail\">\r\n <!-- <div class=\"title\">{{\"Generic.Password\" | translate}}</div> -->\r\n <div class=\"mt-4 position-relative px-4\">\r\n <ng-container *ngIf=\"isContentLoaded; else LoadingAnimation\">\r\n <ng-container *ngIf=\"isSSHKey\">\r\n <div class=\"title\">{{ mailDetails[\"smi_MailSubject\"] }}</div>\r\n <p class=\"note-text mt-2\">\r\n {{ \"Generic_lib.DownloadSSHNote\" | translate }}\r\n </p>\r\n </ng-container>\r\n\r\n <ng-container *ngIf=\"showPassword()\">\r\n <div class=\"d-flex align-items-center\">\r\n <div class=\"password-checkbox-right\">\r\n <div class=\"checkbox-visibility-icon\">\r\n <input type=\"checkbox\" (click)=\"togglePasswordVisibility()\" />\r\n <span></span>\r\n </div>\r\n </div>\r\n <input\r\n class=\"form-control view-pass\"\r\n [ngClass]=\"isSSHKey === true ? 'ssh' : ''\"\r\n readonly\r\n type=\"{{ isPasswordVisible ? 'password' : 'text' }}\"\r\n [value]=\"servicePassword\"\r\n placeholder=\"\"\r\n autocomplete=\"off\"\r\n />\r\n <button\r\n (click)=\"copyToClipboard(servicePassword)\"\r\n type=\"button\"\r\n class=\"btn btn-primary d-flex align-items-center copy-btn\"\r\n title=\"Copy To Clipboard\"\r\n >\r\n <img\r\n src=\"assets/common-header-lib/images/copy-img.svg\"\r\n alt=\"copy Icon\"\r\n class=\"mx-2\"\r\n />{{ \"Generic_lib.Copy\" | translate }}\r\n </button>\r\n <img\r\n *ngIf=\"!isSSHKey\"\r\n src=\"assets/common-header-lib/images/pass-img.svg\"\r\n alt=\"Icon\"\r\n class=\"position-absolute mx-2\"\r\n />\r\n <p *ngIf=\"isSSHKey\" class=\"position-absolute mx-2\">\r\n {{ \"Generic_lib.KeyPassphrase\" | translate }}:\r\n </p>\r\n </div>\r\n </ng-container>\r\n </ng-container>\r\n </div>\r\n\r\n <!-- LODDER -->\r\n <ng-template #LoadingAnimation>\r\n <div class=\"row w-100\">\r\n <div class=\"col-12\">\r\n <p-skeleton height=\"1.5rem\" styleClass=\"mb-2\"></p-skeleton>\r\n </div>\r\n <div class=\"col-12\">\r\n <p-skeleton height=\"1.5rem\" styleClass=\"mb-2\"></p-skeleton>\r\n </div>\r\n <div class=\"col-12\">\r\n <p-skeleton\r\n height=\"1.5rem\"\r\n width=\"30%\"\r\n styleClass=\"float-end mb-2\"\r\n ></p-skeleton>\r\n </div>\r\n </div>\r\n </ng-template>\r\n <!-- /LODDER -->\r\n\r\n <!-- MAIN-CONTENT -->\r\n <ng-container *ngIf=\"isContentLoaded\">\r\n <div class=\"d-flex mt-2 my-4 gap-1 px-4\">\r\n <div class=\"label-text\">\r\n {{ \"Generic_lib.RemainingTime\" | translate }} :\r\n </div>\r\n <div class=\"time-text\">{{ OpenTillDate | dateDiff }}</div>\r\n </div>\r\n\r\n <!-- <ng-container *ngIf=\"showVaultBtn\"> -->\r\n <!-- ! AMIT: Check showVaultBtn condition -->\r\n <ng-container *ngIf=\"true\">\r\n <div class=\"border-bottom\"></div>\r\n <div class=\"d-flex mt-4 justify-content-end gap-1 ms-auto px-4 mb-2\">\r\n <ng-container *ngIf=\"isSSHKey; else downloadbtn\">\r\n <p-button\r\n type=\"button\"\r\n label=\"{{ 'Generic_lib.DownloadKey' | translate }}\"\r\n [iconPos]=\"'right'\"\r\n [loading]=\"isValueUpdated\"\r\n class=\"submit-btn view-btn\"\r\n (click)=\"getGenerateFile()\"\r\n ></p-button>\r\n </ng-container>\r\n <ng-template #downloadbtn>\r\n <p-button\r\n type=\"button\"\r\n label=\"{{ 'Generic_lib.VaultCredentials' | translate }}\"\r\n [iconPos]=\"'right'\"\r\n [loading]=\"isValueUpdated\"\r\n class=\"submit-btn view-btn\"\r\n (click)=\"getHideServicePassword()\"\r\n ></p-button>\r\n </ng-template>\r\n </div>\r\n </ng-container>\r\n </ng-container>\r\n <!-- /MAIN-CONTENT -->\r\n</div>\r\n", styles: [".view-pass-detail .key-icon{position:fixed;top:134px;left:35px}.view-pass-detail .title{font-size:15px;font-weight:700;color:var(--primary-text)}.view-pass-detail .note-text{font-size:14px!important}.view-pass-detail .view-pass{border-radius:4px 0 0 4px;padding-left:40px;height:40px;font-size:14px}.view-pass-detail .view-pass.ssh{padding-left:115px;padding-right:40px;margin:10px 0}.view-pass-detail .copy-btn{border-radius:0 4px 4px 0;height:40px;font-size:14px}.view-pass-detail .label-text{color:var(--secondary-text);font-size:13px}.view-pass-detail .time-text{font-size:13px;font-weight:600}.view-pass-detail .view-btn{border-radius:4px;height:35px;font-size:14px;text-align:center;margin-top:4px}.view-pass-detail .border-bottom{position:relative;top:13px}.view-pass-detail p{font-size:14px!important;margin-bottom:1px}.password-checkbox-right{right:120px;position:absolute}.checkbox-visibility-icon{position:relative}.checkbox-visibility-icon input[type=checkbox]{opacity:0;position:absolute;top:4px;left:5px;transform:scale(1.7);z-index:2;cursor:pointer}.checkbox-visibility-icon input[type=checkbox]:checked+span{background:url(assets/common-header-lib/images/login-bg/visibility.svg);background-repeat:no-repeat;background-position:0px;height:12px;width:18px;display:block;background-size:17px}@media (min-width: 992px){.checkbox-visibility-icon input[type=checkbox]:checked+span{height:12px;width:18px;background-size:17px}}.checkbox-visibility-icon input[type=checkbox]+span{background:url(assets/common-header-lib/images/login-bg/visibility_off.svg);background-repeat:no-repeat;background-position:0px;height:12px;width:18px;display:block;background-size:17px}@media (min-width: 992px){.checkbox-visibility-icon input[type=checkbox]+span{height:24px;width:18px;background-size:17px}}\n"] }]
3130
- }], ctorParameters: function () { return [{ type: i1$3.DynamicDialogConfig }, { type: ToastMsgService }, { type: EventService }, { type: i4.TranslateService }, { type: HttpCommonService }]; } });
3131
-
3132
- class NoServiceMyAccessPgComponent {
3133
- constructor() {
3134
- this.heading = "We couldn't find any service matching your search within the chosen LOB. Try refining your keywords or choosing a different LOB for better results"; //'Generic_lib.NoSearchResult';
3135
- this.subHeading = '';
3136
- }
3137
- }
3138
- NoServiceMyAccessPgComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: NoServiceMyAccessPgComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
3139
- NoServiceMyAccessPgComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: NoServiceMyAccessPgComponent, selector: "app-no-service-my-access-pg", inputs: { heading: "heading", subHeading: "subHeading" }, ngImport: i0, template: "<div class=\"no-service-content mt-5\">\r\n <div class=\"text-center\">\r\n <img src=\"assets/common-header-lib/images/Frame.svg\" class=\"frame-img w-75\" alt=\"Icon\">\r\n </div>\r\n <div class=\"no-service-description\">\r\n <!-- <div class=\"no-data-text\">{{heading | translate}}</div> -->\r\n <div class=\"no-data-text\">{{heading }}</div>\r\n <p>{{subHeading}}</p>\r\n </div>\r\n</div>", styles: [".no-service-content{display:flex;justify-content:center;align-items:center;flex-direction:column}@media screen and (min-width: 1744px){.no-service-content{margin-top:200px!important}}.no-service-description{width:55%;text-align:center;margin-top:16px}.no-data-text{font-size:14px;color:#212121;font-weight:400}\n"] });
3140
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: NoServiceMyAccessPgComponent, decorators: [{
3141
- type: Component,
3142
- args: [{ selector: 'app-no-service-my-access-pg', template: "<div class=\"no-service-content mt-5\">\r\n <div class=\"text-center\">\r\n <img src=\"assets/common-header-lib/images/Frame.svg\" class=\"frame-img w-75\" alt=\"Icon\">\r\n </div>\r\n <div class=\"no-service-description\">\r\n <!-- <div class=\"no-data-text\">{{heading | translate}}</div> -->\r\n <div class=\"no-data-text\">{{heading }}</div>\r\n <p>{{subHeading}}</p>\r\n </div>\r\n</div>", styles: [".no-service-content{display:flex;justify-content:center;align-items:center;flex-direction:column}@media screen and (min-width: 1744px){.no-service-content{margin-top:200px!important}}.no-service-description{width:55%;text-align:center;margin-top:16px}.no-data-text{font-size:14px;color:#212121;font-weight:400}\n"] }]
3143
- }], ctorParameters: function () { return []; }, propDecorators: { heading: [{
3144
- type: Input
3145
- }], subHeading: [{
3146
- type: Input
3147
- }] } });
3148
-
3149
- class GridPaginationComponent {
3150
- constructor() {
3151
- this.first = 0;
3152
- this.currentPgNo = 0;
3153
- this.rows = GlobalConstants.PAGEROW;
3154
- this.totalRecords = 0;
3155
- this.onPgChange = new EventEmitter();
3156
- }
3157
- onPageChange(event) {
3158
- event['page'] = event['page'] + 1; // By default pg index 0 so add +1
3159
- this.currentPgNo = event.page;
3160
- this.rows = event.rows;
3161
- //Emit Page No and PageRow Size
3162
- this.onPgChange.emit({
3163
- currentPgNo: this.currentPgNo,
3164
- perPgRows: this.rows,
3165
- });
3166
- }
3167
- }
3168
- GridPaginationComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: GridPaginationComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
3169
- GridPaginationComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: GridPaginationComponent, selector: "app-grid-pagination", inputs: { currentPgNo: "currentPgNo", rows: "rows", totalRecords: "totalRecords" }, outputs: { onPgChange: "onPgChange" }, ngImport: i0, template: "<p-paginator (onPageChange)=\"onPageChange($event)\" [first]=\"first\" [rows]=\"rows\" [totalRecords]=\"totalRecords\"\r\n [showFirstLastIcon]=\"true\" [showCurrentPageReport]=\"true\"\r\n currentPageReportTemplate=\"{first} - {last} of {totalRecords}\" [rowsPerPageOptions]=\"[10, 50, 100]\"></p-paginator>\r\n", styles: [""], dependencies: [{ kind: "component", type: i1$5.Paginator, selector: "p-paginator", inputs: ["pageLinkSize", "style", "styleClass", "alwaysShow", "templateLeft", "templateRight", "dropdownAppendTo", "dropdownScrollHeight", "currentPageReportTemplate", "showCurrentPageReport", "showFirstLastIcon", "totalRecords", "rows", "rowsPerPageOptions", "showJumpToPageDropdown", "showJumpToPageInput", "showPageLinks", "dropdownItemTemplate", "first"], outputs: ["onPageChange"] }] });
3170
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: GridPaginationComponent, decorators: [{
3171
- type: Component,
3172
- args: [{ selector: 'app-grid-pagination', template: "<p-paginator (onPageChange)=\"onPageChange($event)\" [first]=\"first\" [rows]=\"rows\" [totalRecords]=\"totalRecords\"\r\n [showFirstLastIcon]=\"true\" [showCurrentPageReport]=\"true\"\r\n currentPageReportTemplate=\"{first} - {last} of {totalRecords}\" [rowsPerPageOptions]=\"[10, 50, 100]\"></p-paginator>\r\n" }]
3173
- }], ctorParameters: function () { return []; }, propDecorators: { currentPgNo: [{
3174
- type: Input
3175
- }], rows: [{
3176
- type: Input
3177
- }], totalRecords: [{
3178
- type: Input
3179
- }], onPgChange: [{
3180
- type: Output
3181
- }] } });
3182
-
3183
- class customDateFormatPipe {
3184
- constructor() {
3185
- this.datePipe = new DatePipe('en-US');
3186
- }
3187
- transform(value) {
3188
- if (!value) {
3189
- return 'Not Applicable';
3190
- }
3191
- const parsedDate = new Date(value);
3192
- if (isNaN(parsedDate.getTime())) {
3193
- return 'Invalid Date';
3194
- }
3195
- return this.datePipe.transform(parsedDate, 'dd-MMM-yyyy HH:mm:ss');
3196
- }
3197
- }
3198
- customDateFormatPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: customDateFormatPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
3199
- customDateFormatPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.3.0", ngImport: i0, type: customDateFormatPipe, name: "customDateFormat" });
3200
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: customDateFormatPipe, decorators: [{
3201
- type: Pipe,
3202
- args: [{
3203
- name: 'customDateFormat',
3204
- }]
3205
- }] });
3206
-
3207
- class UserMailboxComponent {
3208
- constructor(dialogService,
3209
- // private readonly _restMyaccessService: RESTMyaccessService,
3210
- // private readonly loginService: RESTLoginFormService,
3211
- _eventService, translate, libService, httpCommonService) {
3212
- this.dialogService = dialogService;
3213
- this._eventService = _eventService;
3214
- this.translate = translate;
3215
- this.libService = libService;
3216
- this.httpCommonService = httpCommonService;
3217
- this.closeMailDialogBox = new EventEmitter();
3218
- this.ListOfUserAssingedMails = [];
3219
- // private userId: string;
3220
- this.unsubscribeAPIEventListenerData = new Subject();
3221
- this.showVaultBtn = false;
3222
- this.SSHFileName = 'ppk';
3223
- this.hasUserAssignedMails = true;
3224
- //Pagintion
3225
- this.currentPgNo = 1;
3226
- this.perPgRows = 10;
3227
- this.totalCount = 0;
3228
- this.NoServiceMsgText = '';
3229
- this.isContentLoaded = false;
3230
- this.repeatLoader = Array.from({ length: this.perPgRows }).map((_, i) => `Item #${i}`);
3231
- this.apiURL = '';
3232
- }
3233
- ngOnInit() {
3234
- this.onLoadMethods();
3235
- }
3236
- /* Require Methods on PageLoad */
3237
- onLoadMethods() {
3238
- this.getUserEmails();
3239
- this.getglobalConfigDetails();
3240
- this._eventService.listenerUserEmail().subscribe((data) => {
3241
- var _a;
3242
- if (data && data['component'] === 'view-pwd') {
3243
- if (data['refreshGrid']) {
3244
- (_a = this.ref) === null || _a === void 0 ? void 0 : _a.close();
3245
- // this.getUserEmails();
3246
- }
3247
- }
3248
- });
3249
- }
3250
- openViewPasswordPanel(mailDetails) {
3251
- this.ref = this.dialogService.open(ViewpasswordPopupComponent, {
3252
- header: mailDetails.sshkey_isenabled
3253
- ? this.translate.instant('Generic_lib.SSHKey')
3254
- : this.translate.instant('Generic_lib.Password'),
3255
- styleClass: 'view-pass-details',
3256
- data: {
3257
- payload: mailDetails,
3258
- btnStatus: this.showVaultBtn,
3259
- SSHfileType: this.SSHFileName,
3260
- },
3261
- });
3262
- // Handle the close event here
3263
- this.ref.onClose.subscribe((result) => {
3264
- this.getUserEmails();
3265
- });
3266
- }
3267
- /*Action : Fetching user Emails from a API */
3268
- getUserEmails() {
3269
- this.isContentLoaded = false;
3270
- let payload = {
3271
- pageSize: this.perPgRows,
3272
- pageNumber: this.currentPgNo,
3273
- };
3274
- this.httpCommonService
3275
- .getUserAssignedMails(payload)
3276
- .pipe(takeUntil(this.unsubscribeAPIEventListenerData), finalize(() => {
3277
- this.isContentLoaded = true;
3278
- }))
3279
- .subscribe((response) => {
3280
- this.ListOfUserAssingedMails = response;
3281
- if (this.ListOfUserAssingedMails.length > 0) {
3282
- this.hasUserAssignedMails = true;
3283
- this.getTotalNoOfRecords();
3284
- }
3285
- else {
3286
- this.hasUserAssignedMails = false;
3287
- this.NoServiceMsgText = errorMsg.NOMAILFOUND;
3288
- }
3289
- });
3290
- }
3291
- //Note: Get Total No of Records for Pagination
3292
- getTotalNoOfRecords() {
3293
- if (this.ListOfUserAssingedMails.length > 0 &&
3294
- this.ListOfUserAssingedMails[0]['totalRecords'] != null) {
3295
- this.totalCount = this.ListOfUserAssingedMails[0]['totalRecords'];
3296
- }
3297
- }
3298
- /*Method : POST
3299
- Action : Get configuration ID based on to show hide Vault Btn*/
3300
- getglobalConfigDetails() {
3301
- this.httpCommonService
3302
- .getglobalConfigDetails('1', [247, 338])
3303
- .pipe(takeUntil(this.unsubscribeAPIEventListenerData))
3304
- .subscribe((data) => {
3305
- if (data && data.length > 0) {
3306
- data.forEach((element) => {
3307
- //For Vault Btn
3308
- if (element && element['id'] === 247 && element['value'] === '0') {
3309
- this.showVaultBtn = false;
3310
- }
3311
- else {
3312
- this.showVaultBtn = true;
3313
- }
3314
- //For Vault Btn
3315
- if (element && element['id'] === 338 && element['value'] === '1') {
3316
- this.SSHFileName = 'pem';
3317
- }
3318
- else {
3319
- this.SSHFileName = 'ppk';
3320
- }
3321
- });
3322
- }
3323
- });
3324
- }
3325
- //Method: Fetch User Assigned Email based on PageNo
3326
- updateDataOnPageChange(pageDetails) {
3327
- this.currentPgNo = pageDetails['currentPgNo'];
3328
- this.perPgRows = pageDetails['perPgRows'];
3329
- this.getUserEmails();
3330
- }
3331
- closeMailBox() {
3332
- this.closeMailDialogBox.emit();
3333
- }
3334
- ngOnDestroy() {
3335
- this.unsubscribeAPIEventListenerData.next(true);
3336
- this.unsubscribeAPIEventListenerData.complete();
3337
- }
3338
- }
3339
- UserMailboxComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: UserMailboxComponent, deps: [{ token: i1$3.DialogService }, { token: EventService }, { token: i4.TranslateService }, { token: CommonHeaderLibService }, { token: HttpCommonService }], target: i0.ɵɵFactoryTarget.Component });
3340
- UserMailboxComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: UserMailboxComponent, selector: "app-user-mailbox", inputs: { apiURL: "apiURL" }, outputs: { closeMailDialogBox: "closeMailDialogBox" }, providers: [DialogService], ngImport: i0, template: "<div class=\"mail-content\">\r\n <div\r\n class=\"box-title my-3 d-flex justify-content-between align-items-center w-100\"\r\n >\r\n <div>\r\n {{ \"Generic_lib.MailBox\" | translate }}\r\n </div>\r\n <button\r\n type=\"button\"\r\n class=\"common-bn tertiary-btn ms-auto\"\r\n (click)=\"closeMailBox()\"\r\n >\r\n <img\r\n src=\"assets/common-header-lib/images/close.svg\"\r\n class=\"imgs\"\r\n alt=\"close icon\"\r\n title=\"Close\"\r\n loading=\"lazy\"\r\n />\r\n </button>\r\n </div>\r\n\r\n <div class=\"mail-table\">\r\n <ng-container *ngIf=\"isContentLoaded && hasUserAssignedMails\">\r\n <p-table\r\n [value]=\"ListOfUserAssingedMails\"\r\n selectionMode=\"multiple\"\r\n dataKey=\"code\"\r\n [tableStyle]=\"{ 'min-width': '50rem' }\"\r\n >\r\n <ng-template pTemplate=\"header\">\r\n <tr>\r\n <th scope=\"col\">\r\n {{ \"Generic_lib.From\" | translate }}\r\n </th>\r\n\r\n <th scope=\"col\">\r\n {{ \"Generic_lib.Subject\" | translate }}\r\n </th>\r\n\r\n <th scope=\"col\">\r\n {{ \"Generic_lib.ViewFrom\" | translate }}\r\n </th>\r\n\r\n <th scope=\"col\"></th>\r\n\r\n <th scope=\"col\">\r\n {{ \"Generic_lib.Action\" | translate }}\r\n </th>\r\n </tr>\r\n </ng-template>\r\n <ng-template pTemplate=\"body\" let-userMail>\r\n <tr [ngClass]=\"{ markasRead: userMail.smi_sms_id != 1 }\">\r\n <td class=\"form-colm\">{{ userMail.smi_From_Details }}</td>\r\n <td>\r\n <div class=\"subject-colm\" title=\"{{ userMail.smi_MailSubject }}\">\r\n {{ userMail.smi_MailSubject }}\r\n </div>\r\n </td>\r\n <!-- <td class=\"view-colm\">{{userMail.smi_Received_On}}</td> -->\r\n <td class=\"view-colm\">\r\n {{ userMail.smi_Received_On | customDateFormat }}\r\n </td>\r\n <td>\r\n <div class=\"icon-colm\">\r\n <div>\r\n <img\r\n src=\"assets/common-header-lib/images/mail-icon.svg\"\r\n alt=\"Icon\"\r\n />\r\n </div>\r\n <div>\r\n <img\r\n src=\"assets/common-header-lib/images/flag1.svg\"\r\n alt=\"Icon\"\r\n />\r\n </div>\r\n <div>\r\n <img\r\n src=\"assets/common-header-lib/images/lock1.svg\"\r\n alt=\"Icon\"\r\n class=\"\"\r\n />\r\n </div>\r\n </div>\r\n </td>\r\n <td class=\"action-colm\">\r\n <button\r\n [disabled]=\"userMail.password_status === 'Close'\"\r\n (click)=\"openViewPasswordPanel(userMail)\"\r\n class=\"view-label\"\r\n >\r\n {{ \"Generic_lib.ViewPassword\" | translate }}\r\n </button>\r\n </td>\r\n </tr></ng-template\r\n >\r\n </p-table>\r\n </ng-container>\r\n <ng-container *ngIf=\"!isContentLoaded\">\r\n <p-table\r\n [value]=\"repeatLoader\"\r\n [tableStyle]=\"{ 'min-width': '50rem' }\"\r\n responsiveLayout=\"scroll\"\r\n >\r\n <ng-template pTemplate=\"header\">\r\n <tr>\r\n <th scope=\"col\">{{ \"Generic_lib.From\" | translate }}</th>\r\n <th scope=\"col\">{{ \"Generic_lib.Subject\" | translate }}</th>\r\n <th scope=\"col\">{{ \"Generic_lib.ViewFrom\" | translate }}</th>\r\n <th scope=\"col\"></th>\r\n <th scope=\"col\">{{ \"Generic_lib.Action\" | translate }}</th>\r\n </tr>\r\n </ng-template>\r\n <ng-template pTemplate=\"body\" let-data>\r\n <tr>\r\n <td><p-skeleton height=\"1rem\" width=\"100%\"></p-skeleton></td>\r\n <td><p-skeleton height=\"1rem\" width=\"100%\"></p-skeleton></td>\r\n <td><p-skeleton height=\"1rem\" width=\"100%\"></p-skeleton></td>\r\n <td><p-skeleton height=\"1rem\" width=\"100%\"></p-skeleton></td>\r\n <td><p-skeleton height=\"1rem\" width=\"100%\"></p-skeleton></td>\r\n </tr>\r\n </ng-template>\r\n </p-table>\r\n </ng-container>\r\n <!-- When There is No Data Present -->\r\n <ng-container *ngIf=\"!hasUserAssignedMails\">\r\n <app-no-service-my-access-pg\r\n [heading]=\"NoServiceMsgText\"\r\n ></app-no-service-my-access-pg>\r\n </ng-container>\r\n </div>\r\n <!-- ---Pagination -->\r\n <div class=\"mail-pagination\">\r\n <app-grid-pagination\r\n [totalRecords]=\"totalCount\"\r\n (onPgChange)=\"updateDataOnPageChange($event)\"\r\n ></app-grid-pagination>\r\n </div>\r\n</div>\r\n", styles: [".mail-content{padding:0 25px;height:calc(100vh - 42px);overflow:auto;background-color:#fff}.mail-content .mail-body{background-color:#000}.mail-content .box-title{color:var(--primary-text);font-size:20px;line-height:30px;font-weight:600}.mail-content .view-label{border:none;color:var(--dodger-blue);font-size:13px!important;font-weight:600;cursor:pointer;padding-right:25px}.mail-content .icon-trending{position:relative;left:5px;cursor:pointer}.mail-content .disable-click{pointer-events:none}.mail-content .disable-click:hover,.mail-content .disable-click:focus{cursor:not-allowed}.subject-colm{text-overflow:ellipsis;overflow:hidden;width:500px}.markasRead{border-left:2px solid #3b82f6!important;color:#676879!important;border-bottom:1px solid #dee2e6!important;font-weight:600}.icon-colm div{display:inline-flex;width:30px;height:30px;border-radius:50%;align-items:center;justify-content:center;vertical-align:middle;margin-right:4px;cursor:pointer}.icon-colm div img{width:16px;height:16px}.icon-colm div:hover{background-color:#fff}.icon-colm div:hover img{filter:invert(0%) sepia(4%) saturate(0%) hue-rotate(324deg) brightness(55%) contrast(105%)}.view-label{background:url(assets/common-header-lib/images/east.svg) no-repeat 99% 5px}button:disabled{cursor:not-allowed!important;opacity:50%}\n"], dependencies: [{ kind: "directive", type: i6.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i6.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i9.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "component", type: i9$1.Skeleton, selector: "p-skeleton", inputs: ["styleClass", "style", "shape", "animation", "borderRadius", "size", "width", "height"] }, { kind: "component", type: i9$2.Table, selector: "p-table", inputs: ["frozenColumns", "frozenValue", "style", "styleClass", "tableStyle", "tableStyleClass", "paginator", "pageLinks", "rowsPerPageOptions", "alwaysShowPaginator", "paginatorPosition", "paginatorDropdownAppendTo", "paginatorDropdownScrollHeight", "currentPageReportTemplate", "showCurrentPageReport", "showJumpToPageDropdown", "showJumpToPageInput", "showFirstLastIcon", "showPageLinks", "defaultSortOrder", "sortMode", "resetPageOnSort", "selectionMode", "selectionPageOnly", "contextMenuSelection", "contextMenuSelectionMode", "dataKey", "metaKeySelection", "rowSelectable", "rowTrackBy", "lazy", "lazyLoadOnInit", "compareSelectionBy", "csvSeparator", "exportFilename", "filters", "globalFilterFields", "filterDelay", "filterLocale", "expandedRowKeys", "editingRowKeys", "rowExpandMode", "scrollable", "scrollDirection", "rowGroupMode", "scrollHeight", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "virtualScrollDelay", "frozenWidth", "responsive", "contextMenu", "resizableColumns", "columnResizeMode", "reorderableColumns", "loading", "loadingIcon", "showLoader", "rowHover", "customSort", "showInitialSortBadge", "autoLayout", "exportFunction", "exportHeader", "stateKey", "stateStorage", "editMode", "groupRowsBy", "groupRowsByOrder", "responsiveLayout", "breakpoint", "virtualRowHeight", "value", "columns", "first", "rows", "totalRecords", "sortField", "sortOrder", "multiSortMeta", "selection", "selectAll"], outputs: ["selectAllChange", "selectionChange", "contextMenuSelectionChange", "onRowSelect", "onRowUnselect", "onPage", "onSort", "onFilter", "onLazyLoad", "onRowExpand", "onRowCollapse", "onContextMenuSelect", "onColResize", "onColReorder", "onRowReorder", "onEditInit", "onEditComplete", "onEditCancel", "onHeaderCheckboxToggle", "sortFunction", "firstChange", "rowsChange", "onStateSave", "onStateRestore"] }, { kind: "component", type: NoServiceMyAccessPgComponent, selector: "app-no-service-my-access-pg", inputs: ["heading", "subHeading"] }, { kind: "component", type: GridPaginationComponent, selector: "app-grid-pagination", inputs: ["currentPgNo", "rows", "totalRecords"], outputs: ["onPgChange"] }, { kind: "pipe", type: i4.TranslatePipe, name: "translate" }, { kind: "pipe", type: customDateFormatPipe, name: "customDateFormat" }] });
3341
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: UserMailboxComponent, decorators: [{
3342
- type: Component,
3343
- args: [{ selector: 'app-user-mailbox', providers: [DialogService], template: "<div class=\"mail-content\">\r\n <div\r\n class=\"box-title my-3 d-flex justify-content-between align-items-center w-100\"\r\n >\r\n <div>\r\n {{ \"Generic_lib.MailBox\" | translate }}\r\n </div>\r\n <button\r\n type=\"button\"\r\n class=\"common-bn tertiary-btn ms-auto\"\r\n (click)=\"closeMailBox()\"\r\n >\r\n <img\r\n src=\"assets/common-header-lib/images/close.svg\"\r\n class=\"imgs\"\r\n alt=\"close icon\"\r\n title=\"Close\"\r\n loading=\"lazy\"\r\n />\r\n </button>\r\n </div>\r\n\r\n <div class=\"mail-table\">\r\n <ng-container *ngIf=\"isContentLoaded && hasUserAssignedMails\">\r\n <p-table\r\n [value]=\"ListOfUserAssingedMails\"\r\n selectionMode=\"multiple\"\r\n dataKey=\"code\"\r\n [tableStyle]=\"{ 'min-width': '50rem' }\"\r\n >\r\n <ng-template pTemplate=\"header\">\r\n <tr>\r\n <th scope=\"col\">\r\n {{ \"Generic_lib.From\" | translate }}\r\n </th>\r\n\r\n <th scope=\"col\">\r\n {{ \"Generic_lib.Subject\" | translate }}\r\n </th>\r\n\r\n <th scope=\"col\">\r\n {{ \"Generic_lib.ViewFrom\" | translate }}\r\n </th>\r\n\r\n <th scope=\"col\"></th>\r\n\r\n <th scope=\"col\">\r\n {{ \"Generic_lib.Action\" | translate }}\r\n </th>\r\n </tr>\r\n </ng-template>\r\n <ng-template pTemplate=\"body\" let-userMail>\r\n <tr [ngClass]=\"{ markasRead: userMail.smi_sms_id != 1 }\">\r\n <td class=\"form-colm\">{{ userMail.smi_From_Details }}</td>\r\n <td>\r\n <div class=\"subject-colm\" title=\"{{ userMail.smi_MailSubject }}\">\r\n {{ userMail.smi_MailSubject }}\r\n </div>\r\n </td>\r\n <!-- <td class=\"view-colm\">{{userMail.smi_Received_On}}</td> -->\r\n <td class=\"view-colm\">\r\n {{ userMail.smi_Received_On | customDateFormat }}\r\n </td>\r\n <td>\r\n <div class=\"icon-colm\">\r\n <div>\r\n <img\r\n src=\"assets/common-header-lib/images/mail-icon.svg\"\r\n alt=\"Icon\"\r\n />\r\n </div>\r\n <div>\r\n <img\r\n src=\"assets/common-header-lib/images/flag1.svg\"\r\n alt=\"Icon\"\r\n />\r\n </div>\r\n <div>\r\n <img\r\n src=\"assets/common-header-lib/images/lock1.svg\"\r\n alt=\"Icon\"\r\n class=\"\"\r\n />\r\n </div>\r\n </div>\r\n </td>\r\n <td class=\"action-colm\">\r\n <button\r\n [disabled]=\"userMail.password_status === 'Close'\"\r\n (click)=\"openViewPasswordPanel(userMail)\"\r\n class=\"view-label\"\r\n >\r\n {{ \"Generic_lib.ViewPassword\" | translate }}\r\n </button>\r\n </td>\r\n </tr></ng-template\r\n >\r\n </p-table>\r\n </ng-container>\r\n <ng-container *ngIf=\"!isContentLoaded\">\r\n <p-table\r\n [value]=\"repeatLoader\"\r\n [tableStyle]=\"{ 'min-width': '50rem' }\"\r\n responsiveLayout=\"scroll\"\r\n >\r\n <ng-template pTemplate=\"header\">\r\n <tr>\r\n <th scope=\"col\">{{ \"Generic_lib.From\" | translate }}</th>\r\n <th scope=\"col\">{{ \"Generic_lib.Subject\" | translate }}</th>\r\n <th scope=\"col\">{{ \"Generic_lib.ViewFrom\" | translate }}</th>\r\n <th scope=\"col\"></th>\r\n <th scope=\"col\">{{ \"Generic_lib.Action\" | translate }}</th>\r\n </tr>\r\n </ng-template>\r\n <ng-template pTemplate=\"body\" let-data>\r\n <tr>\r\n <td><p-skeleton height=\"1rem\" width=\"100%\"></p-skeleton></td>\r\n <td><p-skeleton height=\"1rem\" width=\"100%\"></p-skeleton></td>\r\n <td><p-skeleton height=\"1rem\" width=\"100%\"></p-skeleton></td>\r\n <td><p-skeleton height=\"1rem\" width=\"100%\"></p-skeleton></td>\r\n <td><p-skeleton height=\"1rem\" width=\"100%\"></p-skeleton></td>\r\n </tr>\r\n </ng-template>\r\n </p-table>\r\n </ng-container>\r\n <!-- When There is No Data Present -->\r\n <ng-container *ngIf=\"!hasUserAssignedMails\">\r\n <app-no-service-my-access-pg\r\n [heading]=\"NoServiceMsgText\"\r\n ></app-no-service-my-access-pg>\r\n </ng-container>\r\n </div>\r\n <!-- ---Pagination -->\r\n <div class=\"mail-pagination\">\r\n <app-grid-pagination\r\n [totalRecords]=\"totalCount\"\r\n (onPgChange)=\"updateDataOnPageChange($event)\"\r\n ></app-grid-pagination>\r\n </div>\r\n</div>\r\n", styles: [".mail-content{padding:0 25px;height:calc(100vh - 42px);overflow:auto;background-color:#fff}.mail-content .mail-body{background-color:#000}.mail-content .box-title{color:var(--primary-text);font-size:20px;line-height:30px;font-weight:600}.mail-content .view-label{border:none;color:var(--dodger-blue);font-size:13px!important;font-weight:600;cursor:pointer;padding-right:25px}.mail-content .icon-trending{position:relative;left:5px;cursor:pointer}.mail-content .disable-click{pointer-events:none}.mail-content .disable-click:hover,.mail-content .disable-click:focus{cursor:not-allowed}.subject-colm{text-overflow:ellipsis;overflow:hidden;width:500px}.markasRead{border-left:2px solid #3b82f6!important;color:#676879!important;border-bottom:1px solid #dee2e6!important;font-weight:600}.icon-colm div{display:inline-flex;width:30px;height:30px;border-radius:50%;align-items:center;justify-content:center;vertical-align:middle;margin-right:4px;cursor:pointer}.icon-colm div img{width:16px;height:16px}.icon-colm div:hover{background-color:#fff}.icon-colm div:hover img{filter:invert(0%) sepia(4%) saturate(0%) hue-rotate(324deg) brightness(55%) contrast(105%)}.view-label{background:url(assets/common-header-lib/images/east.svg) no-repeat 99% 5px}button:disabled{cursor:not-allowed!important;opacity:50%}\n"] }]
3344
- }], ctorParameters: function () { return [{ type: i1$3.DialogService }, { type: EventService }, { type: i4.TranslateService }, { type: CommonHeaderLibService }, { type: HttpCommonService }]; }, propDecorators: { closeMailDialogBox: [{
3345
- type: Output
3346
- }], apiURL: [{
3347
- type: Input
3348
- }] } });
3349
-
3350
- class ConfirmDialogComponent {
3351
- constructor(confirmationService) {
3352
- this.confirmationService = confirmationService;
3353
- this.header = '';
3354
- this.message = '';
3355
- this.result = new EventEmitter();
3356
- }
3357
- openConfirmModal(event) {
3358
- this.confirmationService.confirm({
3359
- target: event.target,
3360
- message: this.message,
3361
- header: this.header,
3362
- closeOnEscape: true,
3363
- // icon: 'pi pi-exclamation-triangle',
3364
- // ✔ PrimeNG 14 button config
3365
- acceptLabel: 'Yes',
3366
- rejectLabel: 'No',
3367
- acceptButtonStyleClass: 'p-button-primary',
3368
- rejectButtonStyleClass: 'p-button-secondary p-button-outlined',
3369
- accept: () => {
3370
- this.result.emit(true);
3371
- },
3372
- reject: () => {
3373
- this.result.emit(false);
3374
- },
3375
- });
3376
- }
3377
- }
3378
- ConfirmDialogComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ConfirmDialogComponent, deps: [{ token: i9.ConfirmationService }], target: i0.ɵɵFactoryTarget.Component });
3379
- ConfirmDialogComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: ConfirmDialogComponent, selector: "confirm-dialog", inputs: { header: "header", message: "message" }, outputs: { result: "result" }, providers: [ConfirmationService], ngImport: i0, template: "<div class=\"card flex justify-center gap-2 view-pass-details confirmtion-modal\">\n <p-confirmDialog icon=\"none\" acceptIcon=\"\" rejectIcon=\"\"></p-confirmDialog>\n</div>\n", styles: [""], dependencies: [{ kind: "component", type: i2$1.ConfirmDialog, selector: "p-confirmDialog", inputs: ["header", "icon", "message", "style", "styleClass", "maskStyleClass", "acceptIcon", "acceptLabel", "acceptAriaLabel", "acceptVisible", "rejectIcon", "rejectLabel", "rejectAriaLabel", "rejectVisible", "acceptButtonStyleClass", "rejectButtonStyleClass", "closeOnEscape", "dismissableMask", "blockScroll", "rtl", "closable", "appendTo", "key", "autoZIndex", "baseZIndex", "transitionOptions", "focusTrap", "defaultFocus", "breakpoints", "visible", "position"], outputs: ["onHide"] }] });
3380
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ConfirmDialogComponent, decorators: [{
3381
- type: Component,
3382
- args: [{ selector: 'confirm-dialog', providers: [ConfirmationService], template: "<div class=\"card flex justify-center gap-2 view-pass-details confirmtion-modal\">\n <p-confirmDialog icon=\"none\" acceptIcon=\"\" rejectIcon=\"\"></p-confirmDialog>\n</div>\n" }]
3383
- }], ctorParameters: function () { return [{ type: i9.ConfirmationService }]; }, propDecorators: { header: [{
3384
- type: Input,
3385
- args: ['header']
3386
- }], message: [{
3387
- type: Input,
3388
- args: ['message']
3389
- }], result: [{
3390
- type: Output,
3391
- args: ['result']
3392
- }] } });
3393
-
3394
- class CommonHeaderLibComponent {
3395
- constructor(cdRef, _signalRService, _eventService, translate, httpCommonService, msgService) {
3396
- this.cdRef = cdRef;
3397
- this._signalRService = _signalRService;
3398
- this._eventService = _eventService;
3399
- this.translate = translate;
3400
- this.httpCommonService = httpCommonService;
3401
- this.msgService = msgService;
3402
- // @Input() apiURL: string = '';
3403
- this.EnableLogo = true;
3404
- this.moduleName = '';
3405
- this.EnableTimeZone = true;
3406
- this.EnableLOB = true;
3407
- this.showAllLOB = false;
3408
- this.EnableMail = true;
3409
- this.EnableNotifications = true;
3410
- this.EnableMoreApps = true;
3411
- this.EnableProfile = true;
3412
- /* Supported languages forwarded down to <ng-translation>. The host app
3413
- loads languages.json once (via its APP_INITIALIZER) and binds the
3414
- resulting list here, eliminating a duplicate fetch from the library. */
3415
- this.languages = [];
3416
- this.timezoneDetails = new EventEmitter();
3417
- this.lobSelected = new EventEmitter();
3418
- this.getBgImage = new EventEmitter();
3419
- this.langChange = new EventEmitter();
3420
- this.overlayStateChange = new EventEmitter();
3421
- this.userTimeZoneAbbreviations = '';
3422
- this.userTimeZoneFullForm = '';
3423
- this.userLOBList = [];
3424
- this.showLobLoader = true;
3425
- this.totalEmails = '';
3426
- this.userNotificationCount = '';
3427
- this.ListOfUserPrivillegedApp = [];
3428
- this.userdisplayName = '';
3429
- this.userDetailsInfo = [];
3430
- this.isOpenSidePopup = false;
3431
- this.showUserDetails = false;
3432
- this.userAppLoaderLoadder = true;
3433
- this.repeatLoader = new Array(12).fill(0);
3434
- this.showMailboxScreenflag = false;
3435
- this.isErrorFound = false;
3436
- this.userNotificationCountObj = {};
3437
- this.eventwiseNotificationCount = [];
3438
- this.notificationLoadder = true;
3439
- this.unsubscribeAPIEventListenerData = new Subject();
3440
- this.unsubscribeSidebarListenerData = new Subject();
3441
- this.userId = '';
3442
- this.assetCategoryMenuList = [];
3443
- this.showbusinessFileds = false;
3444
- this.showInfraFileds = false;
3445
- this.showfiltersearch = true;
3446
- this.clickInside = false;
3447
- this.isLobContentLoaded = false;
3448
- this.isHeaderContentLoaded = false;
3449
- this.requestTypeId = 1;
3450
- this.accessTypes = [
3451
- { id: 1, name: 'Permanent' },
3452
- { id: 2, name: 'OneTime' },
3453
- { id: 3, name: 'TimeBased' },
3454
- ];
3455
- this.selectedAssetName = {
3456
- assetId: -100,
3457
- assetName: 'All',
3458
- };
3459
- this.assetName = '';
3460
- this.assetId = 0;
3461
- this.allCategory = {
3462
- assetTypeId: -100,
3463
- assetTypeValue: 'All Section',
3464
- assetList: [
3465
- {
3466
- assetId: -100,
3467
- assetName: 'All',
3468
- },
3469
- ],
3470
- };
3471
- this.translateName = [
3472
- 'Generic_lib.Permanent',
3473
- 'Generic_lib.OneTime',
3474
- 'Generic_lib.TimeBased',
3475
- ];
3476
- this.appPanel = OverlayPanel;
3477
- this.isErrorOccured = false;
3478
- // @Output() public refreshNotification = new EventEmitter<boolean>();
3479
- this.repeatLoader1 = new Array(9).fill(0);
3480
- // Mapping of app codes to their pre-connection validation checks.
3481
- // Apps not listed here open the connection directly without a config check.
3482
- this.APP_CONNECTION_CHECKS = {
3483
- APP032: {
3484
- check: () => this.httpCommonService.checkMFAConfiguration(),
3485
- },
3486
- APP033: {
3487
- // Backend expects the lowercase app code (mirrors Workflow_UI MR !287)
3488
- check: () => this.httpCommonService.getInternalAppConfig('app033'),
3489
- },
3490
- };
3491
- this.setWebAPIURL();
3492
- }
3493
- ngOnChanges(changes) {
3494
- if (changes['EnableLOB']) {
3495
- if (changes['EnableLOB'].currentValue === true) {
3496
- this.getListofLOB();
3497
- }
3498
- }
3499
- }
3500
- ngOnInit() {
3501
- this.headerLogo = '';
3502
- this.overlayStateChange.emit(false);
3503
- this.setWebAPIURL();
3504
- if (this.EnableLogo)
3505
- this.loadHeaderLogo();
3506
- this.onLoadMethod();
3507
- }
3508
- onLoadMethod() {
3509
- this.onDemandActions();
3510
- if (this.EnableNotifications)
3511
- this.getEventwiseNotificationCount();
3512
- this.getUserActivityDetails();
3513
- }
3514
- //* on click of Mail icon
3515
- showMailBoxScreen() {
3516
- this.showMailboxScreenflag = true;
3517
- this.overlayStateChange.emit(true);
3518
- }
3519
- hideMailBoxScreen() {
3520
- this.showMailboxScreenflag = false;
3521
- this.overlayStateChange.emit(false);
3522
- }
3523
- //* Main language change emitter
3524
- languageChange(event) {
3525
- if (!event)
3526
- return;
3527
- this.langChange.emit(event);
3528
- }
3529
- showUserAppsPanel(event) {
3530
- this.appPanel.toggle(event);
3531
- if (this.ListOfUserPrivillegedApp.length === 0) {
3532
- this.getUserAssignedApp();
3533
- }
3534
- }
3535
- showUserDetailsPanel() {
3536
- this.openSidePopup();
3537
- this.showUserDetails = true;
3538
- }
3539
- closeSidePopup() {
3540
- this.showUserDetails = false;
3541
- this.isOpenSidePopup = false;
3542
- }
3543
- openSidePopup() {
3544
- this.isOpenSidePopup = true;
3545
- }
3546
- //Method: Take Connection of Application
3547
- getConnectionofApplication(appCode) {
3548
- var _a;
3549
- // Close the apps (9-dots) overlay panel immediately on selection.
3550
- (_a = this.appPanel) === null || _a === void 0 ? void 0 : _a.hide();
3551
- const appCheck = this.APP_CONNECTION_CHECKS[appCode];
3552
- const commonError = 'Unable to verify the application configuration.';
3553
- // Apps without a configured check connect directly.
3554
- if (!appCheck) {
3555
- this.httpCommonService.openAppConnection(appCode);
3556
- return;
3557
- }
3558
- appCheck
3559
- .check()
3560
- .pipe(takeUntil(this.unsubscribeAPIEventListenerData))
3561
- .subscribe({
3562
- next: (response) => {
3563
- if (response === null || response === void 0 ? void 0 : response.isValid) {
3564
- this.httpCommonService.openAppConnection(appCode);
3565
- }
3566
- else {
3567
- this.msgService.error((response === null || response === void 0 ? void 0 : response.errorMessage) || commonError);
3568
- }
3569
- },
3570
- error: () => {
3571
- this.msgService.error(commonError);
3572
- },
3573
- });
3574
- }
3575
- getConnectToSingalRhub() {
3576
- return __awaiter(this, void 0, void 0, function* () {
3577
- try {
3578
- yield this._signalRService.initializeSignalRConnection();
3579
- }
3580
- catch (error) {
3581
- console.error('All SignalR hub connections failed.', error);
3582
- }
3583
- });
3584
- }
3585
- ngAfterViewInit() {
3586
- this.ListenToTranslateEvent();
3587
- // Initialize modal instance when DOM is ready
3588
- this.bsModalInstance = new bootstrap.Modal(this.notifyModal.nativeElement);
3589
- }
3590
- /*Method : Listen to the Other component event
3591
- Action : It used to listen diff. component command on basis of perform some actions */
3592
- onDemandActions() {
3593
- //Listen the Event Emit by SignalR Hub
3594
- this._signalRService
3595
- .listenerEventMsg()
3596
- .pipe(takeUntil(this.unsubscribeAPIEventListenerData))
3597
- .subscribe((data) => {
3598
- if (data && data['application'] && data['events']) {
3599
- this.isErrorFound = false;
3600
- this.userNotificationCountObj = data['application'];
3601
- //Note: If Notification count > 99
3602
- if (this.userNotificationCountObj &&
3603
- this.userNotificationCountObj['PendingCount']) {
3604
- if (Number(this.userNotificationCountObj['PendingCount']) > 99) {
3605
- this.userNotificationCount = '99+';
3606
- }
3607
- else {
3608
- this.userNotificationCount = String(this.userNotificationCountObj['PendingCount']);
3609
- }
3610
- }
3611
- else {
3612
- this.userNotificationCount = '';
3613
- }
3614
- this.eventwiseNotificationCount = data['events'];
3615
- }
3616
- });
3617
- this.listenToTimeZoneConfig();
3618
- this.listenToEmailCountEvent();
3619
- }
3620
- //Listen to TimeZone Config
3621
- listenToTimeZoneConfig() {
3622
- this._eventService
3623
- .listenerTimezone()
3624
- .pipe(takeUntil(this.unsubscribeAPIEventListenerData))
3625
- .subscribe((response) => {
3626
- if (response && response['component'] == 'timezone') {
3627
- this.userTimeZoneAbbreviations =
3628
- response['usertimezoneAbbreviations'];
3629
- this.timezoneDetails.emit({
3630
- abbreviations: response['usertimezoneAbbreviations'],
3631
- userTimeZone: response['id'],
3632
- timelist: response['timelist'],
3633
- });
3634
- this.userTimeZoneFullForm = response['userTimeZoneFullForm'];
3635
- }
3636
- });
3637
- }
3638
- //Listen to Email Count when user Read
3639
- listenToEmailCountEvent() {
3640
- this._eventService
3641
- .listenerUserEmail()
3642
- .pipe(takeUntil(this.unsubscribeAPIEventListenerData))
3643
- .subscribe((data) => {
3644
- if (data && data['component'] === 'email-count') {
3645
- this.totalEmails = data['mailCount'];
3646
- }
3647
- });
3648
- }
3649
- //Method: Convert text one Lang. to another
3650
- ListenToTranslateEvent() {
3651
- this.translate.onLangChange.subscribe((val) => {
3652
- this.getTranslateContent();
3653
- });
3654
- }
3655
- //Method: Convert text one Lang. to another Event Listener
3656
- getTranslateContent() {
3657
- this.translate.get(this.translateName).subscribe((trans) => {
3658
- this.accessTypes.forEach((item, index) => {
3659
- const key = this.translateName[index];
3660
- item['name'] = trans[key];
3661
- });
3662
- });
3663
- }
3664
- OpenNotificationModal() {
3665
- var _a;
3666
- // const modalRef = this.modalService.open(NotificationSidebarComponent);
3667
- // modalRef.componentInstance.lesson = lesson;
3668
- (_a = this.bsModalInstance) === null || _a === void 0 ? void 0 : _a.show();
3669
- }
3670
- closeModal() {
3671
- var _a;
3672
- (_a = this.bsModalInstance) === null || _a === void 0 ? void 0 : _a.hide();
3673
- }
3674
- //Method: Call APi to Fetch New Notification Count
3675
- getEventwiseNotification() {
3676
- // this.refreshNotification.emit(true);
3677
- this.getEventwiseNotificationCount();
3678
- }
3679
- setWebAPIURL() {
3680
- if (GlobalConstants.baseURL == undefined) {
3681
- if (localStorage.getItem('_WAU')) {
3682
- GlobalConstants.baseURL = localStorage.getItem('_WAU') || '';
3683
- }
3684
- else {
3685
- let parsedURL = new URL(window.location.href);
3686
- let WebApiUrl = parsedURL.origin;
3687
- GlobalConstants.baseURL = WebApiUrl;
3688
- localStorage.setItem('_WAU', GlobalConstants.baseURL);
3689
- }
3690
- }
3691
- }
3692
- getUserActivityDetails() {
3693
- // Reset error state before API calls
3694
- this.isErrorFound = false;
3695
- // Initialize response container for forkJoin
3696
- const responseSet = {};
3697
- // Build payload once for notification API
3698
- const notificationPayload = {
3699
- ApplicationName: GlobalConstants.applicationName,
3700
- UserId: String(this.userId),
3701
- };
3702
- // Add notification API if enabled
3703
- if (this.EnableNotifications) {
3704
- responseSet.notifications = this.httpCommonService
3705
- .getWorkFlowTicketCount(notificationPayload)
3706
- .pipe(
3707
- // Extract valid notification data
3708
- map((response) => response),
3709
- // Handle API error without breaking forkJoin
3710
- catchError(() => {
3711
- this.isErrorFound = true;
3712
- return of(null);
3713
- }));
3714
- }
3715
- // Add user profile API if enabled
3716
- if (this.EnableProfile) {
3717
- responseSet.userinfo = this.httpCommonService.getLoggedInUserDetails();
3718
- }
3719
- // Add timezone API if enabled
3720
- if (this.EnableTimeZone) {
3721
- responseSet.timeZone = this.httpCommonService.getGlobalTimeZone();
3722
- }
3723
- // Add unread email count API if enabled
3724
- if (this.EnableMail) {
3725
- responseSet.emailCount =
3726
- this.httpCommonService.getUnreadUserEmailsCount();
3727
- }
3728
- // Execute all enabled APIs together
3729
- forkJoin(responseSet)
3730
- .pipe(
3731
- // Mark header loading as completed
3732
- finalize(() => {
3733
- this.isHeaderContentLoaded = true;
3734
- }))
3735
- .subscribe((response) => {
3736
- // Process notification data
3737
- if (response.notifications) {
3738
- this.getTotalNotificationCounts(response.notifications);
3739
- }
3740
- // Process user profile data
3741
- if (response.userinfo) {
3742
- this.getLoggedInUserDetails(response.userinfo);
3743
- }
3744
- // Process timezone list
3745
- if (response.timeZone) {
3746
- this.getListOfTimeZones(response.timeZone);
3747
- }
3748
- // Process unread email count
3749
- if (response.emailCount) {
3750
- this.getUserEmailCount(response.emailCount);
3751
- }
3752
- });
3753
- }
3754
- getTotalNotificationCounts(data) {
3755
- // this.isErrorFound = false;
3756
- this.userNotificationCountObj = data || {};
3757
- if (this.userNotificationCountObj &&
3758
- this.userNotificationCountObj['PendingCount']) {
3759
- if (Number(this.userNotificationCountObj['PendingCount']) > 99) {
3760
- this.userNotificationCount = '99+';
3761
- }
3762
- else {
3763
- this.userNotificationCount = String(this.userNotificationCountObj['PendingCount']);
3764
- }
3765
- }
3766
- else {
3767
- this.userNotificationCount = '';
3768
- }
3769
- }
3770
- /*Method : Retrieves details of the currently logged-in user*/
3771
- getLoggedInUserDetails(response) {
3772
- if (response && response['success'] && response['result']) {
3773
- this.userDetails = response['result'];
3774
- this.userdisplayName = this.userDetails['userDisplayName'];
3775
- }
3776
- }
3777
- /*Method : GET
3778
- Action : Get List of Time Zone*/
3779
- getListOfTimeZones(result) {
3780
- if (result && result['abbreviations']) {
3781
- this.timezoneDetails.emit(result);
3782
- this.userTimeZoneAbbreviations = result['abbreviations'];
3783
- this.userTimeZoneFullForm = result['userTimeZone'];
3784
- }
3785
- }
3786
- /*Method : GET
3787
- Action : Transformation fo Count */
3788
- getUserEmailCount(count) {
3789
- if (count <= 0) {
3790
- this.totalEmails = '';
3791
- }
3792
- else if (count > 99) {
3793
- this.totalEmails = '99+';
3794
- }
3795
- else {
3796
- this.totalEmails = String(count);
3797
- }
3798
- }
3799
- /** API to get the header LOGO */
3800
- loadHeaderLogo() {
3801
- this.httpCommonService.getLogo().subscribe((img) => {
3802
- this.getBgImage.emit(img);
3803
- this.headerLogo = 'data:image/png;base64,' + img['logoImg'];
3804
- });
3805
- }
3806
- /** API to get the timezone */
3807
- // getUserPreferredTimezone() {
3808
- // this.httpCommonService.getGlobalTimeZone().subscribe((res: any) => {
3809
- // if (res?.abbreviations) {
3810
- // this.userTimeZoneAbbreviations = res.abbreviations;
3811
- // this.userTimeZoneFullForm = res?.userTimeZone;
3812
- // }
3813
- // });
3814
- // }
3815
- //* get Lob AI call and initial LOB emitter
3816
- getListofLOB() {
3817
- this.showLobLoader = true;
3818
- this.httpCommonService.getLOBList().subscribe((res) => {
3819
- var _a, _b, _c;
3820
- this.showLobLoader = false;
3821
- this.userLOBList = res.result;
3822
- //* As per parent input, here we add All LOB option in DDL
3823
- if (this.showAllLOB)
3824
- this.userLOBList.unshift({
3825
- lobId: -1,
3826
- lobName: 'All LOB',
3827
- });
3828
- let initialLobSelected = this.getLobById(this.userLOBList, (_a = this.userLOBList[0]) === null || _a === void 0 ? void 0 : _a.lobId);
3829
- const preSelectedLob = JSON.parse(localStorage.getItem('XOB') || 'null');
3830
- let isPreSelectedLobExistsInList = this.userLOBList.some((lob) => Number(lob.lobId) == Number(preSelectedLob === null || preSelectedLob === void 0 ? void 0 : preSelectedLob.LOBId));
3831
- if (preSelectedLob &&
3832
- Number(preSelectedLob.LOBId) &&
3833
- isPreSelectedLobExistsInList) {
3834
- //* Emitting 1st LOB for LOB List as LOb details available in localstorega
3835
- this.selectedLOBId = preSelectedLob === null || preSelectedLob === void 0 ? void 0 : preSelectedLob.LOBId;
3836
- this.tempSelectedLOBId = preSelectedLob === null || preSelectedLob === void 0 ? void 0 : preSelectedLob.LOBId;
3837
- initialLobSelected = this.getLobById(this.userLOBList, this.selectedLOBId);
3838
- }
3839
- else {
3840
- //* Emitting 1st LOB for LOB List if localstorage have null LOB details
3841
- this.selectedLOBId = (_b = this.userLOBList[0]) === null || _b === void 0 ? void 0 : _b.lobId;
3842
- this.tempSelectedLOBId = (_c = this.userLOBList[0]) === null || _c === void 0 ? void 0 : _c.lobId;
3843
- localStorage.setItem('XOB', JSON.stringify(initialLobSelected));
3844
- }
3845
- this.lobSelected.emit(initialLobSelected);
3846
- this.cdRef.detectChanges();
3847
- });
3848
- }
3849
- //* Selected LOB emitter
3850
- onLobChangeEvent(event) {
3851
- this.selectedLOBId = event.value;
3852
- this.openConfirm(event);
3853
- }
3854
- openConfirm(event) {
3855
- this.confirmDialog.openConfirmModal(event);
3856
- }
3857
- lobChangeConfirmation(event) {
3858
- if (event) {
3859
- this.tempSelectedLOBId = this.selectedLOBId;
3860
- let selectedLob = this.getLobById(this.userLOBList, this.tempSelectedLOBId);
3861
- localStorage.setItem('XOB', JSON.stringify(selectedLob));
3862
- this.lobSelected.emit(selectedLob);
3863
- }
3864
- else {
3865
- this.selectedLOBId = this.tempSelectedLOBId;
3866
- }
3867
- }
3868
- setCustomLobId(lobId) {
3869
- if (this.userLOBList) {
3870
- let filteredLobs = this.getLobById(this.userLOBList, lobId);
3871
- if (Object.keys(filteredLobs).length > 0) {
3872
- this.selectedLOBId = lobId;
3873
- //* If the LOB is forcefully set from the parent module, CustomLOBSetByParent is set to true; otherwise, it is set to false.
3874
- filteredLobs['CustomLOBSetByParent'] = true;
3875
- this.lobSelected.emit(filteredLobs);
3876
- localStorage.setItem('XOB', JSON.stringify(filteredLobs));
3877
- }
3878
- else {
3879
- //todo need to do translation
3880
- this.msgService.error('The LOB you are trying to set is not available.');
3881
- }
3882
- }
3883
- }
3884
- //* Helper function to get selected LOB Object by LobId
3885
- getLobById(list, id) {
3886
- const item = list.find((x) => x.lobId === id);
3887
- if (!item)
3888
- return {};
3889
- return {
3890
- LOBId: item.lobId,
3891
- LOBName: item.lobName,
3892
- CustomLOBSetByParent: false,
3893
- };
3894
- }
3895
- //* get the Mail count
3896
- // getMailCount() {
3897
- // this.httpCommonService
3898
- // .getUnreadUserEmailsCount()
3899
- // .pipe(takeUntil(this.unsubscribeAPIEventListenerData))
3900
- // .subscribe((result) => {
3901
- // this.totalEmails = result;
3902
- // });
3903
- // }
3904
- //Action: Used to Get Total Eventwise User Notification Count */
3905
- getEventwiseNotificationCount() {
3906
- let payload = {
3907
- ApplicationName: GlobalConstants.applicationName,
3908
- UserId: String(this.userId),
3909
- };
3910
- this.notificationLoadder = true;
3911
- this.httpCommonService
3912
- .getWorkFlowTicketEventwiseCount(payload)
3913
- .pipe(takeUntil(this.unsubscribeAPIEventListenerData), finalize(() => (this.notificationLoadder = false)))
3914
- .subscribe({
3915
- next: (data) => {
3916
- this.isErrorFound = data.length == 0;
3917
- this.eventwiseNotificationCount = data;
3918
- },
3919
- error: () => {
3920
- this.isErrorFound = true;
3921
- },
3922
- });
3923
- }
3924
- //* Get Module privilege list
3925
- getUserAssignedApp() {
3926
- this.ListOfUserPrivillegedApp = [];
3927
- this.userAppLoaderLoadder = true;
3928
- this.httpCommonService
3929
- .getUserAssignedApps()
3930
- .pipe(takeUntil(this.unsubscribeAPIEventListenerData))
3931
- .subscribe((result) => {
3932
- this.userAppLoaderLoadder = false;
3933
- this.ListOfUserPrivillegedApp = result;
3934
- });
3935
- }
3936
- //* Get User details
3937
- getLoggedInuserDetails() {
3938
- this.httpCommonService.getLoggedInUserDetails().subscribe((result) => {
3939
- this.userDetailsInfo = result.result;
3940
- this.userdisplayName = this.userDetailsInfo['userDisplayName'];
3941
- });
3942
- }
3943
- ngOnDestroy() {
3944
- this.unsubscribeAPIEventListenerData.next(true);
3945
- this.unsubscribeAPIEventListenerData.complete();
3946
- this.unsubscribeSidebarListenerData.next(true);
3947
- this.unsubscribeSidebarListenerData.complete();
3948
- }
3949
- }
3950
- CommonHeaderLibComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: CommonHeaderLibComponent, deps: [{ token: i0.ChangeDetectorRef }, { token: RestSignalRService }, { token: EventService }, { token: i4.TranslateService }, { token: HttpCommonService }, { token: ToastMsgService }], target: i0.ɵɵFactoryTarget.Component });
3951
- CommonHeaderLibComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: CommonHeaderLibComponent, selector: "lib-common-header-lib", inputs: { EnableLogo: "EnableLogo", moduleName: "moduleName", EnableTimeZone: "EnableTimeZone", EnableLOB: "EnableLOB", showAllLOB: "showAllLOB", EnableMail: "EnableMail", EnableNotifications: "EnableNotifications", EnableMoreApps: "EnableMoreApps", EnableProfile: "EnableProfile", languages: "languages" }, outputs: { timezoneDetails: "timezoneDetails", lobSelected: "lobSelected", getBgImage: "getBgImage", langChange: "langChange", overlayStateChange: "overlayStateChange" }, viewQueries: [{ propertyName: "confirmDialog", first: true, predicate: ["confirmDialog"], descendants: true }, { propertyName: "appPanel", first: true, predicate: ["App"], descendants: true }, { propertyName: "notifyModalRef", first: true, predicate: ["notifyModal"], descendants: true }, { propertyName: "notifyModal", first: true, predicate: ["notifyModal"], descendants: true }], usesOnChanges: true, ngImport: i0, template: "<header class=\"app-header ext\">\r\n <div class=\"d-flex justify-content-between align-items-center\">\r\n <div class=\"d-flex\">\r\n <div class=\"logo gap-4\" *ngIf=\"EnableLogo\">\r\n <img\r\n *ngIf=\"EnableLogo && headerLogo\"\r\n class=\"logo-size\"\r\n title=\"Logo\"\r\n alt=\"Logo\"\r\n [src]=\"headerLogo\"\r\n loading=\"lazy\"\r\n />\r\n <p-skeleton\r\n *ngIf=\"!headerLogo\"\r\n height=\"1.5rem\"\r\n width=\"5rem\"\r\n ></p-skeleton>\r\n </div>\r\n </div>\r\n\r\n <!--* Test Buttons for toast UI -->\r\n <!-- <button type=\"button\" class=\"btn btn-success\" (click)=\"success()\">\r\n success</button\r\n ><button type=\"button\" class=\"btn btn-success\" (click)=\"success1()\">\r\n success1\r\n </button>\r\n <button type=\"button\" class=\"btn btn-danger\" (click)=\"danger()\">color: #1d4ed8;\r\n background: #eff6ff;\r\n danger\r\n </button>\r\n <button type=\"button\" class=\"btn btn-warning\" (click)=\"warning()\">\r\n warning\r\n </button>\r\n <button type=\"button\" class=\"btn btn-info\" (click)=\"info()\">info</button> -->\r\n\r\n <div class=\"projName\">\r\n <h1 class=\"modname\">{{ moduleName }}</h1>\r\n </div>\r\n\r\n <div class=\"d-flex justify-content-end align-items-center\">\r\n <!--timezone-->\r\n <ng-container *ngIf=\"EnableTimeZone && userTimeZoneAbbreviations\">\r\n <div class=\"timezone\">\r\n <img\r\n src=\"assets/common-header-lib/images/schedule.svg\"\r\n class=\"mb-1\"\r\n alt=\"Icon\"\r\n />\r\n <span class=\"timezone-text\"\r\n >{{ \"Generic_lib.PreferredTimezone\" | translate }} :\r\n </span>\r\n <span\r\n *ngIf=\"userTimeZoneAbbreviations\"\r\n class=\"user-tz\"\r\n [title]=\"userTimeZoneFullForm\"\r\n >{{ userTimeZoneAbbreviations }}</span\r\n >\r\n </div>\r\n </ng-container>\r\n\r\n <!--lob-->\r\n <ng-container *ngIf=\"EnableLOB\">\r\n <ng-container\r\n *ngIf=\"EnableLOB && !showLobLoader; else LobLodderAnimation\"\r\n >\r\n <div class=\"main-left d-flex\">\r\n <img\r\n src=\"assets/common-header-lib/images/marker-pin.svg\"\r\n alt=\"pen Icon\"\r\n />\r\n\r\n <!-- *Note: Removed [virtualScroll] and [itemSize] from p-dropdown because it caused filtered search results to appear empty until scrolling. Not needed as LOB list size is small. -->\r\n <p-dropdown\r\n filterPlaceholder=\"{{ 'Generic_lib.Search' | translate }}\"\r\n [options]=\"userLOBList\"\r\n (onChange)=\"onLobChangeEvent($event)\"\r\n optionLabel=\"lobName\"\r\n optionValue=\"lobId\"\r\n [(ngModel)]=\"selectedLOBId\"\r\n [filter]=\"true\"\r\n filterBy=\"lobName\"\r\n [showClear]=\"false\"\r\n [style]=\"{ width: '150px', height: '30px' }\"\r\n [resetFilterOnHide]=\"true\"\r\n [lazy]=\"false\"\r\n name=\"lob\"\r\n class=\"loblist-drpdwn\"\r\n panelStyleClass=\"loblist-drpdwn-panel\"\r\n >\r\n <ng-template let-loblist pTemplate=\"item\">\r\n <div class=\"flex align-items-center gap-2\">\r\n <div title=\"{{ loblist.lobName }}\" class=\"header-drpdwn\">\r\n {{ loblist.lobName }}\r\n </div>\r\n </div>\r\n </ng-template>\r\n </p-dropdown>\r\n </div>\r\n </ng-container>\r\n <ng-template #LobLodderAnimation>\r\n <p-skeleton height=\"1.5rem\" width=\"10rem\"></p-skeleton>\r\n </ng-template>\r\n </ng-container>\r\n\r\n <!--mailbox-->\r\n <ng-container *ngIf=\"isHeaderContentLoaded; else HeaderLoading\">\r\n <div *ngIf=\"EnableMail\" class=\"header-left-icon\">\r\n <img\r\n src=\"assets/common-header-lib/images/mail-icon.svg\"\r\n alt=\"mail Icon\"\r\n class=\"headeright-icon\"\r\n (click)=\"showMailBoxScreen()\"\r\n />\r\n </div>\r\n <ng-container *ngIf=\"EnableMail && totalEmails.length > 0\">\r\n <!-- <ng-container> -->\r\n <div class=\"badge-notify\">\r\n <div pBadge [value]=\"totalEmails\"></div>\r\n </div>\r\n </ng-container>\r\n\r\n <!--notification-->\r\n <div class=\"header-left-icon\" *ngIf=\"EnableNotifications\">\r\n <img\r\n src=\"assets/common-header-lib/images/bell-icon.svg\"\r\n alt=\"mail Icon\"\r\n class=\"headeright-icon\"\r\n (click)=\"OpenNotificationModal()\"\r\n />\r\n </div>\r\n\r\n <ng-container\r\n *ngIf=\"EnableNotifications && userNotificationCount.length > 0\"\r\n >\r\n <div class=\"badge-notify\">\r\n <div pBadge [value]=\"userNotificationCount\"></div>\r\n </div>\r\n </ng-container>\r\n\r\n <!--9 Dots -->\r\n <div\r\n *ngIf=\"EnableMoreApps\"\r\n class=\"header-left-icon\"\r\n title=\"Control Center\"\r\n alt=\"bell Icon\"\r\n (click)=\"showUserAppsPanel($event)\"\r\n >\r\n <img\r\n src=\"assets/common-header-lib/images/apps-1.svg\"\r\n class=\"apps-icon\"\r\n />\r\n </div>\r\n\r\n <!--user display name -->\r\n <div\r\n *ngIf=\"EnableProfile\"\r\n class=\"main-right\"\r\n (click)=\"showUserDetailsPanel()\"\r\n >\r\n <ng-container>\r\n <div class=\"initial-text mx-1\">\r\n {{ userdisplayName | sliceToTwo }}\r\n </div>\r\n </ng-container>\r\n </div>\r\n </ng-container>\r\n\r\n <ng-template #HeaderLoading>\r\n <p-skeleton shape=\"circle\" size=\"1.3rem\" styleClass=\"mx-2\"></p-skeleton>\r\n <p-skeleton shape=\"circle\" size=\"1.3rem\" styleClass=\"mx-2\"></p-skeleton>\r\n <p-skeleton size=\"1.5rem\" styleClass=\"mx-2\"></p-skeleton>\r\n <p-skeleton shape=\"circle\" size=\"2rem\" styleClass=\"mx-2\"></p-skeleton>\r\n </ng-template>\r\n </div>\r\n </div>\r\n</header>\r\n\r\n<!--List of Application : 9 dots -->\r\n<p-overlayPanel #App class=\"pt-0\" styleClass=\"app-panel\">\r\n <ng-container *ngIf=\"!userAppLoaderLoadder; else LoadingTemplate\">\r\n <div class=\"custom-popover-content\">\r\n <div class=\"waffle-align\">\r\n <div\r\n class=\"waffle-popup\"\r\n [title]=\"appDetails['applicationName']\"\r\n *ngFor=\"let appDetails of ListOfUserPrivillegedApp\"\r\n (click)=\"getConnectionofApplication(appDetails['appCode'])\"\r\n >\r\n <img\r\n *ngIf=\"appDetails?.appCode\"\r\n src=\"assets/common-header-lib/images/{{ appDetails.appCode }}.svg\"\r\n alt=\"App icon\"\r\n />\r\n\r\n <div class=\"waffle-text\">{{ appDetails[\"applicationName\"] }}</div>\r\n </div>\r\n </div>\r\n </div>\r\n </ng-container>\r\n <ng-template #LoadingTemplate>\r\n <div class=\"custom-popover-content skeleton-popover\">\r\n <ng-container *ngFor=\"let item of repeatLoader\">\r\n <div\r\n class=\"d-flex flex-column align-items-center justify-content-center gap-2\"\r\n >\r\n <p-skeleton size=\"3rem\"></p-skeleton>\r\n <p-skeleton height=\".3rem\" width=\"35px\"></p-skeleton>\r\n </div>\r\n </ng-container>\r\n </div>\r\n </ng-template>\r\n</p-overlayPanel>\r\n\r\n<!--mailbox details-->\r\n<ng-container *ngIf=\"showMailboxScreenflag\">\r\n <div class=\"changingContent\">\r\n <app-user-mailbox\r\n (closeMailDialogBox)=\"hideMailBoxScreen()\"\r\n ></app-user-mailbox>\r\n </div>\r\n</ng-container>\r\n\r\n<!-- Userdetails profile pop up -->\r\n<div class=\"profile-sidebar\">\r\n <app-side-popup\r\n *ngIf=\"isOpenSidePopup\"\r\n [visible]=\"true\"\r\n [position]=\"'right'\"\r\n (closeDialogBox)=\"closeSidePopup()\"\r\n >\r\n <app-user-sidebar\r\n *ngIf=\"showUserDetails\"\r\n [languages]=\"languages\"\r\n (closeDialogBox)=\"closeSidePopup()\"\r\n ></app-user-sidebar>\r\n </app-side-popup>\r\n</div>\r\n\r\n<!-- Notification side popup -->\r\n<div\r\n class=\"modal fade common-alert-modal\"\r\n #notifyModal\r\n id=\"Notify_SidebarModal\"\r\n tabindex=\"-1\"\r\n aria-hidden=\"true\"\r\n>\r\n <div class=\"modal-dialog sidebar-outer white-bg\">\r\n <div class=\"modal-content\">\r\n <div class=\"sidebar-container white-bg\">\r\n <!-- keep everything inside this content -->\r\n\r\n <!-- Sidebar Header -->\r\n <div class=\"sidebar-header grey-background\">\r\n <div class=\"sh-top\">\r\n <div class=\"sh-top-left d-flex align-items-center\">\r\n <div class=\"mx-2 log-text\">\r\n {{ \"Generic_lib.Notification\" | translate }}\r\n </div>\r\n </div>\r\n <div class=\"sh-top-right\">\r\n <button\r\n type=\"button\"\r\n class=\"common-bn tertiary-btn\"\r\n aria-label=\"Close\"\r\n (click)=\"closeModal()\"\r\n >\r\n <img\r\n src=\"assets/common-header-lib/images/close.svg\"\r\n alt=\"Close\"\r\n class=\"imgs mb-1\"\r\n />\r\n </button>\r\n </div>\r\n </div>\r\n </div>\r\n\r\n <!-- Sidebar Body -->\r\n <div class=\"sidebar-body\">\r\n <div class=\"d-flex justify-content-between align-items-center mb-2\">\r\n <div class=\"noti-text\">\r\n {{\r\n \"Generic_lib.YouHaveNNotifications\"\r\n | translate: { count: userNotificationCount }\r\n }}\r\n </div>\r\n <div\r\n class=\"d-flex align-items-center gap-1 refresh-icon\"\r\n (click)=\"getEventwiseNotification()\"\r\n >\r\n <img\r\n src=\"assets/common-header-lib/images/refresh-1.svg\"\r\n alt=\"Refresh\"\r\n />\r\n <div class=\"refresh-text\">\r\n {{ \"Generic_lib.Refresh\" | translate }}\r\n </div>\r\n </div>\r\n </div>\r\n <div class=\"mt-3\">\r\n <ng-container\r\n *ngIf=\"\r\n !isErrorFound && !notificationLoadder;\r\n else Noti_LoadingTemplate\r\n \"\r\n >\r\n <div\r\n class=\"notify-border\"\r\n *ngFor=\"let event of eventwiseNotificationCount\"\r\n >\r\n <div class=\"d-flex align-items-center gap-3\">\r\n <div class=\"initial-text initial-text-1 mx-1\">\r\n <img\r\n src=\"assets/common-header-lib/images/noti_ticket.svg\"\r\n alt=\"Icon\"\r\n />\r\n </div>\r\n <div>\r\n <div>\r\n <span class=\"service-count\"\r\n >{{ event[\"PendingCount\"] }} New </span\r\n ><span class=\"service-request\"\r\n >{{ event[\"EventName\"] }} Event requests</span\r\n >\r\n </div>\r\n </div>\r\n </div>\r\n <div class=\"grey-borders mt-2\"></div>\r\n </div>\r\n </ng-container>\r\n <ng-template #Noti_LoadingTemplate>\r\n <ng-container *ngIf=\"notificationLoadder; else errorTemplate\">\r\n <ng-container *ngFor=\"let item of repeatLoader1\">\r\n <div class=\"d-flex align-items-center gap-3\">\r\n <p-skeleton\r\n shape=\"circle\"\r\n size=\"60px\"\r\n styleClass=\"my-2\"\r\n ></p-skeleton>\r\n <div class=\"ms-1\">\r\n <p-skeleton width=\"200%\" styleClass=\"mb-2\"></p-skeleton>\r\n <p-skeleton width=\"150px\" height=\"1rem\"></p-skeleton>\r\n </div>\r\n </div>\r\n </ng-container>\r\n </ng-container>\r\n </ng-template>\r\n\r\n <ng-template #errorTemplate>\r\n <app-no-service-my-access-pg\r\n heading=\"{{ 'Generic_lib.CommonError' | translate }}\"\r\n ></app-no-service-my-access-pg>\r\n </ng-template>\r\n </div>\r\n <!-- Notification content & loaders remain here -->\r\n </div>\r\n </div>\r\n <!-- end of sidebar-container -->\r\n </div>\r\n <!-- end of modal-content -->\r\n </div>\r\n <!-- end of modal-dialog -->\r\n</div>\r\n\r\n<!-- Common Conirmation Modal -->\r\n<confirm-dialog\r\n class=\"rm-invalid-border\"\r\n #confirmDialog\r\n header=\"{{ 'Generic_lib.ChangeLOB' | translate }}\"\r\n message=\"{{ 'Generic_lib.DoYouWantToChangeTheCurrentLOB' | translate }}\"\r\n (result)=\"lobChangeConfirmation($event)\"\r\n></confirm-dialog>\r\n\r\n<!--* Need to use component based notification UI as below -->\r\n<!-- Notification-Sidebar Started -->\r\n<!-- <app-notification-sidebar [isErrorOccured]=\"isErrorFound\" [userNotificationCount]=\"userNotificationCount\"\r\n [userNotificationCountObj]=\"userNotificationCountObj\" [eventwiseNotificationCount]=\"eventwiseNotificationCount\"\r\n (refreshNotification)=\"getEventwiseNotificationCount()\"\r\n [notificationLoadder]=\"notificationLoadder\"></app-notification-sidebar> -->\r\n<!-- Notification-Sidebar Ended -->\r\n", styles: [".app-header{padding:4px 10px 10px;height:42px;border-bottom:1px solid #d0d4e4}.logo{display:flex;align-items:center}.main-right{display:flex;align-items:center;cursor:pointer}.logo-icon{width:0;height:0;border-left:14px solid transparent;border-right:14px solid transparent;position:relative}.logo-icon:after{width:0;height:0;border-left:7px solid transparent;border-right:7px solid transparent;position:absolute;content:\"\";top:7px;left:-7px}p{font-size:25px!important}.p-inputtext.p-inputtext-sm{padding:4px 5px 4px 33px!important}.pi-search:before{font-size:13px;position:absolute;top:2px}.overlay-text{font-size:13px;line-height:18px;color:#676879;font-weight:400}.main-left .p-dropdown{border:none;border-radius:0;width:140px!important}.main-left .p-dropdown-panel .p-dropdown-items{padding:0!important;max-height:110px}.main-left :focus-visible{outline:none}.main-left .p-scroller{overflow-x:hidden;height:120px!important}.header-drpdwn{width:120px!important;font-size:11px!important;text-overflow:ellipsis;overflow:hidden}.logs{gap:70px;margin-top:5px}.head-search{position:fixed;top:4px;left:275px}.head-search input{width:calc(30vw - 40px)!important;border:1px solid #c3c6d4;background-color:#f6f7fb;height:32px;border-radius:0 4px 4px 0;border-left:none;font-size:13px!important;padding-left:30px!important;padding-right:54px}.head-search.active{position:fixed;top:4px;left:275px}.head-search.active input{width:555px!important}@media screen and (min-width: 1920px){.head-search.active{position:fixed;top:4px;left:275px}.head-search.active input{width:900px!important}}.header-left-icon{height:32px;width:32px;cursor:pointer;display:flex;justify-content:center;align-items:center;transition:all .5s;border-radius:50%;margin-right:4px;position:relative}.header-left-icon:hover{background:#dcdfec}.header-left-icon img:hover{filter:invert(0%) sepia(4%) saturate(0%) hue-rotate(324deg) brightness(55%) contrast(105%)}.apps-icon{width:21px}.logo-img{width:80px}.initial-text{width:32px;height:32px;display:flex;align-items:center;justify-content:center;font-size:11px;border-radius:50%;color:#fff;background-color:#8e562e}.initial-text-1{background-color:#f2edfa}.lob-img{padding-bottom:4px}.session-app:hover{background:#dcdfec;border-radius:10px}.app-col{cursor:pointer;padding:8px 0}.app-text{font-size:12px;color:#676879;white-space:nowrap;padding-top:8px;text-align:center;text-overflow:ellipsis;overflow:hidden;width:100px}.filter-search{position:relative;right:50px;bottom:2px;cursor:pointer}.filter-search .cross-search{width:23px}.filter-search .search-filter{width:19px}.headeright-icon{width:17px;height:17px;filter:invert(44%) sepia(3%) saturate(1698%) hue-rotate(199deg) brightness(92%) contrast(93%)}.pl-0{padding-left:0}.form-control-sm{border:none;border-bottom:1px solid #c3c6d4;border-radius:0}.overlay-footer .common-btn{width:110px;height:32px;padding:11px 12px;border-radius:4px;font-size:13px;cursor:pointer;background:#fff}.overlay-footer .primary-btn{padding:8px 12px 11px 14px;border-radius:4px;height:32px;width:65px;font-size:13px;cursor:pointer}.filter-popup{position:relative;left:10px}.form-group{margin-bottom:5px}.waffle-text{font-size:11px;text-align:center;width:70px;text-overflow:ellipsis;overflow:hidden;white-space:nowrap;margin-top:-3px}.waffle-align{display:grid;grid-template-columns:auto auto auto}.waffle{cursor:pointer;margin-right:16px}.waffle-popup{width:89px!important;margin-top:0;padding:8px 0 4px;display:flex;align-items:center;justify-content:center;flex-direction:column;cursor:pointer}.waffle-popup:hover{background:var(--primary-notification-bg);border-radius:10px}.waffle-popup img{height:40px}.custom-popover-content{padding:10px;right:-5px;top:0;position:absolute;background:white;border-radius:8px;box-shadow:0 0 6px #9d9d9d}.custom-popover-content.skeleton-popover{width:313px;display:grid;grid-template-columns:auto auto auto;gap:10px}.timezone{margin-right:12px}.timezone-icon{font-size:16px}.timezone-text{padding-left:6px;font-size:13px;color:#495057;font-weight:400}.user-tz{font-size:13px;color:#757575;font-weight:400;text-overflow:ellipsis;overflow:hidden;width:30px;white-space:normal}.profile-sidebar .p-dialog .p-dialog-content{padding:0}.profile-sidebar .p-dialog-header{display:none}.modname{font-size:18px;margin-bottom:0}.changingContent{overflow:hidden;width:100%}.changingContent .intro-text{background-image:linear-gradient(145deg,#f1eaec,#f8e3e7,#f7e1f8,#ebeeff,#e8eef3);position:relative;height:135px}.changingContent .inner-garient{padding:50px 20px 115px 30px}.changingContent .table-heading{padding:0 20px 1px 30px}.changingContent .table-selection{padding:3px 20px 0 30px}.grey-background{background-color:#f6f7fb}.white-bg{background:#ffffff;overflow:hidden}.imgs{width:20px}.p-dropdown .p-dropdown-label{background:transparent;border:0 none;display:flex;align-items:center}.p-dropdown .p-dropdown-trigger{width:32px!important}.pi-chevron-down:before{content:\"\\e902\";font-size:11px}.sidebar-outer{height:100vh}.lang-dropdown .p-dropdown{border:1px solid #dee2e6!important;height:26px!important;border-radius:4px!important;min-width:calc(40vh - 92px)!important;padding:0 4px 0 12px!important;display:flex!important;align-items:center!important;justify-content:space-between!important}.lang-dropdown .p-dropdown .pi{position:relative;bottom:2px;left:7px}.lang-dropdown .p-dropdown-panel{background:#ffffff!important;color:#495057!important;border:0px!important;box-shadow:0 2px 12px #0000001a!important}.lang-dropdown .p-dropdown-header{padding:5px 10px!important;border-bottom:1px solid #dee2e6!important;background:#f8f9fa!important;color:#343a40!important;margin:0!important}.lang-dropdown .p-dropdown-items-wrapper{max-height:140px!important}.lang-dropdown .p-dropdown-panel .p-dropdown-header{padding:4px 8px!important;border-radius:0!important}.p-dropdown-panel .p-dropdown-header{padding:.75rem 1.25rem;border-bottom:1px solid #dee2e6;color:#343a40;background:#f8f9fa;margin:0;border-top-right-radius:6px;border-top-left-radius:6px}.lang-dropdown .p-dropdown .p-dropdown-header .p-dropdown-filter{height:26px;border-radius:4px;font-size:12px;border:1px solid #ced4da!important;padding-left:12px!important}.lang-dropdown .p-inputtext{margin:0;text-align:start;font-size:13px;padding:0!important}.lang-dropdown .p-dropdown-panel .p-dropdown-header .p-dropdown-filter-icon{position:relative;bottom:13px;font-size:13px}.sidebar-outer .sidebar-body .sb-list ul li span{margin-right:12px}.p-dropdown-panel .p-dropdown-header .p-dropdown-filter-icon{left:6px;color:#6c757d}.lang-dropdown .p-dropdown-items-wrapper ::-webkit-scrollbar{width:6px!important}::-webkit-scrollbar{width:6px}::-webkit-scrollbar-track{background:transparent}::-webkit-scrollbar-thumb{background-color:#c1c1c1;border-radius:6px}::-webkit-scrollbar-thumb:hover{background-color:#a8a8a8}.sidebar-outer .sidebar-body .sb-list ul{float:left;width:100%;list-style:none;padding-left:0}.lang-dropdown .p-dropdown-panel .p-dropdown-items{font-size:12px;padding:0!important}.p-dropdown-panel .p-dropdown-items .p-dropdown-item.p-highlight{color:var(--jaguar-black-color);background:var(--solitude-blue);background-color:var(--solitude-blue)}.lang-dropdown .p-dropdown-panel .p-dropdown-items .p-dropdown-item{padding:2px 14px;font-size:12px}.sidebar-outer .sidebar-body .sb-list ul li{display:flex;padding:8px 2px;cursor:pointer}.modal-dialog{margin-right:0;margin-top:0;margin-bottom:0}.loblist-drpdwn-panel .p-dropdown-header{padding:5px 10px}.loblist-drpdwn-panel .p-inputtext{background:#ffffff;padding:6px}.loblist-drpdwn .p-inputtext{font-size:13px}.loblist-drpdwn-panel .p-dropdown-header .p-dropdown-filter{height:28px;border-radius:4px;font-size:12px}.loblist-drpdwn-panel .p-dropdown-items .p-dropdown-item{margin-bottom:1px;padding:6px 16px;border:0;color:#495057;background:transparent;transition:box-shadow .2s;border-radius:0;font-size:12px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.loblist-drpdwn-panel .p-dropdown-header .p-dropdown-filter-icon{position:absolute;left:82%;top:50%;transform:translateY(-50%);color:#6c757d}.loblist-drpdwn-panel .p-dropdown-items .p-dropdown-empty-message{padding:6px 12px;color:#495057!important;background:transparent!important;font-size:12px}.logo-size{max-height:32px;max-width:92px}.logo-size-1{width:80px;height:30px}.sidebar-body{overflow:auto;height:calc(100vh - 70px);width:100%}.sidebar-body .refresh-icon{cursor:pointer}.sidebar-body .notify-border{padding:8px 8px 0 6px;cursor:pointer}.sidebar-body .notify-border:hover{background-color:#dcdfec;border-radius:8px}.sidebar-body .notify-border .initial-text{width:40px;height:40px;display:flex;align-items:center;justify-content:center;font-size:11px;border-radius:50%;color:#fff;background-color:#f2edfa}.sidebar-body .notify-border .service-count{color:#323238;font-weight:600;font-size:13px}.sidebar-body .notify-border .service-request{color:#676879;font-size:12px;font-weight:500}.sidebar-body .notify-border .time-text{color:#676879;font-size:12px}.sidebar-body .notify-border .grey-borders{border-bottom:1px solid #d0d4e4}.mail-table{height:calc(100vh - 196px);overflow:auto}.mail-table .p-datatable .p-datatable-thead>tr{border:1px solid #dee2e6;border-radius:24px}.mail-table .p-datatable .p-datatable-thead>tr th{padding:0 8px;height:36px;font-size:13px;color:var(--primary-text);font-weight:600;background:#fff}.mail-table .p-datatable .p-datatable-tbody>tr{border:1px solid #dee2e6;border-radius:24px}.mail-table .p-datatable .p-datatable-tbody>tr td{padding:0 25px 0 8px;height:38px;font-size:13px;color:var(--secondary-text);white-space:nowrap}.mail-table .p-checkbox{height:18px;width:18px}.mail-table .p-checkbox .p-checkbox-box{height:16px;width:16px;border-radius:4px;border:1px solid var(--ui-border)}.mail-table .p-checkbox .p-checkbox-box:hover{border:1px solid var(--ui-border)!important}.mail-table .p-checkbox .p-checkbox-icon{font-size:10px!important}.mail-table .p-datatable .p-sortable-column:hover{background-color:#fff!important;color:#000!important}.mail-table .p-datatable .p-sortable-column:focus{box-shadow:none!important}.mail-table .p-datatable .p-sortable-column .p-sortable-column-icon{font-size:12px}.mail-table .p-dropdown-panel .p-dropdown-items{padding:0}.mail-table .p-dropdown-panel .p-dropdown-items .p-dropdown-item{font-size:13px!important;padding:10px 15px}.mail-table .p-paginator{justify-content:flex-start!important;position:fixed;bottom:0;padding-left:0!important}.mail-table .p-paginator .p-paginator-current{font-size:12px;height:1rem!important}.mail-table .p-paginator .p-paginator-pages .p-paginator-page{min-width:30px!important;height:30px!important;font-size:12px}.mail-table .p-paginator .p-dropdown{height:30px!important;margin-top:0;border:0px}.mail-table .p-paginator .p-dropdown .p-dropdown-label{padding:4px 5px 0 10px!important;font-size:14px}.mail-table .p-paginator .p-dropdown .p-dropdown-trigger{width:1.5rem!important}.mail-table .p-paginator .p-dropdown .p-dropdown-trigger .pi{font-size:13px!important}.mail-pagination .p-paginator{justify-content:flex-start!important;padding-left:0;height:47px;width:100%}.mail-pagination .p-paginator .p-paginator-current{font-size:12px;height:1rem!important;padding-left:0}.mail-pagination .p-paginator .p-paginator-pages .p-paginator-page{min-width:30px!important;height:30px!important;font-size:12px}.mail-pagination .p-paginator .p-dropdown{height:30px!important;margin-top:0;border:0px}.mail-pagination .p-paginator .p-dropdown .p-dropdown-label{padding:4px 5px 0 10px!important;font-size:14px}.mail-pagination .p-paginator .p-dropdown .p-dropdown-trigger{width:1.5rem!important}.mail-pagination .p-paginator .p-dropdown .p-dropdown-trigger .pi{font-size:13px!important}.mail-pagination .p-paginator .p-paginator-first,.mail-pagination .p-paginator .p-paginator-prev,.mail-pagination .p-paginator .p-paginator-next,.mail-pagination .p-paginator .p-paginator-last{min-width:30px!important;height:30px!important}.rm-invalid-border .card{border:0px}.view-pass-details{width:600px!important}.view-pass-details .p-dialog-header{background:#ffffff!important;border-radius:4px 4px 0 0!important;border-bottom:1px solid var(--primary-color)!important}.view-pass-details .p-dialog-content:last-of-type{border-bottom-right-radius:4px!important;border-bottom-left-radius:4px!important;padding:0}.confirmtion-modal .p-dialog-content{padding-top:24px;padding-right:100px;font-size:var(--base-font-size)}.confirmtion-modal .p-confirm-dialog-message{margin-left:0!important}.confirmtion-modal .p-button{font-size:var(--base-font-size);background-color:var(--primary-color);border-color:var(--primary-color);padding:6px 28px}.confirmtion-modal .p-button .p-button-secondary .p-button-outlined{background-color:var(--white-color);border:1px solid var(--primary-color);color:var(--primary-color)}.confirmtion-modal .p-button .p-button-secondary .p-button-outlined:enabled:hover{background-color:var(--white-color)}.confirmtion-modal .p-button:enabled:hover{border:1px solid var(--primary-color);background-color:var(--primary-color)}.confirmtion-modal .p-button.p-button-secondary.p-button-outlined{color:var(--primary-color);border:1px solid var(--primary-color);background-color:var(--white-color)}.confirmtion-modal .p-button.p-button-secondary.p-button-outlined:enabled:hover{color:var(--primary-color);border:1px solid var(--primary-color);background-color:var(--white-color)}.badge-notify:hover{border-radius:50%;background:#dcdfec}.badge-notify .p-badge{min-width:16px;height:16px;line-height:15px}.badge-notify .p-overlay-badge .p-badge{background-color:var(--primary-color)!important;position:absolute;top:-7px;right:12px;font-size:9px;padding:0 2px;cursor:pointer}.madontary-icon{color:#d4231d;font-weight:500;padding:5px 0 0 5px}.img-lock{width:12px;margin-bottom:1px}.img-lock.ext{width:16px;margin-bottom:0}.img-lock.ext2{width:18px;margin-bottom:0}.form-group .error-msg{position:relative}.submit-btn .p-button{height:30px;font-size:14px;border-radius:4px;border:1px solid var(--primary-color);background-color:var(--primary-color);border-color:var(--primary-color)}.submit-btn .p-button:enabled:hover{border:1px solid var(--primary-color);background-color:var(--primary-color);border-color:var(--primary-color)}.submit-btn .p-button .p-button-label{font-weight:400;font-size:13px}.p-dialog.general-configuration{width:100%;height:100vh;max-height:100vh}.general-configuration .p-dialog-header{border-bottom:1px solid #d0d4e4!important;background:#ffffff!important}.p-dialog .p-dialog-header{padding:10px 21px!important;background:#fff!important;border-top-right-radius:6px!important;border-top-left-radius:6px!important;height:45px}.p-dialog .p-dialog-header .p-dialog-title{font-weight:600;font-size:var(--base-font-size)}.assets-dropdown .p-dropdown{height:38px!important;width:100%!important;border-radius:4px!important;align-items:center!important}.assets-dropdown .p-dropdown:hover{border:1px solid #ced4da!important}.p-dropdown-panel .p-dropdown-header .p-dropdown-filter{padding-right:1.75rem;margin-right:-1.75rem}.assets-dropdown .p-inputtext{width:100%;border-radius:4px;height:30px;font-size:13px!important}.assets-dropdown .p-dropdown-panel .p-dropdown-header .p-dropdown-filter-icon{left:96%;color:#6c757d;font-size:13px;top:15px!important}.assets-dropdown .p-dropdown-panel .p-dropdown-header{padding:10px!important}.assets-dropdown .p-dropdown-items-wrapper{max-height:100px!important}.assets-dropdown .p-dropdown-panel .p-dropdown-items .p-dropdown-item{padding:5px 20px!important;font-size:13px!important;font-weight:400!important}.p-dropdown-panel .p-dropdown-items{padding:0!important}.assets-dropdown .p-dropdown-panel .p-dropdown-items .p-dropdown-empty-message{font-size:13px!important;padding:8px 20px!important}.p-dropdown-panel .p-dropdown-items .p-dropdown-empty-message{padding:.75rem 1.25rem;color:#495057!important;background:transparent!important}.p-dropdown-filter-container{position:relative}.p-dropdown-filter-container input{border:1px solid #ced4da!important}.input-dropdown .password-checkbox-right{position:absolute;width:24px;right:8px}.timezone-dropdown .p-dropdown{width:100%;border:1px solid #ced4da!important;border-radius:4px;height:38px}.timezone-dropdown .p-dropdown-panel .p-dropdown-header{padding:5px}.timezone-dropdown .p-dropdown:hover{border:1px solid #ced4da!important}.timezone-dropdown .p-inputtext{width:100%;border-radius:4px;height:30px;font-size:13px!important}.timezone-dropdown .p-dropdown-panel .p-dropdown-header .p-dropdown-filter-icon{left:96%;color:#6c757d;font-size:13px;top:15px!important}.timezone-dropdown .p-dropdown-panel .p-dropdown-header{padding:10px!important}.timezone-dropdowntimezone-dropdown .p-dropdown-items-wrapper{max-height:100px!important}.timezone-dropdown .p-dropdown-panel .p-dropdown-items .p-dropdown-item{padding:5px 20px!important;font-size:13px!important;font-weight:400!important}.timezone-dropdown .p-dropdown-panel .p-dropdown-items .p-dropdown-empty-message{font-size:13px!important;padding:8px 20px!important}.sidebar-container{width:420px;position:fixed;top:0;height:100vh;max-width:100%;transition:all .3s ease;-webkit-transition:all .3s ease;-moz-transition:all .3s ease;background-color:#fff}.white-bg{background:#ffffff;width:420px;overflow:hidden}.sidebar-outer .sidebar-header{padding:12px 15px}.sidebar-outer .sidebar-header .sh-top{display:flex;align-items:center;justify-content:space-between}.log-text{font-size:16px;color:#292f4c;font-weight:600}.sidebar-outer .sidebar-header .sh-top button{height:24px}.sidebar-outer .sidebar-body{padding:12px 20px;float:left;width:100%;overflow:auto;height:calc(100vh - 70px)}.tertiary-btn{border:none;background-color:transparent}.sidebar-body .noti-text{color:#292f4c;font-size:13px;font-weight:600;line-height:24px}.sidebar-body .refresh-text{color:#676879;font-size:12px;line-height:24px}.error-msg{font-size:12px;font-weight:600;width:100%;position:absolute;bottom:4px;left:0;display:flex;align-items:flex-end;color:#d83a52;font-family:-apple-system,BlinkMacSystemFont,Roboto,Segoe UI,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\",Segoe UI Symbol!important}.error-msg .error-icon{font-size:18px;margin-right:4px;position:relative;top:-1px}.common-alert-modal .modal-dialog{margin-right:0!important}.ngx-toastr{width:400px!important;margin-top:10px!important}.toast-success{background-color:#fff!important;border-bottom:3px solid #258750;border-radius:4px!important;background-image:url(assets/common-header-lib/images/toast-success.svg)!important;background-repeat:no-repeat}.toast-success .toast-title{color:#258750!important;font-weight:700;font-size:16px}.toast-success .toast-message{padding-top:2px;color:#676879!important;font-size:14px!important}.toast-success .toast-progress{color:#258750!important}.toast-error{background-color:#fff!important;border-bottom:3px solid #d83a52;border-radius:4px!important;background-image:url(assets/common-header-lib/images/toast-error.svg)!important;background-repeat:no-repeat}.toast-error .toast-title{color:#d83a52!important;font-weight:700;font-size:16px}.toast-error .toast-message{padding-top:2px;color:#676879!important;font-size:14px!important}.toast-info{background-color:#fff!important;border-bottom:3px solid #0073ea;border-radius:4px!important;background-image:url(assets/common-header-lib/images/toast-info.svg)!important;background-repeat:no-repeat}.toast-info .toast-title{color:#0073ea!important;font-weight:700;font-size:16px}.toast-info .toast-message{padding-top:3px;color:#676879!important;font-size:14px!important}.toast-warning{background-color:#fff!important;border-bottom:3px solid #fdab3d;border-radius:4px!important;background-image:url(assets/common-header-lib/images/toast-alert.svg)!important;background-repeat:no-repeat}.toast-warning .toast-title{color:#fdab3d!important;font-weight:700;font-size:16px}.toast-warning .toast-message{padding-top:3px;color:#676879!important;font-size:14px!important}.toast-close-button{right:4px!important;top:0;font-size:20px;font-weight:700;text-shadow:0 1px 0 #ffffff;background-color:transparent;border:0px;color:#676879;position:absolute;cursor:pointer}.toast-container{position:fixed;z-index:2147483647!important;pointer-events:auto!important}.toast-container .ngx-toastr{position:relative;overflow:hidden;margin:0 0 6px;padding:15px 40px 15px 50px;width:300px;border-radius:8px!important;background-position:15px 15px;background-repeat:no-repeat;background-size:24px;box-shadow:0 0 9px #99999980;color:#fff}.toast-top-center{top:0;right:0;width:100%}.toast-top-right{right:15px;top:40px}.toast-container.toast-top-center .ngx-toastr,.toast-container.toast-bottom-center .ngx-toastr{margin-left:auto;margin-right:auto}\n"], dependencies: [{ kind: "directive", type: i6.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i6.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "component", type: i8.Dropdown, selector: "p-dropdown", inputs: ["scrollHeight", "filter", "name", "style", "panelStyle", "styleClass", "panelStyleClass", "readonly", "required", "editable", "appendTo", "tabindex", "placeholder", "filterPlaceholder", "filterLocale", "inputId", "selectId", "dataKey", "filterBy", "autofocus", "resetFilterOnHide", "dropdownIcon", "optionLabel", "optionValue", "optionDisabled", "optionGroupLabel", "optionGroupChildren", "autoDisplayFirst", "group", "showClear", "emptyFilterMessage", "emptyMessage", "lazy", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "overlayOptions", "ariaFilterLabel", "ariaLabel", "ariaLabelledBy", "filterMatchMode", "maxlength", "tooltip", "tooltipPosition", "tooltipPositionStyle", "tooltipStyleClass", "autofocusFilter", "overlayDirection", "disabled", "itemSize", "autoZIndex", "baseZIndex", "showTransitionOptions", "hideTransitionOptions", "options", "filterValue"], outputs: ["onChange", "onFilter", "onFocus", "onBlur", "onClick", "onShow", "onHide", "onClear", "onLazyLoad"] }, { kind: "directive", type: i9.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "component", type: i10$1.OverlayPanel, selector: "p-overlayPanel", inputs: ["dismissable", "showCloseIcon", "style", "styleClass", "appendTo", "autoZIndex", "ariaCloseLabel", "baseZIndex", "focusOnShow", "showTransitionOptions", "hideTransitionOptions"], outputs: ["onShow", "onHide"] }, { kind: "directive", type: i11.BadgeDirective, selector: "[pBadge]", inputs: ["iconPos", "badgeDisabled", "value", "severity"] }, { kind: "component", type: i9$1.Skeleton, selector: "p-skeleton", inputs: ["styleClass", "style", "shape", "animation", "borderRadius", "size", "width", "height"] }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: UserSidebarComponent, selector: "app-user-sidebar", inputs: ["languages"], outputs: ["closeDialogBox"] }, { kind: "component", type: SidePopupComponent, selector: "app-side-popup", inputs: ["visible", "position", "header"], outputs: ["closeDialogBox"] }, { kind: "component", type: UserMailboxComponent, selector: "app-user-mailbox", inputs: ["apiURL"], outputs: ["closeMailDialogBox"] }, { kind: "component", type: NoServiceMyAccessPgComponent, selector: "app-no-service-my-access-pg", inputs: ["heading", "subHeading"] }, { kind: "component", type: ConfirmDialogComponent, selector: "confirm-dialog", inputs: ["header", "message"], outputs: ["result"] }, { kind: "pipe", type: i4.TranslatePipe, name: "translate" }, { kind: "pipe", type: SliceToTwoPipe, name: "sliceToTwo" }], encapsulation: i0.ViewEncapsulation.None });
3952
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: CommonHeaderLibComponent, decorators: [{
3953
- type: Component,
3954
- args: [{ selector: 'lib-common-header-lib', encapsulation: ViewEncapsulation.None, template: "<header class=\"app-header ext\">\r\n <div class=\"d-flex justify-content-between align-items-center\">\r\n <div class=\"d-flex\">\r\n <div class=\"logo gap-4\" *ngIf=\"EnableLogo\">\r\n <img\r\n *ngIf=\"EnableLogo && headerLogo\"\r\n class=\"logo-size\"\r\n title=\"Logo\"\r\n alt=\"Logo\"\r\n [src]=\"headerLogo\"\r\n loading=\"lazy\"\r\n />\r\n <p-skeleton\r\n *ngIf=\"!headerLogo\"\r\n height=\"1.5rem\"\r\n width=\"5rem\"\r\n ></p-skeleton>\r\n </div>\r\n </div>\r\n\r\n <!--* Test Buttons for toast UI -->\r\n <!-- <button type=\"button\" class=\"btn btn-success\" (click)=\"success()\">\r\n success</button\r\n ><button type=\"button\" class=\"btn btn-success\" (click)=\"success1()\">\r\n success1\r\n </button>\r\n <button type=\"button\" class=\"btn btn-danger\" (click)=\"danger()\">color: #1d4ed8;\r\n background: #eff6ff;\r\n danger\r\n </button>\r\n <button type=\"button\" class=\"btn btn-warning\" (click)=\"warning()\">\r\n warning\r\n </button>\r\n <button type=\"button\" class=\"btn btn-info\" (click)=\"info()\">info</button> -->\r\n\r\n <div class=\"projName\">\r\n <h1 class=\"modname\">{{ moduleName }}</h1>\r\n </div>\r\n\r\n <div class=\"d-flex justify-content-end align-items-center\">\r\n <!--timezone-->\r\n <ng-container *ngIf=\"EnableTimeZone && userTimeZoneAbbreviations\">\r\n <div class=\"timezone\">\r\n <img\r\n src=\"assets/common-header-lib/images/schedule.svg\"\r\n class=\"mb-1\"\r\n alt=\"Icon\"\r\n />\r\n <span class=\"timezone-text\"\r\n >{{ \"Generic_lib.PreferredTimezone\" | translate }} :\r\n </span>\r\n <span\r\n *ngIf=\"userTimeZoneAbbreviations\"\r\n class=\"user-tz\"\r\n [title]=\"userTimeZoneFullForm\"\r\n >{{ userTimeZoneAbbreviations }}</span\r\n >\r\n </div>\r\n </ng-container>\r\n\r\n <!--lob-->\r\n <ng-container *ngIf=\"EnableLOB\">\r\n <ng-container\r\n *ngIf=\"EnableLOB && !showLobLoader; else LobLodderAnimation\"\r\n >\r\n <div class=\"main-left d-flex\">\r\n <img\r\n src=\"assets/common-header-lib/images/marker-pin.svg\"\r\n alt=\"pen Icon\"\r\n />\r\n\r\n <!-- *Note: Removed [virtualScroll] and [itemSize] from p-dropdown because it caused filtered search results to appear empty until scrolling. Not needed as LOB list size is small. -->\r\n <p-dropdown\r\n filterPlaceholder=\"{{ 'Generic_lib.Search' | translate }}\"\r\n [options]=\"userLOBList\"\r\n (onChange)=\"onLobChangeEvent($event)\"\r\n optionLabel=\"lobName\"\r\n optionValue=\"lobId\"\r\n [(ngModel)]=\"selectedLOBId\"\r\n [filter]=\"true\"\r\n filterBy=\"lobName\"\r\n [showClear]=\"false\"\r\n [style]=\"{ width: '150px', height: '30px' }\"\r\n [resetFilterOnHide]=\"true\"\r\n [lazy]=\"false\"\r\n name=\"lob\"\r\n class=\"loblist-drpdwn\"\r\n panelStyleClass=\"loblist-drpdwn-panel\"\r\n >\r\n <ng-template let-loblist pTemplate=\"item\">\r\n <div class=\"flex align-items-center gap-2\">\r\n <div title=\"{{ loblist.lobName }}\" class=\"header-drpdwn\">\r\n {{ loblist.lobName }}\r\n </div>\r\n </div>\r\n </ng-template>\r\n </p-dropdown>\r\n </div>\r\n </ng-container>\r\n <ng-template #LobLodderAnimation>\r\n <p-skeleton height=\"1.5rem\" width=\"10rem\"></p-skeleton>\r\n </ng-template>\r\n </ng-container>\r\n\r\n <!--mailbox-->\r\n <ng-container *ngIf=\"isHeaderContentLoaded; else HeaderLoading\">\r\n <div *ngIf=\"EnableMail\" class=\"header-left-icon\">\r\n <img\r\n src=\"assets/common-header-lib/images/mail-icon.svg\"\r\n alt=\"mail Icon\"\r\n class=\"headeright-icon\"\r\n (click)=\"showMailBoxScreen()\"\r\n />\r\n </div>\r\n <ng-container *ngIf=\"EnableMail && totalEmails.length > 0\">\r\n <!-- <ng-container> -->\r\n <div class=\"badge-notify\">\r\n <div pBadge [value]=\"totalEmails\"></div>\r\n </div>\r\n </ng-container>\r\n\r\n <!--notification-->\r\n <div class=\"header-left-icon\" *ngIf=\"EnableNotifications\">\r\n <img\r\n src=\"assets/common-header-lib/images/bell-icon.svg\"\r\n alt=\"mail Icon\"\r\n class=\"headeright-icon\"\r\n (click)=\"OpenNotificationModal()\"\r\n />\r\n </div>\r\n\r\n <ng-container\r\n *ngIf=\"EnableNotifications && userNotificationCount.length > 0\"\r\n >\r\n <div class=\"badge-notify\">\r\n <div pBadge [value]=\"userNotificationCount\"></div>\r\n </div>\r\n </ng-container>\r\n\r\n <!--9 Dots -->\r\n <div\r\n *ngIf=\"EnableMoreApps\"\r\n class=\"header-left-icon\"\r\n title=\"Control Center\"\r\n alt=\"bell Icon\"\r\n (click)=\"showUserAppsPanel($event)\"\r\n >\r\n <img\r\n src=\"assets/common-header-lib/images/apps-1.svg\"\r\n class=\"apps-icon\"\r\n />\r\n </div>\r\n\r\n <!--user display name -->\r\n <div\r\n *ngIf=\"EnableProfile\"\r\n class=\"main-right\"\r\n (click)=\"showUserDetailsPanel()\"\r\n >\r\n <ng-container>\r\n <div class=\"initial-text mx-1\">\r\n {{ userdisplayName | sliceToTwo }}\r\n </div>\r\n </ng-container>\r\n </div>\r\n </ng-container>\r\n\r\n <ng-template #HeaderLoading>\r\n <p-skeleton shape=\"circle\" size=\"1.3rem\" styleClass=\"mx-2\"></p-skeleton>\r\n <p-skeleton shape=\"circle\" size=\"1.3rem\" styleClass=\"mx-2\"></p-skeleton>\r\n <p-skeleton size=\"1.5rem\" styleClass=\"mx-2\"></p-skeleton>\r\n <p-skeleton shape=\"circle\" size=\"2rem\" styleClass=\"mx-2\"></p-skeleton>\r\n </ng-template>\r\n </div>\r\n </div>\r\n</header>\r\n\r\n<!--List of Application : 9 dots -->\r\n<p-overlayPanel #App class=\"pt-0\" styleClass=\"app-panel\">\r\n <ng-container *ngIf=\"!userAppLoaderLoadder; else LoadingTemplate\">\r\n <div class=\"custom-popover-content\">\r\n <div class=\"waffle-align\">\r\n <div\r\n class=\"waffle-popup\"\r\n [title]=\"appDetails['applicationName']\"\r\n *ngFor=\"let appDetails of ListOfUserPrivillegedApp\"\r\n (click)=\"getConnectionofApplication(appDetails['appCode'])\"\r\n >\r\n <img\r\n *ngIf=\"appDetails?.appCode\"\r\n src=\"assets/common-header-lib/images/{{ appDetails.appCode }}.svg\"\r\n alt=\"App icon\"\r\n />\r\n\r\n <div class=\"waffle-text\">{{ appDetails[\"applicationName\"] }}</div>\r\n </div>\r\n </div>\r\n </div>\r\n </ng-container>\r\n <ng-template #LoadingTemplate>\r\n <div class=\"custom-popover-content skeleton-popover\">\r\n <ng-container *ngFor=\"let item of repeatLoader\">\r\n <div\r\n class=\"d-flex flex-column align-items-center justify-content-center gap-2\"\r\n >\r\n <p-skeleton size=\"3rem\"></p-skeleton>\r\n <p-skeleton height=\".3rem\" width=\"35px\"></p-skeleton>\r\n </div>\r\n </ng-container>\r\n </div>\r\n </ng-template>\r\n</p-overlayPanel>\r\n\r\n<!--mailbox details-->\r\n<ng-container *ngIf=\"showMailboxScreenflag\">\r\n <div class=\"changingContent\">\r\n <app-user-mailbox\r\n (closeMailDialogBox)=\"hideMailBoxScreen()\"\r\n ></app-user-mailbox>\r\n </div>\r\n</ng-container>\r\n\r\n<!-- Userdetails profile pop up -->\r\n<div class=\"profile-sidebar\">\r\n <app-side-popup\r\n *ngIf=\"isOpenSidePopup\"\r\n [visible]=\"true\"\r\n [position]=\"'right'\"\r\n (closeDialogBox)=\"closeSidePopup()\"\r\n >\r\n <app-user-sidebar\r\n *ngIf=\"showUserDetails\"\r\n [languages]=\"languages\"\r\n (closeDialogBox)=\"closeSidePopup()\"\r\n ></app-user-sidebar>\r\n </app-side-popup>\r\n</div>\r\n\r\n<!-- Notification side popup -->\r\n<div\r\n class=\"modal fade common-alert-modal\"\r\n #notifyModal\r\n id=\"Notify_SidebarModal\"\r\n tabindex=\"-1\"\r\n aria-hidden=\"true\"\r\n>\r\n <div class=\"modal-dialog sidebar-outer white-bg\">\r\n <div class=\"modal-content\">\r\n <div class=\"sidebar-container white-bg\">\r\n <!-- keep everything inside this content -->\r\n\r\n <!-- Sidebar Header -->\r\n <div class=\"sidebar-header grey-background\">\r\n <div class=\"sh-top\">\r\n <div class=\"sh-top-left d-flex align-items-center\">\r\n <div class=\"mx-2 log-text\">\r\n {{ \"Generic_lib.Notification\" | translate }}\r\n </div>\r\n </div>\r\n <div class=\"sh-top-right\">\r\n <button\r\n type=\"button\"\r\n class=\"common-bn tertiary-btn\"\r\n aria-label=\"Close\"\r\n (click)=\"closeModal()\"\r\n >\r\n <img\r\n src=\"assets/common-header-lib/images/close.svg\"\r\n alt=\"Close\"\r\n class=\"imgs mb-1\"\r\n />\r\n </button>\r\n </div>\r\n </div>\r\n </div>\r\n\r\n <!-- Sidebar Body -->\r\n <div class=\"sidebar-body\">\r\n <div class=\"d-flex justify-content-between align-items-center mb-2\">\r\n <div class=\"noti-text\">\r\n {{\r\n \"Generic_lib.YouHaveNNotifications\"\r\n | translate: { count: userNotificationCount }\r\n }}\r\n </div>\r\n <div\r\n class=\"d-flex align-items-center gap-1 refresh-icon\"\r\n (click)=\"getEventwiseNotification()\"\r\n >\r\n <img\r\n src=\"assets/common-header-lib/images/refresh-1.svg\"\r\n alt=\"Refresh\"\r\n />\r\n <div class=\"refresh-text\">\r\n {{ \"Generic_lib.Refresh\" | translate }}\r\n </div>\r\n </div>\r\n </div>\r\n <div class=\"mt-3\">\r\n <ng-container\r\n *ngIf=\"\r\n !isErrorFound && !notificationLoadder;\r\n else Noti_LoadingTemplate\r\n \"\r\n >\r\n <div\r\n class=\"notify-border\"\r\n *ngFor=\"let event of eventwiseNotificationCount\"\r\n >\r\n <div class=\"d-flex align-items-center gap-3\">\r\n <div class=\"initial-text initial-text-1 mx-1\">\r\n <img\r\n src=\"assets/common-header-lib/images/noti_ticket.svg\"\r\n alt=\"Icon\"\r\n />\r\n </div>\r\n <div>\r\n <div>\r\n <span class=\"service-count\"\r\n >{{ event[\"PendingCount\"] }} New </span\r\n ><span class=\"service-request\"\r\n >{{ event[\"EventName\"] }} Event requests</span\r\n >\r\n </div>\r\n </div>\r\n </div>\r\n <div class=\"grey-borders mt-2\"></div>\r\n </div>\r\n </ng-container>\r\n <ng-template #Noti_LoadingTemplate>\r\n <ng-container *ngIf=\"notificationLoadder; else errorTemplate\">\r\n <ng-container *ngFor=\"let item of repeatLoader1\">\r\n <div class=\"d-flex align-items-center gap-3\">\r\n <p-skeleton\r\n shape=\"circle\"\r\n size=\"60px\"\r\n styleClass=\"my-2\"\r\n ></p-skeleton>\r\n <div class=\"ms-1\">\r\n <p-skeleton width=\"200%\" styleClass=\"mb-2\"></p-skeleton>\r\n <p-skeleton width=\"150px\" height=\"1rem\"></p-skeleton>\r\n </div>\r\n </div>\r\n </ng-container>\r\n </ng-container>\r\n </ng-template>\r\n\r\n <ng-template #errorTemplate>\r\n <app-no-service-my-access-pg\r\n heading=\"{{ 'Generic_lib.CommonError' | translate }}\"\r\n ></app-no-service-my-access-pg>\r\n </ng-template>\r\n </div>\r\n <!-- Notification content & loaders remain here -->\r\n </div>\r\n </div>\r\n <!-- end of sidebar-container -->\r\n </div>\r\n <!-- end of modal-content -->\r\n </div>\r\n <!-- end of modal-dialog -->\r\n</div>\r\n\r\n<!-- Common Conirmation Modal -->\r\n<confirm-dialog\r\n class=\"rm-invalid-border\"\r\n #confirmDialog\r\n header=\"{{ 'Generic_lib.ChangeLOB' | translate }}\"\r\n message=\"{{ 'Generic_lib.DoYouWantToChangeTheCurrentLOB' | translate }}\"\r\n (result)=\"lobChangeConfirmation($event)\"\r\n></confirm-dialog>\r\n\r\n<!--* Need to use component based notification UI as below -->\r\n<!-- Notification-Sidebar Started -->\r\n<!-- <app-notification-sidebar [isErrorOccured]=\"isErrorFound\" [userNotificationCount]=\"userNotificationCount\"\r\n [userNotificationCountObj]=\"userNotificationCountObj\" [eventwiseNotificationCount]=\"eventwiseNotificationCount\"\r\n (refreshNotification)=\"getEventwiseNotificationCount()\"\r\n [notificationLoadder]=\"notificationLoadder\"></app-notification-sidebar> -->\r\n<!-- Notification-Sidebar Ended -->\r\n", styles: [".app-header{padding:4px 10px 10px;height:42px;border-bottom:1px solid #d0d4e4}.logo{display:flex;align-items:center}.main-right{display:flex;align-items:center;cursor:pointer}.logo-icon{width:0;height:0;border-left:14px solid transparent;border-right:14px solid transparent;position:relative}.logo-icon:after{width:0;height:0;border-left:7px solid transparent;border-right:7px solid transparent;position:absolute;content:\"\";top:7px;left:-7px}p{font-size:25px!important}.p-inputtext.p-inputtext-sm{padding:4px 5px 4px 33px!important}.pi-search:before{font-size:13px;position:absolute;top:2px}.overlay-text{font-size:13px;line-height:18px;color:#676879;font-weight:400}.main-left .p-dropdown{border:none;border-radius:0;width:140px!important}.main-left .p-dropdown-panel .p-dropdown-items{padding:0!important;max-height:110px}.main-left :focus-visible{outline:none}.main-left .p-scroller{overflow-x:hidden;height:120px!important}.header-drpdwn{width:120px!important;font-size:11px!important;text-overflow:ellipsis;overflow:hidden}.logs{gap:70px;margin-top:5px}.head-search{position:fixed;top:4px;left:275px}.head-search input{width:calc(30vw - 40px)!important;border:1px solid #c3c6d4;background-color:#f6f7fb;height:32px;border-radius:0 4px 4px 0;border-left:none;font-size:13px!important;padding-left:30px!important;padding-right:54px}.head-search.active{position:fixed;top:4px;left:275px}.head-search.active input{width:555px!important}@media screen and (min-width: 1920px){.head-search.active{position:fixed;top:4px;left:275px}.head-search.active input{width:900px!important}}.header-left-icon{height:32px;width:32px;cursor:pointer;display:flex;justify-content:center;align-items:center;transition:all .5s;border-radius:50%;margin-right:4px;position:relative}.header-left-icon:hover{background:#dcdfec}.header-left-icon img:hover{filter:invert(0%) sepia(4%) saturate(0%) hue-rotate(324deg) brightness(55%) contrast(105%)}.apps-icon{width:21px}.logo-img{width:80px}.initial-text{width:32px;height:32px;display:flex;align-items:center;justify-content:center;font-size:11px;border-radius:50%;color:#fff;background-color:#8e562e}.initial-text-1{background-color:#f2edfa}.lob-img{padding-bottom:4px}.session-app:hover{background:#dcdfec;border-radius:10px}.app-col{cursor:pointer;padding:8px 0}.app-text{font-size:12px;color:#676879;white-space:nowrap;padding-top:8px;text-align:center;text-overflow:ellipsis;overflow:hidden;width:100px}.filter-search{position:relative;right:50px;bottom:2px;cursor:pointer}.filter-search .cross-search{width:23px}.filter-search .search-filter{width:19px}.headeright-icon{width:17px;height:17px;filter:invert(44%) sepia(3%) saturate(1698%) hue-rotate(199deg) brightness(92%) contrast(93%)}.pl-0{padding-left:0}.form-control-sm{border:none;border-bottom:1px solid #c3c6d4;border-radius:0}.overlay-footer .common-btn{width:110px;height:32px;padding:11px 12px;border-radius:4px;font-size:13px;cursor:pointer;background:#fff}.overlay-footer .primary-btn{padding:8px 12px 11px 14px;border-radius:4px;height:32px;width:65px;font-size:13px;cursor:pointer}.filter-popup{position:relative;left:10px}.form-group{margin-bottom:5px}.waffle-text{font-size:11px;text-align:center;width:70px;text-overflow:ellipsis;overflow:hidden;white-space:nowrap;margin-top:-3px}.waffle-align{display:grid;grid-template-columns:auto auto auto}.waffle{cursor:pointer;margin-right:16px}.waffle-popup{width:89px!important;margin-top:0;padding:8px 0 4px;display:flex;align-items:center;justify-content:center;flex-direction:column;cursor:pointer}.waffle-popup:hover{background:var(--primary-notification-bg);border-radius:10px}.waffle-popup img{height:40px}.custom-popover-content{padding:10px;right:-5px;top:0;position:absolute;background:white;border-radius:8px;box-shadow:0 0 6px #9d9d9d}.custom-popover-content.skeleton-popover{width:313px;display:grid;grid-template-columns:auto auto auto;gap:10px}.timezone{margin-right:12px}.timezone-icon{font-size:16px}.timezone-text{padding-left:6px;font-size:13px;color:#495057;font-weight:400}.user-tz{font-size:13px;color:#757575;font-weight:400;text-overflow:ellipsis;overflow:hidden;width:30px;white-space:normal}.profile-sidebar .p-dialog .p-dialog-content{padding:0}.profile-sidebar .p-dialog-header{display:none}.modname{font-size:18px;margin-bottom:0}.changingContent{overflow:hidden;width:100%}.changingContent .intro-text{background-image:linear-gradient(145deg,#f1eaec,#f8e3e7,#f7e1f8,#ebeeff,#e8eef3);position:relative;height:135px}.changingContent .inner-garient{padding:50px 20px 115px 30px}.changingContent .table-heading{padding:0 20px 1px 30px}.changingContent .table-selection{padding:3px 20px 0 30px}.grey-background{background-color:#f6f7fb}.white-bg{background:#ffffff;overflow:hidden}.imgs{width:20px}.p-dropdown .p-dropdown-label{background:transparent;border:0 none;display:flex;align-items:center}.p-dropdown .p-dropdown-trigger{width:32px!important}.pi-chevron-down:before{content:\"\\e902\";font-size:11px}.sidebar-outer{height:100vh}.lang-dropdown .p-dropdown{border:1px solid #dee2e6!important;height:26px!important;border-radius:4px!important;min-width:calc(40vh - 92px)!important;padding:0 4px 0 12px!important;display:flex!important;align-items:center!important;justify-content:space-between!important}.lang-dropdown .p-dropdown .pi{position:relative;bottom:2px;left:7px}.lang-dropdown .p-dropdown-panel{background:#ffffff!important;color:#495057!important;border:0px!important;box-shadow:0 2px 12px #0000001a!important}.lang-dropdown .p-dropdown-header{padding:5px 10px!important;border-bottom:1px solid #dee2e6!important;background:#f8f9fa!important;color:#343a40!important;margin:0!important}.lang-dropdown .p-dropdown-items-wrapper{max-height:140px!important}.lang-dropdown .p-dropdown-panel .p-dropdown-header{padding:4px 8px!important;border-radius:0!important}.p-dropdown-panel .p-dropdown-header{padding:.75rem 1.25rem;border-bottom:1px solid #dee2e6;color:#343a40;background:#f8f9fa;margin:0;border-top-right-radius:6px;border-top-left-radius:6px}.lang-dropdown .p-dropdown .p-dropdown-header .p-dropdown-filter{height:26px;border-radius:4px;font-size:12px;border:1px solid #ced4da!important;padding-left:12px!important}.lang-dropdown .p-inputtext{margin:0;text-align:start;font-size:13px;padding:0!important}.lang-dropdown .p-dropdown-panel .p-dropdown-header .p-dropdown-filter-icon{position:relative;bottom:13px;font-size:13px}.sidebar-outer .sidebar-body .sb-list ul li span{margin-right:12px}.p-dropdown-panel .p-dropdown-header .p-dropdown-filter-icon{left:6px;color:#6c757d}.lang-dropdown .p-dropdown-items-wrapper ::-webkit-scrollbar{width:6px!important}::-webkit-scrollbar{width:6px}::-webkit-scrollbar-track{background:transparent}::-webkit-scrollbar-thumb{background-color:#c1c1c1;border-radius:6px}::-webkit-scrollbar-thumb:hover{background-color:#a8a8a8}.sidebar-outer .sidebar-body .sb-list ul{float:left;width:100%;list-style:none;padding-left:0}.lang-dropdown .p-dropdown-panel .p-dropdown-items{font-size:12px;padding:0!important}.p-dropdown-panel .p-dropdown-items .p-dropdown-item.p-highlight{color:var(--jaguar-black-color);background:var(--solitude-blue);background-color:var(--solitude-blue)}.lang-dropdown .p-dropdown-panel .p-dropdown-items .p-dropdown-item{padding:2px 14px;font-size:12px}.sidebar-outer .sidebar-body .sb-list ul li{display:flex;padding:8px 2px;cursor:pointer}.modal-dialog{margin-right:0;margin-top:0;margin-bottom:0}.loblist-drpdwn-panel .p-dropdown-header{padding:5px 10px}.loblist-drpdwn-panel .p-inputtext{background:#ffffff;padding:6px}.loblist-drpdwn .p-inputtext{font-size:13px}.loblist-drpdwn-panel .p-dropdown-header .p-dropdown-filter{height:28px;border-radius:4px;font-size:12px}.loblist-drpdwn-panel .p-dropdown-items .p-dropdown-item{margin-bottom:1px;padding:6px 16px;border:0;color:#495057;background:transparent;transition:box-shadow .2s;border-radius:0;font-size:12px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.loblist-drpdwn-panel .p-dropdown-header .p-dropdown-filter-icon{position:absolute;left:82%;top:50%;transform:translateY(-50%);color:#6c757d}.loblist-drpdwn-panel .p-dropdown-items .p-dropdown-empty-message{padding:6px 12px;color:#495057!important;background:transparent!important;font-size:12px}.logo-size{max-height:32px;max-width:92px}.logo-size-1{width:80px;height:30px}.sidebar-body{overflow:auto;height:calc(100vh - 70px);width:100%}.sidebar-body .refresh-icon{cursor:pointer}.sidebar-body .notify-border{padding:8px 8px 0 6px;cursor:pointer}.sidebar-body .notify-border:hover{background-color:#dcdfec;border-radius:8px}.sidebar-body .notify-border .initial-text{width:40px;height:40px;display:flex;align-items:center;justify-content:center;font-size:11px;border-radius:50%;color:#fff;background-color:#f2edfa}.sidebar-body .notify-border .service-count{color:#323238;font-weight:600;font-size:13px}.sidebar-body .notify-border .service-request{color:#676879;font-size:12px;font-weight:500}.sidebar-body .notify-border .time-text{color:#676879;font-size:12px}.sidebar-body .notify-border .grey-borders{border-bottom:1px solid #d0d4e4}.mail-table{height:calc(100vh - 196px);overflow:auto}.mail-table .p-datatable .p-datatable-thead>tr{border:1px solid #dee2e6;border-radius:24px}.mail-table .p-datatable .p-datatable-thead>tr th{padding:0 8px;height:36px;font-size:13px;color:var(--primary-text);font-weight:600;background:#fff}.mail-table .p-datatable .p-datatable-tbody>tr{border:1px solid #dee2e6;border-radius:24px}.mail-table .p-datatable .p-datatable-tbody>tr td{padding:0 25px 0 8px;height:38px;font-size:13px;color:var(--secondary-text);white-space:nowrap}.mail-table .p-checkbox{height:18px;width:18px}.mail-table .p-checkbox .p-checkbox-box{height:16px;width:16px;border-radius:4px;border:1px solid var(--ui-border)}.mail-table .p-checkbox .p-checkbox-box:hover{border:1px solid var(--ui-border)!important}.mail-table .p-checkbox .p-checkbox-icon{font-size:10px!important}.mail-table .p-datatable .p-sortable-column:hover{background-color:#fff!important;color:#000!important}.mail-table .p-datatable .p-sortable-column:focus{box-shadow:none!important}.mail-table .p-datatable .p-sortable-column .p-sortable-column-icon{font-size:12px}.mail-table .p-dropdown-panel .p-dropdown-items{padding:0}.mail-table .p-dropdown-panel .p-dropdown-items .p-dropdown-item{font-size:13px!important;padding:10px 15px}.mail-table .p-paginator{justify-content:flex-start!important;position:fixed;bottom:0;padding-left:0!important}.mail-table .p-paginator .p-paginator-current{font-size:12px;height:1rem!important}.mail-table .p-paginator .p-paginator-pages .p-paginator-page{min-width:30px!important;height:30px!important;font-size:12px}.mail-table .p-paginator .p-dropdown{height:30px!important;margin-top:0;border:0px}.mail-table .p-paginator .p-dropdown .p-dropdown-label{padding:4px 5px 0 10px!important;font-size:14px}.mail-table .p-paginator .p-dropdown .p-dropdown-trigger{width:1.5rem!important}.mail-table .p-paginator .p-dropdown .p-dropdown-trigger .pi{font-size:13px!important}.mail-pagination .p-paginator{justify-content:flex-start!important;padding-left:0;height:47px;width:100%}.mail-pagination .p-paginator .p-paginator-current{font-size:12px;height:1rem!important;padding-left:0}.mail-pagination .p-paginator .p-paginator-pages .p-paginator-page{min-width:30px!important;height:30px!important;font-size:12px}.mail-pagination .p-paginator .p-dropdown{height:30px!important;margin-top:0;border:0px}.mail-pagination .p-paginator .p-dropdown .p-dropdown-label{padding:4px 5px 0 10px!important;font-size:14px}.mail-pagination .p-paginator .p-dropdown .p-dropdown-trigger{width:1.5rem!important}.mail-pagination .p-paginator .p-dropdown .p-dropdown-trigger .pi{font-size:13px!important}.mail-pagination .p-paginator .p-paginator-first,.mail-pagination .p-paginator .p-paginator-prev,.mail-pagination .p-paginator .p-paginator-next,.mail-pagination .p-paginator .p-paginator-last{min-width:30px!important;height:30px!important}.rm-invalid-border .card{border:0px}.view-pass-details{width:600px!important}.view-pass-details .p-dialog-header{background:#ffffff!important;border-radius:4px 4px 0 0!important;border-bottom:1px solid var(--primary-color)!important}.view-pass-details .p-dialog-content:last-of-type{border-bottom-right-radius:4px!important;border-bottom-left-radius:4px!important;padding:0}.confirmtion-modal .p-dialog-content{padding-top:24px;padding-right:100px;font-size:var(--base-font-size)}.confirmtion-modal .p-confirm-dialog-message{margin-left:0!important}.confirmtion-modal .p-button{font-size:var(--base-font-size);background-color:var(--primary-color);border-color:var(--primary-color);padding:6px 28px}.confirmtion-modal .p-button .p-button-secondary .p-button-outlined{background-color:var(--white-color);border:1px solid var(--primary-color);color:var(--primary-color)}.confirmtion-modal .p-button .p-button-secondary .p-button-outlined:enabled:hover{background-color:var(--white-color)}.confirmtion-modal .p-button:enabled:hover{border:1px solid var(--primary-color);background-color:var(--primary-color)}.confirmtion-modal .p-button.p-button-secondary.p-button-outlined{color:var(--primary-color);border:1px solid var(--primary-color);background-color:var(--white-color)}.confirmtion-modal .p-button.p-button-secondary.p-button-outlined:enabled:hover{color:var(--primary-color);border:1px solid var(--primary-color);background-color:var(--white-color)}.badge-notify:hover{border-radius:50%;background:#dcdfec}.badge-notify .p-badge{min-width:16px;height:16px;line-height:15px}.badge-notify .p-overlay-badge .p-badge{background-color:var(--primary-color)!important;position:absolute;top:-7px;right:12px;font-size:9px;padding:0 2px;cursor:pointer}.madontary-icon{color:#d4231d;font-weight:500;padding:5px 0 0 5px}.img-lock{width:12px;margin-bottom:1px}.img-lock.ext{width:16px;margin-bottom:0}.img-lock.ext2{width:18px;margin-bottom:0}.form-group .error-msg{position:relative}.submit-btn .p-button{height:30px;font-size:14px;border-radius:4px;border:1px solid var(--primary-color);background-color:var(--primary-color);border-color:var(--primary-color)}.submit-btn .p-button:enabled:hover{border:1px solid var(--primary-color);background-color:var(--primary-color);border-color:var(--primary-color)}.submit-btn .p-button .p-button-label{font-weight:400;font-size:13px}.p-dialog.general-configuration{width:100%;height:100vh;max-height:100vh}.general-configuration .p-dialog-header{border-bottom:1px solid #d0d4e4!important;background:#ffffff!important}.p-dialog .p-dialog-header{padding:10px 21px!important;background:#fff!important;border-top-right-radius:6px!important;border-top-left-radius:6px!important;height:45px}.p-dialog .p-dialog-header .p-dialog-title{font-weight:600;font-size:var(--base-font-size)}.assets-dropdown .p-dropdown{height:38px!important;width:100%!important;border-radius:4px!important;align-items:center!important}.assets-dropdown .p-dropdown:hover{border:1px solid #ced4da!important}.p-dropdown-panel .p-dropdown-header .p-dropdown-filter{padding-right:1.75rem;margin-right:-1.75rem}.assets-dropdown .p-inputtext{width:100%;border-radius:4px;height:30px;font-size:13px!important}.assets-dropdown .p-dropdown-panel .p-dropdown-header .p-dropdown-filter-icon{left:96%;color:#6c757d;font-size:13px;top:15px!important}.assets-dropdown .p-dropdown-panel .p-dropdown-header{padding:10px!important}.assets-dropdown .p-dropdown-items-wrapper{max-height:100px!important}.assets-dropdown .p-dropdown-panel .p-dropdown-items .p-dropdown-item{padding:5px 20px!important;font-size:13px!important;font-weight:400!important}.p-dropdown-panel .p-dropdown-items{padding:0!important}.assets-dropdown .p-dropdown-panel .p-dropdown-items .p-dropdown-empty-message{font-size:13px!important;padding:8px 20px!important}.p-dropdown-panel .p-dropdown-items .p-dropdown-empty-message{padding:.75rem 1.25rem;color:#495057!important;background:transparent!important}.p-dropdown-filter-container{position:relative}.p-dropdown-filter-container input{border:1px solid #ced4da!important}.input-dropdown .password-checkbox-right{position:absolute;width:24px;right:8px}.timezone-dropdown .p-dropdown{width:100%;border:1px solid #ced4da!important;border-radius:4px;height:38px}.timezone-dropdown .p-dropdown-panel .p-dropdown-header{padding:5px}.timezone-dropdown .p-dropdown:hover{border:1px solid #ced4da!important}.timezone-dropdown .p-inputtext{width:100%;border-radius:4px;height:30px;font-size:13px!important}.timezone-dropdown .p-dropdown-panel .p-dropdown-header .p-dropdown-filter-icon{left:96%;color:#6c757d;font-size:13px;top:15px!important}.timezone-dropdown .p-dropdown-panel .p-dropdown-header{padding:10px!important}.timezone-dropdowntimezone-dropdown .p-dropdown-items-wrapper{max-height:100px!important}.timezone-dropdown .p-dropdown-panel .p-dropdown-items .p-dropdown-item{padding:5px 20px!important;font-size:13px!important;font-weight:400!important}.timezone-dropdown .p-dropdown-panel .p-dropdown-items .p-dropdown-empty-message{font-size:13px!important;padding:8px 20px!important}.sidebar-container{width:420px;position:fixed;top:0;height:100vh;max-width:100%;transition:all .3s ease;-webkit-transition:all .3s ease;-moz-transition:all .3s ease;background-color:#fff}.white-bg{background:#ffffff;width:420px;overflow:hidden}.sidebar-outer .sidebar-header{padding:12px 15px}.sidebar-outer .sidebar-header .sh-top{display:flex;align-items:center;justify-content:space-between}.log-text{font-size:16px;color:#292f4c;font-weight:600}.sidebar-outer .sidebar-header .sh-top button{height:24px}.sidebar-outer .sidebar-body{padding:12px 20px;float:left;width:100%;overflow:auto;height:calc(100vh - 70px)}.tertiary-btn{border:none;background-color:transparent}.sidebar-body .noti-text{color:#292f4c;font-size:13px;font-weight:600;line-height:24px}.sidebar-body .refresh-text{color:#676879;font-size:12px;line-height:24px}.error-msg{font-size:12px;font-weight:600;width:100%;position:absolute;bottom:4px;left:0;display:flex;align-items:flex-end;color:#d83a52;font-family:-apple-system,BlinkMacSystemFont,Roboto,Segoe UI,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\",Segoe UI Symbol!important}.error-msg .error-icon{font-size:18px;margin-right:4px;position:relative;top:-1px}.common-alert-modal .modal-dialog{margin-right:0!important}.ngx-toastr{width:400px!important;margin-top:10px!important}.toast-success{background-color:#fff!important;border-bottom:3px solid #258750;border-radius:4px!important;background-image:url(assets/common-header-lib/images/toast-success.svg)!important;background-repeat:no-repeat}.toast-success .toast-title{color:#258750!important;font-weight:700;font-size:16px}.toast-success .toast-message{padding-top:2px;color:#676879!important;font-size:14px!important}.toast-success .toast-progress{color:#258750!important}.toast-error{background-color:#fff!important;border-bottom:3px solid #d83a52;border-radius:4px!important;background-image:url(assets/common-header-lib/images/toast-error.svg)!important;background-repeat:no-repeat}.toast-error .toast-title{color:#d83a52!important;font-weight:700;font-size:16px}.toast-error .toast-message{padding-top:2px;color:#676879!important;font-size:14px!important}.toast-info{background-color:#fff!important;border-bottom:3px solid #0073ea;border-radius:4px!important;background-image:url(assets/common-header-lib/images/toast-info.svg)!important;background-repeat:no-repeat}.toast-info .toast-title{color:#0073ea!important;font-weight:700;font-size:16px}.toast-info .toast-message{padding-top:3px;color:#676879!important;font-size:14px!important}.toast-warning{background-color:#fff!important;border-bottom:3px solid #fdab3d;border-radius:4px!important;background-image:url(assets/common-header-lib/images/toast-alert.svg)!important;background-repeat:no-repeat}.toast-warning .toast-title{color:#fdab3d!important;font-weight:700;font-size:16px}.toast-warning .toast-message{padding-top:3px;color:#676879!important;font-size:14px!important}.toast-close-button{right:4px!important;top:0;font-size:20px;font-weight:700;text-shadow:0 1px 0 #ffffff;background-color:transparent;border:0px;color:#676879;position:absolute;cursor:pointer}.toast-container{position:fixed;z-index:2147483647!important;pointer-events:auto!important}.toast-container .ngx-toastr{position:relative;overflow:hidden;margin:0 0 6px;padding:15px 40px 15px 50px;width:300px;border-radius:8px!important;background-position:15px 15px;background-repeat:no-repeat;background-size:24px;box-shadow:0 0 9px #99999980;color:#fff}.toast-top-center{top:0;right:0;width:100%}.toast-top-right{right:15px;top:40px}.toast-container.toast-top-center .ngx-toastr,.toast-container.toast-bottom-center .ngx-toastr{margin-left:auto;margin-right:auto}\n"] }]
3955
- }], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }, { type: RestSignalRService }, { type: EventService }, { type: i4.TranslateService }, { type: HttpCommonService }, { type: ToastMsgService }]; }, propDecorators: { EnableLogo: [{
3956
- type: Input
3957
- }], moduleName: [{
3958
- type: Input
3959
- }], EnableTimeZone: [{
3960
- type: Input
3961
- }], EnableLOB: [{
3962
- type: Input
3963
- }], showAllLOB: [{
3964
- type: Input
3965
- }], EnableMail: [{
3966
- type: Input
3967
- }], EnableNotifications: [{
3968
- type: Input
3969
- }], EnableMoreApps: [{
3970
- type: Input
3971
- }], EnableProfile: [{
3972
- type: Input
3973
- }], languages: [{
3974
- type: Input
3975
- }], timezoneDetails: [{
3976
- type: Output
3977
- }], lobSelected: [{
3978
- type: Output
3979
- }], getBgImage: [{
3980
- type: Output
3981
- }], langChange: [{
3982
- type: Output
3983
- }], overlayStateChange: [{
3984
- type: Output
3985
- }], confirmDialog: [{
3986
- type: ViewChild,
3987
- args: ['confirmDialog']
3988
- }], appPanel: [{
3989
- type: ViewChild,
3990
- args: ['App']
3991
- }], notifyModalRef: [{
3992
- type: ViewChild,
3993
- args: ['notifyModal']
3994
- }], notifyModal: [{
3995
- type: ViewChild,
3996
- args: ['notifyModal']
3997
- }] } });
3998
-
3999
- class NotificationSidebarComponent {
4000
- constructor() {
4001
- this.userNotificationCount = '';
4002
- this.userNotificationCountObj = {};
4003
- this.eventwiseNotificationCount = [];
4004
- this.refreshNotification = new EventEmitter();
4005
- this.isErrorOccured = false;
4006
- this.notificationLoadder = true;
4007
- this.NoServiceMsgText = 'Generic_lib.CommonError';
4008
- this.repeatLoader = Array(9).fill(0);
4009
- }
4010
- //Method: Call APi to Fetch New Notification Count
4011
- getEventwiseNotification() {
4012
- this.refreshNotification.emit(true);
4013
- }
4014
- }
4015
- NotificationSidebarComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: NotificationSidebarComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
4016
- NotificationSidebarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: NotificationSidebarComponent, selector: "app-notification-sidebar", inputs: { userNotificationCount: "userNotificationCount", userNotificationCountObj: "userNotificationCountObj", eventwiseNotificationCount: "eventwiseNotificationCount", isErrorOccured: "isErrorOccured", notificationLoadder: "notificationLoadder" }, outputs: { refreshNotification: "refreshNotification" }, ngImport: i0, template: "<div class=\"modal fade common-alert-modal\" id=\"Notify_SidebarModal\" tabindex=\"-1\" aria-hidden=\"true\">\r\n <div class=\"sidebar-container white-bg\">\r\n <div class=\"modal-dialog sidebar-outer white-bg\">\r\n <div class=\"sidebar-header grey-background\">\r\n <div class=\"sh-top\">\r\n <div class=\"sh-top-left d-flex align-items-center\">\r\n <div class=\"mx-2 log-text\">Notification</div>\r\n </div>\r\n <div class=\"sh-top-right\">\r\n <button type=\"button\" class=\"common-bn tertiary-btn\" data-bs-dismiss=\"modal\" aria-label=\"Close\">\r\n <img src=\"assets/common-header-lib/images/close.svg\" alt=\"Icon\" class=\"imgs mb-1\" title=\"Close\">\r\n </button>\r\n </div>\r\n </div>\r\n </div>\r\n <div class=\"sidebar-body\">\r\n <div class=\"d-flex justify-content-between align-items-center mb-2\">\r\n <div class=\"noti-text\">You Have {{userNotificationCount}} Notification</div>\r\n <div class=\"d-flex align-items-center gap-1 refresh-icon\" (click)=\"getEventwiseNotification()\">\r\n <img src=\"assets/common-header-lib/images/refresh-1.svg\" alt=\"Icon\">\r\n <div class=\"refresh-text\">Refresh</div>\r\n </div>\r\n </div>\r\n\r\n <div class=\"mt-3\">\r\n <ng-container *ngIf=\"!isErrorOccured && !notificationLoadder; else LoadingTemplate\">\r\n <div class=\"notify-border\" *ngFor=\"let event of eventwiseNotificationCount\">\r\n <div class=\"d-flex align-items-center gap-3\">\r\n <div class=\"initial-text mx-1\">\r\n <img src=\"assets/common-header-lib/images/noti_ticket.svg\" alt=\"Icon\">\r\n </div>\r\n <div>\r\n <div><span class=\"service-count\">{{event['PendingCount']}} New </span><span\r\n class=\"service-request\">{{event['EventName'] }} Event requests</span>\r\n </div>\r\n <!-- <div class=\"time-text\">{{'2h ago'}}</div> -->\r\n </div>\r\n </div>\r\n <div class=\"grey-borders mt-2\"></div>\r\n </div>\r\n </ng-container>\r\n <ng-template #LoadingTemplate>\r\n <ng-container *ngIf=\"notificationLoadder; else errorTemplate\">\r\n <ng-container *ngFor=\"let item of repeatLoader\">\r\n <div class=\"d-flex align-items-center gap-3\">\r\n <p-skeleton shape=\"circle\" size=\"60px\" styleClass=\"my-2\"></p-skeleton>\r\n <div class=\"ms-1\">\r\n <p-skeleton width=\"200%\" styleClass=\"mb-2\"></p-skeleton>\r\n <p-skeleton width=\"150px\" height=\"1rem\"></p-skeleton>\r\n </div>\r\n </div>\r\n </ng-container>\r\n </ng-container>\r\n </ng-template>\r\n <ng-template #errorTemplate>\r\n <app-no-service-my-access-pg [heading]=\"NoServiceMsgText\"></app-no-service-my-access-pg>\r\n </ng-template>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n</div>\r\n", styles: [".grey-background{background-color:#f6f7fb}.white-bg{background:#ffffff;width:420px;overflow:hidden}.log-text{font-size:16px;color:#292f4c;font-weight:600}.imgs{width:20px}.sidebar-body{overflow:auto;height:calc(100vh - 70px);width:100%}.sidebar-body .noti-text{color:#292f4c;font-size:13px;font-weight:600;line-height:24px}.sidebar-body .refresh-icon{cursor:pointer}.sidebar-body .refresh-text{color:#676879;font-size:12px;line-height:24px}.sidebar-body .notify-border{padding:8px 8px 0 6px;cursor:pointer}.sidebar-body .notify-border:hover{background-color:#dcdfec;border-radius:8px}.sidebar-body .notify-border .initial-text{width:40px;height:40px;display:flex;align-items:center;justify-content:center;font-size:11px;border-radius:50%;color:var(--white-color);background-color:#f2edfa}.sidebar-body .notify-border .service-count{color:#323238;font-weight:600;font-size:13px}.sidebar-body .notify-border .service-request{color:#676879;font-size:12px;font-weight:500}.sidebar-body .notify-border .time-text{color:#676879;font-size:12px}.sidebar-body .notify-border .grey-borders{border-bottom:1px solid var(--layout-border)}\n"], dependencies: [{ kind: "directive", type: i6.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i6.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i9$1.Skeleton, selector: "p-skeleton", inputs: ["styleClass", "style", "shape", "animation", "borderRadius", "size", "width", "height"] }, { kind: "component", type: NoServiceMyAccessPgComponent, selector: "app-no-service-my-access-pg", inputs: ["heading", "subHeading"] }] });
4017
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: NotificationSidebarComponent, decorators: [{
4018
- type: Component,
4019
- args: [{ selector: 'app-notification-sidebar', template: "<div class=\"modal fade common-alert-modal\" id=\"Notify_SidebarModal\" tabindex=\"-1\" aria-hidden=\"true\">\r\n <div class=\"sidebar-container white-bg\">\r\n <div class=\"modal-dialog sidebar-outer white-bg\">\r\n <div class=\"sidebar-header grey-background\">\r\n <div class=\"sh-top\">\r\n <div class=\"sh-top-left d-flex align-items-center\">\r\n <div class=\"mx-2 log-text\">Notification</div>\r\n </div>\r\n <div class=\"sh-top-right\">\r\n <button type=\"button\" class=\"common-bn tertiary-btn\" data-bs-dismiss=\"modal\" aria-label=\"Close\">\r\n <img src=\"assets/common-header-lib/images/close.svg\" alt=\"Icon\" class=\"imgs mb-1\" title=\"Close\">\r\n </button>\r\n </div>\r\n </div>\r\n </div>\r\n <div class=\"sidebar-body\">\r\n <div class=\"d-flex justify-content-between align-items-center mb-2\">\r\n <div class=\"noti-text\">You Have {{userNotificationCount}} Notification</div>\r\n <div class=\"d-flex align-items-center gap-1 refresh-icon\" (click)=\"getEventwiseNotification()\">\r\n <img src=\"assets/common-header-lib/images/refresh-1.svg\" alt=\"Icon\">\r\n <div class=\"refresh-text\">Refresh</div>\r\n </div>\r\n </div>\r\n\r\n <div class=\"mt-3\">\r\n <ng-container *ngIf=\"!isErrorOccured && !notificationLoadder; else LoadingTemplate\">\r\n <div class=\"notify-border\" *ngFor=\"let event of eventwiseNotificationCount\">\r\n <div class=\"d-flex align-items-center gap-3\">\r\n <div class=\"initial-text mx-1\">\r\n <img src=\"assets/common-header-lib/images/noti_ticket.svg\" alt=\"Icon\">\r\n </div>\r\n <div>\r\n <div><span class=\"service-count\">{{event['PendingCount']}} New </span><span\r\n class=\"service-request\">{{event['EventName'] }} Event requests</span>\r\n </div>\r\n <!-- <div class=\"time-text\">{{'2h ago'}}</div> -->\r\n </div>\r\n </div>\r\n <div class=\"grey-borders mt-2\"></div>\r\n </div>\r\n </ng-container>\r\n <ng-template #LoadingTemplate>\r\n <ng-container *ngIf=\"notificationLoadder; else errorTemplate\">\r\n <ng-container *ngFor=\"let item of repeatLoader\">\r\n <div class=\"d-flex align-items-center gap-3\">\r\n <p-skeleton shape=\"circle\" size=\"60px\" styleClass=\"my-2\"></p-skeleton>\r\n <div class=\"ms-1\">\r\n <p-skeleton width=\"200%\" styleClass=\"mb-2\"></p-skeleton>\r\n <p-skeleton width=\"150px\" height=\"1rem\"></p-skeleton>\r\n </div>\r\n </div>\r\n </ng-container>\r\n </ng-container>\r\n </ng-template>\r\n <ng-template #errorTemplate>\r\n <app-no-service-my-access-pg [heading]=\"NoServiceMsgText\"></app-no-service-my-access-pg>\r\n </ng-template>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n</div>\r\n", styles: [".grey-background{background-color:#f6f7fb}.white-bg{background:#ffffff;width:420px;overflow:hidden}.log-text{font-size:16px;color:#292f4c;font-weight:600}.imgs{width:20px}.sidebar-body{overflow:auto;height:calc(100vh - 70px);width:100%}.sidebar-body .noti-text{color:#292f4c;font-size:13px;font-weight:600;line-height:24px}.sidebar-body .refresh-icon{cursor:pointer}.sidebar-body .refresh-text{color:#676879;font-size:12px;line-height:24px}.sidebar-body .notify-border{padding:8px 8px 0 6px;cursor:pointer}.sidebar-body .notify-border:hover{background-color:#dcdfec;border-radius:8px}.sidebar-body .notify-border .initial-text{width:40px;height:40px;display:flex;align-items:center;justify-content:center;font-size:11px;border-radius:50%;color:var(--white-color);background-color:#f2edfa}.sidebar-body .notify-border .service-count{color:#323238;font-weight:600;font-size:13px}.sidebar-body .notify-border .service-request{color:#676879;font-size:12px;font-weight:500}.sidebar-body .notify-border .time-text{color:#676879;font-size:12px}.sidebar-body .notify-border .grey-borders{border-bottom:1px solid var(--layout-border)}\n"] }]
4020
- }], ctorParameters: function () { return []; }, propDecorators: { userNotificationCount: [{
4021
- type: Input
4022
- }], userNotificationCountObj: [{
4023
- type: Input
4024
- }], eventwiseNotificationCount: [{
4025
- type: Input
4026
- }], refreshNotification: [{
4027
- type: Output
4028
- }], isErrorOccured: [{
4029
- type: Input
4030
- }], notificationLoadder: [{
4031
- type: Input
4032
- }] } });
4033
-
4034
- /**
4035
- * Common header library module.
4036
- *
4037
- * Translation initialization (APP_INITIALIZER, languages.json validation,
4038
- * fallback chain, language-file loading) is OWNED BY THE CONSUMING APP —
4039
- * see `initTranslateService` and `HttpLoaderFactory` in src/app/app.module.ts
4040
- * (test/dev host) and the equivalent code in your main project's MainModule.
4041
- *
4042
- * The library only imports/exports `TranslateModule` (no `forChild({ isolate })`)
4043
- * so its components share the host app's TranslateService singleton. This
4044
- * guarantees that when the host changes language, library labels translate
4045
- * accordingly.
4046
- *
4047
- * The supported-language list (USERFILTEREDLANGUAGES) is provided by the
4048
- * host app via the `[languages]` @Input on `<lib-common-header-lib>`, which
4049
- * forwards it down to `<ng-translation>`. The library no longer fetches
4050
- * languages.json itself.
4051
- */
4052
- class CommonHeaderLibModule {
4053
- }
4054
- CommonHeaderLibModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: CommonHeaderLibModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
4055
- CommonHeaderLibModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.3.0", ngImport: i0, type: CommonHeaderLibModule, declarations: [CommonHeaderLibComponent,
4056
- SliceToTwoPipe,
4057
- customDateFormatPipe,
4058
- DateDiffPipe,
4059
- UserSidebarComponent,
4060
- SidePopupComponent,
4061
- NgTranslationComponent,
4062
- UserMailboxComponent,
4063
- NotificationSidebarComponent,
4064
- GeneralConfigurationComponent,
4065
- TimezoneConfigurationComponent,
4066
- LandingpgConfigComponent,
4067
- NoServiceMyAccessPgComponent,
4068
- GridPaginationComponent,
4069
- ConfirmDialogComponent,
4070
- ViewpasswordPopupComponent], imports: [CommonModule,
4071
- HttpClientModule,
4072
- ReactiveFormsModule,
4073
- /* UI Modules */
4074
- InputTextModule,
4075
- DropdownModule,
4076
- OverlayPanelModule,
4077
- BadgeModule,
4078
- DialogModule,
4079
- SkeletonModule,
4080
- PaginatorModule,
4081
- TableModule,
4082
- ButtonModule,
4083
- ConfirmDialogModule,
4084
- NgbModule,
4085
- /* Share the host app's TranslateService instance — DO NOT use
4086
- forChild({ isolate: true }) here, otherwise library components would
4087
- receive a separate TranslateService and host language changes would
4088
- not propagate to library labels. */
4089
- TranslateModule], exports: [CommonHeaderLibComponent,
4090
- SliceToTwoPipe,
4091
- DateDiffPipe,
4092
- customDateFormatPipe,
4093
- ConfirmDialogComponent,
4094
- ViewpasswordPopupComponent,
4095
- TranslateModule] });
4096
- CommonHeaderLibModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: CommonHeaderLibModule, imports: [CommonModule,
4097
- HttpClientModule,
4098
- ReactiveFormsModule,
4099
- /* UI Modules */
4100
- InputTextModule,
4101
- DropdownModule,
4102
- OverlayPanelModule,
4103
- BadgeModule,
4104
- DialogModule,
4105
- SkeletonModule,
4106
- PaginatorModule,
4107
- TableModule,
4108
- ButtonModule,
4109
- ConfirmDialogModule,
4110
- NgbModule,
4111
- /* Share the host app's TranslateService instance — DO NOT use
4112
- forChild({ isolate: true }) here, otherwise library components would
4113
- receive a separate TranslateService and host language changes would
4114
- not propagate to library labels. */
4115
- TranslateModule, TranslateModule] });
4116
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: CommonHeaderLibModule, decorators: [{
4117
- type: NgModule,
4118
- args: [{
4119
- declarations: [
4120
- CommonHeaderLibComponent,
4121
- SliceToTwoPipe,
4122
- customDateFormatPipe,
4123
- DateDiffPipe,
4124
- UserSidebarComponent,
4125
- SidePopupComponent,
4126
- NgTranslationComponent,
4127
- UserMailboxComponent,
4128
- NotificationSidebarComponent,
4129
- GeneralConfigurationComponent,
4130
- TimezoneConfigurationComponent,
4131
- LandingpgConfigComponent,
4132
- NoServiceMyAccessPgComponent,
4133
- GridPaginationComponent,
4134
- ConfirmDialogComponent,
4135
- ViewpasswordPopupComponent,
4136
- ],
4137
- imports: [
4138
- CommonModule,
4139
- HttpClientModule,
4140
- ReactiveFormsModule,
4141
- /* UI Modules */
4142
- InputTextModule,
4143
- DropdownModule,
4144
- OverlayPanelModule,
4145
- BadgeModule,
4146
- DialogModule,
4147
- SkeletonModule,
4148
- PaginatorModule,
4149
- TableModule,
4150
- ButtonModule,
4151
- ConfirmDialogModule,
4152
- NgbModule,
4153
- /* Share the host app's TranslateService instance — DO NOT use
4154
- forChild({ isolate: true }) here, otherwise library components would
4155
- receive a separate TranslateService and host language changes would
4156
- not propagate to library labels. */
4157
- TranslateModule,
4158
- ],
4159
- exports: [
4160
- CommonHeaderLibComponent,
4161
- SliceToTwoPipe,
4162
- DateDiffPipe,
4163
- customDateFormatPipe,
4164
- ConfirmDialogComponent,
4165
- ViewpasswordPopupComponent,
4166
- TranslateModule,
4167
- ],
4168
- providers: [],
4169
- }]
4170
- }] });
4171
-
4172
- /*
4173
- * Public API Surface of common-header-lib
4174
- */
4175
- // export * from './assets/js/bigint-decrypt.helper';
4176
-
4177
- /**
4178
- * Generated bundle index. Do not edit.
4179
- */
4180
-
4181
- export { CommonHeaderLibComponent, CommonHeaderLibModule, CommonHeaderLibService, ConfirmDialogComponent, DateDiffPipe, SliceToTwoPipe, ViewpasswordPopupComponent, customDateFormatPipe };
4182
- //# sourceMappingURL=common-header-lib.mjs.map