@flusys/ng-auth 5.4.1 → 5.5.0
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.
- package/fesm2022/flusys-ng-auth.mjs +1034 -632
- package/fesm2022/flusys-ng-auth.mjs.map +1 -1
- package/package.json +11 -10
- package/types/flusys-ng-auth.d.ts +12 -10
|
@@ -3,7 +3,7 @@ import * as i0 from '@angular/core';
|
|
|
3
3
|
import { inject, Injectable, signal, computed, effect, PLATFORM_ID, InjectionToken, Component, untracked, viewChild, DestroyRef, input, Injector, output, resource, makeStateKey, TransferState } from '@angular/core';
|
|
4
4
|
import { APP_CONFIG, getServiceUrl, isCompanyFeatureEnabled, isServiceEnabled, isSignUpEnabled, getPermissionMode, getDefaultCompanySlug, getDefaultBranchSlug } from '@flusys/ng-core';
|
|
5
5
|
import { of, timeout, switchMap, map, tap, catchError, shareReplay, finalize, BehaviorSubject, throwError, filter, take, from, forkJoin, firstValueFrom } from 'rxjs';
|
|
6
|
-
import * as i2
|
|
6
|
+
import * as i2 from '@angular/router';
|
|
7
7
|
import { Router, RouterOutlet, RouterLink, RouterLinkActive, ActivatedRoute } from '@angular/router';
|
|
8
8
|
import { PlatformService, TranslateService, ApiResourceService, CookieService, resolveTranslationModule, SHARED_MESSAGES, permissionGuard, USER_PERMISSIONS, COMPANY_PERMISSIONS, BRANCH_PERMISSIONS, USER_PROVIDER, COMPANY_API_PROVIDER, USER_PERMISSION_PROVIDER, AUTH_STATE_PROVIDER, PermissionValidatorService, TranslatePipe, AngularModule, PrimeModule, HasPermissionDirective, BaseFormComponent, BaseListComponent, BaseListTemplateDirective, FileUrlService, FILE_PROVIDER, PROFILE_PERMISSION_PROVIDER, FileUploaderComponent } from '@flusys/ng-shared';
|
|
9
9
|
import { map as map$1, catchError as catchError$1, tap as tap$1 } from 'rxjs/operators';
|
|
@@ -14,23 +14,25 @@ import { LAYOUT_AUTH_STATE, LAYOUT_AUTH_API, AppFloatingConfigurator } from '@fl
|
|
|
14
14
|
import { toSignal, takeUntilDestroyed } from '@angular/core/rxjs-interop';
|
|
15
15
|
import { form, required, FormField, email, minLength } from '@angular/forms/signals';
|
|
16
16
|
import * as i1 from '@angular/forms';
|
|
17
|
-
import * as
|
|
18
|
-
import * as i3 from 'primeng/card';
|
|
17
|
+
import * as i3 from 'primeng/button';
|
|
18
|
+
import * as i3$1 from 'primeng/card';
|
|
19
19
|
import * as i4 from 'primeng/inputtext';
|
|
20
20
|
import * as i6 from 'primeng/tag';
|
|
21
21
|
import { TagModule } from 'primeng/tag';
|
|
22
22
|
import * as i4$1 from 'primeng/select';
|
|
23
23
|
import * as i5 from 'primeng/table';
|
|
24
24
|
import * as i7 from 'primeng/tooltip';
|
|
25
|
-
import * as i3$
|
|
26
|
-
import * as
|
|
27
|
-
import * as
|
|
28
|
-
import * as
|
|
25
|
+
import * as i3$2 from 'primeng/avatar';
|
|
26
|
+
import * as i5$1 from 'primeng/iconfield';
|
|
27
|
+
import * as i6$1 from 'primeng/inputicon';
|
|
28
|
+
import * as i7$1 from 'primeng/inputpassword';
|
|
29
|
+
import * as i9 from 'primeng/skeleton';
|
|
30
|
+
import * as i11 from 'primeng/textarea';
|
|
29
31
|
import * as i4$2 from 'primeng/dialog';
|
|
30
32
|
import { DialogModule } from 'primeng/dialog';
|
|
31
33
|
import * as i6$2 from 'primeng/progressspinner';
|
|
32
34
|
import { ProgressSpinnerModule } from 'primeng/progressspinner';
|
|
33
|
-
import * as i3$
|
|
35
|
+
import * as i3$3 from 'primeng/checkbox';
|
|
34
36
|
|
|
35
37
|
// ─── Type guards ───────────────────────────────────────────────────────────────
|
|
36
38
|
function isEmailVerificationRequired(response) {
|
|
@@ -86,10 +88,10 @@ class AuthApiService {
|
|
|
86
88
|
verifyEmail(token) {
|
|
87
89
|
return this.http.post(`${this.baseUrl}/verify-email`, { token });
|
|
88
90
|
}
|
|
89
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
90
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
91
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: AuthApiService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
92
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: AuthApiService, providedIn: 'root' });
|
|
91
93
|
}
|
|
92
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
94
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: AuthApiService, decorators: [{
|
|
93
95
|
type: Injectable,
|
|
94
96
|
args: [{ providedIn: 'root' }]
|
|
95
97
|
}], ctorParameters: () => [] });
|
|
@@ -117,27 +119,39 @@ class AuthStateService {
|
|
|
117
119
|
optional: true,
|
|
118
120
|
});
|
|
119
121
|
// Core State (private writable, public readonly)
|
|
120
|
-
_user = signal(null,
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
122
|
+
_user = signal(null, /* @ts-ignore */
|
|
123
|
+
...(ngDevMode ? [{ debugName: "_user" }] : /* istanbul ignore next */ []));
|
|
124
|
+
_accessToken = signal('', /* @ts-ignore */
|
|
125
|
+
...(ngDevMode ? [{ debugName: "_accessToken" }] : /* istanbul ignore next */ [])); // Memory-only, not persisted
|
|
126
|
+
_tokenExpiresAt = signal(null, /* @ts-ignore */
|
|
127
|
+
...(ngDevMode ? [{ debugName: "_tokenExpiresAt" }] : /* istanbul ignore next */ [])); // Token expiry timestamp
|
|
128
|
+
_company = signal(null, /* @ts-ignore */
|
|
129
|
+
...(ngDevMode ? [{ debugName: "_company" }] : /* istanbul ignore next */ []));
|
|
130
|
+
_branch = signal(null, /* @ts-ignore */
|
|
131
|
+
...(ngDevMode ? [{ debugName: "_branch" }] : /* istanbul ignore next */ []));
|
|
125
132
|
user = this._user.asReadonly();
|
|
126
133
|
accessToken = this._accessToken.asReadonly();
|
|
127
134
|
tokenExpiresAt = this._tokenExpiresAt.asReadonly();
|
|
128
135
|
company = this._company.asReadonly();
|
|
129
136
|
branch = this._branch.asReadonly();
|
|
130
137
|
// Company Selection State (temporary during login flow)
|
|
131
|
-
_selectionSessionId = signal(null,
|
|
132
|
-
|
|
138
|
+
_selectionSessionId = signal(null, /* @ts-ignore */
|
|
139
|
+
...(ngDevMode ? [{ debugName: "_selectionSessionId" }] : /* istanbul ignore next */ []));
|
|
140
|
+
_availableCompanies = signal([], /* @ts-ignore */
|
|
141
|
+
...(ngDevMode ? [{ debugName: "_availableCompanies" }] : /* istanbul ignore next */ []));
|
|
133
142
|
selectionSessionId = this._selectionSessionId.asReadonly();
|
|
134
143
|
availableCompanies = this._availableCompanies.asReadonly();
|
|
135
144
|
// Computed States
|
|
136
|
-
isAuthenticated = computed(() => !!this._accessToken() && !!this._user(),
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
145
|
+
isAuthenticated = computed(() => !!this._accessToken() && !!this._user(), /* @ts-ignore */
|
|
146
|
+
...(ngDevMode ? [{ debugName: "isAuthenticated" }] : /* istanbul ignore next */ []));
|
|
147
|
+
requiresCompanySelection = computed(() => !!this._selectionSessionId() && this._availableCompanies().length > 0, /* @ts-ignore */
|
|
148
|
+
...(ngDevMode ? [{ debugName: "requiresCompanySelection" }] : /* istanbul ignore next */ []));
|
|
149
|
+
userName = computed(() => this._user()?.name ?? 'User', /* @ts-ignore */
|
|
150
|
+
...(ngDevMode ? [{ debugName: "userName" }] : /* istanbul ignore next */ []));
|
|
151
|
+
companyName = computed(() => this._company()?.name ?? '', /* @ts-ignore */
|
|
152
|
+
...(ngDevMode ? [{ debugName: "companyName" }] : /* istanbul ignore next */ []));
|
|
153
|
+
branchName = computed(() => this._branch()?.name ?? '', /* @ts-ignore */
|
|
154
|
+
...(ngDevMode ? [{ debugName: "branchName" }] : /* istanbul ignore next */ []));
|
|
141
155
|
/**
|
|
142
156
|
* Check if token is expired or will expire soon (within 30 seconds).
|
|
143
157
|
* Used to proactively refresh token before requests fail.
|
|
@@ -148,9 +162,11 @@ class AuthStateService {
|
|
|
148
162
|
return true;
|
|
149
163
|
// Consider expired 30 seconds before actual expiry
|
|
150
164
|
return Date.now() >= expiresAt - 30000;
|
|
151
|
-
},
|
|
165
|
+
}, /* @ts-ignore */
|
|
166
|
+
...(ngDevMode ? [{ debugName: "isTokenExpired" }] : /* istanbul ignore next */ []));
|
|
152
167
|
// Config-derived states
|
|
153
|
-
tenantId = computed(() => this.appConfig.multiTenant.tenantId ?? null,
|
|
168
|
+
tenantId = computed(() => this.appConfig.multiTenant.tenantId ?? null, /* @ts-ignore */
|
|
169
|
+
...(ngDevMode ? [{ debugName: "tenantId" }] : /* istanbul ignore next */ []));
|
|
154
170
|
constructor() {
|
|
155
171
|
// Auto-persist token expiry (NOT the token itself - security)
|
|
156
172
|
effect(() => {
|
|
@@ -288,10 +304,10 @@ class AuthStateService {
|
|
|
288
304
|
if (!this.platform.isServer)
|
|
289
305
|
localStorage.removeItem(key);
|
|
290
306
|
}
|
|
291
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
292
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
307
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: AuthStateService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
308
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: AuthStateService, providedIn: 'root' });
|
|
293
309
|
}
|
|
294
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
310
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: AuthStateService, decorators: [{
|
|
295
311
|
type: Injectable,
|
|
296
312
|
args: [{ providedIn: 'root' }]
|
|
297
313
|
}], ctorParameters: () => [] });
|
|
@@ -300,7 +316,8 @@ class AuthInitService {
|
|
|
300
316
|
authState = inject(AuthStateService);
|
|
301
317
|
authApi = inject(AuthApiService);
|
|
302
318
|
appConfig = inject(APP_CONFIG);
|
|
303
|
-
_initialized = signal(false,
|
|
319
|
+
_initialized = signal(false, /* @ts-ignore */
|
|
320
|
+
...(ngDevMode ? [{ debugName: "_initialized" }] : /* istanbul ignore next */ []));
|
|
304
321
|
initialized = this._initialized.asReadonly();
|
|
305
322
|
initializationCache$ = null;
|
|
306
323
|
initialize() {
|
|
@@ -358,10 +375,10 @@ class AuthInitService {
|
|
|
358
375
|
}));
|
|
359
376
|
return this.initializationCache$;
|
|
360
377
|
}
|
|
361
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
362
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
378
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: AuthInitService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
379
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: AuthInitService, providedIn: 'root' });
|
|
363
380
|
}
|
|
364
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
381
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: AuthInitService, decorators: [{
|
|
365
382
|
type: Injectable,
|
|
366
383
|
args: [{ providedIn: 'root' }]
|
|
367
384
|
}] });
|
|
@@ -377,10 +394,10 @@ class BranchApiService extends ApiResourceService {
|
|
|
377
394
|
fetchByCompany(companyId, search = '') {
|
|
378
395
|
this.fetchList(search, { filter: { companyId } });
|
|
379
396
|
}
|
|
380
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
381
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
397
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: BranchApiService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
398
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: BranchApiService, providedIn: 'root' });
|
|
382
399
|
}
|
|
383
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
400
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: BranchApiService, decorators: [{
|
|
384
401
|
type: Injectable,
|
|
385
402
|
args: [{ providedIn: 'root' }]
|
|
386
403
|
}], ctorParameters: () => [] });
|
|
@@ -393,10 +410,10 @@ class CompanyApiService extends ApiResourceService {
|
|
|
393
410
|
constructor() {
|
|
394
411
|
super('company', 'administration');
|
|
395
412
|
}
|
|
396
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
397
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
413
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: CompanyApiService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
414
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: CompanyApiService, providedIn: 'root' });
|
|
398
415
|
}
|
|
399
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
416
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: CompanyApiService, decorators: [{
|
|
400
417
|
type: Injectable,
|
|
401
418
|
args: [{ providedIn: 'root' }]
|
|
402
419
|
}], ctorParameters: () => [] });
|
|
@@ -407,7 +424,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.5", ngImpor
|
|
|
407
424
|
* Uses BehaviorSubject for RxJS interop (multi-subscriber async coordination).
|
|
408
425
|
*/
|
|
409
426
|
class TokenRefreshStateService {
|
|
410
|
-
_isRefreshing = signal(false,
|
|
427
|
+
_isRefreshing = signal(false, /* @ts-ignore */
|
|
428
|
+
...(ngDevMode ? [{ debugName: "_isRefreshing" }] : /* istanbul ignore next */ []));
|
|
411
429
|
isRefreshing = this._isRefreshing.asReadonly();
|
|
412
430
|
_refreshTokenSubject = new BehaviorSubject(null);
|
|
413
431
|
refreshTokenSubject$ = this._refreshTokenSubject.asObservable();
|
|
@@ -422,10 +440,10 @@ class TokenRefreshStateService {
|
|
|
422
440
|
failRefresh() {
|
|
423
441
|
this._isRefreshing.set(false);
|
|
424
442
|
}
|
|
425
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
426
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
443
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: TokenRefreshStateService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
444
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: TokenRefreshStateService, providedIn: 'root' });
|
|
427
445
|
}
|
|
428
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
446
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: TokenRefreshStateService, decorators: [{
|
|
429
447
|
type: Injectable,
|
|
430
448
|
args: [{ providedIn: 'root' }]
|
|
431
449
|
}] });
|
|
@@ -441,10 +459,10 @@ class UserApiService extends ApiResourceService {
|
|
|
441
459
|
updateProfile(data) {
|
|
442
460
|
return this.http.post(`${this.baseUrl}/profile`, data);
|
|
443
461
|
}
|
|
444
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
445
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
462
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: UserApiService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
463
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: UserApiService, providedIn: 'root' });
|
|
446
464
|
}
|
|
447
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
465
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: UserApiService, decorators: [{
|
|
448
466
|
type: Injectable,
|
|
449
467
|
args: [{ providedIn: 'root' }]
|
|
450
468
|
}], ctorParameters: () => [] });
|
|
@@ -487,10 +505,10 @@ class UserPermissionApiService {
|
|
|
487
505
|
...(companyId && { companyId }),
|
|
488
506
|
});
|
|
489
507
|
}
|
|
490
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
491
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
508
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: UserPermissionApiService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
509
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: UserPermissionApiService, providedIn: 'root' });
|
|
492
510
|
}
|
|
493
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
511
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: UserPermissionApiService, decorators: [{
|
|
494
512
|
type: Injectable,
|
|
495
513
|
args: [{ providedIn: 'root' }]
|
|
496
514
|
}] });
|
|
@@ -1167,7 +1185,8 @@ class AuthLayoutStateAdapter {
|
|
|
1167
1185
|
};
|
|
1168
1186
|
}
|
|
1169
1187
|
return null;
|
|
1170
|
-
},
|
|
1188
|
+
}, /* @ts-ignore */
|
|
1189
|
+
...(ngDevMode ? [{ debugName: "currentCompanyInfo" }] : /* istanbul ignore next */ []));
|
|
1171
1190
|
currentBranchInfo = computed(() => {
|
|
1172
1191
|
const branch = this.authState.branch();
|
|
1173
1192
|
if (branch) {
|
|
@@ -1179,7 +1198,8 @@ class AuthLayoutStateAdapter {
|
|
|
1179
1198
|
};
|
|
1180
1199
|
}
|
|
1181
1200
|
return null;
|
|
1182
|
-
},
|
|
1201
|
+
}, /* @ts-ignore */
|
|
1202
|
+
...(ngDevMode ? [{ debugName: "currentBranchInfo" }] : /* istanbul ignore next */ []));
|
|
1183
1203
|
loginUserData = computed(() => {
|
|
1184
1204
|
const user = this.authState.user();
|
|
1185
1205
|
if (user) {
|
|
@@ -1190,11 +1210,12 @@ class AuthLayoutStateAdapter {
|
|
|
1190
1210
|
};
|
|
1191
1211
|
}
|
|
1192
1212
|
return null;
|
|
1193
|
-
},
|
|
1194
|
-
|
|
1195
|
-
static
|
|
1213
|
+
}, /* @ts-ignore */
|
|
1214
|
+
...(ngDevMode ? [{ debugName: "loginUserData" }] : /* istanbul ignore next */ []));
|
|
1215
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: AuthLayoutStateAdapter, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
1216
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: AuthLayoutStateAdapter, providedIn: 'root' });
|
|
1196
1217
|
}
|
|
1197
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1218
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: AuthLayoutStateAdapter, decorators: [{
|
|
1198
1219
|
type: Injectable,
|
|
1199
1220
|
args: [{ providedIn: 'root' }]
|
|
1200
1221
|
}] });
|
|
@@ -1248,10 +1269,10 @@ class AuthLayoutApiAdapter {
|
|
|
1248
1269
|
slug: permission.branchSlug ?? '',
|
|
1249
1270
|
}))));
|
|
1250
1271
|
}
|
|
1251
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1252
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
1272
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: AuthLayoutApiAdapter, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
1273
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: AuthLayoutApiAdapter, providedIn: 'root' });
|
|
1253
1274
|
}
|
|
1254
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1275
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: AuthLayoutApiAdapter, decorators: [{
|
|
1255
1276
|
type: Injectable,
|
|
1256
1277
|
args: [{ providedIn: 'root' }]
|
|
1257
1278
|
}] });
|
|
@@ -1300,10 +1321,10 @@ class AuthUserProviderAdapter {
|
|
|
1300
1321
|
meta: response.meta,
|
|
1301
1322
|
})));
|
|
1302
1323
|
}
|
|
1303
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1304
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
1324
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: AuthUserProviderAdapter, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
1325
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: AuthUserProviderAdapter });
|
|
1305
1326
|
}
|
|
1306
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1327
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: AuthUserProviderAdapter, decorators: [{
|
|
1307
1328
|
type: Injectable
|
|
1308
1329
|
}] });
|
|
1309
1330
|
// =============================================================================
|
|
@@ -1332,10 +1353,10 @@ class AuthCompanyApiProviderAdapter {
|
|
|
1332
1353
|
meta: response.meta,
|
|
1333
1354
|
})));
|
|
1334
1355
|
}
|
|
1335
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1336
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
1356
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: AuthCompanyApiProviderAdapter, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
1357
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: AuthCompanyApiProviderAdapter });
|
|
1337
1358
|
}
|
|
1338
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1359
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: AuthCompanyApiProviderAdapter, decorators: [{
|
|
1339
1360
|
type: Injectable
|
|
1340
1361
|
}] });
|
|
1341
1362
|
// =============================================================================
|
|
@@ -1346,10 +1367,10 @@ class AuthUserPermissionProviderAdapter {
|
|
|
1346
1367
|
getUserBranchPermissions(userId, companyId) {
|
|
1347
1368
|
return this.userPermissionApi.getUserBranches(userId, companyId);
|
|
1348
1369
|
}
|
|
1349
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1350
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
1370
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: AuthUserPermissionProviderAdapter, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
1371
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: AuthUserPermissionProviderAdapter });
|
|
1351
1372
|
}
|
|
1352
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1373
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: AuthUserPermissionProviderAdapter, decorators: [{
|
|
1353
1374
|
type: Injectable
|
|
1354
1375
|
}] });
|
|
1355
1376
|
// =============================================================================
|
|
@@ -1364,10 +1385,10 @@ class AuthStateProviderAdapter {
|
|
|
1364
1385
|
initialize() {
|
|
1365
1386
|
return this.authInit.initialize().pipe(map(() => undefined));
|
|
1366
1387
|
}
|
|
1367
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1368
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
1388
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: AuthStateProviderAdapter, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
1389
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: AuthStateProviderAdapter });
|
|
1369
1390
|
}
|
|
1370
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1391
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: AuthStateProviderAdapter, decorators: [{
|
|
1371
1392
|
type: Injectable
|
|
1372
1393
|
}] });
|
|
1373
1394
|
|
|
@@ -1474,7 +1495,8 @@ class AdministrationPageComponent {
|
|
|
1474
1495
|
},
|
|
1475
1496
|
];
|
|
1476
1497
|
/** Check if company feature is enabled */
|
|
1477
|
-
companyFeatureEnabled = computed(() => isCompanyFeatureEnabled(this.appConfig),
|
|
1498
|
+
companyFeatureEnabled = computed(() => isCompanyFeatureEnabled(this.appConfig), /* @ts-ignore */
|
|
1499
|
+
...(ngDevMode ? [{ debugName: "companyFeatureEnabled" }] : /* istanbul ignore next */ []));
|
|
1478
1500
|
/** Visible tabs based on config and permissions */
|
|
1479
1501
|
visibleTabs = computed(() => {
|
|
1480
1502
|
return this.allTabs.filter((tab) => {
|
|
@@ -1482,9 +1504,10 @@ class AdministrationPageComponent {
|
|
|
1482
1504
|
const hasPermission = this.permissionValidator.hasPermission(tab.permission);
|
|
1483
1505
|
return hasCompanyFeature && hasPermission;
|
|
1484
1506
|
});
|
|
1485
|
-
},
|
|
1486
|
-
|
|
1487
|
-
static
|
|
1507
|
+
}, /* @ts-ignore */
|
|
1508
|
+
...(ngDevMode ? [{ debugName: "visibleTabs" }] : /* istanbul ignore next */ []));
|
|
1509
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: AdministrationPageComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1510
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.5", type: AdministrationPageComponent, isStandalone: true, selector: "lib-administration-page", ngImport: i0, template: `
|
|
1488
1511
|
<div class="p-4">
|
|
1489
1512
|
<div class="mb-4">
|
|
1490
1513
|
<h1 class="text-2xl font-bold m-0">{{ 'administrative.title' | translate }}</h1>
|
|
@@ -1507,9 +1530,9 @@ class AdministrationPageComponent {
|
|
|
1507
1530
|
<router-outlet />
|
|
1508
1531
|
</div>
|
|
1509
1532
|
</div>
|
|
1510
|
-
`, isInline: true, styles: [".scrollbar-hide{-ms-overflow-style:none;scrollbar-width:none}.scrollbar-hide::-webkit-scrollbar{display:none}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: RouterOutlet, selector: "router-outlet", inputs: ["name", "routerOutletData"], outputs: ["activate", "deactivate", "attach", "detach"], exportAs: ["outlet"] }, { kind: "directive", type: RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "directive", type: RouterLinkActive, selector: "[routerLinkActive]", inputs: ["routerLinkActiveOptions", "ariaCurrentWhenActive", "routerLinkActive"], outputs: ["isActiveChange"], exportAs: ["routerLinkActive"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }] });
|
|
1533
|
+
`, isInline: true, styles: [".scrollbar-hide{-ms-overflow-style:none;scrollbar-width:none}.scrollbar-hide::-webkit-scrollbar{display:none}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: RouterOutlet, selector: "router-outlet", inputs: ["name", "routerOutletData"], outputs: ["activate", "deactivate", "attach", "detach"], exportAs: ["outlet"] }, { kind: "directive", type: RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "browserUrl", "routerLink"] }, { kind: "directive", type: RouterLinkActive, selector: "[routerLinkActive]", inputs: ["routerLinkActiveOptions", "ariaCurrentWhenActive", "routerLinkActive"], outputs: ["isActiveChange"], exportAs: ["routerLinkActive"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }] });
|
|
1511
1534
|
}
|
|
1512
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1535
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: AdministrationPageComponent, decorators: [{
|
|
1513
1536
|
type: Component,
|
|
1514
1537
|
args: [{ selector: 'lib-administration-page', imports: [CommonModule, RouterOutlet, RouterLink, RouterLinkActive, TranslatePipe], template: `
|
|
1515
1538
|
<div class="p-4">
|
|
@@ -1564,11 +1587,14 @@ class BranchFormComponent {
|
|
|
1564
1587
|
routeParams = toSignal(this.route.paramMap);
|
|
1565
1588
|
queryParams = toSignal(this.route.queryParamMap);
|
|
1566
1589
|
/** Loading state */
|
|
1567
|
-
isLoading = signal(false,
|
|
1590
|
+
isLoading = signal(false, /* @ts-ignore */
|
|
1591
|
+
...(ngDevMode ? [{ debugName: "isLoading" }] : /* istanbul ignore next */ []));
|
|
1568
1592
|
/** Existing branch data when editing */
|
|
1569
|
-
existingBranch = signal(null,
|
|
1593
|
+
existingBranch = signal(null, /* @ts-ignore */
|
|
1594
|
+
...(ngDevMode ? [{ debugName: "existingBranch" }] : /* istanbul ignore next */ []));
|
|
1570
1595
|
/** Whether in edit mode */
|
|
1571
|
-
isEditMode = computed(() => !!this.existingBranch(),
|
|
1596
|
+
isEditMode = computed(() => !!this.existingBranch(), /* @ts-ignore */
|
|
1597
|
+
...(ngDevMode ? [{ debugName: "isEditMode" }] : /* istanbul ignore next */ []));
|
|
1572
1598
|
/** Companies list for dropdown */
|
|
1573
1599
|
companies = this.companyService.data;
|
|
1574
1600
|
// ============================================
|
|
@@ -1583,7 +1609,8 @@ class BranchFormComponent {
|
|
|
1583
1609
|
phone: '',
|
|
1584
1610
|
address: '',
|
|
1585
1611
|
isActive: true,
|
|
1586
|
-
},
|
|
1612
|
+
}, /* @ts-ignore */
|
|
1613
|
+
...(ngDevMode ? [{ debugName: "formModel" }] : /* istanbul ignore next */ []));
|
|
1587
1614
|
/** Form with validation schema */
|
|
1588
1615
|
branchForm = form(this.formModel, (f) => {
|
|
1589
1616
|
required(f.companyId, {
|
|
@@ -1600,7 +1627,8 @@ class BranchFormComponent {
|
|
|
1600
1627
|
return (model.companyId.trim().length > 0 &&
|
|
1601
1628
|
model.name.trim().length > 0 &&
|
|
1602
1629
|
model.slug.trim().length > 0);
|
|
1603
|
-
},
|
|
1630
|
+
}, /* @ts-ignore */
|
|
1631
|
+
...(ngDevMode ? [{ debugName: "isFormValid" }] : /* istanbul ignore next */ []));
|
|
1604
1632
|
constructor() {
|
|
1605
1633
|
// Load companies on initialization
|
|
1606
1634
|
this.companyService.fetchList('', {
|
|
@@ -1743,8 +1771,8 @@ class BranchFormComponent {
|
|
|
1743
1771
|
onCancel() {
|
|
1744
1772
|
this.navigateToList();
|
|
1745
1773
|
}
|
|
1746
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1747
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "
|
|
1774
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: BranchFormComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1775
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.5", type: BranchFormComponent, isStandalone: true, selector: "lib-branch-form", ngImport: i0, template: `
|
|
1748
1776
|
<p-card>
|
|
1749
1777
|
<ng-template #header>
|
|
1750
1778
|
<div class="flex justify-between items-center p-4">
|
|
@@ -1861,28 +1889,34 @@ class BranchFormComponent {
|
|
|
1861
1889
|
|
|
1862
1890
|
<!-- Actions -->
|
|
1863
1891
|
<div class="flex justify-end gap-4 md:col-span-2 pt-4">
|
|
1864
|
-
<
|
|
1865
|
-
|
|
1892
|
+
<button
|
|
1893
|
+
pButton
|
|
1866
1894
|
severity="secondary"
|
|
1867
1895
|
[outlined]="true"
|
|
1868
|
-
(
|
|
1869
|
-
|
|
1870
|
-
|
|
1871
|
-
|
|
1896
|
+
(click)="onCancel()"
|
|
1897
|
+
>
|
|
1898
|
+
<span pButtonLabel>{{ 'shared.cancel' | translate }}</span>
|
|
1899
|
+
</button>
|
|
1900
|
+
<button
|
|
1901
|
+
pButton
|
|
1902
|
+
type="submit"
|
|
1903
|
+
[disabled]="!isFormValid() || isLoading()"
|
|
1904
|
+
>
|
|
1905
|
+
@if (isLoading()) {
|
|
1906
|
+
<span pButtonIcon class="pi pi-spinner pi-spin"></span>
|
|
1907
|
+
}
|
|
1908
|
+
<span pButtonLabel>{{
|
|
1872
1909
|
isEditMode()
|
|
1873
1910
|
? ('shared.update' | translate)
|
|
1874
1911
|
: ('shared.create' | translate)
|
|
1875
|
-
|
|
1876
|
-
|
|
1877
|
-
[loading]="isLoading()"
|
|
1878
|
-
[disabled]="!isFormValid() || isLoading()"
|
|
1879
|
-
/>
|
|
1912
|
+
}}</span>
|
|
1913
|
+
</button>
|
|
1880
1914
|
</div>
|
|
1881
1915
|
</form>
|
|
1882
1916
|
</p-card>
|
|
1883
|
-
`, isInline: true, dependencies: [{ kind: "ngmodule", type: AngularModule }, { kind: "directive", type: i1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.NgForm, selector: "form:not([ngNoForm]):not([formGroup]):not([formArray]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "ngmodule", type: PrimeModule }, { kind: "
|
|
1917
|
+
`, isInline: true, dependencies: [{ kind: "ngmodule", type: AngularModule }, { kind: "directive", type: i1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.NgForm, selector: "form:not([ngNoForm]):not([formGroup]):not([formArray]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "ngmodule", type: PrimeModule }, { kind: "directive", type: i3.ButtonDirective, selector: "[pButton]", inputs: ["pButton", "pButtonPT", "pButtonUnstyled", "hostName", "text", "plain", "raised", "size", "outlined", "link", "rounded", "fluid", "variant", "iconOnly", "loading", "severity"] }, { kind: "directive", type: i3.ButtonLabel, selector: "[pButtonLabel]", inputs: ["pButtonLabelPT", "pButtonLabelUnstyled"] }, { kind: "directive", type: i3.ButtonIcon, selector: "[pButtonIcon]", inputs: ["pButtonIconPT", "pButtonUnstyled"] }, { kind: "component", type: i3$1.Card, selector: "p-card", inputs: ["header", "subheader"] }, { kind: "directive", type: i4.InputText, selector: "[pInputText]", inputs: ["hostName", "pInputTextPT", "pInputTextUnstyled", "pSize", "variant", "fluid", "invalid"] }, { kind: "directive", type: FormField, selector: "[formField]", inputs: ["formField"], exportAs: ["formField"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }] });
|
|
1884
1918
|
}
|
|
1885
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1919
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: BranchFormComponent, decorators: [{
|
|
1886
1920
|
type: Component,
|
|
1887
1921
|
args: [{
|
|
1888
1922
|
selector: 'lib-branch-form',
|
|
@@ -2004,22 +2038,28 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.5", ngImpor
|
|
|
2004
2038
|
|
|
2005
2039
|
<!-- Actions -->
|
|
2006
2040
|
<div class="flex justify-end gap-4 md:col-span-2 pt-4">
|
|
2007
|
-
<
|
|
2008
|
-
|
|
2041
|
+
<button
|
|
2042
|
+
pButton
|
|
2009
2043
|
severity="secondary"
|
|
2010
2044
|
[outlined]="true"
|
|
2011
|
-
(
|
|
2012
|
-
|
|
2013
|
-
|
|
2014
|
-
|
|
2045
|
+
(click)="onCancel()"
|
|
2046
|
+
>
|
|
2047
|
+
<span pButtonLabel>{{ 'shared.cancel' | translate }}</span>
|
|
2048
|
+
</button>
|
|
2049
|
+
<button
|
|
2050
|
+
pButton
|
|
2051
|
+
type="submit"
|
|
2052
|
+
[disabled]="!isFormValid() || isLoading()"
|
|
2053
|
+
>
|
|
2054
|
+
@if (isLoading()) {
|
|
2055
|
+
<span pButtonIcon class="pi pi-spinner pi-spin"></span>
|
|
2056
|
+
}
|
|
2057
|
+
<span pButtonLabel>{{
|
|
2015
2058
|
isEditMode()
|
|
2016
2059
|
? ('shared.update' | translate)
|
|
2017
2060
|
: ('shared.create' | translate)
|
|
2018
|
-
|
|
2019
|
-
|
|
2020
|
-
[loading]="isLoading()"
|
|
2021
|
-
[disabled]="!isFormValid() || isLoading()"
|
|
2022
|
-
/>
|
|
2061
|
+
}}</span>
|
|
2062
|
+
</button>
|
|
2023
2063
|
</div>
|
|
2024
2064
|
</form>
|
|
2025
2065
|
</p-card>
|
|
@@ -2056,7 +2096,8 @@ class BranchListComponent {
|
|
|
2056
2096
|
queryParamMap = toSignal(this.route.queryParamMap);
|
|
2057
2097
|
initialized = false;
|
|
2058
2098
|
/** Selected company ID (signal for zoneless change detection) */
|
|
2059
|
-
selectedCompanyId = signal(null,
|
|
2099
|
+
selectedCompanyId = signal(null, /* @ts-ignore */
|
|
2100
|
+
...(ngDevMode ? [{ debugName: "selectedCompanyId" }] : /* istanbul ignore next */ []));
|
|
2060
2101
|
/** Companies list for dropdown */
|
|
2061
2102
|
companies = this.companyService.data;
|
|
2062
2103
|
/** Branches from service */
|
|
@@ -2146,8 +2187,8 @@ class BranchListComponent {
|
|
|
2146
2187
|
},
|
|
2147
2188
|
});
|
|
2148
2189
|
}
|
|
2149
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
2150
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "
|
|
2190
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: BranchListComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
2191
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.5", type: BranchListComponent, isStandalone: true, selector: "lib-branch-list", ngImport: i0, template: `
|
|
2151
2192
|
<p-card>
|
|
2152
2193
|
<ng-template #header>
|
|
2153
2194
|
<div
|
|
@@ -2173,13 +2214,15 @@ class BranchListComponent {
|
|
|
2173
2214
|
/>
|
|
2174
2215
|
}
|
|
2175
2216
|
</div>
|
|
2176
|
-
<
|
|
2217
|
+
<button
|
|
2218
|
+
pButton
|
|
2177
2219
|
*hasPermission="BRANCH_PERMISSIONS.CREATE"
|
|
2178
|
-
[label]="'administrative.branch.add' | translate"
|
|
2179
|
-
icon="pi pi-plus"
|
|
2180
2220
|
[disabled]="!selectedCompanyId()"
|
|
2181
|
-
(
|
|
2182
|
-
|
|
2221
|
+
(click)="onCreate()"
|
|
2222
|
+
>
|
|
2223
|
+
<span pButtonIcon class="pi pi-plus"></span>
|
|
2224
|
+
<span pButtonLabel>{{ 'administrative.branch.add' | translate }}</span>
|
|
2225
|
+
</button>
|
|
2183
2226
|
</div>
|
|
2184
2227
|
</ng-template>
|
|
2185
2228
|
|
|
@@ -2224,25 +2267,29 @@ class BranchListComponent {
|
|
|
2224
2267
|
</td>
|
|
2225
2268
|
<td>
|
|
2226
2269
|
<div class="flex gap-2">
|
|
2227
|
-
<
|
|
2270
|
+
<button
|
|
2271
|
+
pButton
|
|
2228
2272
|
*hasPermission="BRANCH_PERMISSIONS.UPDATE"
|
|
2229
|
-
icon="pi pi-pencil"
|
|
2230
2273
|
[rounded]="true"
|
|
2231
2274
|
[text]="true"
|
|
2232
2275
|
severity="info"
|
|
2233
2276
|
[pTooltip]="'shared.edit' | translate"
|
|
2234
|
-
(
|
|
2235
|
-
|
|
2277
|
+
(click)="onEdit(branch)"
|
|
2278
|
+
>
|
|
2279
|
+
<span pButtonIcon class="pi pi-pencil"></span>
|
|
2280
|
+
</button>
|
|
2236
2281
|
@if (!branch.readOnly) {
|
|
2237
|
-
<
|
|
2282
|
+
<button
|
|
2283
|
+
pButton
|
|
2238
2284
|
*hasPermission="BRANCH_PERMISSIONS.DELETE"
|
|
2239
|
-
icon="pi pi-trash"
|
|
2240
2285
|
[rounded]="true"
|
|
2241
2286
|
[text]="true"
|
|
2242
2287
|
severity="danger"
|
|
2243
2288
|
[pTooltip]="'shared.delete' | translate"
|
|
2244
|
-
(
|
|
2245
|
-
|
|
2289
|
+
(click)="onDelete(branch)"
|
|
2290
|
+
>
|
|
2291
|
+
<span pButtonIcon class="pi pi-trash"></span>
|
|
2292
|
+
</button>
|
|
2246
2293
|
}
|
|
2247
2294
|
</div>
|
|
2248
2295
|
</td>
|
|
@@ -2262,9 +2309,9 @@ class BranchListComponent {
|
|
|
2262
2309
|
</p-table>
|
|
2263
2310
|
</div>
|
|
2264
2311
|
</p-card>
|
|
2265
|
-
`, isInline: true, dependencies: [{ kind: "ngmodule", type: AngularModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: PrimeModule }, { kind: "
|
|
2312
|
+
`, isInline: true, dependencies: [{ kind: "ngmodule", type: AngularModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: PrimeModule }, { kind: "directive", type: i3.ButtonDirective, selector: "[pButton]", inputs: ["pButton", "pButtonPT", "pButtonUnstyled", "hostName", "text", "plain", "raised", "size", "outlined", "link", "rounded", "fluid", "variant", "iconOnly", "loading", "severity"] }, { kind: "directive", type: i3.ButtonLabel, selector: "[pButtonLabel]", inputs: ["pButtonLabelPT", "pButtonLabelUnstyled"] }, { kind: "directive", type: i3.ButtonIcon, selector: "[pButtonIcon]", inputs: ["pButtonIconPT", "pButtonUnstyled"] }, { kind: "component", type: i3$1.Card, selector: "p-card", inputs: ["header", "subheader"] }, { kind: "component", type: i4$1.Select, selector: "p-select", inputs: ["id", "scrollHeight", "filter", "panelStyle", "panelStyleClass", "readonly", "editable", "tabindex", "placeholder", "loadingIcon", "filterPlaceholder", "filterLocale", "inputId", "dataKey", "filterBy", "filterFields", "autofocus", "resetFilterOnHide", "checkmark", "dropdownIcon", "loading", "optionLabel", "optionValue", "optionDisabled", "optionGroupLabel", "optionGroupChildren", "group", "showClear", "emptyFilterMessage", "emptyMessage", "lazy", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "overlayOptions", "ariaFilterLabel", "ariaLabel", "ariaLabelledBy", "filterMatchMode", "tooltip", "tooltipPosition", "tooltipPositionStyle", "tooltipStyleClass", "focusOnHover", "selectOnFocus", "multiple", "autoOptionFocus", "autofocusFilter", "filterValue", "options", "appendTo", "motionOptions"], outputs: ["onChange", "onFilter", "onFocus", "onBlur", "onClick", "onShow", "onHide", "onClear", "onLazyLoad"] }, { kind: "component", type: i5.Table, selector: "p-table", inputs: ["frozenColumns", "frozenValue", "tableStyle", "tableStyleClass", "paginator", "pageLinks", "rowsPerPageOptions", "alwaysShowPaginator", "paginatorPosition", "paginatorStyleClass", "paginatorDropdownAppendTo", "paginatorDropdownScrollHeight", "currentPageReportTemplate", "showCurrentPageReport", "showJumpToPageDropdown", "showJumpToPageInput", "showFirstLastIcon", "showPageLinks", "defaultSortOrder", "sortMode", "resetPageOnSort", "selectionMode", "selectionPageOnly", "contextMenuSelection", "dataKey", "metaKeySelection", "rowSelectable", "rowTrackBy", "lazy", "lazyLoadOnInit", "compareSelectionBy", "csvSeparator", "exportFilename", "filters", "globalFilterFields", "filterDelay", "filterLocale", "expandedRowKeys", "editingRowKeys", "rowExpandMode", "scrollable", "rowGroupMode", "scrollHeight", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "virtualScrollDelay", "frozenWidth", "contextMenu", "resizableColumns", "columnResizeMode", "reorderableColumns", "loading", "loadingIcon", "showLoader", "rowHover", "customSort", "showInitialSortBadge", "exportFunction", "exportHeader", "stateKey", "stateStorage", "editMode", "groupRowsBy", "size", "showGridlines", "stripedRows", "groupRowsByOrder", "paginatorLocale", "value", "columns", "first", "rows", "totalRecords", "sortField", "sortOrder", "multiSortMeta", "selection", "selectAll"], outputs: ["contextMenuSelectionChange", "firstChange", "rowsChange", "totalRecordsChange", "selectionChange", "selectAllChange", "onRowSelect", "onRowUnselect", "onPage", "onSort", "onFilter", "onLazyLoad", "onRowExpand", "onRowCollapse", "onContextMenuSelect", "onColResize", "onColReorder", "onRowReorder", "onEditInit", "onEditComplete", "onEditCancel", "onHeaderCheckboxToggle", "sortFunction", "onStateSave", "onStateRestore"] }, { kind: "component", type: i6.Tag, selector: "p-tag", inputs: ["severity", "value", "icon", "rounded"] }, { kind: "directive", type: i7.Tooltip, selector: "[pTooltip]", inputs: ["tooltipPosition", "tooltipEvent", "positionStyle", "tooltipStyleClass", "tooltipZIndex", "escape", "showDelay", "hideDelay", "life", "positionTop", "positionLeft", "autoHide", "fitContent", "hideOnEscape", "showOnEllipsis", "pTooltip", "tooltipDisabled", "tooltipOptions", "appendTo", "pTooltipPT", "pTooltipUnstyled"] }, { kind: "ngmodule", type: TagModule }, { kind: "directive", type: HasPermissionDirective, selector: "[hasPermission]", inputs: ["hasPermission"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }] });
|
|
2266
2313
|
}
|
|
2267
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
2314
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: BranchListComponent, decorators: [{
|
|
2268
2315
|
type: Component,
|
|
2269
2316
|
args: [{
|
|
2270
2317
|
selector: 'lib-branch-list',
|
|
@@ -2301,13 +2348,15 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.5", ngImpor
|
|
|
2301
2348
|
/>
|
|
2302
2349
|
}
|
|
2303
2350
|
</div>
|
|
2304
|
-
<
|
|
2351
|
+
<button
|
|
2352
|
+
pButton
|
|
2305
2353
|
*hasPermission="BRANCH_PERMISSIONS.CREATE"
|
|
2306
|
-
[label]="'administrative.branch.add' | translate"
|
|
2307
|
-
icon="pi pi-plus"
|
|
2308
2354
|
[disabled]="!selectedCompanyId()"
|
|
2309
|
-
(
|
|
2310
|
-
|
|
2355
|
+
(click)="onCreate()"
|
|
2356
|
+
>
|
|
2357
|
+
<span pButtonIcon class="pi pi-plus"></span>
|
|
2358
|
+
<span pButtonLabel>{{ 'administrative.branch.add' | translate }}</span>
|
|
2359
|
+
</button>
|
|
2311
2360
|
</div>
|
|
2312
2361
|
</ng-template>
|
|
2313
2362
|
|
|
@@ -2352,25 +2401,29 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.5", ngImpor
|
|
|
2352
2401
|
</td>
|
|
2353
2402
|
<td>
|
|
2354
2403
|
<div class="flex gap-2">
|
|
2355
|
-
<
|
|
2404
|
+
<button
|
|
2405
|
+
pButton
|
|
2356
2406
|
*hasPermission="BRANCH_PERMISSIONS.UPDATE"
|
|
2357
|
-
icon="pi pi-pencil"
|
|
2358
2407
|
[rounded]="true"
|
|
2359
2408
|
[text]="true"
|
|
2360
2409
|
severity="info"
|
|
2361
2410
|
[pTooltip]="'shared.edit' | translate"
|
|
2362
|
-
(
|
|
2363
|
-
|
|
2411
|
+
(click)="onEdit(branch)"
|
|
2412
|
+
>
|
|
2413
|
+
<span pButtonIcon class="pi pi-pencil"></span>
|
|
2414
|
+
</button>
|
|
2364
2415
|
@if (!branch.readOnly) {
|
|
2365
|
-
<
|
|
2416
|
+
<button
|
|
2417
|
+
pButton
|
|
2366
2418
|
*hasPermission="BRANCH_PERMISSIONS.DELETE"
|
|
2367
|
-
icon="pi pi-trash"
|
|
2368
2419
|
[rounded]="true"
|
|
2369
2420
|
[text]="true"
|
|
2370
2421
|
severity="danger"
|
|
2371
2422
|
[pTooltip]="'shared.delete' | translate"
|
|
2372
|
-
(
|
|
2373
|
-
|
|
2423
|
+
(click)="onDelete(branch)"
|
|
2424
|
+
>
|
|
2425
|
+
<span pButtonIcon class="pi pi-trash"></span>
|
|
2426
|
+
</button>
|
|
2374
2427
|
}
|
|
2375
2428
|
</div>
|
|
2376
2429
|
</td>
|
|
@@ -2403,12 +2456,14 @@ class CompanyFormComponent {
|
|
|
2403
2456
|
route = inject(ActivatedRoute);
|
|
2404
2457
|
translateAdapter = inject(TranslateService, { optional: true });
|
|
2405
2458
|
companyService = inject(CompanyApiService);
|
|
2406
|
-
formRef = viewChild(BaseFormComponent,
|
|
2459
|
+
formRef = viewChild(BaseFormComponent, /* @ts-ignore */
|
|
2460
|
+
...(ngDevMode ? [{ debugName: "formRef" }] : /* istanbul ignore next */ []));
|
|
2407
2461
|
routeParams = toSignal(this.route.paramMap);
|
|
2408
2462
|
editId = computed(() => {
|
|
2409
2463
|
const id = this.routeParams()?.get('id');
|
|
2410
2464
|
return id && id !== 'new' ? id : null;
|
|
2411
|
-
},
|
|
2465
|
+
}, /* @ts-ignore */
|
|
2466
|
+
...(ngDevMode ? [{ debugName: "editId" }] : /* istanbul ignore next */ []));
|
|
2412
2467
|
fields = [
|
|
2413
2468
|
{
|
|
2414
2469
|
key: 'name',
|
|
@@ -2488,8 +2543,8 @@ class CompanyFormComponent {
|
|
|
2488
2543
|
t(key, vars) {
|
|
2489
2544
|
return this.translateAdapter?.translate(key, vars) ?? key;
|
|
2490
2545
|
}
|
|
2491
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
2492
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "
|
|
2546
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: CompanyFormComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
2547
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "22.0.5", type: CompanyFormComponent, isStandalone: true, selector: "lib-company-form", viewQueries: [{ propertyName: "formRef", first: true, predicate: BaseFormComponent, descendants: true, isSignal: true }], ngImport: i0, template: `
|
|
2493
2548
|
<lib-base-form
|
|
2494
2549
|
[fields]="fields"
|
|
2495
2550
|
[service]="companyService"
|
|
@@ -2504,7 +2559,7 @@ class CompanyFormComponent {
|
|
|
2504
2559
|
/>
|
|
2505
2560
|
`, isInline: true, dependencies: [{ kind: "component", type: BaseFormComponent, selector: "lib-base-form", inputs: ["fields", "title", "createTitle", "editTitle", "columns", "submitLabel", "cancelLabel", "isLoading", "isEditMode", "initialValue", "service", "editId", "cancelRoute", "navigateOnSuccess", "mapToRequest", "mapFromEntity"], outputs: ["onSubmit", "onCancel", "onValueChange"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }] });
|
|
2506
2561
|
}
|
|
2507
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
2562
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: CompanyFormComponent, decorators: [{
|
|
2508
2563
|
type: Component,
|
|
2509
2564
|
args: [{
|
|
2510
2565
|
selector: 'lib-company-form',
|
|
@@ -2536,7 +2591,8 @@ class CompanyListComponent {
|
|
|
2536
2591
|
translateAdapter = inject(TranslateService, { optional: true });
|
|
2537
2592
|
router = inject(Router);
|
|
2538
2593
|
companyService = inject(CompanyApiService);
|
|
2539
|
-
canCreate = computed(() => this.permissionValidator.hasPermission(COMPANY_PERMISSIONS.CREATE),
|
|
2594
|
+
canCreate = computed(() => this.permissionValidator.hasPermission(COMPANY_PERMISSIONS.CREATE), /* @ts-ignore */
|
|
2595
|
+
...(ngDevMode ? [{ debugName: "canCreate" }] : /* istanbul ignore next */ []));
|
|
2540
2596
|
canEditFn = (_item) => this.permissionValidator.hasPermission(COMPANY_PERMISSIONS.UPDATE);
|
|
2541
2597
|
canDeleteFn = (item) => !item.readOnly && this.permissionValidator.hasPermission(COMPANY_PERMISSIONS.DELETE);
|
|
2542
2598
|
viewBranchesAction = [{
|
|
@@ -2561,8 +2617,8 @@ class CompanyListComponent {
|
|
|
2561
2617
|
t(key) {
|
|
2562
2618
|
return this.translateAdapter?.translate(key) ?? key;
|
|
2563
2619
|
}
|
|
2564
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
2565
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "
|
|
2620
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: CompanyListComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
2621
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.5", type: CompanyListComponent, isStandalone: true, selector: "lib-company-list", ngImport: i0, template: `
|
|
2566
2622
|
<lib-base-list
|
|
2567
2623
|
[columns]="columns"
|
|
2568
2624
|
[actions]="viewBranchesAction"
|
|
@@ -2583,9 +2639,9 @@ class CompanyListComponent {
|
|
|
2583
2639
|
/>
|
|
2584
2640
|
</ng-template>
|
|
2585
2641
|
</lib-base-list>
|
|
2586
|
-
`, isInline: true, dependencies: [{ kind: "component", type: BaseListComponent, selector: "lib-base-list", inputs: ["columns", "actions", "title", "showCreateButton", "searchable", "pageSize", "emptyMessage", "createButtonLabel", "createButtonIcon", "data", "total", "isLoading", "service", "filter", "createRoute", "editRoute", "deleteConfirmField", "idField", "canEdit", "canDelete"], outputs: ["onCreate", "onLazyLoad", "onSearch"] }, { kind: "directive", type: BaseListTemplateDirective, selector: "ng-template[baseListTemplate]", inputs: ["baseListTemplate"] }, { kind: "ngmodule", type: PrimeModule }, { kind: "component", type: i6.Tag, selector: "p-tag", inputs: ["
|
|
2642
|
+
`, isInline: true, dependencies: [{ kind: "component", type: BaseListComponent, selector: "lib-base-list", inputs: ["columns", "actions", "title", "showCreateButton", "searchable", "pageSize", "emptyMessage", "createButtonLabel", "createButtonIcon", "data", "total", "isLoading", "service", "filter", "createRoute", "editRoute", "deleteConfirmField", "idField", "canEdit", "canDelete"], outputs: ["onCreate", "onLazyLoad", "onSearch"] }, { kind: "directive", type: BaseListTemplateDirective, selector: "ng-template[baseListTemplate]", inputs: ["baseListTemplate"] }, { kind: "ngmodule", type: PrimeModule }, { kind: "component", type: i6.Tag, selector: "p-tag", inputs: ["severity", "value", "icon", "rounded"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }] });
|
|
2587
2643
|
}
|
|
2588
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
2644
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: CompanyListComponent, decorators: [{
|
|
2589
2645
|
type: Component,
|
|
2590
2646
|
args: [{
|
|
2591
2647
|
selector: 'lib-company-list',
|
|
@@ -2630,10 +2686,14 @@ class ForgotPasswordPageComponent {
|
|
|
2630
2686
|
translate(key, vars) {
|
|
2631
2687
|
return this.translateAdapter?.translate(key, vars) ?? key;
|
|
2632
2688
|
}
|
|
2633
|
-
isLoading = signal(false,
|
|
2634
|
-
|
|
2635
|
-
|
|
2636
|
-
|
|
2689
|
+
isLoading = signal(false, /* @ts-ignore */
|
|
2690
|
+
...(ngDevMode ? [{ debugName: "isLoading" }] : /* istanbul ignore next */ []));
|
|
2691
|
+
emailSent = signal(false, /* @ts-ignore */
|
|
2692
|
+
...(ngDevMode ? [{ debugName: "emailSent" }] : /* istanbul ignore next */ []));
|
|
2693
|
+
submittedEmail = signal('', /* @ts-ignore */
|
|
2694
|
+
...(ngDevMode ? [{ debugName: "submittedEmail" }] : /* istanbul ignore next */ []));
|
|
2695
|
+
formModel = signal({ email: '' }, /* @ts-ignore */
|
|
2696
|
+
...(ngDevMode ? [{ debugName: "formModel" }] : /* istanbul ignore next */ []));
|
|
2637
2697
|
forgotForm = form(this.formModel, (f) => {
|
|
2638
2698
|
required(f.email, {
|
|
2639
2699
|
message: this.translate('auth.validation.email.required'),
|
|
@@ -2642,7 +2702,8 @@ class ForgotPasswordPageComponent {
|
|
|
2642
2702
|
message: this.translate('shared.invalid.email'),
|
|
2643
2703
|
});
|
|
2644
2704
|
});
|
|
2645
|
-
isFormValid = computed(() => this.forgotForm().valid(),
|
|
2705
|
+
isFormValid = computed(() => this.forgotForm().valid(), /* @ts-ignore */
|
|
2706
|
+
...(ngDevMode ? [{ debugName: "isFormValid" }] : /* istanbul ignore next */ []));
|
|
2646
2707
|
onSubmit() {
|
|
2647
2708
|
if (!this.isFormValid()) {
|
|
2648
2709
|
this.messageService.add({
|
|
@@ -2672,8 +2733,8 @@ class ForgotPasswordPageComponent {
|
|
|
2672
2733
|
this.submittedEmail.set('');
|
|
2673
2734
|
this.formModel.set({ email: '' });
|
|
2674
2735
|
}
|
|
2675
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
2676
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "
|
|
2736
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: ForgotPasswordPageComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
2737
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.5", type: ForgotPasswordPageComponent, isStandalone: true, selector: "lib-forgot-password-page", ngImport: i0, template: `
|
|
2677
2738
|
<app-floating-configurator />
|
|
2678
2739
|
<div
|
|
2679
2740
|
class="bg-surface-ground flex items-center justify-center min-h-screen"
|
|
@@ -2716,13 +2777,17 @@ class ForgotPasswordPageComponent {
|
|
|
2716
2777
|
autocomplete="email"
|
|
2717
2778
|
/>
|
|
2718
2779
|
|
|
2719
|
-
<
|
|
2720
|
-
|
|
2721
|
-
|
|
2780
|
+
<button
|
|
2781
|
+
pButton
|
|
2782
|
+
class="w-full mb-4"
|
|
2722
2783
|
type="submit"
|
|
2723
|
-
[loading]="isLoading()"
|
|
2724
2784
|
[disabled]="!isFormValid() || isLoading()"
|
|
2725
|
-
|
|
2785
|
+
>
|
|
2786
|
+
@if (isLoading()) {
|
|
2787
|
+
<span pButtonIcon class="pi pi-spinner pi-spin"></span>
|
|
2788
|
+
}
|
|
2789
|
+
<span pButtonLabel>{{ 'auth.forgot.password.send.reset.link' | translate }}</span>
|
|
2790
|
+
</button>
|
|
2726
2791
|
|
|
2727
2792
|
<div class="flex items-center justify-center gap-2">
|
|
2728
2793
|
<span class="font-medium">{{
|
|
@@ -2771,9 +2836,9 @@ class ForgotPasswordPageComponent {
|
|
|
2771
2836
|
</div>
|
|
2772
2837
|
</div>
|
|
2773
2838
|
</div>
|
|
2774
|
-
`, isInline: true, dependencies: [{ kind: "ngmodule", type: AngularModule }, { kind: "directive", type: i1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.NgForm, selector: "form:not([ngNoForm]):not([formGroup]):not([formArray]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i2
|
|
2839
|
+
`, isInline: true, dependencies: [{ kind: "ngmodule", type: AngularModule }, { kind: "directive", type: i1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.NgForm, selector: "form:not([ngNoForm]):not([formGroup]):not([formArray]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "browserUrl", "routerLink"] }, { kind: "ngmodule", type: PrimeModule }, { kind: "directive", type: i3.ButtonDirective, selector: "[pButton]", inputs: ["pButton", "pButtonPT", "pButtonUnstyled", "hostName", "text", "plain", "raised", "size", "outlined", "link", "rounded", "fluid", "variant", "iconOnly", "loading", "severity"] }, { kind: "directive", type: i3.ButtonLabel, selector: "[pButtonLabel]", inputs: ["pButtonLabelPT", "pButtonLabelUnstyled"] }, { kind: "directive", type: i3.ButtonIcon, selector: "[pButtonIcon]", inputs: ["pButtonIconPT", "pButtonUnstyled"] }, { kind: "directive", type: i4.InputText, selector: "[pInputText]", inputs: ["hostName", "pInputTextPT", "pInputTextUnstyled", "pSize", "variant", "fluid", "invalid"] }, { kind: "directive", type: FormField, selector: "[formField]", inputs: ["formField"], exportAs: ["formField"] }, { kind: "component", type: AppFloatingConfigurator, selector: "app-floating-configurator" }, { kind: "pipe", type: TranslatePipe, name: "translate" }] });
|
|
2775
2840
|
}
|
|
2776
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
2841
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: ForgotPasswordPageComponent, decorators: [{
|
|
2777
2842
|
type: Component,
|
|
2778
2843
|
args: [{
|
|
2779
2844
|
selector: 'lib-forgot-password-page',
|
|
@@ -2827,13 +2892,17 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.5", ngImpor
|
|
|
2827
2892
|
autocomplete="email"
|
|
2828
2893
|
/>
|
|
2829
2894
|
|
|
2830
|
-
<
|
|
2831
|
-
|
|
2832
|
-
|
|
2895
|
+
<button
|
|
2896
|
+
pButton
|
|
2897
|
+
class="w-full mb-4"
|
|
2833
2898
|
type="submit"
|
|
2834
|
-
[loading]="isLoading()"
|
|
2835
2899
|
[disabled]="!isFormValid() || isLoading()"
|
|
2836
|
-
|
|
2900
|
+
>
|
|
2901
|
+
@if (isLoading()) {
|
|
2902
|
+
<span pButtonIcon class="pi pi-spinner pi-spin"></span>
|
|
2903
|
+
}
|
|
2904
|
+
<span pButtonLabel>{{ 'auth.forgot.password.send.reset.link' | translate }}</span>
|
|
2905
|
+
</button>
|
|
2837
2906
|
|
|
2838
2907
|
<div class="flex items-center justify-center gap-2">
|
|
2839
2908
|
<span class="font-medium">{{
|
|
@@ -2906,22 +2975,30 @@ class LoginPageComponent {
|
|
|
2906
2975
|
translate(key, vars) {
|
|
2907
2976
|
return this.translateAdapter?.translate(key, vars) ?? key;
|
|
2908
2977
|
}
|
|
2909
|
-
returnUrl = input('',
|
|
2910
|
-
|
|
2911
|
-
|
|
2912
|
-
|
|
2978
|
+
returnUrl = input('', /* @ts-ignore */
|
|
2979
|
+
...(ngDevMode ? [{ debugName: "returnUrl" }] : /* istanbul ignore next */ []));
|
|
2980
|
+
currentStep = signal('credentials', /* @ts-ignore */
|
|
2981
|
+
...(ngDevMode ? [{ debugName: "currentStep" }] : /* istanbul ignore next */ []));
|
|
2982
|
+
isLoading = signal(false, /* @ts-ignore */
|
|
2983
|
+
...(ngDevMode ? [{ debugName: "isLoading" }] : /* istanbul ignore next */ []));
|
|
2984
|
+
unverifiedEmail = signal('', /* @ts-ignore */
|
|
2985
|
+
...(ngDevMode ? [{ debugName: "unverifiedEmail" }] : /* istanbul ignore next */ []));
|
|
2913
2986
|
loginFormModel = signal({
|
|
2914
2987
|
email: '',
|
|
2915
2988
|
password: '',
|
|
2916
2989
|
rememberMe: true,
|
|
2917
|
-
},
|
|
2990
|
+
}, /* @ts-ignore */
|
|
2991
|
+
...(ngDevMode ? [{ debugName: "loginFormModel" }] : /* istanbul ignore next */ []));
|
|
2918
2992
|
emailErrorMessage = computed(() => this.validationConfig?.email?.message ??
|
|
2919
|
-
this.translate('shared.invalid.email'),
|
|
2920
|
-
|
|
2993
|
+
this.translate('shared.invalid.email'), /* @ts-ignore */
|
|
2994
|
+
...(ngDevMode ? [{ debugName: "emailErrorMessage" }] : /* istanbul ignore next */ []));
|
|
2995
|
+
passwordMinLength = computed(() => this.validationConfig?.password?.minLength ?? 8, /* @ts-ignore */
|
|
2996
|
+
...(ngDevMode ? [{ debugName: "passwordMinLength" }] : /* istanbul ignore next */ []));
|
|
2921
2997
|
passwordErrorMessage = computed(() => this.validationConfig?.password?.message ??
|
|
2922
2998
|
this.translate('auth.validation.password.min.length', {
|
|
2923
2999
|
min: this.passwordMinLength(),
|
|
2924
|
-
}),
|
|
3000
|
+
}), /* @ts-ignore */
|
|
3001
|
+
...(ngDevMode ? [{ debugName: "passwordErrorMessage" }] : /* istanbul ignore next */ []));
|
|
2925
3002
|
loginForm = form(this.loginFormModel, (f) => {
|
|
2926
3003
|
required(f.email, {
|
|
2927
3004
|
message: this.translate('auth.validation.email.required'),
|
|
@@ -2939,7 +3016,8 @@ class LoginPageComponent {
|
|
|
2939
3016
|
if (!email)
|
|
2940
3017
|
return null;
|
|
2941
3018
|
return validateEmail(email, this.validationConfig?.email ?? undefined);
|
|
2942
|
-
},
|
|
3019
|
+
}, /* @ts-ignore */
|
|
3020
|
+
...(ngDevMode ? [{ debugName: "emailValidationError" }] : /* istanbul ignore next */ []));
|
|
2943
3021
|
passwordValidationError = computed(() => {
|
|
2944
3022
|
const password = this.loginFormModel().password;
|
|
2945
3023
|
if (!password)
|
|
@@ -2947,18 +3025,21 @@ class LoginPageComponent {
|
|
|
2947
3025
|
if (!this.validationConfig?.password)
|
|
2948
3026
|
return null;
|
|
2949
3027
|
return validatePassword(password, this.validationConfig.password);
|
|
2950
|
-
},
|
|
3028
|
+
}, /* @ts-ignore */
|
|
3029
|
+
...(ngDevMode ? [{ debugName: "passwordValidationError" }] : /* istanbul ignore next */ []));
|
|
2951
3030
|
isLoginFormValid = computed(() => {
|
|
2952
3031
|
const formValid = this.loginForm().valid();
|
|
2953
3032
|
const emailError = this.emailValidationError();
|
|
2954
3033
|
const passwordError = this.passwordValidationError();
|
|
2955
3034
|
return formValid && !emailError && !passwordError;
|
|
2956
|
-
},
|
|
3035
|
+
}, /* @ts-ignore */
|
|
3036
|
+
...(ngDevMode ? [{ debugName: "isLoginFormValid" }] : /* istanbul ignore next */ []));
|
|
2957
3037
|
selectionFormModel = signal({
|
|
2958
3038
|
companyId: '',
|
|
2959
3039
|
branchId: '',
|
|
2960
3040
|
rememberSelection: true,
|
|
2961
|
-
},
|
|
3041
|
+
}, /* @ts-ignore */
|
|
3042
|
+
...(ngDevMode ? [{ debugName: "selectionFormModel" }] : /* istanbul ignore next */ []));
|
|
2962
3043
|
selectionForm = form(this.selectionFormModel, (f) => {
|
|
2963
3044
|
required(f.companyId, {
|
|
2964
3045
|
message: this.translate('auth.validation.company.required'),
|
|
@@ -2967,20 +3048,27 @@ class LoginPageComponent {
|
|
|
2967
3048
|
message: this.translate('auth.validation.branch.required'),
|
|
2968
3049
|
});
|
|
2969
3050
|
});
|
|
2970
|
-
isSelectionFormValid = computed(() => this.selectionForm().valid(),
|
|
2971
|
-
|
|
2972
|
-
|
|
2973
|
-
|
|
3051
|
+
isSelectionFormValid = computed(() => this.selectionForm().valid(), /* @ts-ignore */
|
|
3052
|
+
...(ngDevMode ? [{ debugName: "isSelectionFormValid" }] : /* istanbul ignore next */ []));
|
|
3053
|
+
companyFeatureEnabled = computed(() => isCompanyFeatureEnabled(this.appConfig), /* @ts-ignore */
|
|
3054
|
+
...(ngDevMode ? [{ debugName: "companyFeatureEnabled" }] : /* istanbul ignore next */ []));
|
|
3055
|
+
emailFeatureEnabled = computed(() => isServiceEnabled(this.appConfig, 'email'), /* @ts-ignore */
|
|
3056
|
+
...(ngDevMode ? [{ debugName: "emailFeatureEnabled" }] : /* istanbul ignore next */ []));
|
|
3057
|
+
signUpEnabled = computed(() => isSignUpEnabled(this.appConfig), /* @ts-ignore */
|
|
3058
|
+
...(ngDevMode ? [{ debugName: "signUpEnabled" }] : /* istanbul ignore next */ []));
|
|
2974
3059
|
sessionId = null;
|
|
2975
|
-
companies = signal([],
|
|
2976
|
-
|
|
3060
|
+
companies = signal([], /* @ts-ignore */
|
|
3061
|
+
...(ngDevMode ? [{ debugName: "companies" }] : /* istanbul ignore next */ []));
|
|
3062
|
+
userName = signal('', /* @ts-ignore */
|
|
3063
|
+
...(ngDevMode ? [{ debugName: "userName" }] : /* istanbul ignore next */ []));
|
|
2977
3064
|
branches = computed(() => {
|
|
2978
3065
|
const companyId = this.selectionFormModel().companyId;
|
|
2979
3066
|
if (!companyId)
|
|
2980
3067
|
return [];
|
|
2981
3068
|
const company = this.companies().find((c) => c.id === companyId);
|
|
2982
3069
|
return company?.branches ?? [];
|
|
2983
|
-
},
|
|
3070
|
+
}, /* @ts-ignore */
|
|
3071
|
+
...(ngDevMode ? [{ debugName: "branches" }] : /* istanbul ignore next */ []));
|
|
2984
3072
|
constructor() {
|
|
2985
3073
|
effect(() => {
|
|
2986
3074
|
if (this.authState.requiresCompanySelection()) {
|
|
@@ -3192,8 +3280,8 @@ class LoginPageComponent {
|
|
|
3192
3280
|
}
|
|
3193
3281
|
}
|
|
3194
3282
|
}
|
|
3195
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
3196
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "
|
|
3283
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: LoginPageComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
3284
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.5", type: LoginPageComponent, isStandalone: true, selector: "lib-login-page", inputs: { returnUrl: { classPropertyName: "returnUrl", publicName: "returnUrl", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: `
|
|
3197
3285
|
<app-floating-configurator />
|
|
3198
3286
|
<div
|
|
3199
3287
|
class="bg-surface-ground flex items-center justify-center min-h-screen"
|
|
@@ -3315,13 +3403,17 @@ class LoginPageComponent {
|
|
|
3315
3403
|
}
|
|
3316
3404
|
</div>
|
|
3317
3405
|
|
|
3318
|
-
<
|
|
3319
|
-
|
|
3320
|
-
|
|
3406
|
+
<button
|
|
3407
|
+
pButton
|
|
3408
|
+
class="w-full"
|
|
3321
3409
|
type="submit"
|
|
3322
|
-
[loading]="isLoading()"
|
|
3323
3410
|
[disabled]="!isLoginFormValid() || isLoading()"
|
|
3324
|
-
|
|
3411
|
+
>
|
|
3412
|
+
@if (isLoading()) {
|
|
3413
|
+
<span pButtonIcon class="pi pi-spinner pi-spin"></span>
|
|
3414
|
+
}
|
|
3415
|
+
<span pButtonLabel>{{ 'auth.login.sign.in' | translate }}</span>
|
|
3416
|
+
</button>
|
|
3325
3417
|
|
|
3326
3418
|
@if (signUpEnabled()) {
|
|
3327
3419
|
<div class="flex items-center justify-center mt-4 gap-2">
|
|
@@ -3351,12 +3443,17 @@ class LoginPageComponent {
|
|
|
3351
3443
|
<p class="text-muted-color font-medium mb-6">
|
|
3352
3444
|
{{ 'auth.login.verify.email.message' | translate }}
|
|
3353
3445
|
</p>
|
|
3354
|
-
<
|
|
3355
|
-
|
|
3356
|
-
|
|
3357
|
-
|
|
3358
|
-
|
|
3359
|
-
|
|
3446
|
+
<button
|
|
3447
|
+
pButton
|
|
3448
|
+
class="w-full mb-4"
|
|
3449
|
+
(click)="onResendVerification()"
|
|
3450
|
+
[disabled]="isLoading()"
|
|
3451
|
+
>
|
|
3452
|
+
@if (isLoading()) {
|
|
3453
|
+
<span pButtonIcon class="pi pi-spinner pi-spin"></span>
|
|
3454
|
+
}
|
|
3455
|
+
<span pButtonLabel>{{ 'auth.verify.resend' | translate }}</span>
|
|
3456
|
+
</button>
|
|
3360
3457
|
<div class="mt-4">
|
|
3361
3458
|
<span
|
|
3362
3459
|
class="font-semibold text-primary cursor-pointer"
|
|
@@ -3432,21 +3529,27 @@ class LoginPageComponent {
|
|
|
3432
3529
|
</div>
|
|
3433
3530
|
|
|
3434
3531
|
<div class="flex flex-col sm:flex-row gap-4">
|
|
3435
|
-
<
|
|
3436
|
-
|
|
3437
|
-
|
|
3532
|
+
<button
|
|
3533
|
+
pButton
|
|
3534
|
+
class="w-full"
|
|
3438
3535
|
severity="secondary"
|
|
3439
3536
|
[outlined]="true"
|
|
3440
3537
|
type="button"
|
|
3441
|
-
(
|
|
3442
|
-
|
|
3443
|
-
|
|
3444
|
-
|
|
3445
|
-
|
|
3538
|
+
(click)="goBackToCredentials()"
|
|
3539
|
+
>
|
|
3540
|
+
<span pButtonLabel>{{ 'shared.back' | translate }}</span>
|
|
3541
|
+
</button>
|
|
3542
|
+
<button
|
|
3543
|
+
pButton
|
|
3544
|
+
class="w-full"
|
|
3446
3545
|
type="submit"
|
|
3447
|
-
[loading]="isLoading()"
|
|
3448
3546
|
[disabled]="!isSelectionFormValid() || isLoading()"
|
|
3449
|
-
|
|
3547
|
+
>
|
|
3548
|
+
@if (isLoading()) {
|
|
3549
|
+
<span pButtonIcon class="pi pi-spinner pi-spin"></span>
|
|
3550
|
+
}
|
|
3551
|
+
<span pButtonLabel>{{ 'shared.continue' | translate }}</span>
|
|
3552
|
+
</button>
|
|
3450
3553
|
</div>
|
|
3451
3554
|
</form>
|
|
3452
3555
|
}
|
|
@@ -3454,9 +3557,9 @@ class LoginPageComponent {
|
|
|
3454
3557
|
</div>
|
|
3455
3558
|
</div>
|
|
3456
3559
|
</div>
|
|
3457
|
-
`, isInline: true, dependencies: [{ kind: "ngmodule", type: AngularModule }, { kind: "directive", type: i1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.NgForm, selector: "form:not([ngNoForm]):not([formGroup]):not([formArray]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i2
|
|
3560
|
+
`, isInline: true, dependencies: [{ kind: "ngmodule", type: AngularModule }, { kind: "directive", type: i1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.NgForm, selector: "form:not([ngNoForm]):not([formGroup]):not([formArray]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "browserUrl", "routerLink"] }, { kind: "ngmodule", type: PrimeModule }, { kind: "directive", type: i3.ButtonDirective, selector: "[pButton]", inputs: ["pButton", "pButtonPT", "pButtonUnstyled", "hostName", "text", "plain", "raised", "size", "outlined", "link", "rounded", "fluid", "variant", "iconOnly", "loading", "severity"] }, { kind: "directive", type: i3.ButtonLabel, selector: "[pButtonLabel]", inputs: ["pButtonLabelPT", "pButtonLabelUnstyled"] }, { kind: "directive", type: i3.ButtonIcon, selector: "[pButtonIcon]", inputs: ["pButtonIconPT", "pButtonUnstyled"] }, { kind: "directive", type: i4.InputText, selector: "[pInputText]", inputs: ["hostName", "pInputTextPT", "pInputTextUnstyled", "pSize", "variant", "fluid", "invalid"] }, { kind: "directive", type: FormField, selector: "[formField]", inputs: ["formField"], exportAs: ["formField"] }, { kind: "component", type: AppFloatingConfigurator, selector: "app-floating-configurator" }, { kind: "pipe", type: TranslatePipe, name: "translate" }] });
|
|
3458
3561
|
}
|
|
3459
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
3562
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: LoginPageComponent, decorators: [{
|
|
3460
3563
|
type: Component,
|
|
3461
3564
|
args: [{
|
|
3462
3565
|
selector: 'lib-login-page',
|
|
@@ -3589,13 +3692,17 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.5", ngImpor
|
|
|
3589
3692
|
}
|
|
3590
3693
|
</div>
|
|
3591
3694
|
|
|
3592
|
-
<
|
|
3593
|
-
|
|
3594
|
-
|
|
3695
|
+
<button
|
|
3696
|
+
pButton
|
|
3697
|
+
class="w-full"
|
|
3595
3698
|
type="submit"
|
|
3596
|
-
[loading]="isLoading()"
|
|
3597
3699
|
[disabled]="!isLoginFormValid() || isLoading()"
|
|
3598
|
-
|
|
3700
|
+
>
|
|
3701
|
+
@if (isLoading()) {
|
|
3702
|
+
<span pButtonIcon class="pi pi-spinner pi-spin"></span>
|
|
3703
|
+
}
|
|
3704
|
+
<span pButtonLabel>{{ 'auth.login.sign.in' | translate }}</span>
|
|
3705
|
+
</button>
|
|
3599
3706
|
|
|
3600
3707
|
@if (signUpEnabled()) {
|
|
3601
3708
|
<div class="flex items-center justify-center mt-4 gap-2">
|
|
@@ -3625,12 +3732,17 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.5", ngImpor
|
|
|
3625
3732
|
<p class="text-muted-color font-medium mb-6">
|
|
3626
3733
|
{{ 'auth.login.verify.email.message' | translate }}
|
|
3627
3734
|
</p>
|
|
3628
|
-
<
|
|
3629
|
-
|
|
3630
|
-
|
|
3631
|
-
|
|
3632
|
-
|
|
3633
|
-
|
|
3735
|
+
<button
|
|
3736
|
+
pButton
|
|
3737
|
+
class="w-full mb-4"
|
|
3738
|
+
(click)="onResendVerification()"
|
|
3739
|
+
[disabled]="isLoading()"
|
|
3740
|
+
>
|
|
3741
|
+
@if (isLoading()) {
|
|
3742
|
+
<span pButtonIcon class="pi pi-spinner pi-spin"></span>
|
|
3743
|
+
}
|
|
3744
|
+
<span pButtonLabel>{{ 'auth.verify.resend' | translate }}</span>
|
|
3745
|
+
</button>
|
|
3634
3746
|
<div class="mt-4">
|
|
3635
3747
|
<span
|
|
3636
3748
|
class="font-semibold text-primary cursor-pointer"
|
|
@@ -3706,21 +3818,27 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.5", ngImpor
|
|
|
3706
3818
|
</div>
|
|
3707
3819
|
|
|
3708
3820
|
<div class="flex flex-col sm:flex-row gap-4">
|
|
3709
|
-
<
|
|
3710
|
-
|
|
3711
|
-
|
|
3821
|
+
<button
|
|
3822
|
+
pButton
|
|
3823
|
+
class="w-full"
|
|
3712
3824
|
severity="secondary"
|
|
3713
3825
|
[outlined]="true"
|
|
3714
3826
|
type="button"
|
|
3715
|
-
(
|
|
3716
|
-
|
|
3717
|
-
|
|
3718
|
-
|
|
3719
|
-
|
|
3827
|
+
(click)="goBackToCredentials()"
|
|
3828
|
+
>
|
|
3829
|
+
<span pButtonLabel>{{ 'shared.back' | translate }}</span>
|
|
3830
|
+
</button>
|
|
3831
|
+
<button
|
|
3832
|
+
pButton
|
|
3833
|
+
class="w-full"
|
|
3720
3834
|
type="submit"
|
|
3721
|
-
[loading]="isLoading()"
|
|
3722
3835
|
[disabled]="!isSelectionFormValid() || isLoading()"
|
|
3723
|
-
|
|
3836
|
+
>
|
|
3837
|
+
@if (isLoading()) {
|
|
3838
|
+
<span pButtonIcon class="pi pi-spinner pi-spin"></span>
|
|
3839
|
+
}
|
|
3840
|
+
<span pButtonLabel>{{ 'shared.continue' | translate }}</span>
|
|
3841
|
+
</button>
|
|
3724
3842
|
</div>
|
|
3725
3843
|
</form>
|
|
3726
3844
|
}
|
|
@@ -3761,51 +3879,68 @@ class ProfilePageComponent {
|
|
|
3761
3879
|
translate(key, vars) {
|
|
3762
3880
|
return this.translateAdapter?.translate(key, vars) ?? key;
|
|
3763
3881
|
}
|
|
3764
|
-
isLoading = signal(false,
|
|
3765
|
-
|
|
3766
|
-
|
|
3767
|
-
|
|
3882
|
+
isLoading = signal(false, /* @ts-ignore */
|
|
3883
|
+
...(ngDevMode ? [{ debugName: "isLoading" }] : /* istanbul ignore next */ []));
|
|
3884
|
+
isLoadingPermissions = signal(false, /* @ts-ignore */
|
|
3885
|
+
...(ngDevMode ? [{ debugName: "isLoadingPermissions" }] : /* istanbul ignore next */ []));
|
|
3886
|
+
isLoadingExtraFields = signal(false, /* @ts-ignore */
|
|
3887
|
+
...(ngDevMode ? [{ debugName: "isLoadingExtraFields" }] : /* istanbul ignore next */ []));
|
|
3888
|
+
_profilePictureUrl = signal(null, /* @ts-ignore */
|
|
3889
|
+
...(ngDevMode ? [{ debugName: "_profilePictureUrl" }] : /* istanbul ignore next */ []));
|
|
3768
3890
|
profilePictureUrl = this._profilePictureUrl.asReadonly();
|
|
3769
|
-
_userRoles = signal([],
|
|
3891
|
+
_userRoles = signal([], /* @ts-ignore */
|
|
3892
|
+
...(ngDevMode ? [{ debugName: "_userRoles" }] : /* istanbul ignore next */ []));
|
|
3770
3893
|
userRoles = this._userRoles.asReadonly();
|
|
3771
|
-
_userActions = signal([],
|
|
3894
|
+
_userActions = signal([], /* @ts-ignore */
|
|
3895
|
+
...(ngDevMode ? [{ debugName: "_userActions" }] : /* istanbul ignore next */ []));
|
|
3772
3896
|
userActions = this._userActions.asReadonly();
|
|
3773
3897
|
extraSections = computed(() => {
|
|
3774
3898
|
if (!this.profileExtension?.getExtraSections)
|
|
3775
3899
|
return [];
|
|
3776
3900
|
const sections = this.profileExtension.getExtraSections();
|
|
3777
3901
|
return sections.sort((a, b) => (a.order ?? 100) - (b.order ?? 100));
|
|
3778
|
-
},
|
|
3902
|
+
}, /* @ts-ignore */
|
|
3903
|
+
...(ngDevMode ? [{ debugName: "extraSections" }] : /* istanbul ignore next */ []));
|
|
3779
3904
|
editableFields = computed(() => {
|
|
3780
3905
|
if (!this.profileExtension?.getExtraFields)
|
|
3781
3906
|
return [];
|
|
3782
3907
|
const fields = this.profileExtension.getExtraFields();
|
|
3783
3908
|
return fields.sort((a, b) => (a.order ?? 100) - (b.order ?? 100));
|
|
3784
|
-
},
|
|
3909
|
+
}, /* @ts-ignore */
|
|
3910
|
+
...(ngDevMode ? [{ debugName: "editableFields" }] : /* istanbul ignore next */ []));
|
|
3785
3911
|
viewOnlyFields = computed(() => {
|
|
3786
3912
|
if (!this.userFormExtension?.getExtraFields)
|
|
3787
3913
|
return [];
|
|
3788
3914
|
const fields = this.userFormExtension.getExtraFields();
|
|
3789
3915
|
return fields.sort((a, b) => (a.order ?? 100) - (b.order ?? 100));
|
|
3790
|
-
},
|
|
3916
|
+
}, /* @ts-ignore */
|
|
3917
|
+
...(ngDevMode ? [{ debugName: "viewOnlyFields" }] : /* istanbul ignore next */ []));
|
|
3791
3918
|
hasExtraContent = computed(() => this.extraSections().length > 0 ||
|
|
3792
3919
|
this.editableFields().length > 0 ||
|
|
3793
|
-
this.viewOnlyFields().length > 0,
|
|
3794
|
-
|
|
3795
|
-
|
|
3796
|
-
|
|
3920
|
+
this.viewOnlyFields().length > 0, /* @ts-ignore */
|
|
3921
|
+
...(ngDevMode ? [{ debugName: "hasExtraContent" }] : /* istanbul ignore next */ []));
|
|
3922
|
+
extraFieldsModel = signal({}, /* @ts-ignore */
|
|
3923
|
+
...(ngDevMode ? [{ debugName: "extraFieldsModel" }] : /* istanbul ignore next */ []));
|
|
3924
|
+
originalExtraFieldsModel = signal({}, /* @ts-ignore */
|
|
3925
|
+
...(ngDevMode ? [{ debugName: "originalExtraFieldsModel" }] : /* istanbul ignore next */ []));
|
|
3926
|
+
adminFieldsModel = signal({}, /* @ts-ignore */
|
|
3927
|
+
...(ngDevMode ? [{ debugName: "adminFieldsModel" }] : /* istanbul ignore next */ []));
|
|
3797
3928
|
isExtraFieldsDirty = computed(() => {
|
|
3798
3929
|
const current = this.extraFieldsModel();
|
|
3799
3930
|
const original = this.originalExtraFieldsModel();
|
|
3800
3931
|
return JSON.stringify(current) !== JSON.stringify(original);
|
|
3801
|
-
},
|
|
3932
|
+
}, /* @ts-ignore */
|
|
3933
|
+
...(ngDevMode ? [{ debugName: "isExtraFieldsDirty" }] : /* istanbul ignore next */ []));
|
|
3802
3934
|
extraFieldsValidationError = computed(() => {
|
|
3803
3935
|
if (!this.profileExtension?.validateExtraFields)
|
|
3804
3936
|
return null;
|
|
3805
3937
|
return this.profileExtension.validateExtraFields(this.extraFieldsModel());
|
|
3806
|
-
},
|
|
3807
|
-
|
|
3808
|
-
|
|
3938
|
+
}, /* @ts-ignore */
|
|
3939
|
+
...(ngDevMode ? [{ debugName: "extraFieldsValidationError" }] : /* istanbul ignore next */ []));
|
|
3940
|
+
userEmail = computed(() => this.authState.user()?.email ?? '', /* @ts-ignore */
|
|
3941
|
+
...(ngDevMode ? [{ debugName: "userEmail" }] : /* istanbul ignore next */ []));
|
|
3942
|
+
userName = computed(() => this.authState.userName(), /* @ts-ignore */
|
|
3943
|
+
...(ngDevMode ? [{ debugName: "userName" }] : /* istanbul ignore next */ []));
|
|
3809
3944
|
userInitials = computed(() => {
|
|
3810
3945
|
const name = this.authState.user()?.name ?? '';
|
|
3811
3946
|
return name
|
|
@@ -3814,40 +3949,54 @@ class ProfilePageComponent {
|
|
|
3814
3949
|
.join('')
|
|
3815
3950
|
.toUpperCase()
|
|
3816
3951
|
.slice(0, 2);
|
|
3817
|
-
},
|
|
3818
|
-
|
|
3819
|
-
|
|
3820
|
-
|
|
3821
|
-
|
|
3952
|
+
}, /* @ts-ignore */
|
|
3953
|
+
...(ngDevMode ? [{ debugName: "userInitials" }] : /* istanbul ignore next */ []));
|
|
3954
|
+
companyName = computed(() => this.authState.companyName(), /* @ts-ignore */
|
|
3955
|
+
...(ngDevMode ? [{ debugName: "companyName" }] : /* istanbul ignore next */ []));
|
|
3956
|
+
branchName = computed(() => this.authState.branchName(), /* @ts-ignore */
|
|
3957
|
+
...(ngDevMode ? [{ debugName: "branchName" }] : /* istanbul ignore next */ []));
|
|
3958
|
+
showUploadSection = computed(() => isServiceEnabled(this.appConfig, 'storage') && this.fileProvider !== null, /* @ts-ignore */
|
|
3959
|
+
...(ngDevMode ? [{ debugName: "showUploadSection" }] : /* istanbul ignore next */ []));
|
|
3960
|
+
showCompanySection = computed(() => isCompanyFeatureEnabled(this.appConfig), /* @ts-ignore */
|
|
3961
|
+
...(ngDevMode ? [{ debugName: "showCompanySection" }] : /* istanbul ignore next */ []));
|
|
3822
3962
|
showPermissionsSection = computed(() => isServiceEnabled(this.appConfig, 'iam') &&
|
|
3823
|
-
this.permissionProvider !== null,
|
|
3824
|
-
|
|
3963
|
+
this.permissionProvider !== null, /* @ts-ignore */
|
|
3964
|
+
...(ngDevMode ? [{ debugName: "showPermissionsSection" }] : /* istanbul ignore next */ []));
|
|
3965
|
+
permissionMode = computed(() => getPermissionMode(this.appConfig), /* @ts-ignore */
|
|
3966
|
+
...(ngDevMode ? [{ debugName: "permissionMode" }] : /* istanbul ignore next */ []));
|
|
3825
3967
|
showRoles = computed(() => {
|
|
3826
3968
|
const mode = this.permissionMode();
|
|
3827
3969
|
return mode === 'rbac' || mode === 'full';
|
|
3828
|
-
},
|
|
3970
|
+
}, /* @ts-ignore */
|
|
3971
|
+
...(ngDevMode ? [{ debugName: "showRoles" }] : /* istanbul ignore next */ []));
|
|
3829
3972
|
showActions = computed(() => {
|
|
3830
3973
|
const mode = this.permissionMode();
|
|
3831
3974
|
return mode === 'direct' || mode === 'full';
|
|
3832
|
-
},
|
|
3833
|
-
|
|
3975
|
+
}, /* @ts-ignore */
|
|
3976
|
+
...(ngDevMode ? [{ debugName: "showActions" }] : /* istanbul ignore next */ []));
|
|
3977
|
+
showBottomRow = computed(() => this.showCompanySection() || this.showPermissionsSection(), /* @ts-ignore */
|
|
3978
|
+
...(ngDevMode ? [{ debugName: "showBottomRow" }] : /* istanbul ignore next */ []));
|
|
3834
3979
|
originalFormModel = signal({
|
|
3835
3980
|
name: '',
|
|
3836
3981
|
phone: '',
|
|
3837
|
-
},
|
|
3838
|
-
|
|
3982
|
+
}, /* @ts-ignore */
|
|
3983
|
+
...(ngDevMode ? [{ debugName: "originalFormModel" }] : /* istanbul ignore next */ []));
|
|
3984
|
+
formModel = signal({ name: '', phone: '' }, /* @ts-ignore */
|
|
3985
|
+
...(ngDevMode ? [{ debugName: "formModel" }] : /* istanbul ignore next */ []));
|
|
3839
3986
|
formTree = form(this.formModel, (f) => {
|
|
3840
3987
|
required(f.name, {
|
|
3841
3988
|
message: this.translate('shared.name.required'),
|
|
3842
3989
|
});
|
|
3843
3990
|
});
|
|
3844
|
-
isFormValid = computed(() => this.formModel().name.trim().length > 0,
|
|
3991
|
+
isFormValid = computed(() => this.formModel().name.trim().length > 0, /* @ts-ignore */
|
|
3992
|
+
...(ngDevMode ? [{ debugName: "isFormValid" }] : /* istanbul ignore next */ []));
|
|
3845
3993
|
isFormDirty = computed(() => {
|
|
3846
3994
|
const current = this.formModel();
|
|
3847
3995
|
const original = this.originalFormModel();
|
|
3848
3996
|
const basicDirty = current.name !== original.name || current.phone !== original.phone;
|
|
3849
3997
|
return basicDirty || this.isExtraFieldsDirty();
|
|
3850
|
-
},
|
|
3998
|
+
}, /* @ts-ignore */
|
|
3999
|
+
...(ngDevMode ? [{ debugName: "isFormDirty" }] : /* istanbul ignore next */ []));
|
|
3851
4000
|
updateExtraField(key, value) {
|
|
3852
4001
|
this.extraFieldsModel.update((model) => ({ ...model, [key]: value }));
|
|
3853
4002
|
}
|
|
@@ -3886,19 +4035,29 @@ class ProfilePageComponent {
|
|
|
3886
4035
|
currentPassword: '',
|
|
3887
4036
|
newPassword: '',
|
|
3888
4037
|
confirmPassword: '',
|
|
3889
|
-
},
|
|
3890
|
-
|
|
4038
|
+
}, /* @ts-ignore */
|
|
4039
|
+
...(ngDevMode ? [{ debugName: "passwordModel" }] : /* istanbul ignore next */ []));
|
|
4040
|
+
visiblePasswords = signal({
|
|
4041
|
+
currentPassword: false,
|
|
4042
|
+
newPassword: false,
|
|
4043
|
+
confirmPassword: false,
|
|
4044
|
+
}, /* @ts-ignore */
|
|
4045
|
+
...(ngDevMode ? [{ debugName: "visiblePasswords" }] : /* istanbul ignore next */ []));
|
|
4046
|
+
isPasswordLoading = signal(false, /* @ts-ignore */
|
|
4047
|
+
...(ngDevMode ? [{ debugName: "isPasswordLoading" }] : /* istanbul ignore next */ []));
|
|
3891
4048
|
isPasswordFormValid = computed(() => {
|
|
3892
4049
|
const model = this.passwordModel();
|
|
3893
4050
|
return (model.currentPassword.length > 0 &&
|
|
3894
4051
|
model.newPassword.length >= 6 &&
|
|
3895
4052
|
model.newPassword === model.confirmPassword);
|
|
3896
|
-
},
|
|
4053
|
+
}, /* @ts-ignore */
|
|
4054
|
+
...(ngDevMode ? [{ debugName: "isPasswordFormValid" }] : /* istanbul ignore next */ []));
|
|
3897
4055
|
passwordsMatch = computed(() => {
|
|
3898
4056
|
const model = this.passwordModel();
|
|
3899
4057
|
return (model.confirmPassword.length === 0 ||
|
|
3900
4058
|
model.newPassword === model.confirmPassword);
|
|
3901
|
-
},
|
|
4059
|
+
}, /* @ts-ignore */
|
|
4060
|
+
...(ngDevMode ? [{ debugName: "passwordsMatch" }] : /* istanbul ignore next */ []));
|
|
3902
4061
|
profileUploadOptions = {
|
|
3903
4062
|
folderPath: 'profile-pictures',
|
|
3904
4063
|
compress: true,
|
|
@@ -4084,6 +4243,9 @@ class ProfilePageComponent {
|
|
|
4084
4243
|
error: () => { },
|
|
4085
4244
|
});
|
|
4086
4245
|
}
|
|
4246
|
+
togglePasswordVisibility(field) {
|
|
4247
|
+
this.visiblePasswords.update((v) => ({ ...v, [field]: !v[field] }));
|
|
4248
|
+
}
|
|
4087
4249
|
updatePasswordField(field, value) {
|
|
4088
4250
|
this.passwordModel.update((model) => ({ ...model, [field]: value }));
|
|
4089
4251
|
}
|
|
@@ -4116,8 +4278,8 @@ class ProfilePageComponent {
|
|
|
4116
4278
|
error: () => { },
|
|
4117
4279
|
});
|
|
4118
4280
|
}
|
|
4119
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
4120
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "
|
|
4281
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: ProfilePageComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
4282
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.5", type: ProfilePageComponent, isStandalone: true, selector: "lib-profile-page", ngImport: i0, template: `
|
|
4121
4283
|
<div class="mb-4 md:mb-6">
|
|
4122
4284
|
<h1 class="text-2xl font-bold text-color mb-2">
|
|
4123
4285
|
{{ 'profile.title' | translate }}
|
|
@@ -4414,13 +4576,18 @@ class ProfilePageComponent {
|
|
|
4414
4576
|
</ng-template>
|
|
4415
4577
|
|
|
4416
4578
|
<div class="flex justify-end pt-4">
|
|
4417
|
-
<
|
|
4418
|
-
|
|
4419
|
-
icon="pi pi-check"
|
|
4579
|
+
<button
|
|
4580
|
+
pButton
|
|
4420
4581
|
type="submit"
|
|
4421
|
-
[loading]="isLoading()"
|
|
4422
4582
|
[disabled]="!isFormValid() || !isFormDirty() || isLoading()"
|
|
4423
|
-
|
|
4583
|
+
>
|
|
4584
|
+
@if (isLoading()) {
|
|
4585
|
+
<span pButtonIcon class="pi pi-spinner pi-spin"></span>
|
|
4586
|
+
} @else {
|
|
4587
|
+
<span pButtonIcon class="pi pi-check"></span>
|
|
4588
|
+
}
|
|
4589
|
+
<span pButtonLabel>{{ 'shared.save.changes' | translate }}</span>
|
|
4590
|
+
</button>
|
|
4424
4591
|
</div>
|
|
4425
4592
|
</form>
|
|
4426
4593
|
</div>
|
|
@@ -4440,51 +4607,81 @@ class ProfilePageComponent {
|
|
|
4440
4607
|
<label for="currentPassword" class="font-medium text-color"
|
|
4441
4608
|
>{{ 'profile.current.password' | translate }} *</label
|
|
4442
4609
|
>
|
|
4443
|
-
<p-
|
|
4444
|
-
|
|
4445
|
-
|
|
4446
|
-
|
|
4447
|
-
|
|
4448
|
-
|
|
4449
|
-
|
|
4450
|
-
|
|
4451
|
-
|
|
4452
|
-
|
|
4453
|
-
|
|
4610
|
+
<p-iconfield iconPosition="right" class="w-full">
|
|
4611
|
+
<input
|
|
4612
|
+
pInputText
|
|
4613
|
+
pInputPassword
|
|
4614
|
+
id="currentPassword"
|
|
4615
|
+
name="currentPassword"
|
|
4616
|
+
[mask]="!visiblePasswords().currentPassword"
|
|
4617
|
+
[ngModel]="passwordModel().currentPassword"
|
|
4618
|
+
(ngModelChange)="updatePasswordField('currentPassword', $event)"
|
|
4619
|
+
[placeholder]="'profile.current.password.placeholder' | translate"
|
|
4620
|
+
class="w-full"
|
|
4621
|
+
/>
|
|
4622
|
+
<p-inputicon
|
|
4623
|
+
[class]="
|
|
4624
|
+
visiblePasswords().currentPassword
|
|
4625
|
+
? 'pi pi-eye-slash cursor-pointer'
|
|
4626
|
+
: 'pi pi-eye cursor-pointer'
|
|
4627
|
+
"
|
|
4628
|
+
(click)="togglePasswordVisibility('currentPassword')"
|
|
4629
|
+
/>
|
|
4630
|
+
</p-iconfield>
|
|
4454
4631
|
</div>
|
|
4455
4632
|
|
|
4456
4633
|
<div class="flex flex-col gap-2">
|
|
4457
4634
|
<label for="newPassword" class="font-medium text-color"
|
|
4458
4635
|
>{{ 'profile.new.password' | translate }} *</label
|
|
4459
4636
|
>
|
|
4460
|
-
<p-
|
|
4461
|
-
|
|
4462
|
-
|
|
4463
|
-
|
|
4464
|
-
|
|
4465
|
-
|
|
4466
|
-
|
|
4467
|
-
|
|
4468
|
-
|
|
4469
|
-
|
|
4470
|
-
|
|
4637
|
+
<p-iconfield iconPosition="right" class="w-full">
|
|
4638
|
+
<input
|
|
4639
|
+
pInputText
|
|
4640
|
+
pInputPassword
|
|
4641
|
+
id="newPassword"
|
|
4642
|
+
name="newPassword"
|
|
4643
|
+
[mask]="!visiblePasswords().newPassword"
|
|
4644
|
+
[ngModel]="passwordModel().newPassword"
|
|
4645
|
+
(ngModelChange)="updatePasswordField('newPassword', $event)"
|
|
4646
|
+
[placeholder]="'shared.min.characters' | translate: { count: 6 }"
|
|
4647
|
+
class="w-full"
|
|
4648
|
+
/>
|
|
4649
|
+
<p-inputicon
|
|
4650
|
+
[class]="
|
|
4651
|
+
visiblePasswords().newPassword
|
|
4652
|
+
? 'pi pi-eye-slash cursor-pointer'
|
|
4653
|
+
: 'pi pi-eye cursor-pointer'
|
|
4654
|
+
"
|
|
4655
|
+
(click)="togglePasswordVisibility('newPassword')"
|
|
4656
|
+
/>
|
|
4657
|
+
</p-iconfield>
|
|
4471
4658
|
</div>
|
|
4472
4659
|
|
|
4473
4660
|
<div class="flex flex-col gap-2">
|
|
4474
4661
|
<label for="confirmPassword" class="font-medium text-color"
|
|
4475
4662
|
>{{ 'profile.confirm.password' | translate }} *</label
|
|
4476
4663
|
>
|
|
4477
|
-
<p-
|
|
4478
|
-
|
|
4479
|
-
|
|
4480
|
-
|
|
4481
|
-
|
|
4482
|
-
|
|
4483
|
-
|
|
4484
|
-
|
|
4485
|
-
|
|
4486
|
-
|
|
4487
|
-
|
|
4664
|
+
<p-iconfield iconPosition="right" class="w-full">
|
|
4665
|
+
<input
|
|
4666
|
+
pInputText
|
|
4667
|
+
pInputPassword
|
|
4668
|
+
id="confirmPassword"
|
|
4669
|
+
name="confirmPassword"
|
|
4670
|
+
[mask]="!visiblePasswords().confirmPassword"
|
|
4671
|
+
[ngModel]="passwordModel().confirmPassword"
|
|
4672
|
+
(ngModelChange)="updatePasswordField('confirmPassword', $event)"
|
|
4673
|
+
[placeholder]="'profile.confirm.password.placeholder' | translate"
|
|
4674
|
+
class="w-full"
|
|
4675
|
+
/>
|
|
4676
|
+
<p-inputicon
|
|
4677
|
+
[class]="
|
|
4678
|
+
visiblePasswords().confirmPassword
|
|
4679
|
+
? 'pi pi-eye-slash cursor-pointer'
|
|
4680
|
+
: 'pi pi-eye cursor-pointer'
|
|
4681
|
+
"
|
|
4682
|
+
(click)="togglePasswordVisibility('confirmPassword')"
|
|
4683
|
+
/>
|
|
4684
|
+
</p-iconfield>
|
|
4488
4685
|
@if (!passwordsMatch()) {
|
|
4489
4686
|
<small class="text-danger">{{
|
|
4490
4687
|
'auth.register.passwords.do.not.match' | translate
|
|
@@ -4494,13 +4691,18 @@ class ProfilePageComponent {
|
|
|
4494
4691
|
</div>
|
|
4495
4692
|
|
|
4496
4693
|
<div class="flex justify-end">
|
|
4497
|
-
<
|
|
4498
|
-
|
|
4499
|
-
icon="pi pi-key"
|
|
4694
|
+
<button
|
|
4695
|
+
pButton
|
|
4500
4696
|
type="submit"
|
|
4501
|
-
[loading]="isPasswordLoading()"
|
|
4502
4697
|
[disabled]="!isPasswordFormValid() || isPasswordLoading()"
|
|
4503
|
-
|
|
4698
|
+
>
|
|
4699
|
+
@if (isPasswordLoading()) {
|
|
4700
|
+
<span pButtonIcon class="pi pi-spinner pi-spin"></span>
|
|
4701
|
+
} @else {
|
|
4702
|
+
<span pButtonIcon class="pi pi-key"></span>
|
|
4703
|
+
}
|
|
4704
|
+
<span pButtonLabel>{{ 'profile.change.password' | translate }}</span>
|
|
4705
|
+
</button>
|
|
4504
4706
|
</div>
|
|
4505
4707
|
</form>
|
|
4506
4708
|
</div>
|
|
@@ -4653,9 +4855,9 @@ class ProfilePageComponent {
|
|
|
4653
4855
|
}
|
|
4654
4856
|
</div>
|
|
4655
4857
|
}
|
|
4656
|
-
`, isInline: true, dependencies: [{ kind: "ngmodule", type: AngularModule }, { kind: "directive", type: i1$1.NgComponentOutlet, selector: "[ngComponentOutlet]", inputs: ["ngComponentOutlet", "ngComponentOutletInputs", "ngComponentOutletInjector", "ngComponentOutletEnvironmentInjector", "ngComponentOutletContent", "ngComponentOutletNgModule"], exportAs: ["ngComponentOutlet"] }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1.SelectControlValueAccessor, selector: "select:not([multiple])[formControlName],select:not([multiple])[formControl],select:not([multiple])[ngModel]", inputs: ["compareWith"] }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i1.NgForm, selector: "form:not([ngNoForm]):not([formGroup]):not([formArray]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "ngmodule", type: PrimeModule }, { kind: "component", type: i3$
|
|
4858
|
+
`, isInline: true, dependencies: [{ kind: "ngmodule", type: AngularModule }, { kind: "directive", type: i1$1.NgComponentOutlet, selector: "[ngComponentOutlet]", inputs: ["ngComponentOutlet", "ngComponentOutletInputs", "ngComponentOutletInjector", "ngComponentOutletEnvironmentInjector", "ngComponentOutletContent", "ngComponentOutletNgModule"], exportAs: ["ngComponentOutlet"] }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1.DefaultValueAccessor, selector: "input:not([type=checkbox]):not([ngNoCva])[formControlName],textarea:not([ngNoCva])[formControlName],input:not([type=checkbox]):not([ngNoCva])[formControl],textarea:not([ngNoCva])[formControl],input:not([type=checkbox]):not([ngNoCva])[ngModel],textarea:not([ngNoCva])[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1.SelectControlValueAccessor, selector: "select:not([multiple]):not([ngNoCva])[formControlName],select:not([multiple]):not([ngNoCva])[formControl],select:not([multiple]):not([ngNoCva])[ngModel]", inputs: ["compareWith"] }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i1.NgForm, selector: "form:not([ngNoForm]):not([formGroup]):not([formArray]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "ngmodule", type: PrimeModule }, { kind: "component", type: i3$2.Avatar, selector: "p-avatar", inputs: ["label", "icon", "image", "size", "shape", "ariaLabel", "ariaLabelledBy"], outputs: ["onImageError"] }, { kind: "directive", type: i3.ButtonDirective, selector: "[pButton]", inputs: ["pButton", "pButtonPT", "pButtonUnstyled", "hostName", "text", "plain", "raised", "size", "outlined", "link", "rounded", "fluid", "variant", "iconOnly", "loading", "severity"] }, { kind: "directive", type: i3.ButtonLabel, selector: "[pButtonLabel]", inputs: ["pButtonLabelPT", "pButtonLabelUnstyled"] }, { kind: "directive", type: i3.ButtonIcon, selector: "[pButtonIcon]", inputs: ["pButtonIconPT", "pButtonUnstyled"] }, { kind: "component", type: i5$1.IconField, selector: "p-iconfield, p-icon-field", inputs: ["hostName", "iconPosition"] }, { kind: "component", type: i6$1.InputIcon, selector: "p-inputicon", inputs: ["hostName"] }, { kind: "directive", type: i7$1.InputPassword, selector: "[pInputPassword]", inputs: ["mask"], outputs: ["maskChange"] }, { kind: "directive", type: i4.InputText, selector: "[pInputText]", inputs: ["hostName", "pInputTextPT", "pInputTextUnstyled", "pSize", "variant", "fluid", "invalid"] }, { kind: "component", type: i9.Skeleton, selector: "p-skeleton", inputs: ["shape", "animation", "borderRadius", "size", "width", "height"] }, { kind: "component", type: i6.Tag, selector: "p-tag", inputs: ["severity", "value", "icon", "rounded"] }, { kind: "directive", type: i11.Textarea, selector: "[pTextarea], [pInputTextarea]", inputs: ["pTextareaPT", "pTextareaUnstyled", "autoResize", "pSize", "variant", "fluid", "invalid"], outputs: ["onResize"] }, { kind: "directive", type: FormField, selector: "[formField]", inputs: ["formField"], exportAs: ["formField"] }, { kind: "component", type: FileUploaderComponent, selector: "lib-file-uploader", inputs: ["uploadFile", "uploadMultipleFiles", "acceptTypes", "multiple", "maxFiles", "maxSizeMb", "uploadOptions", "disabled", "showPreview", "autoUpload"], outputs: ["fileUploaded", "filesUploaded", "onError", "fileSelected"] }, { kind: "directive", type: HasPermissionDirective, selector: "[hasPermission]", inputs: ["hasPermission"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }] });
|
|
4657
4859
|
}
|
|
4658
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
4860
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: ProfilePageComponent, decorators: [{
|
|
4659
4861
|
type: Component,
|
|
4660
4862
|
args: [{
|
|
4661
4863
|
selector: 'lib-profile-page',
|
|
@@ -4964,13 +5166,18 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.5", ngImpor
|
|
|
4964
5166
|
</ng-template>
|
|
4965
5167
|
|
|
4966
5168
|
<div class="flex justify-end pt-4">
|
|
4967
|
-
<
|
|
4968
|
-
|
|
4969
|
-
icon="pi pi-check"
|
|
5169
|
+
<button
|
|
5170
|
+
pButton
|
|
4970
5171
|
type="submit"
|
|
4971
|
-
[loading]="isLoading()"
|
|
4972
5172
|
[disabled]="!isFormValid() || !isFormDirty() || isLoading()"
|
|
4973
|
-
|
|
5173
|
+
>
|
|
5174
|
+
@if (isLoading()) {
|
|
5175
|
+
<span pButtonIcon class="pi pi-spinner pi-spin"></span>
|
|
5176
|
+
} @else {
|
|
5177
|
+
<span pButtonIcon class="pi pi-check"></span>
|
|
5178
|
+
}
|
|
5179
|
+
<span pButtonLabel>{{ 'shared.save.changes' | translate }}</span>
|
|
5180
|
+
</button>
|
|
4974
5181
|
</div>
|
|
4975
5182
|
</form>
|
|
4976
5183
|
</div>
|
|
@@ -4990,51 +5197,81 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.5", ngImpor
|
|
|
4990
5197
|
<label for="currentPassword" class="font-medium text-color"
|
|
4991
5198
|
>{{ 'profile.current.password' | translate }} *</label
|
|
4992
5199
|
>
|
|
4993
|
-
<p-
|
|
4994
|
-
|
|
4995
|
-
|
|
4996
|
-
|
|
4997
|
-
|
|
4998
|
-
|
|
4999
|
-
|
|
5000
|
-
|
|
5001
|
-
|
|
5002
|
-
|
|
5003
|
-
|
|
5200
|
+
<p-iconfield iconPosition="right" class="w-full">
|
|
5201
|
+
<input
|
|
5202
|
+
pInputText
|
|
5203
|
+
pInputPassword
|
|
5204
|
+
id="currentPassword"
|
|
5205
|
+
name="currentPassword"
|
|
5206
|
+
[mask]="!visiblePasswords().currentPassword"
|
|
5207
|
+
[ngModel]="passwordModel().currentPassword"
|
|
5208
|
+
(ngModelChange)="updatePasswordField('currentPassword', $event)"
|
|
5209
|
+
[placeholder]="'profile.current.password.placeholder' | translate"
|
|
5210
|
+
class="w-full"
|
|
5211
|
+
/>
|
|
5212
|
+
<p-inputicon
|
|
5213
|
+
[class]="
|
|
5214
|
+
visiblePasswords().currentPassword
|
|
5215
|
+
? 'pi pi-eye-slash cursor-pointer'
|
|
5216
|
+
: 'pi pi-eye cursor-pointer'
|
|
5217
|
+
"
|
|
5218
|
+
(click)="togglePasswordVisibility('currentPassword')"
|
|
5219
|
+
/>
|
|
5220
|
+
</p-iconfield>
|
|
5004
5221
|
</div>
|
|
5005
5222
|
|
|
5006
5223
|
<div class="flex flex-col gap-2">
|
|
5007
5224
|
<label for="newPassword" class="font-medium text-color"
|
|
5008
5225
|
>{{ 'profile.new.password' | translate }} *</label
|
|
5009
5226
|
>
|
|
5010
|
-
<p-
|
|
5011
|
-
|
|
5012
|
-
|
|
5013
|
-
|
|
5014
|
-
|
|
5015
|
-
|
|
5016
|
-
|
|
5017
|
-
|
|
5018
|
-
|
|
5019
|
-
|
|
5020
|
-
|
|
5227
|
+
<p-iconfield iconPosition="right" class="w-full">
|
|
5228
|
+
<input
|
|
5229
|
+
pInputText
|
|
5230
|
+
pInputPassword
|
|
5231
|
+
id="newPassword"
|
|
5232
|
+
name="newPassword"
|
|
5233
|
+
[mask]="!visiblePasswords().newPassword"
|
|
5234
|
+
[ngModel]="passwordModel().newPassword"
|
|
5235
|
+
(ngModelChange)="updatePasswordField('newPassword', $event)"
|
|
5236
|
+
[placeholder]="'shared.min.characters' | translate: { count: 6 }"
|
|
5237
|
+
class="w-full"
|
|
5238
|
+
/>
|
|
5239
|
+
<p-inputicon
|
|
5240
|
+
[class]="
|
|
5241
|
+
visiblePasswords().newPassword
|
|
5242
|
+
? 'pi pi-eye-slash cursor-pointer'
|
|
5243
|
+
: 'pi pi-eye cursor-pointer'
|
|
5244
|
+
"
|
|
5245
|
+
(click)="togglePasswordVisibility('newPassword')"
|
|
5246
|
+
/>
|
|
5247
|
+
</p-iconfield>
|
|
5021
5248
|
</div>
|
|
5022
5249
|
|
|
5023
5250
|
<div class="flex flex-col gap-2">
|
|
5024
5251
|
<label for="confirmPassword" class="font-medium text-color"
|
|
5025
5252
|
>{{ 'profile.confirm.password' | translate }} *</label
|
|
5026
5253
|
>
|
|
5027
|
-
<p-
|
|
5028
|
-
|
|
5029
|
-
|
|
5030
|
-
|
|
5031
|
-
|
|
5032
|
-
|
|
5033
|
-
|
|
5034
|
-
|
|
5035
|
-
|
|
5036
|
-
|
|
5037
|
-
|
|
5254
|
+
<p-iconfield iconPosition="right" class="w-full">
|
|
5255
|
+
<input
|
|
5256
|
+
pInputText
|
|
5257
|
+
pInputPassword
|
|
5258
|
+
id="confirmPassword"
|
|
5259
|
+
name="confirmPassword"
|
|
5260
|
+
[mask]="!visiblePasswords().confirmPassword"
|
|
5261
|
+
[ngModel]="passwordModel().confirmPassword"
|
|
5262
|
+
(ngModelChange)="updatePasswordField('confirmPassword', $event)"
|
|
5263
|
+
[placeholder]="'profile.confirm.password.placeholder' | translate"
|
|
5264
|
+
class="w-full"
|
|
5265
|
+
/>
|
|
5266
|
+
<p-inputicon
|
|
5267
|
+
[class]="
|
|
5268
|
+
visiblePasswords().confirmPassword
|
|
5269
|
+
? 'pi pi-eye-slash cursor-pointer'
|
|
5270
|
+
: 'pi pi-eye cursor-pointer'
|
|
5271
|
+
"
|
|
5272
|
+
(click)="togglePasswordVisibility('confirmPassword')"
|
|
5273
|
+
/>
|
|
5274
|
+
</p-iconfield>
|
|
5038
5275
|
@if (!passwordsMatch()) {
|
|
5039
5276
|
<small class="text-danger">{{
|
|
5040
5277
|
'auth.register.passwords.do.not.match' | translate
|
|
@@ -5044,13 +5281,18 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.5", ngImpor
|
|
|
5044
5281
|
</div>
|
|
5045
5282
|
|
|
5046
5283
|
<div class="flex justify-end">
|
|
5047
|
-
<
|
|
5048
|
-
|
|
5049
|
-
icon="pi pi-key"
|
|
5284
|
+
<button
|
|
5285
|
+
pButton
|
|
5050
5286
|
type="submit"
|
|
5051
|
-
[loading]="isPasswordLoading()"
|
|
5052
5287
|
[disabled]="!isPasswordFormValid() || isPasswordLoading()"
|
|
5053
|
-
|
|
5288
|
+
>
|
|
5289
|
+
@if (isPasswordLoading()) {
|
|
5290
|
+
<span pButtonIcon class="pi pi-spinner pi-spin"></span>
|
|
5291
|
+
} @else {
|
|
5292
|
+
<span pButtonIcon class="pi pi-key"></span>
|
|
5293
|
+
}
|
|
5294
|
+
<span pButtonLabel>{{ 'profile.change.password' | translate }}</span>
|
|
5295
|
+
</button>
|
|
5054
5296
|
</div>
|
|
5055
5297
|
</form>
|
|
5056
5298
|
</div>
|
|
@@ -5234,34 +5476,47 @@ class RegisterPageComponent {
|
|
|
5234
5476
|
}
|
|
5235
5477
|
queryParamMap = toSignal(this.route.queryParamMap);
|
|
5236
5478
|
companySlugInitialized = false;
|
|
5237
|
-
returnUrl = input('',
|
|
5238
|
-
|
|
5239
|
-
|
|
5240
|
-
|
|
5241
|
-
|
|
5242
|
-
|
|
5243
|
-
|
|
5479
|
+
returnUrl = input('', /* @ts-ignore */
|
|
5480
|
+
...(ngDevMode ? [{ debugName: "returnUrl" }] : /* istanbul ignore next */ []));
|
|
5481
|
+
isLoading = signal(false, /* @ts-ignore */
|
|
5482
|
+
...(ngDevMode ? [{ debugName: "isLoading" }] : /* istanbul ignore next */ []));
|
|
5483
|
+
companyFeatureEnabled = computed(() => isCompanyFeatureEnabled(this.appConfig), /* @ts-ignore */
|
|
5484
|
+
...(ngDevMode ? [{ debugName: "companyFeatureEnabled" }] : /* istanbul ignore next */ []));
|
|
5485
|
+
defaultCompanySlug = computed(() => getDefaultCompanySlug(this.appConfig), /* @ts-ignore */
|
|
5486
|
+
...(ngDevMode ? [{ debugName: "defaultCompanySlug" }] : /* istanbul ignore next */ []));
|
|
5487
|
+
defaultBranchSlug = computed(() => getDefaultBranchSlug(this.appConfig), /* @ts-ignore */
|
|
5488
|
+
...(ngDevMode ? [{ debugName: "defaultBranchSlug" }] : /* istanbul ignore next */ []));
|
|
5489
|
+
hasDefaultCompany = computed(() => !!this.defaultCompanySlug(), /* @ts-ignore */
|
|
5490
|
+
...(ngDevMode ? [{ debugName: "hasDefaultCompany" }] : /* istanbul ignore next */ []));
|
|
5491
|
+
hasDefaultBranch = computed(() => !!this.defaultBranchSlug(), /* @ts-ignore */
|
|
5492
|
+
...(ngDevMode ? [{ debugName: "hasDefaultBranch" }] : /* istanbul ignore next */ []));
|
|
5244
5493
|
extraFields = computed(() => {
|
|
5245
5494
|
if (!this.registrationExtension)
|
|
5246
5495
|
return [];
|
|
5247
5496
|
const fields = this.registrationExtension.getExtraFields();
|
|
5248
5497
|
return fields.sort((a, b) => (a.order ?? 100) - (b.order ?? 100));
|
|
5249
|
-
},
|
|
5250
|
-
|
|
5498
|
+
}, /* @ts-ignore */
|
|
5499
|
+
...(ngDevMode ? [{ debugName: "extraFields" }] : /* istanbul ignore next */ []));
|
|
5500
|
+
extraFieldsModel = signal({}, /* @ts-ignore */
|
|
5501
|
+
...(ngDevMode ? [{ debugName: "extraFieldsModel" }] : /* istanbul ignore next */ []));
|
|
5251
5502
|
emailErrorMessage = computed(() => this.validationConfig?.email?.message ??
|
|
5252
|
-
this.translate('shared.invalid.email'),
|
|
5253
|
-
|
|
5503
|
+
this.translate('shared.invalid.email'), /* @ts-ignore */
|
|
5504
|
+
...(ngDevMode ? [{ debugName: "emailErrorMessage" }] : /* istanbul ignore next */ []));
|
|
5505
|
+
passwordMinLength = computed(() => this.validationConfig?.password?.minLength ?? 8, /* @ts-ignore */
|
|
5506
|
+
...(ngDevMode ? [{ debugName: "passwordMinLength" }] : /* istanbul ignore next */ []));
|
|
5254
5507
|
passwordErrorMessage = computed(() => this.validationConfig?.password?.message ??
|
|
5255
5508
|
this.translate('auth.validation.password.min.length', {
|
|
5256
5509
|
min: this.passwordMinLength(),
|
|
5257
|
-
}),
|
|
5510
|
+
}), /* @ts-ignore */
|
|
5511
|
+
...(ngDevMode ? [{ debugName: "passwordErrorMessage" }] : /* istanbul ignore next */ []));
|
|
5258
5512
|
userFormModel = signal({
|
|
5259
5513
|
name: '',
|
|
5260
5514
|
email: '',
|
|
5261
5515
|
password: '',
|
|
5262
5516
|
confirmPassword: '',
|
|
5263
5517
|
phone: '',
|
|
5264
|
-
},
|
|
5518
|
+
}, /* @ts-ignore */
|
|
5519
|
+
...(ngDevMode ? [{ debugName: "userFormModel" }] : /* istanbul ignore next */ []));
|
|
5265
5520
|
userForm = form(this.userFormModel, (f) => {
|
|
5266
5521
|
required(f.name, {
|
|
5267
5522
|
message: this.translate('shared.name.required'),
|
|
@@ -5290,14 +5545,16 @@ class RegisterPageComponent {
|
|
|
5290
5545
|
newCompanyName: '',
|
|
5291
5546
|
newCompanyPhone: '',
|
|
5292
5547
|
newCompanyAddress: '',
|
|
5293
|
-
},
|
|
5548
|
+
}, /* @ts-ignore */
|
|
5549
|
+
...(ngDevMode ? [{ debugName: "companyFormModel" }] : /* istanbul ignore next */ []));
|
|
5294
5550
|
companyForm = form(this.companyFormModel);
|
|
5295
5551
|
emailValidationError = computed(() => {
|
|
5296
5552
|
const email = this.userFormModel().email;
|
|
5297
5553
|
if (!email)
|
|
5298
5554
|
return null;
|
|
5299
5555
|
return validateEmail(email, this.validationConfig?.email ?? undefined);
|
|
5300
|
-
},
|
|
5556
|
+
}, /* @ts-ignore */
|
|
5557
|
+
...(ngDevMode ? [{ debugName: "emailValidationError" }] : /* istanbul ignore next */ []));
|
|
5301
5558
|
passwordValidationError = computed(() => {
|
|
5302
5559
|
const password = this.userFormModel().password;
|
|
5303
5560
|
if (!password)
|
|
@@ -5305,16 +5562,19 @@ class RegisterPageComponent {
|
|
|
5305
5562
|
if (!this.validationConfig?.password)
|
|
5306
5563
|
return null;
|
|
5307
5564
|
return validatePassword(password, this.validationConfig.password);
|
|
5308
|
-
},
|
|
5565
|
+
}, /* @ts-ignore */
|
|
5566
|
+
...(ngDevMode ? [{ debugName: "passwordValidationError" }] : /* istanbul ignore next */ []));
|
|
5309
5567
|
extraFieldsValidationError = computed(() => {
|
|
5310
5568
|
if (!this.registrationExtension?.validateExtraFields)
|
|
5311
5569
|
return null;
|
|
5312
5570
|
return this.registrationExtension.validateExtraFields(this.extraFieldsModel());
|
|
5313
|
-
},
|
|
5571
|
+
}, /* @ts-ignore */
|
|
5572
|
+
...(ngDevMode ? [{ debugName: "extraFieldsValidationError" }] : /* istanbul ignore next */ []));
|
|
5314
5573
|
passwordsMatch = computed(() => {
|
|
5315
5574
|
const model = this.userFormModel();
|
|
5316
5575
|
return model.password === model.confirmPassword;
|
|
5317
|
-
},
|
|
5576
|
+
}, /* @ts-ignore */
|
|
5577
|
+
...(ngDevMode ? [{ debugName: "passwordsMatch" }] : /* istanbul ignore next */ []));
|
|
5318
5578
|
isFormValid = computed(() => {
|
|
5319
5579
|
const userModel = this.userFormModel();
|
|
5320
5580
|
const emailError = this.emailValidationError();
|
|
@@ -5338,7 +5598,8 @@ class RegisterPageComponent {
|
|
|
5338
5598
|
companyModel.newCompanyName.trim().length > 0);
|
|
5339
5599
|
}
|
|
5340
5600
|
return userValid && extraFieldsValid;
|
|
5341
|
-
},
|
|
5601
|
+
}, /* @ts-ignore */
|
|
5602
|
+
...(ngDevMode ? [{ debugName: "isFormValid" }] : /* istanbul ignore next */ []));
|
|
5342
5603
|
validateRequiredExtraFields() {
|
|
5343
5604
|
const fields = this.extraFields();
|
|
5344
5605
|
const values = this.extraFieldsModel();
|
|
@@ -5497,8 +5758,8 @@ class RegisterPageComponent {
|
|
|
5497
5758
|
},
|
|
5498
5759
|
});
|
|
5499
5760
|
}
|
|
5500
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
5501
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "
|
|
5761
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: RegisterPageComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
5762
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.5", type: RegisterPageComponent, isStandalone: true, selector: "lib-register-page", inputs: { returnUrl: { classPropertyName: "returnUrl", publicName: "returnUrl", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: `
|
|
5502
5763
|
<app-floating-configurator />
|
|
5503
5764
|
<div
|
|
5504
5765
|
class="bg-surface-ground flex items-center justify-center min-h-screen py-8"
|
|
@@ -5954,13 +6215,17 @@ class RegisterPageComponent {
|
|
|
5954
6215
|
</div>
|
|
5955
6216
|
}
|
|
5956
6217
|
|
|
5957
|
-
<
|
|
5958
|
-
|
|
6218
|
+
<button
|
|
6219
|
+
pButton
|
|
5959
6220
|
class="w-full mt-4"
|
|
5960
6221
|
type="submit"
|
|
5961
|
-
[loading]="isLoading()"
|
|
5962
6222
|
[disabled]="!isFormValid() || isLoading()"
|
|
5963
|
-
|
|
6223
|
+
>
|
|
6224
|
+
@if (isLoading()) {
|
|
6225
|
+
<span pButtonIcon class="pi pi-spinner pi-spin"></span>
|
|
6226
|
+
}
|
|
6227
|
+
<span pButtonLabel>{{ 'auth.register.create.account' | translate }}</span>
|
|
6228
|
+
</button>
|
|
5964
6229
|
|
|
5965
6230
|
<div class="flex items-center justify-center mt-4 gap-2">
|
|
5966
6231
|
<span class="font-medium">{{
|
|
@@ -5978,9 +6243,9 @@ class RegisterPageComponent {
|
|
|
5978
6243
|
</div>
|
|
5979
6244
|
</div>
|
|
5980
6245
|
</div>
|
|
5981
|
-
`, isInline: true, dependencies: [{ kind: "ngmodule", type: AngularModule }, { kind: "directive", type: i1$1.NgComponentOutlet, selector: "[ngComponentOutlet]", inputs: ["ngComponentOutlet", "ngComponentOutletInputs", "ngComponentOutletInjector", "ngComponentOutletEnvironmentInjector", "ngComponentOutletContent", "ngComponentOutletNgModule"], exportAs: ["ngComponentOutlet"] }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.NgForm, selector: "form:not([ngNoForm]):not([formGroup]):not([formArray]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i2
|
|
6246
|
+
`, isInline: true, dependencies: [{ kind: "ngmodule", type: AngularModule }, { kind: "directive", type: i1$1.NgComponentOutlet, selector: "[ngComponentOutlet]", inputs: ["ngComponentOutlet", "ngComponentOutletInputs", "ngComponentOutletInjector", "ngComponentOutletEnvironmentInjector", "ngComponentOutletContent", "ngComponentOutletNgModule"], exportAs: ["ngComponentOutlet"] }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.NgForm, selector: "form:not([ngNoForm]):not([formGroup]):not([formArray]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "browserUrl", "routerLink"] }, { kind: "ngmodule", type: PrimeModule }, { kind: "directive", type: i3.ButtonDirective, selector: "[pButton]", inputs: ["pButton", "pButtonPT", "pButtonUnstyled", "hostName", "text", "plain", "raised", "size", "outlined", "link", "rounded", "fluid", "variant", "iconOnly", "loading", "severity"] }, { kind: "directive", type: i3.ButtonLabel, selector: "[pButtonLabel]", inputs: ["pButtonLabelPT", "pButtonLabelUnstyled"] }, { kind: "directive", type: i3.ButtonIcon, selector: "[pButtonIcon]", inputs: ["pButtonIconPT", "pButtonUnstyled"] }, { kind: "directive", type: i4.InputText, selector: "[pInputText]", inputs: ["hostName", "pInputTextPT", "pInputTextUnstyled", "pSize", "variant", "fluid", "invalid"] }, { kind: "directive", type: i11.Textarea, selector: "[pTextarea], [pInputTextarea]", inputs: ["pTextareaPT", "pTextareaUnstyled", "autoResize", "pSize", "variant", "fluid", "invalid"], outputs: ["onResize"] }, { kind: "directive", type: FormField, selector: "[formField]", inputs: ["formField"], exportAs: ["formField"] }, { kind: "component", type: AppFloatingConfigurator, selector: "app-floating-configurator" }, { kind: "pipe", type: TranslatePipe, name: "translate" }] });
|
|
5982
6247
|
}
|
|
5983
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
6248
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: RegisterPageComponent, decorators: [{
|
|
5984
6249
|
type: Component,
|
|
5985
6250
|
args: [{
|
|
5986
6251
|
selector: 'lib-register-page',
|
|
@@ -6447,13 +6712,17 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.5", ngImpor
|
|
|
6447
6712
|
</div>
|
|
6448
6713
|
}
|
|
6449
6714
|
|
|
6450
|
-
<
|
|
6451
|
-
|
|
6715
|
+
<button
|
|
6716
|
+
pButton
|
|
6452
6717
|
class="w-full mt-4"
|
|
6453
6718
|
type="submit"
|
|
6454
|
-
[loading]="isLoading()"
|
|
6455
6719
|
[disabled]="!isFormValid() || isLoading()"
|
|
6456
|
-
|
|
6720
|
+
>
|
|
6721
|
+
@if (isLoading()) {
|
|
6722
|
+
<span pButtonIcon class="pi pi-spinner pi-spin"></span>
|
|
6723
|
+
}
|
|
6724
|
+
<span pButtonLabel>{{ 'auth.register.create.account' | translate }}</span>
|
|
6725
|
+
</button>
|
|
6457
6726
|
|
|
6458
6727
|
<div class="flex items-center justify-center mt-4 gap-2">
|
|
6459
6728
|
<span class="font-medium">{{
|
|
@@ -6494,12 +6763,15 @@ class ResetPasswordPageComponent {
|
|
|
6494
6763
|
queryParams = toSignal(this.route.queryParams);
|
|
6495
6764
|
tokenInitialized = false;
|
|
6496
6765
|
token = '';
|
|
6497
|
-
isLoading = signal(false,
|
|
6498
|
-
|
|
6766
|
+
isLoading = signal(false, /* @ts-ignore */
|
|
6767
|
+
...(ngDevMode ? [{ debugName: "isLoading" }] : /* istanbul ignore next */ []));
|
|
6768
|
+
pageState = signal('form', /* @ts-ignore */
|
|
6769
|
+
...(ngDevMode ? [{ debugName: "pageState" }] : /* istanbul ignore next */ []));
|
|
6499
6770
|
formModel = signal({
|
|
6500
6771
|
newPassword: '',
|
|
6501
6772
|
confirmPassword: '',
|
|
6502
|
-
},
|
|
6773
|
+
}, /* @ts-ignore */
|
|
6774
|
+
...(ngDevMode ? [{ debugName: "formModel" }] : /* istanbul ignore next */ []));
|
|
6503
6775
|
resetForm = form(this.formModel, (f) => {
|
|
6504
6776
|
required(f.newPassword, {
|
|
6505
6777
|
message: this.translate('auth.validation.password.required'),
|
|
@@ -6517,8 +6789,10 @@ class ResetPasswordPageComponent {
|
|
|
6517
6789
|
const model = this.formModel();
|
|
6518
6790
|
return (model.confirmPassword.length > 0 &&
|
|
6519
6791
|
model.newPassword !== model.confirmPassword);
|
|
6520
|
-
},
|
|
6521
|
-
|
|
6792
|
+
}, /* @ts-ignore */
|
|
6793
|
+
...(ngDevMode ? [{ debugName: "passwordMismatch" }] : /* istanbul ignore next */ []));
|
|
6794
|
+
canSubmit = computed(() => this.resetForm().valid() && !this.passwordMismatch(), /* @ts-ignore */
|
|
6795
|
+
...(ngDevMode ? [{ debugName: "canSubmit" }] : /* istanbul ignore next */ []));
|
|
6522
6796
|
constructor() {
|
|
6523
6797
|
effect(() => {
|
|
6524
6798
|
const params = this.queryParams();
|
|
@@ -6571,8 +6845,8 @@ class ResetPasswordPageComponent {
|
|
|
6571
6845
|
},
|
|
6572
6846
|
});
|
|
6573
6847
|
}
|
|
6574
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
6575
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "
|
|
6848
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: ResetPasswordPageComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
6849
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.5", type: ResetPasswordPageComponent, isStandalone: true, selector: "lib-reset-password-page", ngImport: i0, template: `
|
|
6576
6850
|
<app-floating-configurator />
|
|
6577
6851
|
<div
|
|
6578
6852
|
class="bg-surface-ground flex items-center justify-center min-h-screen"
|
|
@@ -6643,13 +6917,17 @@ class ResetPasswordPageComponent {
|
|
|
6643
6917
|
}}</small>
|
|
6644
6918
|
}
|
|
6645
6919
|
|
|
6646
|
-
<
|
|
6647
|
-
|
|
6648
|
-
|
|
6920
|
+
<button
|
|
6921
|
+
pButton
|
|
6922
|
+
class="w-full mt-4 mb-4"
|
|
6649
6923
|
type="submit"
|
|
6650
|
-
[loading]="isLoading()"
|
|
6651
6924
|
[disabled]="!canSubmit() || isLoading()"
|
|
6652
|
-
|
|
6925
|
+
>
|
|
6926
|
+
@if (isLoading()) {
|
|
6927
|
+
<span pButtonIcon class="pi pi-spinner pi-spin"></span>
|
|
6928
|
+
}
|
|
6929
|
+
<span pButtonLabel>{{ 'auth.reset.password.reset.password' | translate }}</span>
|
|
6930
|
+
</button>
|
|
6653
6931
|
|
|
6654
6932
|
<div class="flex items-center justify-center gap-2">
|
|
6655
6933
|
<a
|
|
@@ -6674,10 +6952,12 @@ class ResetPasswordPageComponent {
|
|
|
6674
6952
|
{{ 'auth.reset.password.success.message' | translate }}
|
|
6675
6953
|
</p>
|
|
6676
6954
|
<a routerLink="/auth/login">
|
|
6677
|
-
<
|
|
6678
|
-
|
|
6679
|
-
|
|
6680
|
-
|
|
6955
|
+
<button
|
|
6956
|
+
pButton
|
|
6957
|
+
class="w-full"
|
|
6958
|
+
>
|
|
6959
|
+
<span pButtonLabel>{{ 'auth.login.sign.in' | translate }}</span>
|
|
6960
|
+
</button>
|
|
6681
6961
|
</a>
|
|
6682
6962
|
</div>
|
|
6683
6963
|
}
|
|
@@ -6694,12 +6974,14 @@ class ResetPasswordPageComponent {
|
|
|
6694
6974
|
{{ 'auth.reset.password.invalid.link.message' | translate }}
|
|
6695
6975
|
</p>
|
|
6696
6976
|
<a routerLink="/auth/forgot-password">
|
|
6697
|
-
<
|
|
6698
|
-
|
|
6977
|
+
<button
|
|
6978
|
+
pButton
|
|
6979
|
+
class="w-full mb-4"
|
|
6980
|
+
>
|
|
6981
|
+
<span pButtonLabel>{{
|
|
6699
6982
|
'auth.reset.password.request.new.link' | translate
|
|
6700
|
-
|
|
6701
|
-
|
|
6702
|
-
/>
|
|
6983
|
+
}}</span>
|
|
6984
|
+
</button>
|
|
6703
6985
|
</a>
|
|
6704
6986
|
<div class="mt-4">
|
|
6705
6987
|
<a
|
|
@@ -6716,9 +6998,9 @@ class ResetPasswordPageComponent {
|
|
|
6716
6998
|
</div>
|
|
6717
6999
|
</div>
|
|
6718
7000
|
</div>
|
|
6719
|
-
`, isInline: true, dependencies: [{ kind: "ngmodule", type: AngularModule }, { kind: "directive", type: i1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.NgForm, selector: "form:not([ngNoForm]):not([formGroup]):not([formArray]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i2
|
|
7001
|
+
`, isInline: true, dependencies: [{ kind: "ngmodule", type: AngularModule }, { kind: "directive", type: i1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.NgForm, selector: "form:not([ngNoForm]):not([formGroup]):not([formArray]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "browserUrl", "routerLink"] }, { kind: "ngmodule", type: PrimeModule }, { kind: "directive", type: i3.ButtonDirective, selector: "[pButton]", inputs: ["pButton", "pButtonPT", "pButtonUnstyled", "hostName", "text", "plain", "raised", "size", "outlined", "link", "rounded", "fluid", "variant", "iconOnly", "loading", "severity"] }, { kind: "directive", type: i3.ButtonLabel, selector: "[pButtonLabel]", inputs: ["pButtonLabelPT", "pButtonLabelUnstyled"] }, { kind: "directive", type: i3.ButtonIcon, selector: "[pButtonIcon]", inputs: ["pButtonIconPT", "pButtonUnstyled"] }, { kind: "directive", type: i4.InputText, selector: "[pInputText]", inputs: ["hostName", "pInputTextPT", "pInputTextUnstyled", "pSize", "variant", "fluid", "invalid"] }, { kind: "directive", type: FormField, selector: "[formField]", inputs: ["formField"], exportAs: ["formField"] }, { kind: "component", type: AppFloatingConfigurator, selector: "app-floating-configurator" }, { kind: "pipe", type: TranslatePipe, name: "translate" }] });
|
|
6720
7002
|
}
|
|
6721
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
7003
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: ResetPasswordPageComponent, decorators: [{
|
|
6722
7004
|
type: Component,
|
|
6723
7005
|
args: [{
|
|
6724
7006
|
selector: 'lib-reset-password-page',
|
|
@@ -6800,13 +7082,17 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.5", ngImpor
|
|
|
6800
7082
|
}}</small>
|
|
6801
7083
|
}
|
|
6802
7084
|
|
|
6803
|
-
<
|
|
6804
|
-
|
|
6805
|
-
|
|
7085
|
+
<button
|
|
7086
|
+
pButton
|
|
7087
|
+
class="w-full mt-4 mb-4"
|
|
6806
7088
|
type="submit"
|
|
6807
|
-
[loading]="isLoading()"
|
|
6808
7089
|
[disabled]="!canSubmit() || isLoading()"
|
|
6809
|
-
|
|
7090
|
+
>
|
|
7091
|
+
@if (isLoading()) {
|
|
7092
|
+
<span pButtonIcon class="pi pi-spinner pi-spin"></span>
|
|
7093
|
+
}
|
|
7094
|
+
<span pButtonLabel>{{ 'auth.reset.password.reset.password' | translate }}</span>
|
|
7095
|
+
</button>
|
|
6810
7096
|
|
|
6811
7097
|
<div class="flex items-center justify-center gap-2">
|
|
6812
7098
|
<a
|
|
@@ -6831,10 +7117,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.5", ngImpor
|
|
|
6831
7117
|
{{ 'auth.reset.password.success.message' | translate }}
|
|
6832
7118
|
</p>
|
|
6833
7119
|
<a routerLink="/auth/login">
|
|
6834
|
-
<
|
|
6835
|
-
|
|
6836
|
-
|
|
6837
|
-
|
|
7120
|
+
<button
|
|
7121
|
+
pButton
|
|
7122
|
+
class="w-full"
|
|
7123
|
+
>
|
|
7124
|
+
<span pButtonLabel>{{ 'auth.login.sign.in' | translate }}</span>
|
|
7125
|
+
</button>
|
|
6838
7126
|
</a>
|
|
6839
7127
|
</div>
|
|
6840
7128
|
}
|
|
@@ -6851,12 +7139,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.5", ngImpor
|
|
|
6851
7139
|
{{ 'auth.reset.password.invalid.link.message' | translate }}
|
|
6852
7140
|
</p>
|
|
6853
7141
|
<a routerLink="/auth/forgot-password">
|
|
6854
|
-
<
|
|
6855
|
-
|
|
7142
|
+
<button
|
|
7143
|
+
pButton
|
|
7144
|
+
class="w-full mb-4"
|
|
7145
|
+
>
|
|
7146
|
+
<span pButtonLabel>{{
|
|
6856
7147
|
'auth.reset.password.request.new.link' | translate
|
|
6857
|
-
|
|
6858
|
-
|
|
6859
|
-
/>
|
|
7148
|
+
}}</span>
|
|
7149
|
+
</button>
|
|
6860
7150
|
</a>
|
|
6861
7151
|
<div class="mt-4">
|
|
6862
7152
|
<a
|
|
@@ -6903,12 +7193,18 @@ class UserFormComponent {
|
|
|
6903
7193
|
}
|
|
6904
7194
|
routeParams = toSignal(this.route.paramMap);
|
|
6905
7195
|
userLoadTriggered = false;
|
|
6906
|
-
isLoading = signal(false,
|
|
6907
|
-
|
|
6908
|
-
|
|
6909
|
-
|
|
6910
|
-
|
|
6911
|
-
|
|
7196
|
+
isLoading = signal(false, /* @ts-ignore */
|
|
7197
|
+
...(ngDevMode ? [{ debugName: "isLoading" }] : /* istanbul ignore next */ []));
|
|
7198
|
+
existingUser = signal(null, /* @ts-ignore */
|
|
7199
|
+
...(ngDevMode ? [{ debugName: "existingUser" }] : /* istanbul ignore next */ []));
|
|
7200
|
+
isEditMode = computed(() => !!this.existingUser(), /* @ts-ignore */
|
|
7201
|
+
...(ngDevMode ? [{ debugName: "isEditMode" }] : /* istanbul ignore next */ []));
|
|
7202
|
+
companyFeatureEnabled = computed(() => isCompanyFeatureEnabled(this.appConfig), /* @ts-ignore */
|
|
7203
|
+
...(ngDevMode ? [{ debugName: "companyFeatureEnabled" }] : /* istanbul ignore next */ []));
|
|
7204
|
+
currentCompanyName = computed(() => this.authState.companyName(), /* @ts-ignore */
|
|
7205
|
+
...(ngDevMode ? [{ debugName: "currentCompanyName" }] : /* istanbul ignore next */ []));
|
|
7206
|
+
currentBranchName = computed(() => this.authState.branchName(), /* @ts-ignore */
|
|
7207
|
+
...(ngDevMode ? [{ debugName: "currentBranchName" }] : /* istanbul ignore next */ []));
|
|
6912
7208
|
formModel = signal({
|
|
6913
7209
|
name: '',
|
|
6914
7210
|
email: '',
|
|
@@ -6916,7 +7212,8 @@ class UserFormComponent {
|
|
|
6916
7212
|
phone: '',
|
|
6917
7213
|
isActive: true,
|
|
6918
7214
|
emailVerified: false,
|
|
6919
|
-
},
|
|
7215
|
+
}, /* @ts-ignore */
|
|
7216
|
+
...(ngDevMode ? [{ debugName: "formModel" }] : /* istanbul ignore next */ []));
|
|
6920
7217
|
formTree = form(this.formModel, (f) => {
|
|
6921
7218
|
required(f.name, {
|
|
6922
7219
|
message: this.translate('shared.name.required'),
|
|
@@ -6928,27 +7225,34 @@ class UserFormComponent {
|
|
|
6928
7225
|
message: this.translate('shared.invalid.email'),
|
|
6929
7226
|
});
|
|
6930
7227
|
});
|
|
6931
|
-
isLoadingExtraFields = signal(false,
|
|
6932
|
-
|
|
6933
|
-
|
|
7228
|
+
isLoadingExtraFields = signal(false, /* @ts-ignore */
|
|
7229
|
+
...(ngDevMode ? [{ debugName: "isLoadingExtraFields" }] : /* istanbul ignore next */ []));
|
|
7230
|
+
extraFieldsModel = signal({}, /* @ts-ignore */
|
|
7231
|
+
...(ngDevMode ? [{ debugName: "extraFieldsModel" }] : /* istanbul ignore next */ []));
|
|
7232
|
+
originalExtraFieldsModel = signal({}, /* @ts-ignore */
|
|
7233
|
+
...(ngDevMode ? [{ debugName: "originalExtraFieldsModel" }] : /* istanbul ignore next */ []));
|
|
6934
7234
|
extraFields = computed(() => {
|
|
6935
7235
|
if (!this.userFormExtension?.getExtraFields)
|
|
6936
7236
|
return [];
|
|
6937
7237
|
return this.userFormExtension
|
|
6938
7238
|
.getExtraFields()
|
|
6939
7239
|
.sort((a, b) => (a.order ?? 100) - (b.order ?? 100));
|
|
6940
|
-
},
|
|
6941
|
-
|
|
7240
|
+
}, /* @ts-ignore */
|
|
7241
|
+
...(ngDevMode ? [{ debugName: "extraFields" }] : /* istanbul ignore next */ []));
|
|
7242
|
+
hasExtraFields = computed(() => this.extraFields().length > 0, /* @ts-ignore */
|
|
7243
|
+
...(ngDevMode ? [{ debugName: "hasExtraFields" }] : /* istanbul ignore next */ []));
|
|
6942
7244
|
extraFieldsValidationError = computed(() => {
|
|
6943
7245
|
if (!this.userFormExtension?.validateExtraFields)
|
|
6944
7246
|
return null;
|
|
6945
7247
|
return this.userFormExtension.validateExtraFields(this.extraFieldsModel());
|
|
6946
|
-
},
|
|
7248
|
+
}, /* @ts-ignore */
|
|
7249
|
+
...(ngDevMode ? [{ debugName: "extraFieldsValidationError" }] : /* istanbul ignore next */ []));
|
|
6947
7250
|
isExtraFieldsDirty = computed(() => {
|
|
6948
7251
|
const current = this.extraFieldsModel();
|
|
6949
7252
|
const original = this.originalExtraFieldsModel();
|
|
6950
7253
|
return JSON.stringify(current) !== JSON.stringify(original);
|
|
6951
|
-
},
|
|
7254
|
+
}, /* @ts-ignore */
|
|
7255
|
+
...(ngDevMode ? [{ debugName: "isExtraFieldsDirty" }] : /* istanbul ignore next */ []));
|
|
6952
7256
|
updateExtraField(key, value) {
|
|
6953
7257
|
this.extraFieldsModel.update((model) => ({ ...model, [key]: value }));
|
|
6954
7258
|
}
|
|
@@ -6980,7 +7284,8 @@ class UserFormComponent {
|
|
|
6980
7284
|
const emailValid = model.email.includes('@');
|
|
6981
7285
|
const passwordValid = isEdit ? true : model.password.length >= 8;
|
|
6982
7286
|
return nameValid && emailValid && passwordValid;
|
|
6983
|
-
},
|
|
7287
|
+
}, /* @ts-ignore */
|
|
7288
|
+
...(ngDevMode ? [{ debugName: "isFormValid" }] : /* istanbul ignore next */ []));
|
|
6984
7289
|
constructor() {
|
|
6985
7290
|
effect(() => {
|
|
6986
7291
|
const params = this.routeParams();
|
|
@@ -7158,8 +7463,8 @@ class UserFormComponent {
|
|
|
7158
7463
|
onCancel() {
|
|
7159
7464
|
this.router.navigate(['/administration/users']);
|
|
7160
7465
|
}
|
|
7161
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
7162
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "
|
|
7466
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: UserFormComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
7467
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.5", type: UserFormComponent, isStandalone: true, selector: "lib-user-form", ngImport: i0, template: `
|
|
7163
7468
|
<p-card>
|
|
7164
7469
|
<ng-template #header>
|
|
7165
7470
|
<div class="flex justify-between items-center p-4">
|
|
@@ -7432,28 +7737,34 @@ class UserFormComponent {
|
|
|
7432
7737
|
}
|
|
7433
7738
|
|
|
7434
7739
|
<div class="flex justify-end gap-4 md:col-span-2 pt-4">
|
|
7435
|
-
<
|
|
7436
|
-
|
|
7740
|
+
<button
|
|
7741
|
+
pButton
|
|
7437
7742
|
severity="secondary"
|
|
7438
7743
|
[outlined]="true"
|
|
7439
|
-
(
|
|
7440
|
-
|
|
7441
|
-
|
|
7442
|
-
|
|
7744
|
+
(click)="onCancel()"
|
|
7745
|
+
>
|
|
7746
|
+
<span pButtonLabel>{{ 'shared.cancel' | translate }}</span>
|
|
7747
|
+
</button>
|
|
7748
|
+
<button
|
|
7749
|
+
pButton
|
|
7750
|
+
type="submit"
|
|
7751
|
+
[disabled]="!isFormValid() || isLoading()"
|
|
7752
|
+
>
|
|
7753
|
+
@if (isLoading()) {
|
|
7754
|
+
<span pButtonIcon class="pi pi-spinner pi-spin"></span>
|
|
7755
|
+
}
|
|
7756
|
+
<span pButtonLabel>{{
|
|
7443
7757
|
isEditMode()
|
|
7444
7758
|
? ('shared.update' | translate)
|
|
7445
7759
|
: ('shared.create' | translate)
|
|
7446
|
-
|
|
7447
|
-
|
|
7448
|
-
[loading]="isLoading()"
|
|
7449
|
-
[disabled]="!isFormValid() || isLoading()"
|
|
7450
|
-
/>
|
|
7760
|
+
}}</span>
|
|
7761
|
+
</button>
|
|
7451
7762
|
</div>
|
|
7452
7763
|
</form>
|
|
7453
7764
|
</p-card>
|
|
7454
|
-
`, isInline: true, dependencies: [{ kind: "ngmodule", type: AngularModule }, { kind: "directive", type: i1$1.NgComponentOutlet, selector: "[ngComponentOutlet]", inputs: ["ngComponentOutlet", "ngComponentOutletInputs", "ngComponentOutletInjector", "ngComponentOutletEnvironmentInjector", "ngComponentOutletContent", "ngComponentOutletNgModule"], exportAs: ["ngComponentOutlet"] }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1.SelectControlValueAccessor, selector: "select:not([multiple])[formControlName],select:not([multiple])[formControl],select:not([multiple])[ngModel]", inputs: ["compareWith"] }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i1.NgForm, selector: "form:not([ngNoForm]):not([formGroup]):not([formArray]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "ngmodule", type: PrimeModule }, { kind: "
|
|
7765
|
+
`, isInline: true, dependencies: [{ kind: "ngmodule", type: AngularModule }, { kind: "directive", type: i1$1.NgComponentOutlet, selector: "[ngComponentOutlet]", inputs: ["ngComponentOutlet", "ngComponentOutletInputs", "ngComponentOutletInjector", "ngComponentOutletEnvironmentInjector", "ngComponentOutletContent", "ngComponentOutletNgModule"], exportAs: ["ngComponentOutlet"] }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1.SelectControlValueAccessor, selector: "select:not([multiple]):not([ngNoCva])[formControlName],select:not([multiple]):not([ngNoCva])[formControl],select:not([multiple]):not([ngNoCva])[ngModel]", inputs: ["compareWith"] }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i1.NgForm, selector: "form:not([ngNoForm]):not([formGroup]):not([formArray]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "ngmodule", type: PrimeModule }, { kind: "directive", type: i3.ButtonDirective, selector: "[pButton]", inputs: ["pButton", "pButtonPT", "pButtonUnstyled", "hostName", "text", "plain", "raised", "size", "outlined", "link", "rounded", "fluid", "variant", "iconOnly", "loading", "severity"] }, { kind: "directive", type: i3.ButtonLabel, selector: "[pButtonLabel]", inputs: ["pButtonLabelPT", "pButtonLabelUnstyled"] }, { kind: "directive", type: i3.ButtonIcon, selector: "[pButtonIcon]", inputs: ["pButtonIconPT", "pButtonUnstyled"] }, { kind: "component", type: i3$1.Card, selector: "p-card", inputs: ["header", "subheader"] }, { kind: "directive", type: i4.InputText, selector: "[pInputText]", inputs: ["hostName", "pInputTextPT", "pInputTextUnstyled", "pSize", "variant", "fluid", "invalid"] }, { kind: "component", type: i9.Skeleton, selector: "p-skeleton", inputs: ["shape", "animation", "borderRadius", "size", "width", "height"] }, { kind: "directive", type: i11.Textarea, selector: "[pTextarea], [pInputTextarea]", inputs: ["pTextareaPT", "pTextareaUnstyled", "autoResize", "pSize", "variant", "fluid", "invalid"], outputs: ["onResize"] }, { kind: "directive", type: FormField, selector: "[formField]", inputs: ["formField"], exportAs: ["formField"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }] });
|
|
7455
7766
|
}
|
|
7456
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
7767
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: UserFormComponent, decorators: [{
|
|
7457
7768
|
type: Component,
|
|
7458
7769
|
args: [{
|
|
7459
7770
|
selector: 'lib-user-form',
|
|
@@ -7731,22 +8042,28 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.5", ngImpor
|
|
|
7731
8042
|
}
|
|
7732
8043
|
|
|
7733
8044
|
<div class="flex justify-end gap-4 md:col-span-2 pt-4">
|
|
7734
|
-
<
|
|
7735
|
-
|
|
8045
|
+
<button
|
|
8046
|
+
pButton
|
|
7736
8047
|
severity="secondary"
|
|
7737
8048
|
[outlined]="true"
|
|
7738
|
-
(
|
|
7739
|
-
|
|
7740
|
-
|
|
7741
|
-
|
|
8049
|
+
(click)="onCancel()"
|
|
8050
|
+
>
|
|
8051
|
+
<span pButtonLabel>{{ 'shared.cancel' | translate }}</span>
|
|
8052
|
+
</button>
|
|
8053
|
+
<button
|
|
8054
|
+
pButton
|
|
8055
|
+
type="submit"
|
|
8056
|
+
[disabled]="!isFormValid() || isLoading()"
|
|
8057
|
+
>
|
|
8058
|
+
@if (isLoading()) {
|
|
8059
|
+
<span pButtonIcon class="pi pi-spinner pi-spin"></span>
|
|
8060
|
+
}
|
|
8061
|
+
<span pButtonLabel>{{
|
|
7742
8062
|
isEditMode()
|
|
7743
8063
|
? ('shared.update' | translate)
|
|
7744
8064
|
: ('shared.create' | translate)
|
|
7745
|
-
|
|
7746
|
-
|
|
7747
|
-
[loading]="isLoading()"
|
|
7748
|
-
[disabled]="!isFormValid() || isLoading()"
|
|
7749
|
-
/>
|
|
8065
|
+
}}</span>
|
|
8066
|
+
</button>
|
|
7750
8067
|
</div>
|
|
7751
8068
|
</form>
|
|
7752
8069
|
</p-card>
|
|
@@ -7769,13 +8086,17 @@ class UserBranchPermissionDialogComponent {
|
|
|
7769
8086
|
t(key, params) {
|
|
7770
8087
|
return this.translateAdapter?.translate(key, params) ?? key;
|
|
7771
8088
|
}
|
|
7772
|
-
visible = input.required(
|
|
7773
|
-
|
|
8089
|
+
visible = input.required(/* @ts-ignore */
|
|
8090
|
+
...(ngDevMode ? [{ debugName: "visible" }] : /* istanbul ignore next */ []));
|
|
8091
|
+
user = input.required(/* @ts-ignore */
|
|
8092
|
+
...(ngDevMode ? [{ debugName: "user" }] : /* istanbul ignore next */ []));
|
|
7774
8093
|
closed = output();
|
|
7775
8094
|
permissionsChanged = output();
|
|
7776
|
-
isSaving = signal(false,
|
|
7777
|
-
|
|
7778
|
-
|
|
8095
|
+
isSaving = signal(false, /* @ts-ignore */
|
|
8096
|
+
...(ngDevMode ? [{ debugName: "isSaving" }] : /* istanbul ignore next */ []));
|
|
8097
|
+
selectedCompanyId = signal(null, /* @ts-ignore */
|
|
8098
|
+
...(ngDevMode ? [{ debugName: "selectedCompanyId" }] : /* istanbul ignore next */ []));
|
|
8099
|
+
companiesResource = resource({ ...(ngDevMode ? { debugName: "companiesResource" } : /* istanbul ignore next */ {}), params: () => {
|
|
7779
8100
|
const user = this.user();
|
|
7780
8101
|
if (!this.visible() || !user)
|
|
7781
8102
|
return undefined;
|
|
@@ -7789,7 +8110,7 @@ class UserBranchPermissionDialogComponent {
|
|
|
7789
8110
|
name: p.companyName,
|
|
7790
8111
|
}));
|
|
7791
8112
|
} });
|
|
7792
|
-
branchesResource = resource({ ...(ngDevMode ? { debugName: "branchesResource" } : {}), params: () => {
|
|
8113
|
+
branchesResource = resource({ ...(ngDevMode ? { debugName: "branchesResource" } : /* istanbul ignore next */ {}), params: () => {
|
|
7793
8114
|
const user = this.user();
|
|
7794
8115
|
const companyId = this.selectedCompanyId();
|
|
7795
8116
|
if (!user || !companyId)
|
|
@@ -7814,7 +8135,8 @@ class UserBranchPermissionDialogComponent {
|
|
|
7814
8135
|
isAssigned: assignedIds.has(branch.id),
|
|
7815
8136
|
}));
|
|
7816
8137
|
} });
|
|
7817
|
-
isInitialLoading = computed(() => this.branchesResource.isLoading() && !this.branchesResource.value(),
|
|
8138
|
+
isInitialLoading = computed(() => this.branchesResource.isLoading() && !this.branchesResource.value(), /* @ts-ignore */
|
|
8139
|
+
...(ngDevMode ? [{ debugName: "isInitialLoading" }] : /* istanbul ignore next */ []));
|
|
7818
8140
|
async onBranchToggle(branch, isAssigned) {
|
|
7819
8141
|
const currentUser = this.user();
|
|
7820
8142
|
if (!currentUser)
|
|
@@ -7861,8 +8183,8 @@ class UserBranchPermissionDialogComponent {
|
|
|
7861
8183
|
onClose() {
|
|
7862
8184
|
this.closed.emit();
|
|
7863
8185
|
}
|
|
7864
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
7865
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "
|
|
8186
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: UserBranchPermissionDialogComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
8187
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.5", type: UserBranchPermissionDialogComponent, isStandalone: true, selector: "lib-user-branch-permission-dialog", inputs: { visible: { classPropertyName: "visible", publicName: "visible", isSignal: true, isRequired: true, transformFunction: null }, user: { classPropertyName: "user", publicName: "user", isSignal: true, isRequired: true, transformFunction: null } }, outputs: { closed: "closed", permissionsChanged: "permissionsChanged" }, ngImport: i0, template: `
|
|
7866
8188
|
<p-dialog
|
|
7867
8189
|
[visible]="visible()"
|
|
7868
8190
|
[modal]="true"
|
|
@@ -7896,7 +8218,7 @@ class UserBranchPermissionDialogComponent {
|
|
|
7896
8218
|
|
|
7897
8219
|
@if (isInitialLoading()) {
|
|
7898
8220
|
<div class="flex justify-center items-center py-8">
|
|
7899
|
-
<p-
|
|
8221
|
+
<p-progressspinner />
|
|
7900
8222
|
</div>
|
|
7901
8223
|
} @else {
|
|
7902
8224
|
<div class="flex flex-col gap-3">
|
|
@@ -7938,18 +8260,20 @@ class UserBranchPermissionDialogComponent {
|
|
|
7938
8260
|
}
|
|
7939
8261
|
|
|
7940
8262
|
<ng-template #footer>
|
|
7941
|
-
<
|
|
7942
|
-
|
|
8263
|
+
<button
|
|
8264
|
+
pButton
|
|
7943
8265
|
severity="secondary"
|
|
7944
8266
|
[outlined]="true"
|
|
7945
|
-
(
|
|
8267
|
+
(click)="onClose()"
|
|
7946
8268
|
[disabled]="isSaving()"
|
|
7947
|
-
|
|
8269
|
+
>
|
|
8270
|
+
<span pButtonLabel>{{ 'shared.close' | translate }}</span>
|
|
8271
|
+
</button>
|
|
7948
8272
|
</ng-template>
|
|
7949
8273
|
</p-dialog>
|
|
7950
|
-
`, isInline: true, dependencies: [{ kind: "ngmodule", type: AngularModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: PrimeModule }, { kind: "
|
|
8274
|
+
`, isInline: true, dependencies: [{ kind: "ngmodule", type: AngularModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: PrimeModule }, { kind: "directive", type: i3.ButtonDirective, selector: "[pButton]", inputs: ["pButton", "pButtonPT", "pButtonUnstyled", "hostName", "text", "plain", "raised", "size", "outlined", "link", "rounded", "fluid", "variant", "iconOnly", "loading", "severity"] }, { kind: "directive", type: i3.ButtonLabel, selector: "[pButtonLabel]", inputs: ["pButtonLabelPT", "pButtonLabelUnstyled"] }, { kind: "component", type: i3$3.Checkbox, selector: "p-checkbox, p-check-box", inputs: ["value", "binary", "ariaLabelledBy", "ariaLabel", "tabindex", "inputId", "inputStyle", "inputClass", "indeterminate", "formControl", "checkboxIcon", "readonly", "autofocus", "trueValue", "falseValue", "variant", "size"], outputs: ["onChange", "onFocus", "onBlur"] }, { kind: "component", type: i4$2.Dialog, selector: "p-dialog", inputs: ["hostName", "header", "draggable", "resizable", "contentStyle", "contentStyleClass", "modal", "closeOnEscape", "dismissableMask", "rtl", "closable", "breakpoints", "styleClass", "maskStyleClass", "maskStyle", "showHeader", "blockScroll", "autoZIndex", "baseZIndex", "minX", "minY", "focusOnShow", "maximizable", "keepInViewport", "focusTrap", "maskMotionOptions", "motionOptions", "closeIcon", "closeAriaLabel", "closeTabindex", "minimizeIcon", "maximizeIcon", "closeButtonProps", "maximizeButtonProps", "visible", "style", "position", "role", "appendTo"], outputs: ["visibleChange", "onShow", "onHide", "onResizeInit", "onResizeEnd", "onDragStart", "onDragEnd", "onMaximize"] }, { kind: "component", type: i4$1.Select, selector: "p-select", inputs: ["id", "scrollHeight", "filter", "panelStyle", "panelStyleClass", "readonly", "editable", "tabindex", "placeholder", "loadingIcon", "filterPlaceholder", "filterLocale", "inputId", "dataKey", "filterBy", "filterFields", "autofocus", "resetFilterOnHide", "checkmark", "dropdownIcon", "loading", "optionLabel", "optionValue", "optionDisabled", "optionGroupLabel", "optionGroupChildren", "group", "showClear", "emptyFilterMessage", "emptyMessage", "lazy", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "overlayOptions", "ariaFilterLabel", "ariaLabel", "ariaLabelledBy", "filterMatchMode", "tooltip", "tooltipPosition", "tooltipPositionStyle", "tooltipStyleClass", "focusOnHover", "selectOnFocus", "multiple", "autoOptionFocus", "autofocusFilter", "filterValue", "options", "appendTo", "motionOptions"], outputs: ["onChange", "onFilter", "onFocus", "onBlur", "onClick", "onShow", "onHide", "onClear", "onLazyLoad"] }, { kind: "component", type: i6$2.ProgressSpinner, selector: "p-progress-spinner, p-progressspinner", inputs: ["value", "strokeWidth", "animationDuration", "min", "max", "ariaLabel", "fill"] }, { kind: "ngmodule", type: DialogModule }, { kind: "ngmodule", type: ProgressSpinnerModule }, { kind: "pipe", type: TranslatePipe, name: "translate" }] });
|
|
7951
8275
|
}
|
|
7952
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
8276
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: UserBranchPermissionDialogComponent, decorators: [{
|
|
7953
8277
|
type: Component,
|
|
7954
8278
|
args: [{
|
|
7955
8279
|
selector: 'lib-user-branch-permission-dialog',
|
|
@@ -7994,7 +8318,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.5", ngImpor
|
|
|
7994
8318
|
|
|
7995
8319
|
@if (isInitialLoading()) {
|
|
7996
8320
|
<div class="flex justify-center items-center py-8">
|
|
7997
|
-
<p-
|
|
8321
|
+
<p-progressspinner />
|
|
7998
8322
|
</div>
|
|
7999
8323
|
} @else {
|
|
8000
8324
|
<div class="flex flex-col gap-3">
|
|
@@ -8036,13 +8360,15 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.5", ngImpor
|
|
|
8036
8360
|
}
|
|
8037
8361
|
|
|
8038
8362
|
<ng-template #footer>
|
|
8039
|
-
<
|
|
8040
|
-
|
|
8363
|
+
<button
|
|
8364
|
+
pButton
|
|
8041
8365
|
severity="secondary"
|
|
8042
8366
|
[outlined]="true"
|
|
8043
|
-
(
|
|
8367
|
+
(click)="onClose()"
|
|
8044
8368
|
[disabled]="isSaving()"
|
|
8045
|
-
|
|
8369
|
+
>
|
|
8370
|
+
<span pButtonLabel>{{ 'shared.close' | translate }}</span>
|
|
8371
|
+
</button>
|
|
8046
8372
|
</ng-template>
|
|
8047
8373
|
</p-dialog>
|
|
8048
8374
|
`,
|
|
@@ -8059,13 +8385,18 @@ class UserCompanyPermissionDialogComponent {
|
|
|
8059
8385
|
t(key, params) {
|
|
8060
8386
|
return this.translateAdapter?.translate(key, params) ?? key;
|
|
8061
8387
|
}
|
|
8062
|
-
visible = input.required(
|
|
8063
|
-
|
|
8388
|
+
visible = input.required(/* @ts-ignore */
|
|
8389
|
+
...(ngDevMode ? [{ debugName: "visible" }] : /* istanbul ignore next */ []));
|
|
8390
|
+
user = input.required(/* @ts-ignore */
|
|
8391
|
+
...(ngDevMode ? [{ debugName: "user" }] : /* istanbul ignore next */ []));
|
|
8064
8392
|
closed = output();
|
|
8065
8393
|
permissionsChanged = output();
|
|
8066
|
-
isLoading = signal(false,
|
|
8067
|
-
|
|
8068
|
-
|
|
8394
|
+
isLoading = signal(false, /* @ts-ignore */
|
|
8395
|
+
...(ngDevMode ? [{ debugName: "isLoading" }] : /* istanbul ignore next */ []));
|
|
8396
|
+
isSaving = signal(false, /* @ts-ignore */
|
|
8397
|
+
...(ngDevMode ? [{ debugName: "isSaving" }] : /* istanbul ignore next */ []));
|
|
8398
|
+
companies = signal([], /* @ts-ignore */
|
|
8399
|
+
...(ngDevMode ? [{ debugName: "companies" }] : /* istanbul ignore next */ []));
|
|
8069
8400
|
assignedCompanyIds = new Set();
|
|
8070
8401
|
constructor() {
|
|
8071
8402
|
effect(() => {
|
|
@@ -8150,8 +8481,8 @@ class UserCompanyPermissionDialogComponent {
|
|
|
8150
8481
|
onClose() {
|
|
8151
8482
|
this.closed.emit();
|
|
8152
8483
|
}
|
|
8153
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
8154
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "
|
|
8484
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: UserCompanyPermissionDialogComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
8485
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.5", type: UserCompanyPermissionDialogComponent, isStandalone: true, selector: "lib-user-company-permission-dialog", inputs: { visible: { classPropertyName: "visible", publicName: "visible", isSignal: true, isRequired: true, transformFunction: null }, user: { classPropertyName: "user", publicName: "user", isSignal: true, isRequired: true, transformFunction: null } }, outputs: { closed: "closed", permissionsChanged: "permissionsChanged" }, ngImport: i0, template: `
|
|
8155
8486
|
<p-dialog
|
|
8156
8487
|
[visible]="visible()"
|
|
8157
8488
|
[modal]="true"
|
|
@@ -8170,7 +8501,7 @@ class UserCompanyPermissionDialogComponent {
|
|
|
8170
8501
|
|
|
8171
8502
|
@if (isLoading()) {
|
|
8172
8503
|
<div class="flex justify-center items-center py-8">
|
|
8173
|
-
<p-
|
|
8504
|
+
<p-progressspinner />
|
|
8174
8505
|
</div>
|
|
8175
8506
|
} @else {
|
|
8176
8507
|
<div class="flex flex-col gap-3">
|
|
@@ -8200,18 +8531,20 @@ class UserCompanyPermissionDialogComponent {
|
|
|
8200
8531
|
}
|
|
8201
8532
|
|
|
8202
8533
|
<ng-template #footer>
|
|
8203
|
-
<
|
|
8204
|
-
|
|
8534
|
+
<button
|
|
8535
|
+
pButton
|
|
8205
8536
|
severity="secondary"
|
|
8206
8537
|
[outlined]="true"
|
|
8207
|
-
(
|
|
8538
|
+
(click)="onClose()"
|
|
8208
8539
|
[disabled]="isSaving()"
|
|
8209
|
-
|
|
8540
|
+
>
|
|
8541
|
+
<span pButtonLabel>{{ 'shared.close' | translate }}</span>
|
|
8542
|
+
</button>
|
|
8210
8543
|
</ng-template>
|
|
8211
8544
|
</p-dialog>
|
|
8212
|
-
`, isInline: true, dependencies: [{ kind: "ngmodule", type: AngularModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: PrimeModule }, { kind: "
|
|
8545
|
+
`, isInline: true, dependencies: [{ kind: "ngmodule", type: AngularModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: PrimeModule }, { kind: "directive", type: i3.ButtonDirective, selector: "[pButton]", inputs: ["pButton", "pButtonPT", "pButtonUnstyled", "hostName", "text", "plain", "raised", "size", "outlined", "link", "rounded", "fluid", "variant", "iconOnly", "loading", "severity"] }, { kind: "directive", type: i3.ButtonLabel, selector: "[pButtonLabel]", inputs: ["pButtonLabelPT", "pButtonLabelUnstyled"] }, { kind: "component", type: i3$3.Checkbox, selector: "p-checkbox, p-check-box", inputs: ["value", "binary", "ariaLabelledBy", "ariaLabel", "tabindex", "inputId", "inputStyle", "inputClass", "indeterminate", "formControl", "checkboxIcon", "readonly", "autofocus", "trueValue", "falseValue", "variant", "size"], outputs: ["onChange", "onFocus", "onBlur"] }, { kind: "component", type: i4$2.Dialog, selector: "p-dialog", inputs: ["hostName", "header", "draggable", "resizable", "contentStyle", "contentStyleClass", "modal", "closeOnEscape", "dismissableMask", "rtl", "closable", "breakpoints", "styleClass", "maskStyleClass", "maskStyle", "showHeader", "blockScroll", "autoZIndex", "baseZIndex", "minX", "minY", "focusOnShow", "maximizable", "keepInViewport", "focusTrap", "maskMotionOptions", "motionOptions", "closeIcon", "closeAriaLabel", "closeTabindex", "minimizeIcon", "maximizeIcon", "closeButtonProps", "maximizeButtonProps", "visible", "style", "position", "role", "appendTo"], outputs: ["visibleChange", "onShow", "onHide", "onResizeInit", "onResizeEnd", "onDragStart", "onDragEnd", "onMaximize"] }, { kind: "component", type: i6$2.ProgressSpinner, selector: "p-progress-spinner, p-progressspinner", inputs: ["value", "strokeWidth", "animationDuration", "min", "max", "ariaLabel", "fill"] }, { kind: "ngmodule", type: DialogModule }, { kind: "ngmodule", type: ProgressSpinnerModule }, { kind: "pipe", type: TranslatePipe, name: "translate" }] });
|
|
8213
8546
|
}
|
|
8214
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
8547
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: UserCompanyPermissionDialogComponent, decorators: [{
|
|
8215
8548
|
type: Component,
|
|
8216
8549
|
args: [{
|
|
8217
8550
|
selector: 'lib-user-company-permission-dialog',
|
|
@@ -8241,7 +8574,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.5", ngImpor
|
|
|
8241
8574
|
|
|
8242
8575
|
@if (isLoading()) {
|
|
8243
8576
|
<div class="flex justify-center items-center py-8">
|
|
8244
|
-
<p-
|
|
8577
|
+
<p-progressspinner />
|
|
8245
8578
|
</div>
|
|
8246
8579
|
} @else {
|
|
8247
8580
|
<div class="flex flex-col gap-3">
|
|
@@ -8271,13 +8604,15 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.5", ngImpor
|
|
|
8271
8604
|
}
|
|
8272
8605
|
|
|
8273
8606
|
<ng-template #footer>
|
|
8274
|
-
<
|
|
8275
|
-
|
|
8607
|
+
<button
|
|
8608
|
+
pButton
|
|
8276
8609
|
severity="secondary"
|
|
8277
8610
|
[outlined]="true"
|
|
8278
|
-
(
|
|
8611
|
+
(click)="onClose()"
|
|
8279
8612
|
[disabled]="isSaving()"
|
|
8280
|
-
|
|
8613
|
+
>
|
|
8614
|
+
<span pButtonLabel>{{ 'shared.close' | translate }}</span>
|
|
8615
|
+
</button>
|
|
8281
8616
|
</ng-template>
|
|
8282
8617
|
</p-dialog>
|
|
8283
8618
|
`,
|
|
@@ -8306,25 +8641,34 @@ class UserListComponent {
|
|
|
8306
8641
|
users = this.userService.data;
|
|
8307
8642
|
isLoading = this.userService.isLoading;
|
|
8308
8643
|
total = this.userService.total;
|
|
8309
|
-
companyFeatureEnabled = computed(() => isCompanyFeatureEnabled(this.appConfig),
|
|
8644
|
+
companyFeatureEnabled = computed(() => isCompanyFeatureEnabled(this.appConfig), /* @ts-ignore */
|
|
8645
|
+
...(ngDevMode ? [{ debugName: "companyFeatureEnabled" }] : /* istanbul ignore next */ []));
|
|
8310
8646
|
extraColumns = computed(() => {
|
|
8311
8647
|
if (!this.userListExtension)
|
|
8312
8648
|
return [];
|
|
8313
8649
|
const columns = this.userListExtension.getExtraColumns();
|
|
8314
8650
|
return columns.sort((a, b) => (a.order ?? 100) - (b.order ?? 100));
|
|
8315
|
-
},
|
|
8651
|
+
}, /* @ts-ignore */
|
|
8652
|
+
...(ngDevMode ? [{ debugName: "extraColumns" }] : /* istanbul ignore next */ []));
|
|
8316
8653
|
extraActions = computed(() => {
|
|
8317
8654
|
if (!this.userListExtension)
|
|
8318
8655
|
return [];
|
|
8319
8656
|
const actions = this.userListExtension.getExtraActions();
|
|
8320
8657
|
return actions.sort((a, b) => (a.order ?? 100) - (b.order ?? 100));
|
|
8321
|
-
},
|
|
8322
|
-
|
|
8323
|
-
|
|
8324
|
-
|
|
8325
|
-
|
|
8326
|
-
|
|
8327
|
-
|
|
8658
|
+
}, /* @ts-ignore */
|
|
8659
|
+
...(ngDevMode ? [{ debugName: "extraActions" }] : /* istanbul ignore next */ []));
|
|
8660
|
+
hasUserDetailView = computed(() => !!this.userDetailConfig, /* @ts-ignore */
|
|
8661
|
+
...(ngDevMode ? [{ debugName: "hasUserDetailView" }] : /* istanbul ignore next */ []));
|
|
8662
|
+
tableColspan = computed(() => 6 + this.extraColumns().length, /* @ts-ignore */
|
|
8663
|
+
...(ngDevMode ? [{ debugName: "tableColspan" }] : /* istanbul ignore next */ []));
|
|
8664
|
+
showCompanyDialog = signal(false, /* @ts-ignore */
|
|
8665
|
+
...(ngDevMode ? [{ debugName: "showCompanyDialog" }] : /* istanbul ignore next */ []));
|
|
8666
|
+
showBranchDialog = signal(false, /* @ts-ignore */
|
|
8667
|
+
...(ngDevMode ? [{ debugName: "showBranchDialog" }] : /* istanbul ignore next */ []));
|
|
8668
|
+
showUserDetailDialog = signal(false, /* @ts-ignore */
|
|
8669
|
+
...(ngDevMode ? [{ debugName: "showUserDetailDialog" }] : /* istanbul ignore next */ []));
|
|
8670
|
+
selectedUser = signal(null, /* @ts-ignore */
|
|
8671
|
+
...(ngDevMode ? [{ debugName: "selectedUser" }] : /* istanbul ignore next */ []));
|
|
8328
8672
|
getFieldValue(user, field) {
|
|
8329
8673
|
const parts = field.split('.');
|
|
8330
8674
|
let value = user;
|
|
@@ -8415,8 +8759,8 @@ class UserListComponent {
|
|
|
8415
8759
|
},
|
|
8416
8760
|
});
|
|
8417
8761
|
}
|
|
8418
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
8419
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "
|
|
8762
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: UserListComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
8763
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.5", type: UserListComponent, isStandalone: true, selector: "lib-user-list", ngImport: i0, template: `
|
|
8420
8764
|
<p-card>
|
|
8421
8765
|
<ng-template #header>
|
|
8422
8766
|
<div
|
|
@@ -8425,12 +8769,14 @@ class UserListComponent {
|
|
|
8425
8769
|
<h2 class="text-xl font-semibold m-0">
|
|
8426
8770
|
{{ 'administrative.user.title' | translate }}
|
|
8427
8771
|
</h2>
|
|
8428
|
-
<
|
|
8772
|
+
<button
|
|
8773
|
+
pButton
|
|
8429
8774
|
*hasPermission="USER_PERMISSIONS.CREATE"
|
|
8430
|
-
|
|
8431
|
-
|
|
8432
|
-
|
|
8433
|
-
|
|
8775
|
+
(click)="onCreate()"
|
|
8776
|
+
>
|
|
8777
|
+
<span pButtonIcon class="pi pi-plus"></span>
|
|
8778
|
+
<span pButtonLabel>{{ 'administrative.user.add' | translate }}</span>
|
|
8779
|
+
</button>
|
|
8434
8780
|
</div>
|
|
8435
8781
|
</ng-template>
|
|
8436
8782
|
|
|
@@ -8505,28 +8851,32 @@ class UserListComponent {
|
|
|
8505
8851
|
<td>
|
|
8506
8852
|
<div class="flex gap-1 flex-wrap">
|
|
8507
8853
|
@if (hasUserDetailView()) {
|
|
8508
|
-
<
|
|
8509
|
-
|
|
8854
|
+
<button
|
|
8855
|
+
pButton
|
|
8510
8856
|
[rounded]="true"
|
|
8511
8857
|
[text]="true"
|
|
8512
8858
|
severity="info"
|
|
8513
8859
|
[pTooltip]="'shared.view.details' | translate"
|
|
8514
|
-
(
|
|
8515
|
-
|
|
8860
|
+
(click)="onViewDetails(user)"
|
|
8861
|
+
>
|
|
8862
|
+
<span pButtonIcon class="pi pi-eye"></span>
|
|
8863
|
+
</button>
|
|
8516
8864
|
}
|
|
8517
|
-
<
|
|
8865
|
+
<button
|
|
8866
|
+
pButton
|
|
8518
8867
|
*hasPermission="USER_PERMISSIONS.UPDATE"
|
|
8519
|
-
icon="pi pi-pencil"
|
|
8520
8868
|
[rounded]="true"
|
|
8521
8869
|
[text]="true"
|
|
8522
8870
|
severity="info"
|
|
8523
8871
|
[pTooltip]="'shared.edit' | translate"
|
|
8524
|
-
(
|
|
8525
|
-
|
|
8872
|
+
(click)="onEdit(user)"
|
|
8873
|
+
>
|
|
8874
|
+
<span pButtonIcon class="pi pi-pencil"></span>
|
|
8875
|
+
</button>
|
|
8526
8876
|
@if (companyFeatureEnabled()) {
|
|
8527
|
-
<
|
|
8877
|
+
<button
|
|
8878
|
+
pButton
|
|
8528
8879
|
*hasPermission="USER_PERMISSIONS.UPDATE"
|
|
8529
|
-
icon="pi pi-building"
|
|
8530
8880
|
[rounded]="true"
|
|
8531
8881
|
[text]="true"
|
|
8532
8882
|
severity="secondary"
|
|
@@ -8534,11 +8884,13 @@ class UserListComponent {
|
|
|
8534
8884
|
'administrative.permission.company.permissions'
|
|
8535
8885
|
| translate
|
|
8536
8886
|
"
|
|
8537
|
-
(
|
|
8538
|
-
|
|
8539
|
-
|
|
8887
|
+
(click)="onManageCompanyPermissions(user)"
|
|
8888
|
+
>
|
|
8889
|
+
<span pButtonIcon class="pi pi-building"></span>
|
|
8890
|
+
</button>
|
|
8891
|
+
<button
|
|
8892
|
+
pButton
|
|
8540
8893
|
*hasPermission="USER_PERMISSIONS.UPDATE"
|
|
8541
|
-
icon="pi pi-sitemap"
|
|
8542
8894
|
[rounded]="true"
|
|
8543
8895
|
[text]="true"
|
|
8544
8896
|
severity="secondary"
|
|
@@ -8546,13 +8898,15 @@ class UserListComponent {
|
|
|
8546
8898
|
'administrative.permission.branch.permissions'
|
|
8547
8899
|
| translate
|
|
8548
8900
|
"
|
|
8549
|
-
(
|
|
8550
|
-
|
|
8901
|
+
(click)="onManageBranchPermissions(user)"
|
|
8902
|
+
>
|
|
8903
|
+
<span pButtonIcon class="pi pi-sitemap"></span>
|
|
8904
|
+
</button>
|
|
8551
8905
|
}
|
|
8552
8906
|
@for (action of extraActions(); track action.key) {
|
|
8553
8907
|
@if (isActionVisible(action, user)) {
|
|
8554
|
-
<
|
|
8555
|
-
|
|
8908
|
+
<button
|
|
8909
|
+
pButton
|
|
8556
8910
|
[rounded]="true"
|
|
8557
8911
|
[text]="true"
|
|
8558
8912
|
[severity]="action.severity ?? 'secondary'"
|
|
@@ -8560,19 +8914,23 @@ class UserListComponent {
|
|
|
8560
8914
|
action.labelKey | translate: null : action.label
|
|
8561
8915
|
"
|
|
8562
8916
|
[disabled]="isActionDisabled(action, user)"
|
|
8563
|
-
(
|
|
8564
|
-
|
|
8917
|
+
(click)="onExtraAction(action, user)"
|
|
8918
|
+
>
|
|
8919
|
+
<span pButtonIcon [class]="action.icon"></span>
|
|
8920
|
+
</button>
|
|
8565
8921
|
}
|
|
8566
8922
|
}
|
|
8567
|
-
<
|
|
8923
|
+
<button
|
|
8924
|
+
pButton
|
|
8568
8925
|
*hasPermission="USER_PERMISSIONS.DELETE"
|
|
8569
|
-
icon="pi pi-trash"
|
|
8570
8926
|
[rounded]="true"
|
|
8571
8927
|
[text]="true"
|
|
8572
8928
|
severity="danger"
|
|
8573
8929
|
[pTooltip]="'shared.delete' | translate"
|
|
8574
|
-
(
|
|
8575
|
-
|
|
8930
|
+
(click)="onDelete(user)"
|
|
8931
|
+
>
|
|
8932
|
+
<span pButtonIcon class="pi pi-trash"></span>
|
|
8933
|
+
</button>
|
|
8576
8934
|
</div>
|
|
8577
8935
|
</td>
|
|
8578
8936
|
</tr>
|
|
@@ -8673,25 +9031,29 @@ class UserListComponent {
|
|
|
8673
9031
|
</div>
|
|
8674
9032
|
<div class="flex justify-end gap-2 mt-6">
|
|
8675
9033
|
@if (userDetailConfig?.allowEdit) {
|
|
8676
|
-
<
|
|
8677
|
-
|
|
8678
|
-
|
|
8679
|
-
|
|
8680
|
-
|
|
9034
|
+
<button
|
|
9035
|
+
pButton
|
|
9036
|
+
(click)="onEdit(user); closeUserDetailDialog()"
|
|
9037
|
+
>
|
|
9038
|
+
<span pButtonIcon class="pi pi-pencil"></span>
|
|
9039
|
+
<span pButtonLabel>{{ 'shared.edit' | translate }}</span>
|
|
9040
|
+
</button>
|
|
8681
9041
|
}
|
|
8682
|
-
<
|
|
8683
|
-
|
|
9042
|
+
<button
|
|
9043
|
+
pButton
|
|
8684
9044
|
severity="secondary"
|
|
8685
9045
|
[outlined]="true"
|
|
8686
|
-
(
|
|
8687
|
-
|
|
9046
|
+
(click)="closeUserDetailDialog()"
|
|
9047
|
+
>
|
|
9048
|
+
<span pButtonLabel>{{ 'shared.close' | translate }}</span>
|
|
9049
|
+
</button>
|
|
8688
9050
|
</div>
|
|
8689
9051
|
}
|
|
8690
9052
|
</p-dialog>
|
|
8691
9053
|
}
|
|
8692
|
-
`, isInline: true, dependencies: [{ kind: "ngmodule", type: AngularModule }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "ngmodule", type: PrimeModule }, { kind: "
|
|
9054
|
+
`, isInline: true, dependencies: [{ kind: "ngmodule", type: AngularModule }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "ngmodule", type: PrimeModule }, { kind: "directive", type: i3.ButtonDirective, selector: "[pButton]", inputs: ["pButton", "pButtonPT", "pButtonUnstyled", "hostName", "text", "plain", "raised", "size", "outlined", "link", "rounded", "fluid", "variant", "iconOnly", "loading", "severity"] }, { kind: "directive", type: i3.ButtonLabel, selector: "[pButtonLabel]", inputs: ["pButtonLabelPT", "pButtonLabelUnstyled"] }, { kind: "directive", type: i3.ButtonIcon, selector: "[pButtonIcon]", inputs: ["pButtonIconPT", "pButtonUnstyled"] }, { kind: "component", type: i3$1.Card, selector: "p-card", inputs: ["header", "subheader"] }, { kind: "component", type: i4$2.Dialog, selector: "p-dialog", inputs: ["hostName", "header", "draggable", "resizable", "contentStyle", "contentStyleClass", "modal", "closeOnEscape", "dismissableMask", "rtl", "closable", "breakpoints", "styleClass", "maskStyleClass", "maskStyle", "showHeader", "blockScroll", "autoZIndex", "baseZIndex", "minX", "minY", "focusOnShow", "maximizable", "keepInViewport", "focusTrap", "maskMotionOptions", "motionOptions", "closeIcon", "closeAriaLabel", "closeTabindex", "minimizeIcon", "maximizeIcon", "closeButtonProps", "maximizeButtonProps", "visible", "style", "position", "role", "appendTo"], outputs: ["visibleChange", "onShow", "onHide", "onResizeInit", "onResizeEnd", "onDragStart", "onDragEnd", "onMaximize"] }, { kind: "component", type: i5.Table, selector: "p-table", inputs: ["frozenColumns", "frozenValue", "tableStyle", "tableStyleClass", "paginator", "pageLinks", "rowsPerPageOptions", "alwaysShowPaginator", "paginatorPosition", "paginatorStyleClass", "paginatorDropdownAppendTo", "paginatorDropdownScrollHeight", "currentPageReportTemplate", "showCurrentPageReport", "showJumpToPageDropdown", "showJumpToPageInput", "showFirstLastIcon", "showPageLinks", "defaultSortOrder", "sortMode", "resetPageOnSort", "selectionMode", "selectionPageOnly", "contextMenuSelection", "dataKey", "metaKeySelection", "rowSelectable", "rowTrackBy", "lazy", "lazyLoadOnInit", "compareSelectionBy", "csvSeparator", "exportFilename", "filters", "globalFilterFields", "filterDelay", "filterLocale", "expandedRowKeys", "editingRowKeys", "rowExpandMode", "scrollable", "rowGroupMode", "scrollHeight", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "virtualScrollDelay", "frozenWidth", "contextMenu", "resizableColumns", "columnResizeMode", "reorderableColumns", "loading", "loadingIcon", "showLoader", "rowHover", "customSort", "showInitialSortBadge", "exportFunction", "exportHeader", "stateKey", "stateStorage", "editMode", "groupRowsBy", "size", "showGridlines", "stripedRows", "groupRowsByOrder", "paginatorLocale", "value", "columns", "first", "rows", "totalRecords", "sortField", "sortOrder", "multiSortMeta", "selection", "selectAll"], outputs: ["contextMenuSelectionChange", "firstChange", "rowsChange", "totalRecordsChange", "selectionChange", "selectAllChange", "onRowSelect", "onRowUnselect", "onPage", "onSort", "onFilter", "onLazyLoad", "onRowExpand", "onRowCollapse", "onContextMenuSelect", "onColResize", "onColReorder", "onRowReorder", "onEditInit", "onEditComplete", "onEditCancel", "onHeaderCheckboxToggle", "sortFunction", "onStateSave", "onStateRestore"] }, { kind: "component", type: i6.Tag, selector: "p-tag", inputs: ["severity", "value", "icon", "rounded"] }, { kind: "directive", type: i7.Tooltip, selector: "[pTooltip]", inputs: ["tooltipPosition", "tooltipEvent", "positionStyle", "tooltipStyleClass", "tooltipZIndex", "escape", "showDelay", "hideDelay", "life", "positionTop", "positionLeft", "autoHide", "fitContent", "hideOnEscape", "showOnEllipsis", "pTooltip", "tooltipDisabled", "tooltipOptions", "appendTo", "pTooltipPT", "pTooltipUnstyled"] }, { kind: "directive", type: HasPermissionDirective, selector: "[hasPermission]", inputs: ["hasPermission"] }, { kind: "component", type: UserCompanyPermissionDialogComponent, selector: "lib-user-company-permission-dialog", inputs: ["visible", "user"], outputs: ["closed", "permissionsChanged"] }, { kind: "component", type: UserBranchPermissionDialogComponent, selector: "lib-user-branch-permission-dialog", inputs: ["visible", "user"], outputs: ["closed", "permissionsChanged"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }] });
|
|
8693
9055
|
}
|
|
8694
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
9056
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: UserListComponent, decorators: [{
|
|
8695
9057
|
type: Component,
|
|
8696
9058
|
args: [{
|
|
8697
9059
|
selector: 'lib-user-list',
|
|
@@ -8712,12 +9074,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.5", ngImpor
|
|
|
8712
9074
|
<h2 class="text-xl font-semibold m-0">
|
|
8713
9075
|
{{ 'administrative.user.title' | translate }}
|
|
8714
9076
|
</h2>
|
|
8715
|
-
<
|
|
9077
|
+
<button
|
|
9078
|
+
pButton
|
|
8716
9079
|
*hasPermission="USER_PERMISSIONS.CREATE"
|
|
8717
|
-
|
|
8718
|
-
|
|
8719
|
-
|
|
8720
|
-
|
|
9080
|
+
(click)="onCreate()"
|
|
9081
|
+
>
|
|
9082
|
+
<span pButtonIcon class="pi pi-plus"></span>
|
|
9083
|
+
<span pButtonLabel>{{ 'administrative.user.add' | translate }}</span>
|
|
9084
|
+
</button>
|
|
8721
9085
|
</div>
|
|
8722
9086
|
</ng-template>
|
|
8723
9087
|
|
|
@@ -8792,28 +9156,32 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.5", ngImpor
|
|
|
8792
9156
|
<td>
|
|
8793
9157
|
<div class="flex gap-1 flex-wrap">
|
|
8794
9158
|
@if (hasUserDetailView()) {
|
|
8795
|
-
<
|
|
8796
|
-
|
|
9159
|
+
<button
|
|
9160
|
+
pButton
|
|
8797
9161
|
[rounded]="true"
|
|
8798
9162
|
[text]="true"
|
|
8799
9163
|
severity="info"
|
|
8800
9164
|
[pTooltip]="'shared.view.details' | translate"
|
|
8801
|
-
(
|
|
8802
|
-
|
|
9165
|
+
(click)="onViewDetails(user)"
|
|
9166
|
+
>
|
|
9167
|
+
<span pButtonIcon class="pi pi-eye"></span>
|
|
9168
|
+
</button>
|
|
8803
9169
|
}
|
|
8804
|
-
<
|
|
9170
|
+
<button
|
|
9171
|
+
pButton
|
|
8805
9172
|
*hasPermission="USER_PERMISSIONS.UPDATE"
|
|
8806
|
-
icon="pi pi-pencil"
|
|
8807
9173
|
[rounded]="true"
|
|
8808
9174
|
[text]="true"
|
|
8809
9175
|
severity="info"
|
|
8810
9176
|
[pTooltip]="'shared.edit' | translate"
|
|
8811
|
-
(
|
|
8812
|
-
|
|
9177
|
+
(click)="onEdit(user)"
|
|
9178
|
+
>
|
|
9179
|
+
<span pButtonIcon class="pi pi-pencil"></span>
|
|
9180
|
+
</button>
|
|
8813
9181
|
@if (companyFeatureEnabled()) {
|
|
8814
|
-
<
|
|
9182
|
+
<button
|
|
9183
|
+
pButton
|
|
8815
9184
|
*hasPermission="USER_PERMISSIONS.UPDATE"
|
|
8816
|
-
icon="pi pi-building"
|
|
8817
9185
|
[rounded]="true"
|
|
8818
9186
|
[text]="true"
|
|
8819
9187
|
severity="secondary"
|
|
@@ -8821,11 +9189,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.5", ngImpor
|
|
|
8821
9189
|
'administrative.permission.company.permissions'
|
|
8822
9190
|
| translate
|
|
8823
9191
|
"
|
|
8824
|
-
(
|
|
8825
|
-
|
|
8826
|
-
|
|
9192
|
+
(click)="onManageCompanyPermissions(user)"
|
|
9193
|
+
>
|
|
9194
|
+
<span pButtonIcon class="pi pi-building"></span>
|
|
9195
|
+
</button>
|
|
9196
|
+
<button
|
|
9197
|
+
pButton
|
|
8827
9198
|
*hasPermission="USER_PERMISSIONS.UPDATE"
|
|
8828
|
-
icon="pi pi-sitemap"
|
|
8829
9199
|
[rounded]="true"
|
|
8830
9200
|
[text]="true"
|
|
8831
9201
|
severity="secondary"
|
|
@@ -8833,13 +9203,15 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.5", ngImpor
|
|
|
8833
9203
|
'administrative.permission.branch.permissions'
|
|
8834
9204
|
| translate
|
|
8835
9205
|
"
|
|
8836
|
-
(
|
|
8837
|
-
|
|
9206
|
+
(click)="onManageBranchPermissions(user)"
|
|
9207
|
+
>
|
|
9208
|
+
<span pButtonIcon class="pi pi-sitemap"></span>
|
|
9209
|
+
</button>
|
|
8838
9210
|
}
|
|
8839
9211
|
@for (action of extraActions(); track action.key) {
|
|
8840
9212
|
@if (isActionVisible(action, user)) {
|
|
8841
|
-
<
|
|
8842
|
-
|
|
9213
|
+
<button
|
|
9214
|
+
pButton
|
|
8843
9215
|
[rounded]="true"
|
|
8844
9216
|
[text]="true"
|
|
8845
9217
|
[severity]="action.severity ?? 'secondary'"
|
|
@@ -8847,19 +9219,23 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.5", ngImpor
|
|
|
8847
9219
|
action.labelKey | translate: null : action.label
|
|
8848
9220
|
"
|
|
8849
9221
|
[disabled]="isActionDisabled(action, user)"
|
|
8850
|
-
(
|
|
8851
|
-
|
|
9222
|
+
(click)="onExtraAction(action, user)"
|
|
9223
|
+
>
|
|
9224
|
+
<span pButtonIcon [class]="action.icon"></span>
|
|
9225
|
+
</button>
|
|
8852
9226
|
}
|
|
8853
9227
|
}
|
|
8854
|
-
<
|
|
9228
|
+
<button
|
|
9229
|
+
pButton
|
|
8855
9230
|
*hasPermission="USER_PERMISSIONS.DELETE"
|
|
8856
|
-
icon="pi pi-trash"
|
|
8857
9231
|
[rounded]="true"
|
|
8858
9232
|
[text]="true"
|
|
8859
9233
|
severity="danger"
|
|
8860
9234
|
[pTooltip]="'shared.delete' | translate"
|
|
8861
|
-
(
|
|
8862
|
-
|
|
9235
|
+
(click)="onDelete(user)"
|
|
9236
|
+
>
|
|
9237
|
+
<span pButtonIcon class="pi pi-trash"></span>
|
|
9238
|
+
</button>
|
|
8863
9239
|
</div>
|
|
8864
9240
|
</td>
|
|
8865
9241
|
</tr>
|
|
@@ -8960,18 +9336,22 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.5", ngImpor
|
|
|
8960
9336
|
</div>
|
|
8961
9337
|
<div class="flex justify-end gap-2 mt-6">
|
|
8962
9338
|
@if (userDetailConfig?.allowEdit) {
|
|
8963
|
-
<
|
|
8964
|
-
|
|
8965
|
-
|
|
8966
|
-
|
|
8967
|
-
|
|
9339
|
+
<button
|
|
9340
|
+
pButton
|
|
9341
|
+
(click)="onEdit(user); closeUserDetailDialog()"
|
|
9342
|
+
>
|
|
9343
|
+
<span pButtonIcon class="pi pi-pencil"></span>
|
|
9344
|
+
<span pButtonLabel>{{ 'shared.edit' | translate }}</span>
|
|
9345
|
+
</button>
|
|
8968
9346
|
}
|
|
8969
|
-
<
|
|
8970
|
-
|
|
9347
|
+
<button
|
|
9348
|
+
pButton
|
|
8971
9349
|
severity="secondary"
|
|
8972
9350
|
[outlined]="true"
|
|
8973
|
-
(
|
|
8974
|
-
|
|
9351
|
+
(click)="closeUserDetailDialog()"
|
|
9352
|
+
>
|
|
9353
|
+
<span pButtonLabel>{{ 'shared.close' | translate }}</span>
|
|
9354
|
+
</button>
|
|
8975
9355
|
</div>
|
|
8976
9356
|
}
|
|
8977
9357
|
</p-dialog>
|
|
@@ -9001,11 +9381,16 @@ class VerifyEmailPageComponent {
|
|
|
9001
9381
|
}
|
|
9002
9382
|
queryParams = toSignal(this.route.queryParams);
|
|
9003
9383
|
verificationTriggered = false;
|
|
9004
|
-
isLoading = signal(false,
|
|
9005
|
-
|
|
9006
|
-
|
|
9007
|
-
|
|
9008
|
-
|
|
9384
|
+
isLoading = signal(false, /* @ts-ignore */
|
|
9385
|
+
...(ngDevMode ? [{ debugName: "isLoading" }] : /* istanbul ignore next */ []));
|
|
9386
|
+
pageState = signal('verifying', /* @ts-ignore */
|
|
9387
|
+
...(ngDevMode ? [{ debugName: "pageState" }] : /* istanbul ignore next */ []));
|
|
9388
|
+
resendSuccess = signal(false, /* @ts-ignore */
|
|
9389
|
+
...(ngDevMode ? [{ debugName: "resendSuccess" }] : /* istanbul ignore next */ []));
|
|
9390
|
+
submittedEmail = signal('', /* @ts-ignore */
|
|
9391
|
+
...(ngDevMode ? [{ debugName: "submittedEmail" }] : /* istanbul ignore next */ []));
|
|
9392
|
+
resendFormModel = signal({ email: '' }, /* @ts-ignore */
|
|
9393
|
+
...(ngDevMode ? [{ debugName: "resendFormModel" }] : /* istanbul ignore next */ []));
|
|
9009
9394
|
resendForm = form(this.resendFormModel, (f) => {
|
|
9010
9395
|
required(f.email, {
|
|
9011
9396
|
message: this.translate('auth.validation.email.required'),
|
|
@@ -9014,7 +9399,8 @@ class VerifyEmailPageComponent {
|
|
|
9014
9399
|
message: this.translate('shared.invalid.email'),
|
|
9015
9400
|
});
|
|
9016
9401
|
});
|
|
9017
|
-
isResendFormValid = computed(() => this.resendForm().valid(),
|
|
9402
|
+
isResendFormValid = computed(() => this.resendForm().valid(), /* @ts-ignore */
|
|
9403
|
+
...(ngDevMode ? [{ debugName: "isResendFormValid" }] : /* istanbul ignore next */ []));
|
|
9018
9404
|
constructor() {
|
|
9019
9405
|
effect(() => {
|
|
9020
9406
|
const params = this.queryParams();
|
|
@@ -9108,8 +9494,8 @@ class VerifyEmailPageComponent {
|
|
|
9108
9494
|
this.submittedEmail.set(email);
|
|
9109
9495
|
this.resendSuccess.set(true);
|
|
9110
9496
|
}
|
|
9111
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
9112
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "
|
|
9497
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: VerifyEmailPageComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
9498
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.5", type: VerifyEmailPageComponent, isStandalone: true, selector: "lib-verify-email-page", ngImport: i0, template: `
|
|
9113
9499
|
<app-floating-configurator />
|
|
9114
9500
|
<div
|
|
9115
9501
|
class="bg-surface-ground flex items-center justify-center min-h-screen"
|
|
@@ -9152,10 +9538,12 @@ class VerifyEmailPageComponent {
|
|
|
9152
9538
|
{{ 'auth.verify.email.success.message' | translate }}
|
|
9153
9539
|
</p>
|
|
9154
9540
|
<a routerLink="/auth/login">
|
|
9155
|
-
<
|
|
9156
|
-
|
|
9157
|
-
|
|
9158
|
-
|
|
9541
|
+
<button
|
|
9542
|
+
pButton
|
|
9543
|
+
class="w-full"
|
|
9544
|
+
>
|
|
9545
|
+
<span pButtonLabel>{{ 'auth.login.sign.in' | translate }}</span>
|
|
9546
|
+
</button>
|
|
9159
9547
|
</a>
|
|
9160
9548
|
</div>
|
|
9161
9549
|
}
|
|
@@ -9171,11 +9559,13 @@ class VerifyEmailPageComponent {
|
|
|
9171
9559
|
<p class="text-muted-color font-medium mb-6">
|
|
9172
9560
|
{{ 'auth.verify.email.invalid.link' | translate }}
|
|
9173
9561
|
</p>
|
|
9174
|
-
<
|
|
9175
|
-
|
|
9176
|
-
|
|
9177
|
-
(
|
|
9178
|
-
|
|
9562
|
+
<button
|
|
9563
|
+
pButton
|
|
9564
|
+
class="w-full mb-4"
|
|
9565
|
+
(click)="showResendForm()"
|
|
9566
|
+
>
|
|
9567
|
+
<span pButtonLabel>{{ 'auth.verify.email.resend.email' | translate }}</span>
|
|
9568
|
+
</button>
|
|
9179
9569
|
<div class="mt-4">
|
|
9180
9570
|
<a
|
|
9181
9571
|
routerLink="/auth/login"
|
|
@@ -9215,13 +9605,17 @@ class VerifyEmailPageComponent {
|
|
|
9215
9605
|
autocomplete="email"
|
|
9216
9606
|
/>
|
|
9217
9607
|
|
|
9218
|
-
<
|
|
9219
|
-
|
|
9220
|
-
|
|
9608
|
+
<button
|
|
9609
|
+
pButton
|
|
9610
|
+
class="w-full mb-4"
|
|
9221
9611
|
type="submit"
|
|
9222
|
-
[loading]="isLoading()"
|
|
9223
9612
|
[disabled]="!isResendFormValid() || isLoading()"
|
|
9224
|
-
|
|
9613
|
+
>
|
|
9614
|
+
@if (isLoading()) {
|
|
9615
|
+
<span pButtonIcon class="pi pi-spinner pi-spin"></span>
|
|
9616
|
+
}
|
|
9617
|
+
<span pButtonLabel>{{ 'auth.verify.email.resend' | translate }}</span>
|
|
9618
|
+
</button>
|
|
9225
9619
|
|
|
9226
9620
|
<div class="flex items-center justify-center gap-2">
|
|
9227
9621
|
<a
|
|
@@ -9254,9 +9648,9 @@ class VerifyEmailPageComponent {
|
|
|
9254
9648
|
</div>
|
|
9255
9649
|
</div>
|
|
9256
9650
|
</div>
|
|
9257
|
-
`, isInline: true, dependencies: [{ kind: "ngmodule", type: AngularModule }, { kind: "directive", type: i1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.NgForm, selector: "form:not([ngNoForm]):not([formGroup]):not([formArray]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i2
|
|
9651
|
+
`, isInline: true, dependencies: [{ kind: "ngmodule", type: AngularModule }, { kind: "directive", type: i1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.NgForm, selector: "form:not([ngNoForm]):not([formGroup]):not([formArray]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "browserUrl", "routerLink"] }, { kind: "ngmodule", type: PrimeModule }, { kind: "directive", type: i3.ButtonDirective, selector: "[pButton]", inputs: ["pButton", "pButtonPT", "pButtonUnstyled", "hostName", "text", "plain", "raised", "size", "outlined", "link", "rounded", "fluid", "variant", "iconOnly", "loading", "severity"] }, { kind: "directive", type: i3.ButtonLabel, selector: "[pButtonLabel]", inputs: ["pButtonLabelPT", "pButtonLabelUnstyled"] }, { kind: "directive", type: i3.ButtonIcon, selector: "[pButtonIcon]", inputs: ["pButtonIconPT", "pButtonUnstyled"] }, { kind: "directive", type: i4.InputText, selector: "[pInputText]", inputs: ["hostName", "pInputTextPT", "pInputTextUnstyled", "pSize", "variant", "fluid", "invalid"] }, { kind: "directive", type: FormField, selector: "[formField]", inputs: ["formField"], exportAs: ["formField"] }, { kind: "component", type: AppFloatingConfigurator, selector: "app-floating-configurator" }, { kind: "pipe", type: TranslatePipe, name: "translate" }] });
|
|
9258
9652
|
}
|
|
9259
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
9653
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: VerifyEmailPageComponent, decorators: [{
|
|
9260
9654
|
type: Component,
|
|
9261
9655
|
args: [{
|
|
9262
9656
|
selector: 'lib-verify-email-page',
|
|
@@ -9310,10 +9704,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.5", ngImpor
|
|
|
9310
9704
|
{{ 'auth.verify.email.success.message' | translate }}
|
|
9311
9705
|
</p>
|
|
9312
9706
|
<a routerLink="/auth/login">
|
|
9313
|
-
<
|
|
9314
|
-
|
|
9315
|
-
|
|
9316
|
-
|
|
9707
|
+
<button
|
|
9708
|
+
pButton
|
|
9709
|
+
class="w-full"
|
|
9710
|
+
>
|
|
9711
|
+
<span pButtonLabel>{{ 'auth.login.sign.in' | translate }}</span>
|
|
9712
|
+
</button>
|
|
9317
9713
|
</a>
|
|
9318
9714
|
</div>
|
|
9319
9715
|
}
|
|
@@ -9329,11 +9725,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.5", ngImpor
|
|
|
9329
9725
|
<p class="text-muted-color font-medium mb-6">
|
|
9330
9726
|
{{ 'auth.verify.email.invalid.link' | translate }}
|
|
9331
9727
|
</p>
|
|
9332
|
-
<
|
|
9333
|
-
|
|
9334
|
-
|
|
9335
|
-
(
|
|
9336
|
-
|
|
9728
|
+
<button
|
|
9729
|
+
pButton
|
|
9730
|
+
class="w-full mb-4"
|
|
9731
|
+
(click)="showResendForm()"
|
|
9732
|
+
>
|
|
9733
|
+
<span pButtonLabel>{{ 'auth.verify.email.resend.email' | translate }}</span>
|
|
9734
|
+
</button>
|
|
9337
9735
|
<div class="mt-4">
|
|
9338
9736
|
<a
|
|
9339
9737
|
routerLink="/auth/login"
|
|
@@ -9373,13 +9771,17 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.5", ngImpor
|
|
|
9373
9771
|
autocomplete="email"
|
|
9374
9772
|
/>
|
|
9375
9773
|
|
|
9376
|
-
<
|
|
9377
|
-
|
|
9378
|
-
|
|
9774
|
+
<button
|
|
9775
|
+
pButton
|
|
9776
|
+
class="w-full mb-4"
|
|
9379
9777
|
type="submit"
|
|
9380
|
-
[loading]="isLoading()"
|
|
9381
9778
|
[disabled]="!isResendFormValid() || isLoading()"
|
|
9382
|
-
|
|
9779
|
+
>
|
|
9780
|
+
@if (isLoading()) {
|
|
9781
|
+
<span pButtonIcon class="pi pi-spinner pi-spin"></span>
|
|
9782
|
+
}
|
|
9783
|
+
<span pButtonLabel>{{ 'auth.verify.email.resend' | translate }}</span>
|
|
9784
|
+
</button>
|
|
9383
9785
|
|
|
9384
9786
|
<div class="flex items-center justify-center gap-2">
|
|
9385
9787
|
<a
|