bpm-core 0.0.32 → 0.0.34
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/esm2022/lib/app/app.component.mjs +2 -2
- package/esm2022/lib/components/app-component-sections/faq-sidenav/faq-sidenav.component.mjs +1 -5
- package/esm2022/lib/components/app-component-sections/faqs/faqs.component.mjs +4 -9
- package/esm2022/lib/components/app-component-sections/form-section/form-section.component.mjs +140 -72
- package/esm2022/lib/components/app-component-sections/index.mjs +1 -2
- package/esm2022/lib/components/app-component-sections/main-request-details/main-request-details.component.mjs +5 -7
- package/esm2022/lib/components/app-component-sections/previous-requests/previous-requests.component.mjs +67 -0
- package/esm2022/lib/components/app-component-sections/service-header/service-header.component.mjs +158 -68
- package/esm2022/lib/components/shared-components/form-field/control-value-accessor.directive.mjs +5 -6
- package/esm2022/lib/components/shared-components/form-field/custom-searchable-autocomplete/custom-searchable.component.mjs +3 -3
- package/esm2022/lib/components/shared-components/form-field/date-picker/date-picker.component.mjs +8 -46
- package/esm2022/lib/components/shared-components/form-field/date-range-picker/date-range-picker.component.mjs +161 -14
- package/esm2022/lib/components/shared-components/form-field/input/input.component.mjs +10 -12
- package/esm2022/lib/components/shared-components/form-field/input-currency/input-currency.component.mjs +11 -4
- package/esm2022/lib/components/shared-components/form-field/input-email/input-email.component.mjs +12 -4
- package/esm2022/lib/components/shared-components/form-field/input-mask/input-mask.component.mjs +3 -3
- package/esm2022/lib/components/shared-components/form-field/input-number/input-number.component.mjs +9 -5
- package/esm2022/lib/components/shared-components/form-field/validation-errors/validation-errors.component.mjs +5 -1
- package/esm2022/lib/{validators → directives}/ar.directive.mjs +4 -3
- package/esm2022/lib/{validators → directives}/currency.directive.mjs +4 -3
- package/esm2022/lib/{validators → directives}/en.directive.mjs +4 -3
- package/esm2022/lib/directives/number.directive.mjs +68 -0
- package/esm2022/lib/i18n/ar.mjs +4 -2
- package/esm2022/lib/i18n/en.mjs +3 -1
- package/esm2022/lib/pipes/status-style.pipe.mjs +57 -0
- package/esm2022/lib/regex/regex-patterns.mjs +4 -0
- package/esm2022/lib/services/core.service.ts.mjs +37 -9
- package/esm2022/lib/testComponent/general-approver-section/general-approver-section.component.mjs +2 -2
- package/esm2022/lib/testComponent/request-details-section/request-details-section.component.mjs +13 -6
- package/esm2022/lib/validators/index.mjs +4 -4
- package/fesm2022/bpm-core.mjs +1007 -592
- package/fesm2022/bpm-core.mjs.map +1 -1
- package/lib/components/app-component-sections/faq-sidenav/faq-sidenav.component.d.ts +2 -4
- package/lib/components/app-component-sections/faqs/faqs.component.d.ts +1 -3
- package/lib/components/app-component-sections/form-section/form-section.component.d.ts +92 -7
- package/lib/components/app-component-sections/index.d.ts +0 -1
- package/lib/components/app-component-sections/previous-requests/previous-requests.component.d.ts +22 -0
- package/lib/components/app-component-sections/service-header/service-header.component.d.ts +98 -7
- package/lib/components/shared-components/form-field/control-value-accessor.directive.d.ts +2 -1
- package/lib/components/shared-components/form-field/date-picker/date-picker.component.d.ts +0 -4
- package/lib/components/shared-components/form-field/date-range-picker/date-range-picker.component.d.ts +22 -6
- package/lib/components/shared-components/form-field/input/input.component.d.ts +1 -3
- package/lib/components/shared-components/form-field/input-email/input-email.component.d.ts +1 -0
- package/lib/{validators → directives}/ar.directive.d.ts +1 -1
- package/lib/{validators → directives}/currency.directive.d.ts +1 -1
- package/lib/{validators → directives}/en.directive.d.ts +1 -1
- package/lib/directives/number.directive.d.ts +14 -0
- package/lib/i18n/ar.d.ts +2 -0
- package/lib/i18n/en.d.ts +2 -0
- package/lib/pipes/status-style.pipe.d.ts +7 -0
- package/lib/regex/regex-patterns.d.ts +3 -0
- package/lib/services/core.service.ts.d.ts +2 -0
- package/lib/validators/index.d.ts +0 -3
- package/package.json +1 -1
- package/src/lib/assets/scss/_custom-popover.scss +3 -0
- package/src/lib/assets/scss/_settings.scss +5 -2
- package/esm2022/lib/components/app-component-sections/comment-section/comment-section.component.mjs +0 -66
- package/lib/components/app-component-sections/comment-section/comment-section.component.d.ts +0 -19
package/fesm2022/bpm-core.mjs
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
2
|
import { Injectable, Inject, Component, CUSTOM_ELEMENTS_SCHEMA, Pipe, forwardRef, EventEmitter, Input, Output, ViewChild, Directive, inject, HostListener, NO_ERRORS_SCHEMA, PLATFORM_ID, InjectionToken } from '@angular/core';
|
|
3
3
|
import * as i1$1 from '@angular/material/dialog';
|
|
4
|
-
import { MAT_DIALOG_DATA, MatDialogContent, MatDialogActions, MatDialogClose, MatDialogTitle, MatDialog } from '@angular/material/dialog';
|
|
4
|
+
import { MAT_DIALOG_DATA, MatDialogContent, MatDialogActions, MatDialogClose, MatDialogTitle, MatDialog, MatDialogModule } from '@angular/material/dialog';
|
|
5
5
|
import { Subject, ReplaySubject, BehaviorSubject, catchError, throwError, switchMap, of, from } from 'rxjs';
|
|
6
6
|
import * as i1 from '@angular/common/http';
|
|
7
7
|
import { HttpHeaders } from '@angular/common/http';
|
|
8
8
|
import { map } from 'rxjs/operators';
|
|
9
|
-
import * as
|
|
9
|
+
import * as i3 from '@angular/common';
|
|
10
10
|
import { NgIf, NgClass, NgForOf, NgTemplateOutlet, NgSwitchCase, DecimalPipe, DatePipe, NgSwitchDefault, NgSwitch, CommonModule, NgFor, SlicePipe, NgComponentOutlet, DOCUMENT } from '@angular/common';
|
|
11
11
|
import { MatButton } from '@angular/material/button';
|
|
12
12
|
import { NoopScrollStrategy } from '@angular/cdk/overlay';
|
|
@@ -17,16 +17,16 @@ import { NG_VALUE_ACCESSOR, FormControl, ControlContainer, NgForm, NgControl, Fo
|
|
|
17
17
|
import * as i7 from '@angular/platform-browser';
|
|
18
18
|
import * as FileSaver from 'file-saver';
|
|
19
19
|
import { ImageCropperComponent } from 'ngx-image-cropper';
|
|
20
|
-
import * as
|
|
20
|
+
import * as i1$2 from '@angular/material/form-field';
|
|
21
21
|
import { MatError, MatHint, MatFormField, MatFormFieldModule } from '@angular/material/form-field';
|
|
22
22
|
import { MatCheckbox } from '@angular/material/checkbox';
|
|
23
23
|
import { MatSlideToggle } from '@angular/material/slide-toggle';
|
|
24
24
|
import * as i1$4 from '@angular/material/autocomplete';
|
|
25
25
|
import { MatAutocomplete, MatOption, MatAutocompleteTrigger, MatAutocompleteModule } from '@angular/material/autocomplete';
|
|
26
|
-
import * as i3 from '@angular/material/input';
|
|
26
|
+
import * as i3$1 from '@angular/material/input';
|
|
27
27
|
import { MatInputModule, MatInput } from '@angular/material/input';
|
|
28
28
|
import { MomentDateAdapter, MAT_MOMENT_DATE_ADAPTER_OPTIONS } from '@angular/material-moment-adapter';
|
|
29
|
-
import * as i2$
|
|
29
|
+
import * as i2$1 from '@angular/material/datepicker';
|
|
30
30
|
import { MatDatepicker, MatDatepickerModule, MatDatepickerToggle, MatDatepickerInput } from '@angular/material/datepicker';
|
|
31
31
|
import * as moment from 'moment';
|
|
32
32
|
import { MatIcon } from '@angular/material/icon';
|
|
@@ -35,27 +35,29 @@ import { SatPopoverModule } from '@ncstate/sat-popover';
|
|
|
35
35
|
import { NgxMaskDirective } from 'ngx-mask';
|
|
36
36
|
import { MatSelect, MatOption as MatOption$1, MatLabel, MatError as MatError$1, MatFormField as MatFormField$1 } from '@angular/material/select';
|
|
37
37
|
import { MatProgressSpinner } from '@angular/material/progress-spinner';
|
|
38
|
-
import
|
|
39
|
-
import
|
|
38
|
+
import * as i4$1 from '@angular/material/button-toggle';
|
|
39
|
+
import { MatButtonToggleGroup, MatButtonToggle, MatButtonToggleModule } from '@angular/material/button-toggle';
|
|
40
|
+
import * as i2$2 from '@angular/material/table';
|
|
40
41
|
import { MatTableDataSource, MatTableModule } from '@angular/material/table';
|
|
41
42
|
import * as i1$5 from '@angular/material/paginator';
|
|
42
43
|
import { MatPaginatorModule } from '@angular/material/paginator';
|
|
43
|
-
import * as i2$
|
|
44
|
-
import { RouterLink, RouterModule, RouterLinkActive, RouterOutlet } from '@angular/router';
|
|
44
|
+
import * as i2$4 from '@angular/router';
|
|
45
|
+
import { RouterLink, Router, RouterModule, RouterLinkActive, RouterOutlet } from '@angular/router';
|
|
45
46
|
import * as i5 from '@angular/material/menu';
|
|
46
47
|
import { MatMenu, MatMenuTrigger, MatMenuItem, MatMenuModule } from '@angular/material/menu';
|
|
47
48
|
import { moveItemInArray, CdkDropList, CdkDrag } from '@angular/cdk/drag-drop';
|
|
48
|
-
import * as i3$
|
|
49
|
+
import * as i3$4 from '@angular/material/tooltip';
|
|
49
50
|
import { MatTooltip, MatTooltipModule } from '@angular/material/tooltip';
|
|
50
51
|
import { MatRadioButton, MatRadioGroup } from '@angular/material/radio';
|
|
51
|
-
import * as
|
|
52
|
-
import * as i2$
|
|
52
|
+
import * as i3$2 from 'ngx-toastr';
|
|
53
|
+
import * as i2$3 from '@angular/material/expansion';
|
|
53
54
|
import { MatAccordion, MatExpansionPanel, MatExpansionPanelTitle, MatExpansionModule } from '@angular/material/expansion';
|
|
54
55
|
import { MatDivider } from '@angular/material/divider';
|
|
55
56
|
import { format } from 'date-fns';
|
|
56
|
-
import
|
|
57
|
+
import { TranslateModule } from '@ngx-translate/core';
|
|
58
|
+
import * as i3$3 from 'ng-dynamic-component';
|
|
57
59
|
import { ComponentOutletIoDirective, DynamicModule, DynamicComponentInjectorToken } from 'ng-dynamic-component';
|
|
58
|
-
import * as i3$
|
|
60
|
+
import * as i3$5 from '@angular/material/sidenav';
|
|
59
61
|
import { MatSidenavModule } from '@angular/material/sidenav';
|
|
60
62
|
import * as i6 from '@angular/material/toolbar';
|
|
61
63
|
import { MatToolbarModule } from '@angular/material/toolbar';
|
|
@@ -394,6 +396,8 @@ var en = {
|
|
|
394
396
|
NORMAL: '3 days',
|
|
395
397
|
select: 'Select',
|
|
396
398
|
addMultiAttachments: "Add Multi Attachments",
|
|
399
|
+
flagStatusUpdated: "Flag status updated successfully",
|
|
400
|
+
"AllRequests": "All Requests",
|
|
397
401
|
};
|
|
398
402
|
|
|
399
403
|
var ar = {
|
|
@@ -576,7 +580,9 @@ var ar = {
|
|
|
576
580
|
addMultiAttachments: "إضافة أكثر من ملف",
|
|
577
581
|
"welcome": "مرحبا ",
|
|
578
582
|
"logout": "تسجيل خروج",
|
|
579
|
-
"otherLang": "English"
|
|
583
|
+
"otherLang": "English",
|
|
584
|
+
flagStatusUpdated: "تم التحديث بنجاح",
|
|
585
|
+
"AllRequests": "عدد الطلبات",
|
|
580
586
|
};
|
|
581
587
|
|
|
582
588
|
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
@@ -1150,6 +1156,22 @@ class CoreService {
|
|
|
1150
1156
|
}
|
|
1151
1157
|
return new Blob([arrayBuffer], { type: 'image/jpeg' });
|
|
1152
1158
|
}
|
|
1159
|
+
setFlagPriority(id) {
|
|
1160
|
+
let body = {
|
|
1161
|
+
method: HTTP_METHOD_PUT,
|
|
1162
|
+
destination: TARGET_SERVER_DP,
|
|
1163
|
+
serviceName: SERVICE_NAME_DP_UPDATE_INBOX_ITEM,
|
|
1164
|
+
formName: this.config.formName,
|
|
1165
|
+
urlParameters: {
|
|
1166
|
+
inboxid: this.config.formId
|
|
1167
|
+
},
|
|
1168
|
+
body: {
|
|
1169
|
+
flag: id
|
|
1170
|
+
}
|
|
1171
|
+
};
|
|
1172
|
+
let options = this.getRequestOptions();
|
|
1173
|
+
return this.generalCallApi(body, STATE_MACHINE_ACTION_SUCCESS_INBOX_ITEM, options);
|
|
1174
|
+
}
|
|
1153
1175
|
loadHistory(...args) {
|
|
1154
1176
|
const [id] = args;
|
|
1155
1177
|
const body = {
|
|
@@ -1199,14 +1221,27 @@ class CoreService {
|
|
|
1199
1221
|
let options = this.getRequestOptions();
|
|
1200
1222
|
return this.generalCallApi(body, STATE_MACHINE_ACTION_SUCCESS_RESPONSE, options);
|
|
1201
1223
|
}
|
|
1224
|
+
myRequests(details) {
|
|
1225
|
+
let body = {
|
|
1226
|
+
method: HTTP_METHOD_GET,
|
|
1227
|
+
destination: TARGET_SERVER_WM,
|
|
1228
|
+
serviceName: "form" //, //this.getServiceName(),
|
|
1229
|
+
,
|
|
1230
|
+
formName: "history",
|
|
1231
|
+
queryParameters: {
|
|
1232
|
+
formName: this.config.formName,
|
|
1233
|
+
year: details.year,
|
|
1234
|
+
month: details.month,
|
|
1235
|
+
email: this.loggedInUserId()
|
|
1236
|
+
}
|
|
1237
|
+
};
|
|
1238
|
+
let options = this.getRequestOptions();
|
|
1239
|
+
return this.generalCallApi(body, STATE_MACHINE_ACTION_SUCCESS_RESPONSE, options);
|
|
1240
|
+
}
|
|
1202
1241
|
generalCallApi(body, type, options) {
|
|
1203
1242
|
let apiUrl = this.config.proxyServiceBaseUrl + this.language + this.config.proxyFullAddress + this.config.proxyServiceExecute;
|
|
1204
1243
|
return this.http.post(apiUrl, encodeURIComponent(JSON.stringify(body)), options).pipe(map((responseObject) => {
|
|
1205
1244
|
return responseObject;
|
|
1206
|
-
/*switch (type) {
|
|
1207
|
-
case constants.STATE_MACHINE_ACTION_LOAD_HISTORY:
|
|
1208
|
-
return responseObject
|
|
1209
|
-
}*/
|
|
1210
1245
|
}), catchError((httpError) => {
|
|
1211
1246
|
return throwError(httpError);
|
|
1212
1247
|
}));
|
|
@@ -1250,12 +1285,12 @@ class CoreService {
|
|
|
1250
1285
|
return window.wmConfig.outlook;
|
|
1251
1286
|
}
|
|
1252
1287
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: CoreService, deps: [{ token: i1.HttpClient }, { token: MY_LIB_CONFIG_TOKEN }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
1253
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: CoreService, providedIn: "
|
|
1288
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: CoreService, providedIn: "root" });
|
|
1254
1289
|
}
|
|
1255
1290
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: CoreService, decorators: [{
|
|
1256
1291
|
type: Injectable,
|
|
1257
1292
|
args: [{
|
|
1258
|
-
providedIn: "
|
|
1293
|
+
providedIn: "root"
|
|
1259
1294
|
}]
|
|
1260
1295
|
}], ctorParameters: () => [{ type: i1.HttpClient }, { type: undefined, decorators: [{
|
|
1261
1296
|
type: Inject,
|
|
@@ -2426,6 +2461,7 @@ class ControlValueAccessorDirective {
|
|
|
2426
2461
|
mask;
|
|
2427
2462
|
label;
|
|
2428
2463
|
matSuffix;
|
|
2464
|
+
hasTooltip = false;
|
|
2429
2465
|
minDateValue;
|
|
2430
2466
|
maxDateValue;
|
|
2431
2467
|
maxDate;
|
|
@@ -2468,7 +2504,6 @@ class ControlValueAccessorDirective {
|
|
|
2468
2504
|
this.setDateFormControl();
|
|
2469
2505
|
}
|
|
2470
2506
|
setFormValidators() {
|
|
2471
|
-
console.log(this.control);
|
|
2472
2507
|
this.required = this.control?.hasValidator(Validators.required) ?? false;
|
|
2473
2508
|
}
|
|
2474
2509
|
setDateFormControl() {
|
|
@@ -2493,9 +2528,6 @@ class ControlValueAccessorDirective {
|
|
|
2493
2528
|
const date = new Date(this.customMaxDate);
|
|
2494
2529
|
this.maxDateValue = new Date(date.getFullYear(), date.getMonth(), date.getDate());
|
|
2495
2530
|
}
|
|
2496
|
-
// if (this.field) {
|
|
2497
|
-
// this.date.setValue(this.field);
|
|
2498
|
-
// }
|
|
2499
2531
|
if (this.required)
|
|
2500
2532
|
this.control.addValidators(Validators.required);
|
|
2501
2533
|
}
|
|
@@ -2510,7 +2542,7 @@ class ControlValueAccessorDirective {
|
|
|
2510
2542
|
this.isDisabled = isDisabled;
|
|
2511
2543
|
}
|
|
2512
2544
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: ControlValueAccessorDirective, deps: [{ token: i0.Injector }, { token: CoreI18nService }], target: i0.ɵɵFactoryTarget.Directive });
|
|
2513
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.2.8", type: ControlValueAccessorDirective, selector: "[appControlValueAccessor]", inputs: { isReadOnly: "isReadOnly", labelTextWriteMode: "labelTextWriteMode", labelTextReadMode: "labelTextReadMode", hint: "hint", loading: "loading", placeholder: "placeholder", type: "type", showErrorMessage: "showErrorMessage", showHint: "showHint", showIfEmpty: "showIfEmpty", insideTable: "insideTable", mask: "mask", label: "label", matSuffix: "matSuffix", maxDate: "maxDate", minDate: "minDate", customMaxDate: "customMaxDate", customMinDate: "customMinDate" }, ngImport: i0 });
|
|
2545
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.2.8", type: ControlValueAccessorDirective, selector: "[appControlValueAccessor]", inputs: { isReadOnly: "isReadOnly", labelTextWriteMode: "labelTextWriteMode", labelTextReadMode: "labelTextReadMode", hint: "hint", loading: "loading", placeholder: "placeholder", type: "type", showErrorMessage: "showErrorMessage", showHint: "showHint", showIfEmpty: "showIfEmpty", insideTable: "insideTable", mask: "mask", label: "label", matSuffix: "matSuffix", hasTooltip: "hasTooltip", maxDate: "maxDate", minDate: "minDate", customMaxDate: "customMaxDate", customMinDate: "customMinDate" }, ngImport: i0 });
|
|
2514
2546
|
}
|
|
2515
2547
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: ControlValueAccessorDirective, decorators: [{
|
|
2516
2548
|
type: Directive,
|
|
@@ -2545,6 +2577,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
|
|
|
2545
2577
|
type: Input
|
|
2546
2578
|
}], matSuffix: [{
|
|
2547
2579
|
type: Input
|
|
2580
|
+
}], hasTooltip: [{
|
|
2581
|
+
type: Input
|
|
2548
2582
|
}], maxDate: [{
|
|
2549
2583
|
type: Input
|
|
2550
2584
|
}], minDate: [{
|
|
@@ -2720,6 +2754,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
|
|
|
2720
2754
|
type: Input
|
|
2721
2755
|
}] } });
|
|
2722
2756
|
|
|
2757
|
+
const RegexPatterns = {
|
|
2758
|
+
email: '^[a-z0-9._%+-]+@[a-z0-9.-]+\\.[a-z]{2,4}$', // Email validation
|
|
2759
|
+
};
|
|
2760
|
+
|
|
2723
2761
|
class ValidationErrorsComponent extends ControlValueAccessorDirective {
|
|
2724
2762
|
errors = {};
|
|
2725
2763
|
customErrorMessages = {};
|
|
@@ -2736,9 +2774,12 @@ class ValidationErrorsComponent extends ControlValueAccessorDirective {
|
|
|
2736
2774
|
...customErrorMessages.currentValue,
|
|
2737
2775
|
};
|
|
2738
2776
|
}
|
|
2777
|
+
if (this.errors?.['pattern']?.requiredPattern === RegexPatterns.email) {
|
|
2778
|
+
this.errorMessages['pattern'] = 'You must enter email';
|
|
2779
|
+
}
|
|
2739
2780
|
}
|
|
2740
2781
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: ValidationErrorsComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
2741
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: ValidationErrorsComponent, isStandalone: true, selector: "app-validation-errors", inputs: { errors: "errors", customErrorMessages: "customErrorMessages" }, usesInheritance: true, usesOnChanges: true, ngImport: i0, template: " @if(control.touched) {\r\n @for(error of errors | keyvalue; track error ) {\r\n <mat-error class=\"mb-2\">\r\n {{ errorMessages[error.key] }} {{errors['maxlength']?.requiredLength}} {{errors['minlength']?.requiredLength}}\r\n </mat-error>\r\n }\r\n }", styles: [""], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "pipe", type:
|
|
2782
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: ValidationErrorsComponent, isStandalone: true, selector: "app-validation-errors", inputs: { errors: "errors", customErrorMessages: "customErrorMessages" }, usesInheritance: true, usesOnChanges: true, ngImport: i0, template: " @if(control.touched) {\r\n @for(error of errors | keyvalue; track error ) {\r\n <mat-error class=\"mb-2\">\r\n {{ errorMessages[error.key] }} {{errors['maxlength']?.requiredLength}} {{errors['minlength']?.requiredLength}}\r\n </mat-error>\r\n }\r\n }", styles: [""], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "pipe", type: i3.KeyValuePipe, name: "keyvalue" }, { kind: "directive", type: MatError, selector: "mat-error, [matError]", inputs: ["id"] }] });
|
|
2742
2783
|
}
|
|
2743
2784
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: ValidationErrorsComponent, decorators: [{
|
|
2744
2785
|
type: Component,
|
|
@@ -2796,7 +2837,7 @@ class CustomSearchableComponent extends ControlValueAccessorDirective {
|
|
|
2796
2837
|
this.setFilteredOptions(data);
|
|
2797
2838
|
}
|
|
2798
2839
|
setFilteredOptions(data) {
|
|
2799
|
-
if (this.options
|
|
2840
|
+
if (this.options?.length > 0) {
|
|
2800
2841
|
this.noData = false;
|
|
2801
2842
|
// this.loading = false
|
|
2802
2843
|
this.filteredOptions = data?.target?.value ? this._filter(data.target.value) : this.options.slice(0, 30);
|
|
@@ -2808,7 +2849,7 @@ class CustomSearchableComponent extends ControlValueAccessorDirective {
|
|
|
2808
2849
|
}
|
|
2809
2850
|
_filter(value) {
|
|
2810
2851
|
const filterValue = typeof value === 'string' ? value?.toLowerCase() : value;
|
|
2811
|
-
return this.options
|
|
2852
|
+
return this.options?.filter((option) => Object.values(option).join('')?.toLowerCase().includes(filterValue)).slice(0, 30);
|
|
2812
2853
|
}
|
|
2813
2854
|
displayFn(option) {
|
|
2814
2855
|
return option ? option : '';
|
|
@@ -2824,7 +2865,7 @@ class CustomSearchableComponent extends ControlValueAccessorDirective {
|
|
|
2824
2865
|
useExisting: forwardRef(() => CustomSearchableComponent),
|
|
2825
2866
|
multi: true,
|
|
2826
2867
|
},
|
|
2827
|
-
], usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "<ng-container *ngIf=\"isReadOnly && control?.value\">\r\n <app-info-item class=\"info-item w-100\" [label]=\"label\" [insideTable]=\"insideTable\" [hasLabel]=\"label ? true: false\" [value]=\"control?.value\"></app-info-item>\r\n</ng-container>\r\n\r\n<ng-container *ngIf=\"!isReadOnly\">\r\n <div class=\"d-flex justify-content-between mb-1\" *ngIf=\"label\">\r\n <span class=\"form-label mb-0\">{{label}}</span>\r\n <span *ngIf=\"!required\" class=\"fs-11 fc-dark-gray\">\r\n {{i18n.translate('Optional')}}\r\n </span>\r\n </div>\r\n <mat-form-field class=\"primary-form {{className}}\" [ngClass]=\"{'input-disabled' : (disabled || loading) }\"\r\n [floatLabel]=\"floatLabel\" >\r\n <!-- (click)=\"clearInput()\" -->\r\n <span class=\"sfi sfi-search fc-coral fs-18\" matPrefix></span>\r\n <label class=\"mat-form-content\">\r\n <!-- <bdi> -->\r\n <input #autocompleteInput type=\"text\" (keydown)=\"onKeyDown($event, autocompleteInput)\" [attr.disabled]=\"disabled \" [placeholder]=\"label\" aria-label=\"Number\" matInput\r\n (input)=\"onValueChange($event)\" [formControl]=\"searchControl\"\r\n ngDefaultControl [name]=\"'test'\" [matAutocomplete]=\"auto\" [value]=\"value\" (focusout)=\"onFocusOut()\">\r\n <!-- </bdi> -->\r\n </label>\r\n <span class=\"sfi sfi-spinner d-inline-block spin fc-coral\" matSuffix *ngIf=\"loading\"></span>\r\n <span class=\"sfi sfi-close d-inline-block fc-black cursor-pointer\" (click)=\"clearInput()\" matSuffix\r\n *ngIf=\"!loading && control?.value\"></span>\r\n <mat-autocomplete autoActiveFirstOption #auto=\"matAutocomplete\" [displayWith]=\"displayFn\" \r\n (optionSelected)='getAutoComplete($event.option.value)'>\r\n <ng-container *ngIf=\"!noData\">\r\n <mat-option *ngFor=\"let option of filteredOptions\" [value]=\"option\">\r\n <div class=\"d-flex align-items-center\">\r\n <figure *ngIf=\"option['avatar_url']\" class=\"img-card small circled-img p-0 m-0\">\r\n <img [src]=\"option['avatar_url']\" alt=\"\">\r\n </figure>\r\n <span *ngIf=\"option['avatar_url']\" class=\"mx-2\"></span>\r\n <!-- <bdi> -->\r\n {{option[displayedLable]}}\r\n <!-- </bdi> -->\r\n </div>\r\n </mat-option>\r\n </ng-container>\r\n <ng-container *ngIf=\"noData\">\r\n <mat-option [disabled]=\"true\" class=\"text-center\">No Data</mat-option>\r\n </ng-container>\r\n </mat-autocomplete>\r\n <!-- <mat-error class=\"mb-2\" *ngIf=\"(!control?.valid)\">{{i18n.translate('validSelectError')}}{{label}}\r\n </mat-error> -->\r\n\r\n <mat-hint *ngIf=\"showHint\">\r\n <span class=\"sfi sfi-check-circle font-10 fc-dark-gray\" [ngClass]=\"{'fc-oasis-light-imp':value}\"></span>\r\n <span class=\"mx-1\"></span>\r\n <span class=\"fs-12 fc-onyx\">{{hint}}</span>\r\n </mat-hint>\r\n </mat-form-field>\r\n <app-validation-errors [errors]=\"control.errors\"></app-validation-errors>\r\n\r\n</ng-container>\r\n", styles: [".small-input~.btn{height:41px}:host{flex-grow:1}\n"], dependencies: [{ kind: "component", type: InfoItemComponent, selector: "app-info-item", inputs: ["label", "value", "name", "type", "dateType", "multiple", "insideTable", "hasLabel", "arrayList", "actionType", "download"] }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: MatAutocomplete, selector: "mat-autocomplete", inputs: ["aria-label", "aria-labelledby", "displayWith", "autoActiveFirstOption", "autoSelectActiveOption", "requireSelection", "panelWidth", "disableRipple", "class", "hideSingleSelectionIndicator"], outputs: ["optionSelected", "opened", "closed", "optionActivated"], exportAs: ["matAutocomplete"] }, { kind: "component", type: MatOption, selector: "mat-option", inputs: ["value", "id", "disabled"], outputs: ["onSelectionChange"], exportAs: ["matOption"] }, { kind: "directive", type: MatAutocompleteTrigger, selector: "input[matAutocomplete], textarea[matAutocomplete]", inputs: ["matAutocomplete", "matAutocompletePosition", "matAutocompleteConnectedTo", "autocomplete", "matAutocompleteDisabled"], exportAs: ["matAutocompleteTrigger"] }, { kind: "directive", type: MatHint, selector: "mat-hint", inputs: ["align", "id"] }, { kind: "directive", type: NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "component", type: MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "ngmodule", type: MatFormFieldModule }, { kind: "directive", type:
|
|
2868
|
+
], usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "<ng-container *ngIf=\"isReadOnly && control?.value\">\r\n <app-info-item class=\"info-item w-100\" [label]=\"label\" [insideTable]=\"insideTable\" [hasLabel]=\"label ? true: false\" [value]=\"control?.value\"></app-info-item>\r\n</ng-container>\r\n\r\n<ng-container *ngIf=\"!isReadOnly\">\r\n <div class=\"d-flex justify-content-between mb-1\" *ngIf=\"label\">\r\n <span class=\"form-label mb-0\">{{label}}</span>\r\n <span *ngIf=\"!required\" class=\"fs-11 fc-dark-gray\">\r\n {{i18n.translate('Optional')}}\r\n </span>\r\n </div>\r\n <mat-form-field class=\"primary-form {{className}}\" [ngClass]=\"{'input-disabled' : (disabled || loading) }\"\r\n [floatLabel]=\"floatLabel\" >\r\n <!-- (click)=\"clearInput()\" -->\r\n <span class=\"sfi sfi-search fc-coral fs-18\" matPrefix></span>\r\n <label class=\"mat-form-content\">\r\n <!-- <bdi> -->\r\n <input #autocompleteInput type=\"text\" (keydown)=\"onKeyDown($event, autocompleteInput)\" [attr.disabled]=\"disabled \" [placeholder]=\"label\" aria-label=\"Number\" matInput\r\n (input)=\"onValueChange($event)\" [formControl]=\"searchControl\"\r\n ngDefaultControl [name]=\"'test'\" [matAutocomplete]=\"auto\" [value]=\"value\" (focusout)=\"onFocusOut()\">\r\n <!-- </bdi> -->\r\n </label>\r\n <span class=\"sfi sfi-spinner d-inline-block spin fc-coral\" matSuffix *ngIf=\"loading\"></span>\r\n <span class=\"sfi sfi-close d-inline-block fc-black cursor-pointer\" (click)=\"clearInput()\" matSuffix\r\n *ngIf=\"!loading && control?.value\"></span>\r\n <mat-autocomplete autoActiveFirstOption #auto=\"matAutocomplete\" [displayWith]=\"displayFn\" \r\n (optionSelected)='getAutoComplete($event.option.value)'>\r\n <ng-container *ngIf=\"!noData\">\r\n <mat-option *ngFor=\"let option of filteredOptions\" [value]=\"option\">\r\n <div class=\"d-flex align-items-center\">\r\n <figure *ngIf=\"option['avatar_url']\" class=\"img-card small circled-img p-0 m-0\">\r\n <img [src]=\"option['avatar_url']\" alt=\"\">\r\n </figure>\r\n <span *ngIf=\"option['avatar_url']\" class=\"mx-2\"></span>\r\n <!-- <bdi> -->\r\n {{option[displayedLable]}}\r\n <!-- </bdi> -->\r\n </div>\r\n </mat-option>\r\n </ng-container>\r\n <ng-container *ngIf=\"noData\">\r\n <mat-option [disabled]=\"true\" class=\"text-center\">No Data</mat-option>\r\n </ng-container>\r\n </mat-autocomplete>\r\n <!-- <mat-error class=\"mb-2\" *ngIf=\"(!control?.valid)\">{{i18n.translate('validSelectError')}}{{label}}\r\n </mat-error> -->\r\n\r\n <mat-hint *ngIf=\"showHint\">\r\n <span class=\"sfi sfi-check-circle font-10 fc-dark-gray\" [ngClass]=\"{'fc-oasis-light-imp':value}\"></span>\r\n <span class=\"mx-1\"></span>\r\n <span class=\"fs-12 fc-onyx\">{{hint}}</span>\r\n </mat-hint>\r\n </mat-form-field>\r\n <app-validation-errors [errors]=\"control.errors\"></app-validation-errors>\r\n\r\n</ng-container>\r\n", styles: [".small-input~.btn{height:41px}:host{flex-grow:1}\n"], dependencies: [{ kind: "component", type: InfoItemComponent, selector: "app-info-item", inputs: ["label", "value", "name", "type", "dateType", "multiple", "insideTable", "hasLabel", "arrayList", "actionType", "download"] }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: MatAutocomplete, selector: "mat-autocomplete", inputs: ["aria-label", "aria-labelledby", "displayWith", "autoActiveFirstOption", "autoSelectActiveOption", "requireSelection", "panelWidth", "disableRipple", "class", "hideSingleSelectionIndicator"], outputs: ["optionSelected", "opened", "closed", "optionActivated"], exportAs: ["matAutocomplete"] }, { kind: "component", type: MatOption, selector: "mat-option", inputs: ["value", "id", "disabled"], outputs: ["onSelectionChange"], exportAs: ["matOption"] }, { kind: "directive", type: MatAutocompleteTrigger, selector: "input[matAutocomplete], textarea[matAutocomplete]", inputs: ["matAutocomplete", "matAutocompletePosition", "matAutocompleteConnectedTo", "autocomplete", "matAutocompleteDisabled"], exportAs: ["matAutocompleteTrigger"] }, { kind: "directive", type: MatHint, selector: "mat-hint", inputs: ["align", "id"] }, { kind: "directive", type: NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "component", type: MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "ngmodule", type: MatFormFieldModule }, { kind: "directive", type: i1$2.MatPrefix, selector: "[matPrefix], [matIconPrefix], [matTextPrefix]", inputs: ["matTextPrefix"] }, { kind: "directive", type: i1$2.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "ngmodule", type: MatInputModule }, { kind: "directive", type: i3$1.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { kind: "component", type: ValidationErrorsComponent, selector: "app-validation-errors", inputs: ["errors", "customErrorMessages"] }] });
|
|
2828
2869
|
}
|
|
2829
2870
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: CustomSearchableComponent, decorators: [{
|
|
2830
2871
|
type: Component,
|
|
@@ -2870,7 +2911,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
|
|
|
2870
2911
|
type: Input
|
|
2871
2912
|
}] } });
|
|
2872
2913
|
|
|
2873
|
-
const YEAR_ONLY_FORMAT = {
|
|
2914
|
+
const YEAR_ONLY_FORMAT$1 = {
|
|
2874
2915
|
parse: {
|
|
2875
2916
|
dateInput: 'YYYY',
|
|
2876
2917
|
},
|
|
@@ -2904,9 +2945,6 @@ class DatePickerComponent extends ControlValueAccessorDirective {
|
|
|
2904
2945
|
if (!this.isReadOnly && this.yearOnly)
|
|
2905
2946
|
this.activateYearOnlyMode();
|
|
2906
2947
|
}
|
|
2907
|
-
get shouldSetDateFormateInAr() {
|
|
2908
|
-
return false;
|
|
2909
|
-
}
|
|
2910
2948
|
ngOnChanges(changes) {
|
|
2911
2949
|
if (changes) {
|
|
2912
2950
|
if (this.customMaxDate) {
|
|
@@ -2924,53 +2962,18 @@ class DatePickerComponent extends ControlValueAccessorDirective {
|
|
|
2924
2962
|
focusPicker(picker) {
|
|
2925
2963
|
picker.open();
|
|
2926
2964
|
}
|
|
2927
|
-
onFocus() {
|
|
2928
|
-
this.datepickerObj.show();
|
|
2929
|
-
}
|
|
2930
2965
|
dateChange(event) {
|
|
2931
|
-
if (!this.isDisabled) {
|
|
2932
|
-
|
|
2933
|
-
|
|
2934
|
-
|
|
2935
|
-
const minDate = moment(this.minDateValue);
|
|
2936
|
-
const maxDate = moment(this.maxDateValue);
|
|
2937
|
-
if (eventDate < minDate && this.minDateValue) {
|
|
2938
|
-
this.control.setValue(null);
|
|
2939
|
-
this.datepickerObj.value = '';
|
|
2940
|
-
inputValue = '';
|
|
2941
|
-
}
|
|
2942
|
-
else if (eventDate > maxDate && this.maxDateValue) {
|
|
2943
|
-
this.control.setValue(null);
|
|
2944
|
-
this.datepickerObj.value = '';
|
|
2945
|
-
inputValue = '';
|
|
2946
|
-
}
|
|
2947
|
-
else {
|
|
2948
|
-
inputValue = moment(event.value).locale('en-US').format("YYYY-MM-DDTHH:mm:ss.SSSZ");
|
|
2949
|
-
this.control.setValue(inputValue);
|
|
2950
|
-
}
|
|
2951
|
-
this.control.setValue(inputValue);
|
|
2952
|
-
}
|
|
2953
|
-
else {
|
|
2954
|
-
// this.section.body.details[this.name] = ''
|
|
2955
|
-
}
|
|
2966
|
+
if (event?.value && !this.isDisabled) {
|
|
2967
|
+
let inputValue;
|
|
2968
|
+
inputValue = moment(event.value).locale('en-US').format("YYYY-MM-DDTHH:mm:ss.SSSZ");
|
|
2969
|
+
this.control.setValue(inputValue);
|
|
2956
2970
|
}
|
|
2957
2971
|
}
|
|
2958
2972
|
clearDateValue(event) {
|
|
2959
2973
|
this.control.setValue(null);
|
|
2960
|
-
event?.preventDefault();
|
|
2961
|
-
event?.stopPropagation();
|
|
2962
|
-
console.log(this.control.errors);
|
|
2963
|
-
}
|
|
2964
|
-
removeDate() {
|
|
2965
|
-
// this.field = ''
|
|
2966
|
-
this.control.setValue('');
|
|
2967
|
-
// this.controller.setValue('')
|
|
2968
|
-
}
|
|
2969
|
-
toggleIslamicCal() {
|
|
2970
|
-
this.showIslamic = !this.showIslamic;
|
|
2971
2974
|
}
|
|
2972
2975
|
activateYearOnlyMode() {
|
|
2973
|
-
this.dateFormat.updateDateFormat(YEAR_ONLY_FORMAT.parse, YEAR_ONLY_FORMAT.display);
|
|
2976
|
+
this.dateFormat.updateDateFormat(YEAR_ONLY_FORMAT$1.parse, YEAR_ONLY_FORMAT$1.display);
|
|
2974
2977
|
if (this.control) {
|
|
2975
2978
|
this.control.setValue(moment(this.control.value).format('yyyy'));
|
|
2976
2979
|
}
|
|
@@ -2987,7 +2990,7 @@ class DatePickerComponent extends ControlValueAccessorDirective {
|
|
|
2987
2990
|
});
|
|
2988
2991
|
}
|
|
2989
2992
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: DatePickerComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
2990
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
|
|
2993
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: DatePickerComponent, isStandalone: true, selector: "app-datepicker", inputs: { tooltip: "tooltip", className: "className", calendarType: "calendarType", showLabel: "showLabel", yearOnly: "yearOnly", resetDate: "resetDate", error: "error", format: "format" }, outputs: { dateValue: "dateValue" }, providers: [
|
|
2991
2994
|
{
|
|
2992
2995
|
provide: DateAdapter,
|
|
2993
2996
|
useClass: MomentDateAdapter,
|
|
@@ -3002,7 +3005,7 @@ class DatePickerComponent extends ControlValueAccessorDirective {
|
|
|
3002
3005
|
useExisting: forwardRef(() => DatePickerComponent),
|
|
3003
3006
|
multi: true,
|
|
3004
3007
|
},
|
|
3005
|
-
], viewQueries: [{ propertyName: "datepicker", first: true, predicate: MatDatepicker, descendants: true }], usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "<ng-container
|
|
3008
|
+
], viewQueries: [{ propertyName: "datepicker", first: true, predicate: MatDatepicker, descendants: true }], usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "@if(!isReadOnly){\r\n <ng-container>\r\n @if(label){\r\n <div class=\"d-flex justify-content-between mb-1\">\r\n <span class=\"form-label mb-0\">{{label}}</span>\r\n @if(!required){\r\n <span class=\"fs-11 fc-dark-gray\"> {{i18n.translate('optional')}} </span>\r\n }\r\n </div>\r\n }\r\n <div class=\"justify-content-between mb-1\">\r\n <mat-form-field [ngClass]=\"{'input-disabled' : isDisabled }\" [floatLabel]=\"floatLabel\">\r\n <label class=\"mat-form-content\">\r\n <input matInput (dateInput)=\"dateChange($event)\" [placeholder]=\"label ? (i18n.translate('select') + ' ' + label) : ''\" (focus)=\"focusPicker(dp)\" [min]=\"minDateValue\"\r\n [max]=\"maxDateValue\" readonly [matDatepicker]=\"dp\" [formControl]=\"control\">\r\n </label>\r\n @if(control?.value){\r\n <ds-icon matSuffix icon=\"close\" class=\"fc-onyx fs-10 mx-2 cursor-pointer\" (click)=\"clearDateValue($event)\"></ds-icon>\r\n }\r\n <mat-datepicker-toggle matSuffix [for]=\"dp\">\r\n <ds-icon icon=\"calendar-o\" class=\"fc-black fs-18\" matDatepickerToggleIcon></ds-icon>\r\n </mat-datepicker-toggle>\r\n <mat-datepicker #dp>\r\n </mat-datepicker>\r\n <!-- <mat-error *ngIf=\"errorMessage\">{{errorMessage}}</mat-error> -->\r\n </mat-form-field>\r\n <app-validation-errors [errors]=\"control.errors\"></app-validation-errors>\r\n </div>\r\n \r\n </ng-container>\r\n}\r\n@if(isReadOnly && control){\r\n <ng-container>\r\n <app-info-item class=\"info-item w-100\" type=\"date\" [insideTable]=\"insideTable\" [dateType]=\"calendarType\" [label]=\"labelTextReadMode\"\r\n [value]=\"control.value\" [hasLabel]=\"label? true: false\">\r\n </app-info-item>\r\n </ng-container>\r\n}\r\n\r\n", styles: [":host{flex-grow:1}::ng-deep .year-only .mat-calendar-period-button{pointer-events:none}::ng-deep .year-only .mat-calendar-arrow{display:none}\n"], dependencies: [{ kind: "ngmodule", type: MatFormFieldModule }, { kind: "component", type: i1$2.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i1$2.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "ngmodule", type: MatDatepickerModule }, { kind: "component", type: i2$1.MatDatepicker, selector: "mat-datepicker", exportAs: ["matDatepicker"] }, { kind: "directive", type: i2$1.MatDatepickerInput, selector: "input[matDatepicker]", inputs: ["matDatepicker", "min", "max", "matDatepickerFilter"], exportAs: ["matDatepickerInput"] }, { kind: "component", type: i2$1.MatDatepickerToggle, selector: "mat-datepicker-toggle", inputs: ["for", "tabIndex", "aria-label", "disabled", "disableRipple"], exportAs: ["matDatepickerToggle"] }, { kind: "directive", type: i2$1.MatDatepickerToggleIcon, selector: "[matDatepickerToggleIcon]" }, { kind: "directive", type: MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: InfoItemComponent, selector: "app-info-item", inputs: ["label", "value", "name", "type", "dateType", "multiple", "insideTable", "hasLabel", "arrayList", "actionType", "download"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: ValidationErrorsComponent, selector: "app-validation-errors", inputs: ["errors", "customErrorMessages"] }] });
|
|
3006
3009
|
}
|
|
3007
3010
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: DatePickerComponent, decorators: [{
|
|
3008
3011
|
type: Component,
|
|
@@ -3035,7 +3038,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
|
|
|
3035
3038
|
InfoItemComponent,
|
|
3036
3039
|
ReactiveFormsModule,
|
|
3037
3040
|
ValidationErrorsComponent
|
|
3038
|
-
], template: "<ng-container
|
|
3041
|
+
], template: "@if(!isReadOnly){\r\n <ng-container>\r\n @if(label){\r\n <div class=\"d-flex justify-content-between mb-1\">\r\n <span class=\"form-label mb-0\">{{label}}</span>\r\n @if(!required){\r\n <span class=\"fs-11 fc-dark-gray\"> {{i18n.translate('optional')}} </span>\r\n }\r\n </div>\r\n }\r\n <div class=\"justify-content-between mb-1\">\r\n <mat-form-field [ngClass]=\"{'input-disabled' : isDisabled }\" [floatLabel]=\"floatLabel\">\r\n <label class=\"mat-form-content\">\r\n <input matInput (dateInput)=\"dateChange($event)\" [placeholder]=\"label ? (i18n.translate('select') + ' ' + label) : ''\" (focus)=\"focusPicker(dp)\" [min]=\"minDateValue\"\r\n [max]=\"maxDateValue\" readonly [matDatepicker]=\"dp\" [formControl]=\"control\">\r\n </label>\r\n @if(control?.value){\r\n <ds-icon matSuffix icon=\"close\" class=\"fc-onyx fs-10 mx-2 cursor-pointer\" (click)=\"clearDateValue($event)\"></ds-icon>\r\n }\r\n <mat-datepicker-toggle matSuffix [for]=\"dp\">\r\n <ds-icon icon=\"calendar-o\" class=\"fc-black fs-18\" matDatepickerToggleIcon></ds-icon>\r\n </mat-datepicker-toggle>\r\n <mat-datepicker #dp>\r\n </mat-datepicker>\r\n <!-- <mat-error *ngIf=\"errorMessage\">{{errorMessage}}</mat-error> -->\r\n </mat-form-field>\r\n <app-validation-errors [errors]=\"control.errors\"></app-validation-errors>\r\n </div>\r\n \r\n </ng-container>\r\n}\r\n@if(isReadOnly && control){\r\n <ng-container>\r\n <app-info-item class=\"info-item w-100\" type=\"date\" [insideTable]=\"insideTable\" [dateType]=\"calendarType\" [label]=\"labelTextReadMode\"\r\n [value]=\"control.value\" [hasLabel]=\"label? true: false\">\r\n </app-info-item>\r\n </ng-container>\r\n}\r\n\r\n", styles: [":host{flex-grow:1}::ng-deep .year-only .mat-calendar-period-button{pointer-events:none}::ng-deep .year-only .mat-calendar-arrow{display:none}\n"] }]
|
|
3039
3042
|
}], propDecorators: { tooltip: [{
|
|
3040
3043
|
type: Input
|
|
3041
3044
|
}], className: [{
|
|
@@ -3064,26 +3067,157 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
|
|
|
3064
3067
|
|
|
3065
3068
|
/* eslint-disable @angular-eslint/component-selector */
|
|
3066
3069
|
/* eslint-disable @typescript-eslint/no-empty-function */
|
|
3067
|
-
|
|
3068
|
-
|
|
3070
|
+
const YEAR_ONLY_FORMAT = {
|
|
3071
|
+
parse: {
|
|
3072
|
+
dateInput: 'YYYY',
|
|
3073
|
+
},
|
|
3074
|
+
display: {
|
|
3075
|
+
dateInput: 'YYYY',
|
|
3076
|
+
monthYearLabel: 'YYYY',
|
|
3077
|
+
dateA11yLabel: 'LL',
|
|
3078
|
+
monthYearA11yLabel: 'YYYY',
|
|
3079
|
+
},
|
|
3080
|
+
};
|
|
3081
|
+
class DateRangePickerComponent extends ControlValueAccessorDirective {
|
|
3069
3082
|
tooltip;
|
|
3070
|
-
className = '
|
|
3071
|
-
|
|
3072
|
-
|
|
3073
|
-
|
|
3074
|
-
|
|
3083
|
+
className = 'white-input';
|
|
3084
|
+
yearOnly;
|
|
3085
|
+
dateFormat;
|
|
3086
|
+
datepicker;
|
|
3087
|
+
startControl = new FormControl();
|
|
3088
|
+
endControl = new FormControl();
|
|
3089
|
+
startInputValue;
|
|
3090
|
+
endInputValue;
|
|
3091
|
+
dateRange;
|
|
3092
|
+
ngAfterViewInit() {
|
|
3093
|
+
if (!this.isReadOnly && this.yearOnly)
|
|
3094
|
+
this.activateYearOnlyMode();
|
|
3095
|
+
}
|
|
3096
|
+
ngOnChanges(changes) {
|
|
3097
|
+
if (changes) {
|
|
3098
|
+
if (this.customMaxDate) {
|
|
3099
|
+
const date = new Date(this.customMaxDate);
|
|
3100
|
+
this.maxDateValue = new Date(date.getFullYear(), date.getMonth(), date.getDate());
|
|
3101
|
+
}
|
|
3102
|
+
}
|
|
3103
|
+
if (changes && !this.isReadOnly) { // add min date value for 2 dates validations
|
|
3104
|
+
if (this.customMinDate) {
|
|
3105
|
+
const date = new Date(this.customMinDate);
|
|
3106
|
+
this.minDateValue = new Date(date.getFullYear(), date.getMonth(), date.getDate() + 1);
|
|
3107
|
+
}
|
|
3108
|
+
}
|
|
3109
|
+
}
|
|
3110
|
+
focusPicker(picker) {
|
|
3111
|
+
picker.open();
|
|
3112
|
+
}
|
|
3113
|
+
dateChange(event) {
|
|
3114
|
+
if (event?.value && !this.isDisabled) {
|
|
3115
|
+
let inputValue;
|
|
3116
|
+
if (this.startControl.value && !this.endControl.value) {
|
|
3117
|
+
this.startInputValue = moment(event.value).locale('en-US').format("YYYY-MM-DDTHH:mm:ss.SSSZ");
|
|
3118
|
+
}
|
|
3119
|
+
if (this.startControl.value && this.endControl.value) {
|
|
3120
|
+
this.endInputValue = moment(event.value).locale('en-US').format("YYYY-MM-DDTHH:mm:ss.SSSZ");
|
|
3121
|
+
}
|
|
3122
|
+
if (this.endInputValue && this.startInputValue) {
|
|
3123
|
+
this.dateRange = {
|
|
3124
|
+
startDate: this.startInputValue,
|
|
3125
|
+
endDate: this.endInputValue
|
|
3126
|
+
};
|
|
3127
|
+
}
|
|
3128
|
+
inputValue = moment(event.value).locale('en-US').format("YYYY-MM-DDTHH:mm:ss.SSSZ");
|
|
3129
|
+
if (this.dateRange?.startDate && this.dateRange?.endDate) {
|
|
3130
|
+
this.control.setValue(this.dateRange);
|
|
3131
|
+
}
|
|
3132
|
+
}
|
|
3133
|
+
}
|
|
3134
|
+
clearDateValue(event) {
|
|
3135
|
+
this.dateRange = null;
|
|
3136
|
+
this.startInputValue = null;
|
|
3137
|
+
this.endInputValue = null;
|
|
3138
|
+
this.control.setValue(null);
|
|
3139
|
+
this.endControl.setValue(null);
|
|
3140
|
+
this.startControl.setValue(null);
|
|
3141
|
+
}
|
|
3142
|
+
activateYearOnlyMode() {
|
|
3143
|
+
this.dateFormat.updateDateFormat(YEAR_ONLY_FORMAT.parse, YEAR_ONLY_FORMAT.display);
|
|
3144
|
+
if (this.control) {
|
|
3145
|
+
this.control.setValue(moment(this.control.value).format('yyyy'));
|
|
3146
|
+
}
|
|
3147
|
+
this.datepicker.startView = 'multi-year';
|
|
3148
|
+
this.datepicker.yearSelected.subscribe(e => {
|
|
3149
|
+
this.control.setValue(moment(e).format('yyyy'));
|
|
3150
|
+
this.datepicker.close();
|
|
3151
|
+
});
|
|
3152
|
+
this.datepicker.openedStream.subscribe(() => {
|
|
3153
|
+
document.body.classList.add('year-only');
|
|
3154
|
+
});
|
|
3155
|
+
this.datepicker.closedStream.subscribe(() => {
|
|
3156
|
+
document.body.classList.remove('year-only');
|
|
3157
|
+
});
|
|
3158
|
+
}
|
|
3159
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: DateRangePickerComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
3160
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: DateRangePickerComponent, isStandalone: true, selector: "app-date-range-picker", inputs: { tooltip: "tooltip", className: "className", yearOnly: "yearOnly" }, providers: [
|
|
3161
|
+
{
|
|
3162
|
+
provide: NG_VALUE_ACCESSOR,
|
|
3163
|
+
useExisting: forwardRef(() => DateRangePickerComponent),
|
|
3164
|
+
multi: true,
|
|
3165
|
+
},
|
|
3166
|
+
{
|
|
3167
|
+
provide: DateAdapter,
|
|
3168
|
+
useClass: MomentDateAdapter,
|
|
3169
|
+
deps: [MAT_DATE_LOCALE, MAT_MOMENT_DATE_ADAPTER_OPTIONS],
|
|
3170
|
+
},
|
|
3171
|
+
{
|
|
3172
|
+
provide: MAT_DATE_FORMATS,
|
|
3173
|
+
useClass: CustomDateFormat
|
|
3174
|
+
},
|
|
3175
|
+
], viewQueries: [{ propertyName: "datepicker", first: true, predicate: MatDatepicker, descendants: true }], usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "@if(label){\r\n <div class=\"d-flex justify-content-between mb-1\">\r\n <span class=\"form-label mb-0\">{{label}}</span>\r\n @if(!required){\r\n <span class=\"fs-11 fc-dark-gray\"> {{i18n.translate('optional')}} </span>\r\n }\r\n </div>\r\n}\r\n<mat-form-field class=\"date-range primary-form {{className}}\">\r\n <label class=\"mat-form-content\">\r\n <mat-date-range-input [rangePicker]=\"picker\">\r\n <input matStartDate placeholder=\"Start date\" [formControl]=\"startControl\" [value]=\"value?.startDate ? value?.startDate : null\" (dateInput)=\"dateChange($event)\" (focus)=\"focusPicker(picker)\" [min]=\"minDateValue\"\r\n [max]=\"maxDateValue\">\r\n <input matEndDate placeholder=\"End date\" [formControl]=\"endControl\" [value]=\"value?.endDate ? value?.endDate : null\" (dateInput)=\"dateChange($event)\" (focus)=\"focusPicker(picker)\" [min]=\"minDateValue\"\r\n [max]=\"maxDateValue\">\r\n </mat-date-range-input>\r\n </label>\r\n @if(control?.value){\r\n <ds-icon matSuffix icon=\"close\" class=\"fc-onyx fs-10 mx-2 cursor-pointer\" (click)=\"clearDateValue($event)\"></ds-icon>\r\n }\r\n <mat-datepicker-toggle matSuffix [for]=\"picker\" [disableRipple]=\"true\">\r\n <i class=\"sfi sfi-calendar-o fc-onyx font-18\" matDatepickerToggleIcon></i>\r\n </mat-datepicker-toggle>\r\n <mat-date-range-picker #picker></mat-date-range-picker>\r\n</mat-form-field>\r\n<app-validation-errors [errors]=\"control.errors\"></app-validation-errors>\r\n", styles: [":host{flex-grow:1}\n"], dependencies: [{ kind: "ngmodule", type: MatFormFieldModule }, { kind: "component", type: i1$2.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i1$2.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "ngmodule", type: MatDatepickerModule }, { kind: "component", type: i2$1.MatDatepickerToggle, selector: "mat-datepicker-toggle", inputs: ["for", "tabIndex", "aria-label", "disabled", "disableRipple"], exportAs: ["matDatepickerToggle"] }, { kind: "directive", type: i2$1.MatDatepickerToggleIcon, selector: "[matDatepickerToggleIcon]" }, { kind: "component", type: i2$1.MatDateRangeInput, selector: "mat-date-range-input", inputs: ["rangePicker", "required", "dateFilter", "min", "max", "disabled", "separator", "comparisonStart", "comparisonEnd"], exportAs: ["matDateRangeInput"] }, { kind: "directive", type: i2$1.MatStartDate, selector: "input[matStartDate]", outputs: ["dateChange", "dateInput"] }, { kind: "directive", type: i2$1.MatEndDate, selector: "input[matEndDate]", outputs: ["dateChange", "dateInput"] }, { kind: "component", type: i2$1.MatDateRangePicker, selector: "mat-date-range-picker", exportAs: ["matDateRangePicker"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: ValidationErrorsComponent, selector: "app-validation-errors", inputs: ["errors", "customErrorMessages"] }] });
|
|
3075
3176
|
}
|
|
3076
3177
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: DateRangePickerComponent, decorators: [{
|
|
3077
3178
|
type: Component,
|
|
3078
|
-
args: [{ selector: 'app-date-range-picker', schemas: [CUSTOM_ELEMENTS_SCHEMA], standalone: true,
|
|
3079
|
-
|
|
3080
|
-
|
|
3081
|
-
|
|
3179
|
+
args: [{ selector: 'app-date-range-picker', schemas: [CUSTOM_ELEMENTS_SCHEMA], standalone: true, providers: [
|
|
3180
|
+
{
|
|
3181
|
+
provide: NG_VALUE_ACCESSOR,
|
|
3182
|
+
useExisting: forwardRef(() => DateRangePickerComponent),
|
|
3183
|
+
multi: true,
|
|
3184
|
+
},
|
|
3185
|
+
{
|
|
3186
|
+
provide: DateAdapter,
|
|
3187
|
+
useClass: MomentDateAdapter,
|
|
3188
|
+
deps: [MAT_DATE_LOCALE, MAT_MOMENT_DATE_ADAPTER_OPTIONS],
|
|
3189
|
+
},
|
|
3190
|
+
{
|
|
3191
|
+
provide: MAT_DATE_FORMATS,
|
|
3192
|
+
useClass: CustomDateFormat
|
|
3193
|
+
},
|
|
3194
|
+
], imports: [
|
|
3195
|
+
MatFormFieldModule,
|
|
3196
|
+
MatDatepickerModule,
|
|
3197
|
+
MatFormField,
|
|
3198
|
+
MatInput,
|
|
3199
|
+
MatIcon,
|
|
3200
|
+
MatDatepickerToggle,
|
|
3201
|
+
MatDatepicker,
|
|
3202
|
+
MatDatepickerInput,
|
|
3203
|
+
NgClass,
|
|
3204
|
+
NgIf,
|
|
3205
|
+
InfoItemComponent,
|
|
3206
|
+
ReactiveFormsModule,
|
|
3207
|
+
ValidationErrorsComponent
|
|
3208
|
+
], template: "@if(label){\r\n <div class=\"d-flex justify-content-between mb-1\">\r\n <span class=\"form-label mb-0\">{{label}}</span>\r\n @if(!required){\r\n <span class=\"fs-11 fc-dark-gray\"> {{i18n.translate('optional')}} </span>\r\n }\r\n </div>\r\n}\r\n<mat-form-field class=\"date-range primary-form {{className}}\">\r\n <label class=\"mat-form-content\">\r\n <mat-date-range-input [rangePicker]=\"picker\">\r\n <input matStartDate placeholder=\"Start date\" [formControl]=\"startControl\" [value]=\"value?.startDate ? value?.startDate : null\" (dateInput)=\"dateChange($event)\" (focus)=\"focusPicker(picker)\" [min]=\"minDateValue\"\r\n [max]=\"maxDateValue\">\r\n <input matEndDate placeholder=\"End date\" [formControl]=\"endControl\" [value]=\"value?.endDate ? value?.endDate : null\" (dateInput)=\"dateChange($event)\" (focus)=\"focusPicker(picker)\" [min]=\"minDateValue\"\r\n [max]=\"maxDateValue\">\r\n </mat-date-range-input>\r\n </label>\r\n @if(control?.value){\r\n <ds-icon matSuffix icon=\"close\" class=\"fc-onyx fs-10 mx-2 cursor-pointer\" (click)=\"clearDateValue($event)\"></ds-icon>\r\n }\r\n <mat-datepicker-toggle matSuffix [for]=\"picker\" [disableRipple]=\"true\">\r\n <i class=\"sfi sfi-calendar-o fc-onyx font-18\" matDatepickerToggleIcon></i>\r\n </mat-datepicker-toggle>\r\n <mat-date-range-picker #picker></mat-date-range-picker>\r\n</mat-form-field>\r\n<app-validation-errors [errors]=\"control.errors\"></app-validation-errors>\r\n", styles: [":host{flex-grow:1}\n"] }]
|
|
3209
|
+
}], propDecorators: { tooltip: [{
|
|
3082
3210
|
type: Input
|
|
3083
3211
|
}], className: [{
|
|
3084
3212
|
type: Input
|
|
3085
|
-
}],
|
|
3213
|
+
}], yearOnly: [{
|
|
3086
3214
|
type: Input
|
|
3215
|
+
}], dateFormat: [{
|
|
3216
|
+
type: Inject,
|
|
3217
|
+
args: [MAT_DATE_FORMATS]
|
|
3218
|
+
}], datepicker: [{
|
|
3219
|
+
type: ViewChild,
|
|
3220
|
+
args: [MatDatepicker]
|
|
3087
3221
|
}] } });
|
|
3088
3222
|
|
|
3089
3223
|
class FormLabelComponent {
|
|
@@ -3113,85 +3247,248 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
|
|
|
3113
3247
|
type: Input
|
|
3114
3248
|
}] } });
|
|
3115
3249
|
|
|
3116
|
-
/* eslint-disable @angular-eslint/
|
|
3117
|
-
/* eslint-disable @typescript-eslint/no-
|
|
3118
|
-
|
|
3119
|
-
|
|
3120
|
-
|
|
3121
|
-
|
|
3122
|
-
|
|
3123
|
-
|
|
3124
|
-
|
|
3125
|
-
|
|
3126
|
-
|
|
3127
|
-
|
|
3128
|
-
|
|
3129
|
-
|
|
3130
|
-
|
|
3131
|
-
|
|
3132
|
-
|
|
3133
|
-
|
|
3134
|
-
|
|
3135
|
-
|
|
3250
|
+
/* eslint-disable @angular-eslint/directive-selector */
|
|
3251
|
+
/* eslint-disable @typescript-eslint/no-empty-function */
|
|
3252
|
+
class EnOnlyDirective {
|
|
3253
|
+
specialKeys = ['Backspace', 'ArrowRight', 'ArrowLeft', 'ArrowUp', 'ArrowDown', 'Control'];
|
|
3254
|
+
constructor() {
|
|
3255
|
+
}
|
|
3256
|
+
regex = /^[~`!@#$%^&*()_+=[\]\{}|;':",.\/<>?a-zA-Z0-9- ]+$/;
|
|
3257
|
+
onKeyDown(event) {
|
|
3258
|
+
const text = event.key;
|
|
3259
|
+
const english = /^[a-zA-Z ]*$/;
|
|
3260
|
+
if (this.regex.test(text) || text == " " || text == 'Backspace' || (event.ctrlKey && (text == 'c' || text == 'ؤ' || text == 'v' || text == 'ر' || text == 'x' || text == 'ء' || text == 'a' || text == 'ش' || text == 'z' || text == 'ئ'))) {
|
|
3261
|
+
return;
|
|
3262
|
+
}
|
|
3263
|
+
else {
|
|
3264
|
+
event.preventDefault();
|
|
3265
|
+
}
|
|
3266
|
+
}
|
|
3267
|
+
onPaste(event) {
|
|
3268
|
+
const data = event.clipboardData.getData('text/plain');
|
|
3269
|
+
if (!(this.regex.test(data))) {
|
|
3270
|
+
event.preventDefault();
|
|
3271
|
+
}
|
|
3272
|
+
}
|
|
3273
|
+
onDrop(event) {
|
|
3274
|
+
const data = event.dataTransfer.getData("text/plain");
|
|
3275
|
+
if (!(this.regex.test(data))) {
|
|
3276
|
+
event.preventDefault();
|
|
3277
|
+
}
|
|
3278
|
+
}
|
|
3279
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: EnOnlyDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
3280
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.2.8", type: EnOnlyDirective, isStandalone: true, selector: "[enOnly]", host: { listeners: { "keydown": "onKeyDown($event)", "paste": "onPaste($event)", "drop": "onDrop($event)" } }, ngImport: i0 });
|
|
3136
3281
|
}
|
|
3137
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type:
|
|
3138
|
-
type:
|
|
3139
|
-
args: [{
|
|
3140
|
-
|
|
3141
|
-
|
|
3142
|
-
|
|
3143
|
-
|
|
3144
|
-
|
|
3145
|
-
|
|
3146
|
-
|
|
3147
|
-
|
|
3148
|
-
|
|
3149
|
-
|
|
3150
|
-
|
|
3151
|
-
|
|
3152
|
-
|
|
3153
|
-
|
|
3154
|
-
|
|
3155
|
-
|
|
3156
|
-
|
|
3157
|
-
|
|
3158
|
-
|
|
3159
|
-
|
|
3160
|
-
|
|
3161
|
-
|
|
3162
|
-
|
|
3163
|
-
|
|
3164
|
-
|
|
3165
|
-
|
|
3166
|
-
|
|
3167
|
-
|
|
3168
|
-
|
|
3169
|
-
|
|
3170
|
-
|
|
3171
|
-
|
|
3172
|
-
|
|
3173
|
-
|
|
3174
|
-
|
|
3175
|
-
|
|
3176
|
-
|
|
3177
|
-
|
|
3178
|
-
|
|
3179
|
-
|
|
3180
|
-
|
|
3181
|
-
|
|
3182
|
-
|
|
3183
|
-
|
|
3282
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: EnOnlyDirective, decorators: [{
|
|
3283
|
+
type: Directive,
|
|
3284
|
+
args: [{
|
|
3285
|
+
selector: '[enOnly]',
|
|
3286
|
+
standalone: true
|
|
3287
|
+
}]
|
|
3288
|
+
}], ctorParameters: () => [], propDecorators: { onKeyDown: [{
|
|
3289
|
+
type: HostListener,
|
|
3290
|
+
args: ['keydown', ['$event']]
|
|
3291
|
+
}], onPaste: [{
|
|
3292
|
+
type: HostListener,
|
|
3293
|
+
args: ['paste', ['$event']]
|
|
3294
|
+
}], onDrop: [{
|
|
3295
|
+
type: HostListener,
|
|
3296
|
+
args: ['drop', ['$event']]
|
|
3297
|
+
}] } });
|
|
3298
|
+
|
|
3299
|
+
/* eslint-disable @typescript-eslint/no-empty-function */
|
|
3300
|
+
/* eslint-disable @angular-eslint/directive-selector */
|
|
3301
|
+
class ArOnlyDirective {
|
|
3302
|
+
specialKeys = ['Backspace', 'ArrowRight', 'ArrowLeft', 'ArrowUp', 'ArrowDown', 'Control'];
|
|
3303
|
+
constructor() {
|
|
3304
|
+
}
|
|
3305
|
+
regex = /^[~`!@#$%^&*()_+=[\]\{}|;':",.\/<>?0-9-]+$/;
|
|
3306
|
+
onKeyDown(event) {
|
|
3307
|
+
const text = event.key;
|
|
3308
|
+
if (event.ctrlKey && (text == 'c' || text == 'v' || text == 'x' || text == 'a' || text == 'z')) {
|
|
3309
|
+
return;
|
|
3310
|
+
}
|
|
3311
|
+
const arabicAlphabetDigits = /[\u0600-\u06ff]|[\u0750-\u077f]|[\ufb50-\ufc3f]|[\ufe70-\ufefc]|[\u0200]|[\u00A0]/g;
|
|
3312
|
+
if (arabicAlphabetDigits.test(text) || text == " " || text == 'Backspace' || this.regex.test(text)) {
|
|
3313
|
+
return;
|
|
3314
|
+
}
|
|
3315
|
+
else {
|
|
3316
|
+
event.preventDefault();
|
|
3317
|
+
}
|
|
3318
|
+
}
|
|
3319
|
+
onPaste(event) {
|
|
3320
|
+
const data = event.clipboardData.getData('text/plain');
|
|
3321
|
+
if (!(/[\u0600-\u06ff]|[\u0750-\u077f]|[\ufb50-\ufc3f]|[\ufe70-\ufefc]|[\u0200]|[\u00A0]/g.test(data))) {
|
|
3322
|
+
event.preventDefault();
|
|
3323
|
+
}
|
|
3324
|
+
}
|
|
3325
|
+
onDrop(event) {
|
|
3326
|
+
const data = event.dataTransfer.getData("text/plain");
|
|
3327
|
+
if (!(/[\u0600-\u06ff]|[\u0750-\u077f]|[\ufb50-\ufc3f]|[\ufe70-\ufefc]|[\u0200]|[\u00A0]/g.test(data))) {
|
|
3328
|
+
event.preventDefault();
|
|
3329
|
+
}
|
|
3330
|
+
}
|
|
3331
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: ArOnlyDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
3332
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.2.8", type: ArOnlyDirective, isStandalone: true, selector: "[arOnly]", host: { listeners: { "keydown": "onKeyDown($event)", "paste": "onPaste($event)", "drop": "onDrop($event)" } }, ngImport: i0 });
|
|
3333
|
+
}
|
|
3334
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: ArOnlyDirective, decorators: [{
|
|
3335
|
+
type: Directive,
|
|
3336
|
+
args: [{
|
|
3337
|
+
selector: '[arOnly]',
|
|
3338
|
+
standalone: true
|
|
3339
|
+
}]
|
|
3340
|
+
}], ctorParameters: () => [], propDecorators: { onKeyDown: [{
|
|
3341
|
+
type: HostListener,
|
|
3342
|
+
args: ['keydown', ['$event']]
|
|
3343
|
+
}], onPaste: [{
|
|
3344
|
+
type: HostListener,
|
|
3345
|
+
args: ['paste', ['$event']]
|
|
3346
|
+
}], onDrop: [{
|
|
3347
|
+
type: HostListener,
|
|
3348
|
+
args: ['drop', ['$event']]
|
|
3349
|
+
}] } });
|
|
3350
|
+
|
|
3351
|
+
/* eslint-disable @angular-eslint/use-lifecycle-interface */
|
|
3352
|
+
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
3353
|
+
/* eslint-disable @angular-eslint/component-selector */
|
|
3354
|
+
class InputComponent extends ControlValueAccessorDirective {
|
|
3355
|
+
tooltip;
|
|
3356
|
+
floatLabel = 'auto';
|
|
3357
|
+
className = 'bordered-input';
|
|
3358
|
+
iconPrefixName;
|
|
3359
|
+
iconSuffixName;
|
|
3360
|
+
emitedChangedValue1 = new EventEmitter();
|
|
3361
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: InputComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
3362
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: InputComponent, isStandalone: true, selector: "app-input", inputs: { tooltip: "tooltip", floatLabel: "floatLabel", className: "className", iconPrefixName: "iconPrefixName", iconSuffixName: "iconSuffixName", emitedChangedValue1: "emitedChangedValue1" }, providers: [
|
|
3363
|
+
{
|
|
3364
|
+
provide: NG_VALUE_ACCESSOR,
|
|
3365
|
+
useExisting: forwardRef(() => InputComponent),
|
|
3366
|
+
multi: true,
|
|
3367
|
+
},
|
|
3368
|
+
], usesInheritance: true, ngImport: i0, template: "@if(!isReadOnly){\r\n@if(label){\r\n<div class=\"d-flex justify-content-between mb-1\">\r\n <span class=\"form-label mb-0\">{{ label }}</span\r\n > @if(!required){<span class=\"fs-11 fc-dark-gray\">{{\r\n i18n.translate(\"Optional\")\r\n }}</span\r\n >} @if(hasTooltip){\r\n <span class=\"form-label mb-0\">\r\n {{ tooltip }}\r\n <ds-icon\r\n icon=\"info fs-22\"\r\n class=\"cursor-pointer\"\r\n [satPopoverAnchor]=\"popover\"\r\n (click)=\"popover.toggle(); $event.stopImmediatePropagation()\"\r\n ></ds-icon>\r\n </span>\r\n }\r\n</div>\r\n}\r\n<mat-form-field\r\n class=\"primary-form {{ className }}\"\r\n [ngClass]=\"{ 'input-disabled': control.disabled }\"\r\n [floatLabel]=\"floatLabel\"\r\n>\r\n @if(iconPrefixName){<span class=\"sfi {{ iconPrefixName }}\"></span>}\r\n <label class=\"mat-form-content\">\r\n <!-- add input for ar && en custom directive with add type = arOnly || type = enOnly-->\r\n @if(type === 'arOnly'){\r\n <input\r\n arOnly\r\n matInput\r\n [value]=\"value\"\r\n oninput=\"validity.valid || (value='');\"\r\n [formControl]=\"control\"\r\n [required]=\"required\"\r\n [placeholder]=\"placeholder\"\r\n />\r\n } @else if(type === 'enOnly'){\r\n <input\r\n enOnly\r\n matInput\r\n [value]=\"value\"\r\n oninput=\"validity.valid || (value='');\"\r\n [formControl]=\"control\"\r\n [required]=\"required\"\r\n [placeholder]=\"placeholder\"\r\n />\r\n }\r\n @else{\r\n <input\r\n matInput\r\n [value]=\"value\"\r\n oninput=\"validity.valid || (value='');\"\r\n [formControl]=\"control\"\r\n [type]=\"type\"\r\n [placeholder]=\"placeholder\"\r\n />\r\n }\r\n </label>\r\n \r\n @if(iconSuffixName){<span matSuffix class=\"sfi {{ iconSuffixName }}\"></span>}\r\n @if(hint){\r\n <mat-hint class=\"d-flex align-items-center gap-1 mt-1\">\r\n <span\r\n class=\"sfi sfi-info fs-17 fc-dark-gray\"\r\n [ngClass]=\"{ 'fc-oasis-light-imp': value }\"\r\n ></span>\r\n <span class=\"fs-12 fc-black line-height-1\">{{ hint }}</span>\r\n </mat-hint>\r\n }\r\n</mat-form-field>\r\n<app-validation-errors [errors]=\"control.errors\"></app-validation-errors>\r\n\r\n} @if(isReadOnly && (showIfEmpty || control)){\r\n<ng-container class=\"info-section\">\r\n <app-info-item\r\n class=\"info-item w-100\"\r\n [label]=\"label\"\r\n [insideTable]=\"insideTable\"\r\n [hasLabel]=\"!!label\"\r\n [type]=\"type\"\r\n [value]=\"control.value\"\r\n ></app-info-item>\r\n</ng-container>\r\n}\r\n\r\n<sat-popover #popover [hasBackdrop]=\"true\" verticalAlign=\"below\">\r\n <div class=\"default-popover p-3 fs-14\">\r\n <span class=\"fs-14 fw-bold signature-notes\" [innerHTML]=\"tooltip\"></span>\r\n </div>\r\n</sat-popover>\r\n", styles: [":host{flex-grow:1}.input-disabled{pointer-events:none;opacity:1.5}\n"], dependencies: [{ kind: "ngmodule", type: SatPopoverModule }, { kind: "component", type: i1$3.SatPopoverComponent, selector: "sat-popover", inputs: ["anchor", "horizontalAlign", "xAlign", "verticalAlign", "yAlign", "forceAlignment", "lockAlignment", "autoFocus", "restoreFocus", "scrollStrategy", "hasBackdrop", "interactiveClose", "openTransition", "closeTransition", "openAnimationStartAtScale", "closeAnimationEndAtScale", "backdropClass", "panelClass"], outputs: ["opened", "closed", "afterOpen", "afterClose", "backdropClicked", "overlayKeydown"] }, { kind: "directive", type: i1$3.SatPopoverAnchorDirective, selector: "[satPopoverAnchor]", inputs: ["satPopoverAnchor"], exportAs: ["satPopoverAnchor"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { kind: "directive", type: i2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: MatHint, selector: "mat-hint", inputs: ["align", "id"] }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: InfoItemComponent, selector: "app-info-item", inputs: ["label", "value", "name", "type", "dateType", "multiple", "insideTable", "hasLabel", "arrayList", "actionType", "download"] }, { kind: "component", type: MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { kind: "component", type: ValidationErrorsComponent, selector: "app-validation-errors", inputs: ["errors", "customErrorMessages"] }, { kind: "directive", type: EnOnlyDirective, selector: "[enOnly]" }, { kind: "directive", type: ArOnlyDirective, selector: "[arOnly]" }] });
|
|
3369
|
+
}
|
|
3370
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: InputComponent, decorators: [{
|
|
3371
|
+
type: Component,
|
|
3372
|
+
args: [{ selector: 'app-input', schemas: [CUSTOM_ELEMENTS_SCHEMA], imports: [
|
|
3373
|
+
SatPopoverModule,
|
|
3374
|
+
ReactiveFormsModule,
|
|
3375
|
+
NgIf,
|
|
3376
|
+
MatError,
|
|
3377
|
+
MatHint,
|
|
3378
|
+
NgClass,
|
|
3379
|
+
InfoItemComponent,
|
|
3380
|
+
MatFormField,
|
|
3381
|
+
MatInput,
|
|
3382
|
+
ValidationErrorsComponent,
|
|
3383
|
+
EnOnlyDirective,
|
|
3384
|
+
ArOnlyDirective
|
|
3385
|
+
], standalone: true, providers: [
|
|
3386
|
+
{
|
|
3387
|
+
provide: NG_VALUE_ACCESSOR,
|
|
3388
|
+
useExisting: forwardRef(() => InputComponent),
|
|
3389
|
+
multi: true,
|
|
3390
|
+
},
|
|
3391
|
+
], template: "@if(!isReadOnly){\r\n@if(label){\r\n<div class=\"d-flex justify-content-between mb-1\">\r\n <span class=\"form-label mb-0\">{{ label }}</span\r\n > @if(!required){<span class=\"fs-11 fc-dark-gray\">{{\r\n i18n.translate(\"Optional\")\r\n }}</span\r\n >} @if(hasTooltip){\r\n <span class=\"form-label mb-0\">\r\n {{ tooltip }}\r\n <ds-icon\r\n icon=\"info fs-22\"\r\n class=\"cursor-pointer\"\r\n [satPopoverAnchor]=\"popover\"\r\n (click)=\"popover.toggle(); $event.stopImmediatePropagation()\"\r\n ></ds-icon>\r\n </span>\r\n }\r\n</div>\r\n}\r\n<mat-form-field\r\n class=\"primary-form {{ className }}\"\r\n [ngClass]=\"{ 'input-disabled': control.disabled }\"\r\n [floatLabel]=\"floatLabel\"\r\n>\r\n @if(iconPrefixName){<span class=\"sfi {{ iconPrefixName }}\"></span>}\r\n <label class=\"mat-form-content\">\r\n <!-- add input for ar && en custom directive with add type = arOnly || type = enOnly-->\r\n @if(type === 'arOnly'){\r\n <input\r\n arOnly\r\n matInput\r\n [value]=\"value\"\r\n oninput=\"validity.valid || (value='');\"\r\n [formControl]=\"control\"\r\n [required]=\"required\"\r\n [placeholder]=\"placeholder\"\r\n />\r\n } @else if(type === 'enOnly'){\r\n <input\r\n enOnly\r\n matInput\r\n [value]=\"value\"\r\n oninput=\"validity.valid || (value='');\"\r\n [formControl]=\"control\"\r\n [required]=\"required\"\r\n [placeholder]=\"placeholder\"\r\n />\r\n }\r\n @else{\r\n <input\r\n matInput\r\n [value]=\"value\"\r\n oninput=\"validity.valid || (value='');\"\r\n [formControl]=\"control\"\r\n [type]=\"type\"\r\n [placeholder]=\"placeholder\"\r\n />\r\n }\r\n </label>\r\n \r\n @if(iconSuffixName){<span matSuffix class=\"sfi {{ iconSuffixName }}\"></span>}\r\n @if(hint){\r\n <mat-hint class=\"d-flex align-items-center gap-1 mt-1\">\r\n <span\r\n class=\"sfi sfi-info fs-17 fc-dark-gray\"\r\n [ngClass]=\"{ 'fc-oasis-light-imp': value }\"\r\n ></span>\r\n <span class=\"fs-12 fc-black line-height-1\">{{ hint }}</span>\r\n </mat-hint>\r\n }\r\n</mat-form-field>\r\n<app-validation-errors [errors]=\"control.errors\"></app-validation-errors>\r\n\r\n} @if(isReadOnly && (showIfEmpty || control)){\r\n<ng-container class=\"info-section\">\r\n <app-info-item\r\n class=\"info-item w-100\"\r\n [label]=\"label\"\r\n [insideTable]=\"insideTable\"\r\n [hasLabel]=\"!!label\"\r\n [type]=\"type\"\r\n [value]=\"control.value\"\r\n ></app-info-item>\r\n</ng-container>\r\n}\r\n\r\n<sat-popover #popover [hasBackdrop]=\"true\" verticalAlign=\"below\">\r\n <div class=\"default-popover p-3 fs-14\">\r\n <span class=\"fs-14 fw-bold signature-notes\" [innerHTML]=\"tooltip\"></span>\r\n </div>\r\n</sat-popover>\r\n", styles: [":host{flex-grow:1}.input-disabled{pointer-events:none;opacity:1.5}\n"] }]
|
|
3392
|
+
}], propDecorators: { tooltip: [{
|
|
3393
|
+
type: Input
|
|
3394
|
+
}], floatLabel: [{
|
|
3395
|
+
type: Input
|
|
3396
|
+
}], className: [{
|
|
3397
|
+
type: Input
|
|
3398
|
+
}], iconPrefixName: [{
|
|
3399
|
+
type: Input
|
|
3400
|
+
}], iconSuffixName: [{
|
|
3401
|
+
type: Input
|
|
3402
|
+
}], emitedChangedValue1: [{
|
|
3403
|
+
type: Input
|
|
3404
|
+
}] } });
|
|
3405
|
+
|
|
3406
|
+
/* eslint-disable @typescript-eslint/no-unused-vars */
|
|
3407
|
+
/* eslint-disable @angular-eslint/directive-selector */
|
|
3408
|
+
class NumberDirective {
|
|
3409
|
+
el;
|
|
3410
|
+
decimals = 0;
|
|
3411
|
+
constructor(el) {
|
|
3412
|
+
this.el = el;
|
|
3413
|
+
}
|
|
3414
|
+
check(value) {
|
|
3415
|
+
if (this.decimals <= 0) {
|
|
3416
|
+
// Updated RegExp to allow for decimal
|
|
3417
|
+
return String(value).match(new RegExp(/^\d*\.?\d*$/));
|
|
3418
|
+
}
|
|
3419
|
+
else {
|
|
3420
|
+
const regExpString = "^\\s*((\\d+(\\.\\d{0," +
|
|
3421
|
+
this.decimals +
|
|
3422
|
+
"})?)|((\\d*(\\.\\d{1," +
|
|
3423
|
+
this.decimals +
|
|
3424
|
+
"}))))\\s*$";
|
|
3425
|
+
return String(value).match(new RegExp(regExpString));
|
|
3426
|
+
}
|
|
3427
|
+
}
|
|
3428
|
+
onKeyPress(event) {
|
|
3429
|
+
const char = event.key;
|
|
3430
|
+
const currentValue = this.el.nativeElement.value;
|
|
3431
|
+
const nextValue = currentValue + char;
|
|
3432
|
+
if (nextValue !== '' && !this.check(nextValue)) {
|
|
3433
|
+
event.preventDefault();
|
|
3434
|
+
}
|
|
3435
|
+
}
|
|
3436
|
+
run(oldValue) {
|
|
3437
|
+
setTimeout(() => {
|
|
3438
|
+
const currentValue = this.el.nativeElement.value;
|
|
3439
|
+
if (currentValue !== '' && !this.check(currentValue)) {
|
|
3440
|
+
this.el.nativeElement.value = oldValue;
|
|
3441
|
+
}
|
|
3442
|
+
});
|
|
3443
|
+
}
|
|
3444
|
+
onKeyDown() {
|
|
3445
|
+
this.run(this.el.nativeElement.value);
|
|
3446
|
+
}
|
|
3447
|
+
onPaste() {
|
|
3448
|
+
this.run(this.el.nativeElement.value);
|
|
3449
|
+
}
|
|
3450
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: NumberDirective, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive });
|
|
3451
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.2.8", type: NumberDirective, isStandalone: true, selector: "[numberOnly]", inputs: { decimals: "decimals" }, host: { listeners: { "keypress": "onKeyPress($event)", "keydown": "onKeyDown($event)", "paste": "onPaste($event)" } }, ngImport: i0 });
|
|
3452
|
+
}
|
|
3453
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: NumberDirective, decorators: [{
|
|
3454
|
+
type: Directive,
|
|
3455
|
+
args: [{
|
|
3456
|
+
selector: "[numberOnly]",
|
|
3457
|
+
standalone: true
|
|
3458
|
+
}]
|
|
3459
|
+
}], ctorParameters: () => [{ type: i0.ElementRef }], propDecorators: { decimals: [{
|
|
3460
|
+
type: Input
|
|
3461
|
+
}], onKeyPress: [{
|
|
3462
|
+
type: HostListener,
|
|
3463
|
+
args: ['keypress', ['$event']]
|
|
3464
|
+
}], onKeyDown: [{
|
|
3465
|
+
type: HostListener,
|
|
3466
|
+
args: ["keydown", ["$event"]]
|
|
3467
|
+
}], onPaste: [{
|
|
3468
|
+
type: HostListener,
|
|
3469
|
+
args: ["paste", ["$event"]]
|
|
3470
|
+
}] } });
|
|
3471
|
+
|
|
3472
|
+
/* eslint-disable @angular-eslint/use-lifecycle-interface */
|
|
3473
|
+
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
3474
|
+
/* eslint-disable @angular-eslint/component-selector */
|
|
3475
|
+
class InputNumberComponent extends ControlValueAccessorDirective {
|
|
3476
|
+
tooltip;
|
|
3477
|
+
floatLabel = 'auto';
|
|
3478
|
+
className = 'bordered-input';
|
|
3479
|
+
iconPrefixName;
|
|
3480
|
+
iconSuffixName;
|
|
3184
3481
|
numberSuffixName;
|
|
3185
3482
|
allowedPattern = '';
|
|
3186
3483
|
emitedChangedValue = new EventEmitter();
|
|
3187
3484
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: InputNumberComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
3188
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
|
|
3485
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: InputNumberComponent, isStandalone: true, selector: "app-input-number", inputs: { tooltip: "tooltip", floatLabel: "floatLabel", className: "className", iconPrefixName: "iconPrefixName", iconSuffixName: "iconSuffixName", numberSuffixName: "numberSuffixName", allowedPattern: "allowedPattern" }, outputs: { emitedChangedValue: "emitedChangedValue" }, providers: [
|
|
3189
3486
|
{
|
|
3190
3487
|
provide: NG_VALUE_ACCESSOR,
|
|
3191
3488
|
useExisting: forwardRef(() => InputNumberComponent),
|
|
3192
3489
|
multi: true,
|
|
3193
3490
|
},
|
|
3194
|
-
], usesInheritance: true, ngImport: i0, template: "
|
|
3491
|
+
], usesInheritance: true, ngImport: i0, template: "@if(!isReadOnly){\r\n @if(label){\r\n <div class=\"d-flex justify-content-between mb-1\">\r\n <span class=\"form-label mb-0\">{{ label }}</span\r\n > @if(!required){<span class=\"fs-11 fc-dark-gray\">{{\r\n i18n.translate(\"Optional\")\r\n }}</span\r\n >} @if(hasTooltip){\r\n <span class=\"form-label mb-0\">\r\n {{ tooltip }}\r\n <ds-icon\r\n icon=\"info fs-22\"\r\n class=\"cursor-pointer\"\r\n [satPopoverAnchor]=\"popover\"\r\n (click)=\"popover.toggle(); $event.stopImmediatePropagation()\"\r\n ></ds-icon>\r\n </span>\r\n }\r\n </div>\r\n }\r\n <mat-form-field\r\n class=\"primary-form {{ className }}\"\r\n [ngClass]=\"{ 'input-disabled': control.disabled }\"\r\n [floatLabel]=\"floatLabel\"\r\n >\r\n @if(iconPrefixName){<span class=\"sfi {{ iconPrefixName }}\"></span>}\r\n @if(loading){<span\r\n class=\"sfi sfi-spinner d-inline-block spin fc-coral\"\r\n matSuffix\r\n ></span\r\n >}\r\n <label class=\"mat-form-content\">\r\n <!-- add input for ar && en custom directive with add type = arOnly || type = enOnly-->\r\n <input\r\n matInput\r\n [value]=\"value\"\r\n oninput=\"validity.valid || (value='');\"\r\n [formControl]=\"control\"\r\n [type]=\"type\"\r\n [placeholder]=\"placeholder\"\r\n numberOnly\r\n />\r\n </label>\r\n @if(iconSuffixName){<span matSuffix class=\"sfi {{ iconSuffixName }}\"></span>}\r\n @if(hint){\r\n <mat-hint class=\"d-flex align-items-center gap-1 mt-1\">\r\n <span\r\n class=\"sfi sfi-info fs-17 fc-dark-gray\"\r\n [ngClass]=\"{ 'fc-oasis-light-imp': value }\"\r\n ></span>\r\n <span class=\"fs-12 fc-black line-height-1\">{{ hint }}</span>\r\n </mat-hint>\r\n }\r\n </mat-form-field>\r\n <app-validation-errors [errors]=\"control.errors\"></app-validation-errors>\r\n } @if(isReadOnly && (showIfEmpty || control)){\r\n <ng-container class=\"info-section\">\r\n <app-info-item\r\n class=\"info-item w-100\"\r\n [label]=\"label\"\r\n [insideTable]=\"insideTable\"\r\n [hasLabel]=\"!!label\"\r\n [type]=\"type\"\r\n [value]=\"control.value\"\r\n ></app-info-item>\r\n </ng-container>\r\n }\r\n <sat-popover #popover [hasBackdrop]=\"true\" verticalAlign=\"below\">\r\n <div class=\"default-popover p-3 fs-14\">\r\n <span class=\"fs-14 fw-bold signature-notes\" [innerHTML]=\"tooltip\"></span>\r\n </div>\r\n </sat-popover>\r\n ", styles: [":host{flex-grow:1}.input-disabled{pointer-events:none;opacity:1.5}\n"], dependencies: [{ kind: "component", type: MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: InfoItemComponent, selector: "app-info-item", inputs: ["label", "value", "name", "type", "dateType", "multiple", "insideTable", "hasLabel", "arrayList", "actionType", "download"] }, { kind: "ngmodule", type: SatPopoverModule }, { kind: "component", type: i1$3.SatPopoverComponent, selector: "sat-popover", inputs: ["anchor", "horizontalAlign", "xAlign", "verticalAlign", "yAlign", "forceAlignment", "lockAlignment", "autoFocus", "restoreFocus", "scrollStrategy", "hasBackdrop", "interactiveClose", "openTransition", "closeTransition", "openAnimationStartAtScale", "closeAnimationEndAtScale", "backdropClass", "panelClass"], outputs: ["opened", "closed", "afterOpen", "afterClose", "backdropClicked", "overlayKeydown"] }, { kind: "directive", type: i1$3.SatPopoverAnchorDirective, selector: "[satPopoverAnchor]", inputs: ["satPopoverAnchor"], exportAs: ["satPopoverAnchor"] }, { kind: "directive", type: MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { kind: "directive", type: NumberDirective, selector: "[numberOnly]", inputs: ["decimals"] }, { kind: "component", type: ValidationErrorsComponent, selector: "app-validation-errors", inputs: ["errors", "customErrorMessages"] }] });
|
|
3195
3492
|
}
|
|
3196
3493
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: InputNumberComponent, decorators: [{
|
|
3197
3494
|
type: Component,
|
|
@@ -3203,14 +3500,16 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
|
|
|
3203
3500
|
NgxMaskDirective,
|
|
3204
3501
|
InfoItemComponent,
|
|
3205
3502
|
SatPopoverModule,
|
|
3206
|
-
MatInput
|
|
3503
|
+
MatInput,
|
|
3504
|
+
NumberDirective,
|
|
3505
|
+
ValidationErrorsComponent
|
|
3207
3506
|
], providers: [
|
|
3208
3507
|
{
|
|
3209
3508
|
provide: NG_VALUE_ACCESSOR,
|
|
3210
3509
|
useExisting: forwardRef(() => InputNumberComponent),
|
|
3211
3510
|
multi: true,
|
|
3212
3511
|
},
|
|
3213
|
-
], template: "
|
|
3512
|
+
], template: "@if(!isReadOnly){\r\n @if(label){\r\n <div class=\"d-flex justify-content-between mb-1\">\r\n <span class=\"form-label mb-0\">{{ label }}</span\r\n > @if(!required){<span class=\"fs-11 fc-dark-gray\">{{\r\n i18n.translate(\"Optional\")\r\n }}</span\r\n >} @if(hasTooltip){\r\n <span class=\"form-label mb-0\">\r\n {{ tooltip }}\r\n <ds-icon\r\n icon=\"info fs-22\"\r\n class=\"cursor-pointer\"\r\n [satPopoverAnchor]=\"popover\"\r\n (click)=\"popover.toggle(); $event.stopImmediatePropagation()\"\r\n ></ds-icon>\r\n </span>\r\n }\r\n </div>\r\n }\r\n <mat-form-field\r\n class=\"primary-form {{ className }}\"\r\n [ngClass]=\"{ 'input-disabled': control.disabled }\"\r\n [floatLabel]=\"floatLabel\"\r\n >\r\n @if(iconPrefixName){<span class=\"sfi {{ iconPrefixName }}\"></span>}\r\n @if(loading){<span\r\n class=\"sfi sfi-spinner d-inline-block spin fc-coral\"\r\n matSuffix\r\n ></span\r\n >}\r\n <label class=\"mat-form-content\">\r\n <!-- add input for ar && en custom directive with add type = arOnly || type = enOnly-->\r\n <input\r\n matInput\r\n [value]=\"value\"\r\n oninput=\"validity.valid || (value='');\"\r\n [formControl]=\"control\"\r\n [type]=\"type\"\r\n [placeholder]=\"placeholder\"\r\n numberOnly\r\n />\r\n </label>\r\n @if(iconSuffixName){<span matSuffix class=\"sfi {{ iconSuffixName }}\"></span>}\r\n @if(hint){\r\n <mat-hint class=\"d-flex align-items-center gap-1 mt-1\">\r\n <span\r\n class=\"sfi sfi-info fs-17 fc-dark-gray\"\r\n [ngClass]=\"{ 'fc-oasis-light-imp': value }\"\r\n ></span>\r\n <span class=\"fs-12 fc-black line-height-1\">{{ hint }}</span>\r\n </mat-hint>\r\n }\r\n </mat-form-field>\r\n <app-validation-errors [errors]=\"control.errors\"></app-validation-errors>\r\n } @if(isReadOnly && (showIfEmpty || control)){\r\n <ng-container class=\"info-section\">\r\n <app-info-item\r\n class=\"info-item w-100\"\r\n [label]=\"label\"\r\n [insideTable]=\"insideTable\"\r\n [hasLabel]=\"!!label\"\r\n [type]=\"type\"\r\n [value]=\"control.value\"\r\n ></app-info-item>\r\n </ng-container>\r\n }\r\n <sat-popover #popover [hasBackdrop]=\"true\" verticalAlign=\"below\">\r\n <div class=\"default-popover p-3 fs-14\">\r\n <span class=\"fs-14 fw-bold signature-notes\" [innerHTML]=\"tooltip\"></span>\r\n </div>\r\n </sat-popover>\r\n ", styles: [":host{flex-grow:1}.input-disabled{pointer-events:none;opacity:1.5}\n"] }]
|
|
3214
3513
|
}], propDecorators: { tooltip: [{
|
|
3215
3514
|
type: Input
|
|
3216
3515
|
}], floatLabel: [{
|
|
@@ -3240,6 +3539,9 @@ class InputEmailComponent extends ControlValueAccessorDirective {
|
|
|
3240
3539
|
iconPrefixName;
|
|
3241
3540
|
iconSuffixName;
|
|
3242
3541
|
numberSuffixName;
|
|
3542
|
+
displayErrors(data) {
|
|
3543
|
+
console.log(this.control.errors);
|
|
3544
|
+
}
|
|
3243
3545
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: InputEmailComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
3244
3546
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: InputEmailComponent, isStandalone: true, selector: "app-input-email", inputs: { tooltip: "tooltip", floatLabel: "floatLabel", className: "className", matPrefix: "matPrefix", iconPrefixName: "iconPrefixName", iconSuffixName: "iconSuffixName", numberSuffixName: "numberSuffixName" }, providers: [
|
|
3245
3547
|
{
|
|
@@ -3247,7 +3549,7 @@ class InputEmailComponent extends ControlValueAccessorDirective {
|
|
|
3247
3549
|
useExisting: forwardRef(() => InputEmailComponent),
|
|
3248
3550
|
multi: true,
|
|
3249
3551
|
},
|
|
3250
|
-
], usesInheritance: true, ngImport: i0, template: "
|
|
3552
|
+
], usesInheritance: true, ngImport: i0, template: "@if(!isReadOnly){\r\n @if(label){\r\n <div class=\"d-flex justify-content-between mb-1\">\r\n <span class=\"form-label mb-0\">{{ label }}</span\r\n > @if(!required){<span class=\"fs-11 fc-dark-gray\">{{\r\n i18n.translate(\"Optional\")\r\n }}</span\r\n >} @if(hasTooltip){\r\n <span class=\"form-label mb-0\">\r\n {{ tooltip }}\r\n <ds-icon\r\n icon=\"info fs-22\"\r\n class=\"cursor-pointer\"\r\n [satPopoverAnchor]=\"popover\"\r\n (click)=\"popover.toggle(); $event.stopImmediatePropagation()\"\r\n ></ds-icon>\r\n </span>\r\n }\r\n </div>\r\n }\r\n <mat-form-field\r\n class=\"primary-form {{ className }}\"\r\n [ngClass]=\"{ 'input-disabled': control.disabled }\"\r\n [floatLabel]=\"floatLabel\"\r\n >\r\n @if(iconPrefixName){<span class=\"sfi {{ iconPrefixName }}\"></span>}\r\n @if(loading){<span\r\n class=\"sfi sfi-spinner d-inline-block spin fc-coral\"\r\n matSuffix\r\n ></span\r\n >}\r\n <label class=\"mat-form-content\">\r\n <!-- add input for ar && en custom directive with add type = arOnly || type = enOnly-->\r\n <input\r\n matInput\r\n [value]=\"value\"\r\n oninput=\"validity.valid || (value='');\"\r\n [formControl]=\"control\"\r\n [type]=\"type\"\r\n [placeholder]=\"placeholder\"\r\n (change)=\"displayErrors($event)\"\r\n />\r\n </label>\r\n @if(iconSuffixName){<span matSuffix class=\"sfi {{ iconSuffixName }}\"></span>}\r\n @if(hint){\r\n <mat-hint class=\"d-flex align-items-center gap-1 mt-1\">\r\n <span\r\n class=\"sfi sfi-info fs-17 fc-dark-gray\"\r\n [ngClass]=\"{ 'fc-oasis-light-imp': value }\"\r\n ></span>\r\n <span class=\"fs-12 fc-black line-height-1\">{{ hint }}</span>\r\n </mat-hint>\r\n }\r\n </mat-form-field>\r\n <app-validation-errors [errors]=\"control.errors\"></app-validation-errors>\r\n } @if(isReadOnly && (showIfEmpty || control)){\r\n <ng-container class=\"info-section\">\r\n <app-info-item\r\n class=\"info-item w-100\"\r\n [label]=\"label\"\r\n [insideTable]=\"insideTable\"\r\n [hasLabel]=\"!!label\"\r\n [type]=\"type\"\r\n [value]=\"control.value\"\r\n ></app-info-item>\r\n </ng-container>\r\n }\r\n <sat-popover #popover [hasBackdrop]=\"true\" verticalAlign=\"below\">\r\n <div class=\"default-popover p-3 fs-14\">\r\n <span class=\"fs-14 fw-bold signature-notes\" [innerHTML]=\"tooltip\"></span>\r\n </div>\r\n </sat-popover>\r\n ", styles: [":host{flex-grow:1}.input-disabled{pointer-events:none;opacity:1.5}\n"], dependencies: [{ kind: "component", type: MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "component", type: InfoItemComponent, selector: "app-info-item", inputs: ["label", "value", "name", "type", "dateType", "multiple", "insideTable", "hasLabel", "arrayList", "actionType", "download"] }, { kind: "ngmodule", type: SatPopoverModule }, { kind: "component", type: i1$3.SatPopoverComponent, selector: "sat-popover", inputs: ["anchor", "horizontalAlign", "xAlign", "verticalAlign", "yAlign", "forceAlignment", "lockAlignment", "autoFocus", "restoreFocus", "scrollStrategy", "hasBackdrop", "interactiveClose", "openTransition", "closeTransition", "openAnimationStartAtScale", "closeAnimationEndAtScale", "backdropClass", "panelClass"], outputs: ["opened", "closed", "afterOpen", "afterClose", "backdropClicked", "overlayKeydown"] }, { kind: "directive", type: i1$3.SatPopoverAnchorDirective, selector: "[satPopoverAnchor]", inputs: ["satPopoverAnchor"], exportAs: ["satPopoverAnchor"] }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: ValidationErrorsComponent, selector: "app-validation-errors", inputs: ["errors", "customErrorMessages"] }] });
|
|
3251
3553
|
}
|
|
3252
3554
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: InputEmailComponent, decorators: [{
|
|
3253
3555
|
type: Component,
|
|
@@ -3257,14 +3559,17 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
|
|
|
3257
3559
|
InfoItemComponent,
|
|
3258
3560
|
SatPopoverModule,
|
|
3259
3561
|
NgClass,
|
|
3260
|
-
|
|
3562
|
+
MatFormField,
|
|
3563
|
+
MatInput,
|
|
3564
|
+
ReactiveFormsModule,
|
|
3565
|
+
ValidationErrorsComponent
|
|
3261
3566
|
], providers: [
|
|
3262
3567
|
{
|
|
3263
3568
|
provide: NG_VALUE_ACCESSOR,
|
|
3264
3569
|
useExisting: forwardRef(() => InputEmailComponent),
|
|
3265
3570
|
multi: true,
|
|
3266
3571
|
},
|
|
3267
|
-
], template: "
|
|
3572
|
+
], template: "@if(!isReadOnly){\r\n @if(label){\r\n <div class=\"d-flex justify-content-between mb-1\">\r\n <span class=\"form-label mb-0\">{{ label }}</span\r\n > @if(!required){<span class=\"fs-11 fc-dark-gray\">{{\r\n i18n.translate(\"Optional\")\r\n }}</span\r\n >} @if(hasTooltip){\r\n <span class=\"form-label mb-0\">\r\n {{ tooltip }}\r\n <ds-icon\r\n icon=\"info fs-22\"\r\n class=\"cursor-pointer\"\r\n [satPopoverAnchor]=\"popover\"\r\n (click)=\"popover.toggle(); $event.stopImmediatePropagation()\"\r\n ></ds-icon>\r\n </span>\r\n }\r\n </div>\r\n }\r\n <mat-form-field\r\n class=\"primary-form {{ className }}\"\r\n [ngClass]=\"{ 'input-disabled': control.disabled }\"\r\n [floatLabel]=\"floatLabel\"\r\n >\r\n @if(iconPrefixName){<span class=\"sfi {{ iconPrefixName }}\"></span>}\r\n @if(loading){<span\r\n class=\"sfi sfi-spinner d-inline-block spin fc-coral\"\r\n matSuffix\r\n ></span\r\n >}\r\n <label class=\"mat-form-content\">\r\n <!-- add input for ar && en custom directive with add type = arOnly || type = enOnly-->\r\n <input\r\n matInput\r\n [value]=\"value\"\r\n oninput=\"validity.valid || (value='');\"\r\n [formControl]=\"control\"\r\n [type]=\"type\"\r\n [placeholder]=\"placeholder\"\r\n (change)=\"displayErrors($event)\"\r\n />\r\n </label>\r\n @if(iconSuffixName){<span matSuffix class=\"sfi {{ iconSuffixName }}\"></span>}\r\n @if(hint){\r\n <mat-hint class=\"d-flex align-items-center gap-1 mt-1\">\r\n <span\r\n class=\"sfi sfi-info fs-17 fc-dark-gray\"\r\n [ngClass]=\"{ 'fc-oasis-light-imp': value }\"\r\n ></span>\r\n <span class=\"fs-12 fc-black line-height-1\">{{ hint }}</span>\r\n </mat-hint>\r\n }\r\n </mat-form-field>\r\n <app-validation-errors [errors]=\"control.errors\"></app-validation-errors>\r\n } @if(isReadOnly && (showIfEmpty || control)){\r\n <ng-container class=\"info-section\">\r\n <app-info-item\r\n class=\"info-item w-100\"\r\n [label]=\"label\"\r\n [insideTable]=\"insideTable\"\r\n [hasLabel]=\"!!label\"\r\n [type]=\"type\"\r\n [value]=\"control.value\"\r\n ></app-info-item>\r\n </ng-container>\r\n }\r\n <sat-popover #popover [hasBackdrop]=\"true\" verticalAlign=\"below\">\r\n <div class=\"default-popover p-3 fs-14\">\r\n <span class=\"fs-14 fw-bold signature-notes\" [innerHTML]=\"tooltip\"></span>\r\n </div>\r\n </sat-popover>\r\n ", styles: [":host{flex-grow:1}.input-disabled{pointer-events:none;opacity:1.5}\n"] }]
|
|
3268
3573
|
}], propDecorators: { tooltip: [{
|
|
3269
3574
|
type: Input
|
|
3270
3575
|
}], floatLabel: [{
|
|
@@ -3300,7 +3605,7 @@ class InputMaskComponent extends ControlValueAccessorDirective {
|
|
|
3300
3605
|
useExisting: forwardRef(() => InputMaskComponent),
|
|
3301
3606
|
multi: true,
|
|
3302
3607
|
},
|
|
3303
|
-
], usesInheritance: true, ngImport: i0, template: "\r\n@if(!isReadOnly){\r\n <ng-container>\r\n <!-- <app-form-label [label]=\"label\" [optional]=\"!required\" [hideOption]=\"hideOption\" [showLabel]=\"showLabel\"></app-form-label> -->\r\n @if(label){\r\n <div class=\"d-flex justify-content-between mb-1\">\r\n <span class=\"form-label mb-0\">{{label}}</span>\r\n @if(!required){\r\n <span class=\"fs-11 fc-dark-gray\">{{i18n.translate('Optional')}}\r\n </span>\r\n }\r\n </div>\r\n }\r\n \r\n <mat-form-field class=\"primary-form {{className}}\" [ngClass]=\"{'input-disabled' : isDisabled }\"\r\n [floatLabel]=\"floatLabel\">\r\n \r\n <span
|
|
3608
|
+
], usesInheritance: true, ngImport: i0, template: "\r\n@if(!isReadOnly){\r\n <ng-container>\r\n <!-- <app-form-label [label]=\"label\" [optional]=\"!required\" [hideOption]=\"hideOption\" [showLabel]=\"showLabel\"></app-form-label> -->\r\n @if(label){\r\n <div class=\"d-flex justify-content-between mb-1\">\r\n <span class=\"form-label mb-0\">{{label}}</span>\r\n @if(!required){\r\n <span class=\"fs-11 fc-dark-gray\">{{i18n.translate('Optional')}}\r\n </span>\r\n }\r\n </div>\r\n }\r\n \r\n <mat-form-field class=\"primary-form {{className}}\" [ngClass]=\"{'input-disabled' : isDisabled }\"\r\n [floatLabel]=\"floatLabel\">\r\n \r\n @if(iconPrefixName){\r\n <span matPrefix class=\"sfi {{iconPrefixName}}\"></span>\r\n }\r\n <label class=\"mat-form-content\">\r\n <input matInput [placeholder]=\"placeholder\" [value]=\"value\" [attr.disabled]=\"isDisabled\" [mask]=\"mask\"\r\n [showMaskTyped]=\"false\" oninput=\"validity.valid || (value='');\" [formControl]=\"control\"\r\n [required]=\"required\" [placeholder]=\"placeholder\">\r\n </label>\r\n \r\n @if(matSuffix){\r\n <span matSuffix class=\"sfi {{iconSuffixName}}\"></span>\r\n }\r\n @if(type === 'number'){\r\n <div matSuffix class=\"d-flex align-items-center gap-2\">\r\n @if(numberSuffixName){\r\n <span class=\"fs-14 fw-medium\">{{numberSuffixName}}</span>\r\n }\r\n <!-- <span class=\"sfi sfi-minus p-2 bc-light-gray fc-black\"></span>\r\n <span class=\"sfi sfi-plus p-2 bc-light-gray fc-black\"></span> -->\r\n </div>\r\n }\r\n <!-- @if((!control?.valid)){\r\n <mat-error class=\"mb-2\">\r\n {{i18n.translate('validFieldError')}}{{label}}\r\n </mat-error>\r\n } -->\r\n \r\n \r\n <!-- <mat-error *ngIf=\"(type ==='email' && !control?.valid)\">\r\n {{i18n.translate('validEmailError')}}\r\n </mat-error> -->\r\n @if(showHint){\r\n <mat-hint>\r\n <span class=\"sfi sfi-check-circle font-10 fc-dark-gray\" [ngClass]=\"{'fc-oasis-light-imp':value}\"></span>\r\n <span class=\"mx-1\"></span>\r\n <span class=\"fs-12 fc-onyx\">{{hint}}</span>\r\n </mat-hint>\r\n }\r\n </mat-form-field>\r\n <!-- <span class=\"fc-coral\" style=\"color:#f44336\" *ngIf=\"( showErrorMessage && control.value)\">\r\n {{errorMessage}}\r\n </span> -->\r\n \r\n </ng-container>\r\n}\r\n\r\n@if(isReadOnly && control){\r\n <ng-container class=\"info-section\">\r\n <app-info-item class=\"info-item w-100\" [label]=\"label\" [insideTable]=\"insideTable\" [hasLabel]=\"label ? true: false\"\r\n [value]=\"control\"></app-info-item>\r\n </ng-container>\r\n \r\n}\r\n\r\n\r\n<!-- section tooltip -->\r\n<sat-popover #popover [hasBackdrop]=\"true\" verticalAlign=\"below\">\r\n <div class=\"deafult-tooltip\">\r\n {{tooltip}}\r\n </div>\r\n</sat-popover>\r\n", styles: [":host{flex-grow:1}\n"], dependencies: [{ kind: "ngmodule", type: SatPopoverModule }, { kind: "component", type: i1$3.SatPopoverComponent, selector: "sat-popover", inputs: ["anchor", "horizontalAlign", "xAlign", "verticalAlign", "yAlign", "forceAlignment", "lockAlignment", "autoFocus", "restoreFocus", "scrollStrategy", "hasBackdrop", "interactiveClose", "openTransition", "closeTransition", "openAnimationStartAtScale", "closeAnimationEndAtScale", "backdropClass", "panelClass"], outputs: ["opened", "closed", "afterOpen", "afterClose", "backdropClicked", "overlayKeydown"] }, { kind: "component", type: MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: NgxMaskDirective, selector: "input[mask], textarea[mask]", inputs: ["mask", "specialCharacters", "patterns", "prefix", "suffix", "thousandSeparator", "decimalMarker", "dropSpecialCharacters", "hiddenInput", "showMaskTyped", "placeHolderCharacter", "shownMaskExpression", "showTemplate", "clearIfNotMatch", "validation", "separatorLimit", "allowNegativeNumbers", "leadZeroDateTime", "leadZero", "triggerOnMaskChange", "apm", "inputTransformFn", "outputTransformFn", "keepCharacterPositions"], outputs: ["maskFilled"], exportAs: ["mask", "ngxMask"] }, { kind: "component", type: InfoItemComponent, selector: "app-info-item", inputs: ["label", "value", "name", "type", "dateType", "multiple", "insideTable", "hasLabel", "arrayList", "actionType", "download"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { kind: "directive", type: i2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }] });
|
|
3304
3609
|
}
|
|
3305
3610
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: InputMaskComponent, decorators: [{
|
|
3306
3611
|
type: Component,
|
|
@@ -3310,7 +3615,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
|
|
|
3310
3615
|
useExisting: forwardRef(() => InputMaskComponent),
|
|
3311
3616
|
multi: true,
|
|
3312
3617
|
},
|
|
3313
|
-
], imports: [SatPopoverModule, MatFormField, NgxMaskDirective, NgIf, InfoItemComponent, ReactiveFormsModule, NgClass], template: "\r\n@if(!isReadOnly){\r\n <ng-container>\r\n <!-- <app-form-label [label]=\"label\" [optional]=\"!required\" [hideOption]=\"hideOption\" [showLabel]=\"showLabel\"></app-form-label> -->\r\n @if(label){\r\n <div class=\"d-flex justify-content-between mb-1\">\r\n <span class=\"form-label mb-0\">{{label}}</span>\r\n @if(!required){\r\n <span class=\"fs-11 fc-dark-gray\">{{i18n.translate('Optional')}}\r\n </span>\r\n }\r\n </div>\r\n }\r\n \r\n <mat-form-field class=\"primary-form {{className}}\" [ngClass]=\"{'input-disabled' : isDisabled }\"\r\n [floatLabel]=\"floatLabel\">\r\n \r\n <span
|
|
3618
|
+
], imports: [SatPopoverModule, MatFormField, NgxMaskDirective, NgIf, InfoItemComponent, ReactiveFormsModule, NgClass], template: "\r\n@if(!isReadOnly){\r\n <ng-container>\r\n <!-- <app-form-label [label]=\"label\" [optional]=\"!required\" [hideOption]=\"hideOption\" [showLabel]=\"showLabel\"></app-form-label> -->\r\n @if(label){\r\n <div class=\"d-flex justify-content-between mb-1\">\r\n <span class=\"form-label mb-0\">{{label}}</span>\r\n @if(!required){\r\n <span class=\"fs-11 fc-dark-gray\">{{i18n.translate('Optional')}}\r\n </span>\r\n }\r\n </div>\r\n }\r\n \r\n <mat-form-field class=\"primary-form {{className}}\" [ngClass]=\"{'input-disabled' : isDisabled }\"\r\n [floatLabel]=\"floatLabel\">\r\n \r\n @if(iconPrefixName){\r\n <span matPrefix class=\"sfi {{iconPrefixName}}\"></span>\r\n }\r\n <label class=\"mat-form-content\">\r\n <input matInput [placeholder]=\"placeholder\" [value]=\"value\" [attr.disabled]=\"isDisabled\" [mask]=\"mask\"\r\n [showMaskTyped]=\"false\" oninput=\"validity.valid || (value='');\" [formControl]=\"control\"\r\n [required]=\"required\" [placeholder]=\"placeholder\">\r\n </label>\r\n \r\n @if(matSuffix){\r\n <span matSuffix class=\"sfi {{iconSuffixName}}\"></span>\r\n }\r\n @if(type === 'number'){\r\n <div matSuffix class=\"d-flex align-items-center gap-2\">\r\n @if(numberSuffixName){\r\n <span class=\"fs-14 fw-medium\">{{numberSuffixName}}</span>\r\n }\r\n <!-- <span class=\"sfi sfi-minus p-2 bc-light-gray fc-black\"></span>\r\n <span class=\"sfi sfi-plus p-2 bc-light-gray fc-black\"></span> -->\r\n </div>\r\n }\r\n <!-- @if((!control?.valid)){\r\n <mat-error class=\"mb-2\">\r\n {{i18n.translate('validFieldError')}}{{label}}\r\n </mat-error>\r\n } -->\r\n \r\n \r\n <!-- <mat-error *ngIf=\"(type ==='email' && !control?.valid)\">\r\n {{i18n.translate('validEmailError')}}\r\n </mat-error> -->\r\n @if(showHint){\r\n <mat-hint>\r\n <span class=\"sfi sfi-check-circle font-10 fc-dark-gray\" [ngClass]=\"{'fc-oasis-light-imp':value}\"></span>\r\n <span class=\"mx-1\"></span>\r\n <span class=\"fs-12 fc-onyx\">{{hint}}</span>\r\n </mat-hint>\r\n }\r\n </mat-form-field>\r\n <!-- <span class=\"fc-coral\" style=\"color:#f44336\" *ngIf=\"( showErrorMessage && control.value)\">\r\n {{errorMessage}}\r\n </span> -->\r\n \r\n </ng-container>\r\n}\r\n\r\n@if(isReadOnly && control){\r\n <ng-container class=\"info-section\">\r\n <app-info-item class=\"info-item w-100\" [label]=\"label\" [insideTable]=\"insideTable\" [hasLabel]=\"label ? true: false\"\r\n [value]=\"control\"></app-info-item>\r\n </ng-container>\r\n \r\n}\r\n\r\n\r\n<!-- section tooltip -->\r\n<sat-popover #popover [hasBackdrop]=\"true\" verticalAlign=\"below\">\r\n <div class=\"deafult-tooltip\">\r\n {{tooltip}}\r\n </div>\r\n</sat-popover>\r\n", styles: [":host{flex-grow:1}\n"] }]
|
|
3314
3619
|
}], propDecorators: { tooltip: [{
|
|
3315
3620
|
type: Input
|
|
3316
3621
|
}], floatLabel: [{
|
|
@@ -3327,6 +3632,78 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
|
|
|
3327
3632
|
type: Input
|
|
3328
3633
|
}] } });
|
|
3329
3634
|
|
|
3635
|
+
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
3636
|
+
/* eslint-disable @angular-eslint/directive-selector */
|
|
3637
|
+
class MycurrencyDirective {
|
|
3638
|
+
elementRef;
|
|
3639
|
+
formatcurrencypipe;
|
|
3640
|
+
el;
|
|
3641
|
+
decimals;
|
|
3642
|
+
constructor(elementRef, formatcurrencypipe) {
|
|
3643
|
+
this.elementRef = elementRef;
|
|
3644
|
+
this.formatcurrencypipe = formatcurrencypipe;
|
|
3645
|
+
this.el = this.elementRef.nativeElement;
|
|
3646
|
+
}
|
|
3647
|
+
ngOnInit() {
|
|
3648
|
+
this.el.value = this.formatcurrencypipe.transform(this.el.value);
|
|
3649
|
+
}
|
|
3650
|
+
onFocus(value, event) {
|
|
3651
|
+
this.el.value = this.formatcurrencypipe.parse(value); // opossite of transform
|
|
3652
|
+
if (event.which == 9) {
|
|
3653
|
+
return false;
|
|
3654
|
+
}
|
|
3655
|
+
return this.el.select();
|
|
3656
|
+
}
|
|
3657
|
+
onBlur(value) {
|
|
3658
|
+
this.el.value = this.formatcurrencypipe.transform(value);
|
|
3659
|
+
}
|
|
3660
|
+
onKeyDown(event) {
|
|
3661
|
+
const e = event;
|
|
3662
|
+
if (e.key == 'و' || e.key == 'ز') {
|
|
3663
|
+
e.preventDefault();
|
|
3664
|
+
}
|
|
3665
|
+
if ([46, 8, 9, 27, 13, 110, 190].indexOf(e.keyCode) !== -1 ||
|
|
3666
|
+
// Allow: Ctrl+A
|
|
3667
|
+
(e.keyCode === 65 && (e.ctrlKey || e.metaKey)) ||
|
|
3668
|
+
// Allow: Ctrl+C
|
|
3669
|
+
(e.keyCode === 67 && (e.ctrlKey || e.metaKey)) ||
|
|
3670
|
+
// Allow: Ctrl+V
|
|
3671
|
+
(e.keyCode === 86 && (e.ctrlKey || e.metaKey)) ||
|
|
3672
|
+
// Allow: Ctrl+X
|
|
3673
|
+
(e.keyCode === 88 && (e.ctrlKey || e.metaKey)) ||
|
|
3674
|
+
(e.keyCode === 188) ||
|
|
3675
|
+
// Allow: home, end, left, right
|
|
3676
|
+
(e.keyCode >= 35 && e.keyCode <= 39)) {
|
|
3677
|
+
// let it happen, don't do anything
|
|
3678
|
+
return;
|
|
3679
|
+
}
|
|
3680
|
+
// Ensure that it is a number and stop the keypress
|
|
3681
|
+
if ((e.shiftKey || (e.keyCode < 48 || e.keyCode > 57)) && (e.keyCode < 96 || e.keyCode > 105)) {
|
|
3682
|
+
e.preventDefault();
|
|
3683
|
+
}
|
|
3684
|
+
}
|
|
3685
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: MycurrencyDirective, deps: [{ token: i0.ElementRef }, { token: MycurrencyPipe }], target: i0.ɵɵFactoryTarget.Directive });
|
|
3686
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.2.8", type: MycurrencyDirective, isStandalone: true, selector: "[appMycurrency]", inputs: { decimals: "decimals" }, host: { listeners: { "focus": "onFocus($event.target.value,$event)", "blur": "onBlur($event.target.value)", "keydown": "onKeyDown($event)" } }, ngImport: i0 });
|
|
3687
|
+
}
|
|
3688
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: MycurrencyDirective, decorators: [{
|
|
3689
|
+
type: Directive,
|
|
3690
|
+
args: [{
|
|
3691
|
+
selector: '[appMycurrency]',
|
|
3692
|
+
standalone: true
|
|
3693
|
+
}]
|
|
3694
|
+
}], ctorParameters: () => [{ type: i0.ElementRef }, { type: MycurrencyPipe }], propDecorators: { decimals: [{
|
|
3695
|
+
type: Input
|
|
3696
|
+
}], onFocus: [{
|
|
3697
|
+
type: HostListener,
|
|
3698
|
+
args: ["focus", ["$event.target.value", "$event"]]
|
|
3699
|
+
}], onBlur: [{
|
|
3700
|
+
type: HostListener,
|
|
3701
|
+
args: ["blur", ["$event.target.value"]]
|
|
3702
|
+
}], onKeyDown: [{
|
|
3703
|
+
type: HostListener,
|
|
3704
|
+
args: ['keydown', ['$event']]
|
|
3705
|
+
}] } });
|
|
3706
|
+
|
|
3330
3707
|
/* eslint-disable @typescript-eslint/no-unused-vars */
|
|
3331
3708
|
/* eslint-disable @angular-eslint/use-lifecycle-interface */
|
|
3332
3709
|
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
@@ -3346,7 +3723,8 @@ class InputCurrencyComponent extends ControlValueAccessorDirective {
|
|
|
3346
3723
|
useExisting: forwardRef(() => InputCurrencyComponent),
|
|
3347
3724
|
multi: true,
|
|
3348
3725
|
},
|
|
3349
|
-
|
|
3726
|
+
MycurrencyPipe
|
|
3727
|
+
], usesInheritance: true, ngImport: i0, template: "@if(!isReadOnly){\r\n @if(label){\r\n <div class=\"d-flex justify-content-between mb-1\">\r\n <span class=\"form-label mb-0\">{{ label }}</span\r\n > @if(!required){<span class=\"fs-11 fc-dark-gray\">{{\r\n i18n.translate(\"Optional\")\r\n }}</span\r\n >} @if(hasTooltip){\r\n <span class=\"form-label mb-0\">\r\n {{ tooltip }}\r\n <ds-icon\r\n icon=\"info fs-22\"\r\n class=\"cursor-pointer\"\r\n [satPopoverAnchor]=\"popover\"\r\n (click)=\"popover.toggle(); $event.stopImmediatePropagation()\"\r\n ></ds-icon>\r\n </span>\r\n }\r\n </div>\r\n }\r\n <mat-form-field\r\n class=\"primary-form {{ className }}\"\r\n [ngClass]=\"{ 'input-disabled': control.disabled }\"\r\n [floatLabel]=\"floatLabel\"\r\n >\r\n @if(iconPrefixName){<span class=\"sfi {{ iconPrefixName }}\"></span>}\r\n @if(loading){<span\r\n class=\"sfi sfi-spinner d-inline-block spin fc-coral\"\r\n matSuffix\r\n ></span\r\n >}\r\n <label class=\"mat-form-content\">\r\n <!-- add input for ar && en custom directive with add type = arOnly || type = enOnly-->\r\n <input\r\n matInput\r\n [value]=\"value\"\r\n oninput=\"validity.valid || (value='');\"\r\n [formControl]=\"control\"\r\n [type]=\"type\"\r\n [placeholder]=\"placeholder\"\r\n appMycurrency\r\n />\r\n </label>\r\n @if(iconSuffixName){<span matSuffix class=\"sfi {{ iconSuffixName }}\"></span>}\r\n @if(hint){\r\n <mat-hint class=\"d-flex align-items-center gap-1 mt-1\">\r\n <span\r\n class=\"sfi sfi-info fs-17 fc-dark-gray\"\r\n [ngClass]=\"{ 'fc-oasis-light-imp': value }\"\r\n ></span>\r\n <span class=\"fs-12 fc-black line-height-1\">{{ hint }}</span>\r\n </mat-hint>\r\n }\r\n </mat-form-field>\r\n <app-validation-errors [errors]=\"control.errors\"></app-validation-errors>\r\n } @if(isReadOnly && (showIfEmpty || control)){\r\n <ng-container class=\"info-section\">\r\n <app-info-item\r\n class=\"info-item w-100\"\r\n [label]=\"label\"\r\n [insideTable]=\"insideTable\"\r\n [hasLabel]=\"!!label\"\r\n [type]=\"type\"\r\n [value]=\"control.value\"\r\n ></app-info-item>\r\n </ng-container>\r\n }\r\n <sat-popover #popover [hasBackdrop]=\"true\" verticalAlign=\"below\">\r\n <div class=\"default-popover p-3 fs-14\">\r\n <span class=\"fs-14 fw-bold signature-notes\" [innerHTML]=\"tooltip\"></span>\r\n </div>\r\n </sat-popover>\r\n ", styles: [":host{flex-grow:1}.input-disabled{pointer-events:none!important;opacity:1.5}\n"], dependencies: [{ kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: MatHint, selector: "mat-hint", inputs: ["align", "id"] }, { kind: "component", type: InfoItemComponent, selector: "app-info-item", inputs: ["label", "value", "name", "type", "dateType", "multiple", "insideTable", "hasLabel", "arrayList", "actionType", "download"] }, { kind: "ngmodule", type: SatPopoverModule }, { kind: "component", type: i1$3.SatPopoverComponent, selector: "sat-popover", inputs: ["anchor", "horizontalAlign", "xAlign", "verticalAlign", "yAlign", "forceAlignment", "lockAlignment", "autoFocus", "restoreFocus", "scrollStrategy", "hasBackdrop", "interactiveClose", "openTransition", "closeTransition", "openAnimationStartAtScale", "closeAnimationEndAtScale", "backdropClass", "panelClass"], outputs: ["opened", "closed", "afterOpen", "afterClose", "backdropClicked", "overlayKeydown"] }, { kind: "directive", type: i1$3.SatPopoverAnchorDirective, selector: "[satPopoverAnchor]", inputs: ["satPopoverAnchor"], exportAs: ["satPopoverAnchor"] }, { kind: "component", type: MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { kind: "directive", type: MycurrencyDirective, selector: "[appMycurrency]", inputs: ["decimals"] }, { kind: "component", type: ValidationErrorsComponent, selector: "app-validation-errors", inputs: ["errors", "customErrorMessages"] }] });
|
|
3350
3728
|
}
|
|
3351
3729
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: InputCurrencyComponent, decorators: [{
|
|
3352
3730
|
type: Component,
|
|
@@ -3359,14 +3737,17 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
|
|
|
3359
3737
|
SatPopoverModule,
|
|
3360
3738
|
MatFormField,
|
|
3361
3739
|
MatInput,
|
|
3362
|
-
NgIf
|
|
3740
|
+
NgIf,
|
|
3741
|
+
MycurrencyDirective,
|
|
3742
|
+
ValidationErrorsComponent
|
|
3363
3743
|
], providers: [
|
|
3364
3744
|
{
|
|
3365
3745
|
provide: NG_VALUE_ACCESSOR,
|
|
3366
3746
|
useExisting: forwardRef(() => InputCurrencyComponent),
|
|
3367
3747
|
multi: true,
|
|
3368
3748
|
},
|
|
3369
|
-
|
|
3749
|
+
MycurrencyPipe
|
|
3750
|
+
], template: "@if(!isReadOnly){\r\n @if(label){\r\n <div class=\"d-flex justify-content-between mb-1\">\r\n <span class=\"form-label mb-0\">{{ label }}</span\r\n > @if(!required){<span class=\"fs-11 fc-dark-gray\">{{\r\n i18n.translate(\"Optional\")\r\n }}</span\r\n >} @if(hasTooltip){\r\n <span class=\"form-label mb-0\">\r\n {{ tooltip }}\r\n <ds-icon\r\n icon=\"info fs-22\"\r\n class=\"cursor-pointer\"\r\n [satPopoverAnchor]=\"popover\"\r\n (click)=\"popover.toggle(); $event.stopImmediatePropagation()\"\r\n ></ds-icon>\r\n </span>\r\n }\r\n </div>\r\n }\r\n <mat-form-field\r\n class=\"primary-form {{ className }}\"\r\n [ngClass]=\"{ 'input-disabled': control.disabled }\"\r\n [floatLabel]=\"floatLabel\"\r\n >\r\n @if(iconPrefixName){<span class=\"sfi {{ iconPrefixName }}\"></span>}\r\n @if(loading){<span\r\n class=\"sfi sfi-spinner d-inline-block spin fc-coral\"\r\n matSuffix\r\n ></span\r\n >}\r\n <label class=\"mat-form-content\">\r\n <!-- add input for ar && en custom directive with add type = arOnly || type = enOnly-->\r\n <input\r\n matInput\r\n [value]=\"value\"\r\n oninput=\"validity.valid || (value='');\"\r\n [formControl]=\"control\"\r\n [type]=\"type\"\r\n [placeholder]=\"placeholder\"\r\n appMycurrency\r\n />\r\n </label>\r\n @if(iconSuffixName){<span matSuffix class=\"sfi {{ iconSuffixName }}\"></span>}\r\n @if(hint){\r\n <mat-hint class=\"d-flex align-items-center gap-1 mt-1\">\r\n <span\r\n class=\"sfi sfi-info fs-17 fc-dark-gray\"\r\n [ngClass]=\"{ 'fc-oasis-light-imp': value }\"\r\n ></span>\r\n <span class=\"fs-12 fc-black line-height-1\">{{ hint }}</span>\r\n </mat-hint>\r\n }\r\n </mat-form-field>\r\n <app-validation-errors [errors]=\"control.errors\"></app-validation-errors>\r\n } @if(isReadOnly && (showIfEmpty || control)){\r\n <ng-container class=\"info-section\">\r\n <app-info-item\r\n class=\"info-item w-100\"\r\n [label]=\"label\"\r\n [insideTable]=\"insideTable\"\r\n [hasLabel]=\"!!label\"\r\n [type]=\"type\"\r\n [value]=\"control.value\"\r\n ></app-info-item>\r\n </ng-container>\r\n }\r\n <sat-popover #popover [hasBackdrop]=\"true\" verticalAlign=\"below\">\r\n <div class=\"default-popover p-3 fs-14\">\r\n <span class=\"fs-14 fw-bold signature-notes\" [innerHTML]=\"tooltip\"></span>\r\n </div>\r\n </sat-popover>\r\n ", styles: [":host{flex-grow:1}.input-disabled{pointer-events:none!important;opacity:1.5}\n"] }]
|
|
3370
3751
|
}], propDecorators: { tooltip: [{
|
|
3371
3752
|
type: Input
|
|
3372
3753
|
}], floatLabel: [{
|
|
@@ -4161,7 +4542,7 @@ class TableListComponent extends BaseComponent {
|
|
|
4161
4542
|
sentBack() {
|
|
4162
4543
|
}
|
|
4163
4544
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: TableListComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
4164
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.8", type: TableListComponent, isStandalone: true, selector: "app-table-list", inputs: { columns: "columns", columnsConfig: "columnsConfig", rows: "rows", actions: "actions", totalRecords: "totalRecords", className: "className" }, outputs: { pageChanged: "pageChanged", buttonAction: "buttonAction", emitDataRow: "emitDataRow" }, usesInheritance: true, ngImport: i0, template: "<div class=\"overflow-auto\">\r\n <!-- #table (scroll)=\"onPageChange($event)\" -->\r\n <ng-container >\r\n <!-- (matSortChange)=\"sortData($event)\" -->\r\n <table mat-table [dataSource]=\"dataSource\" class=\"primary-table {{className}}\" matSort >\r\n <ng-container *ngFor=\"let column of columns; let i = index;\">\r\n <ng-container [matColumnDef]=\"column\">\r\n <th mat-header-cell *matHeaderCellDef [ngClass]=\"{'last-column' : columnsConfig[i].type === 'actions', 'sortArrow': columnsConfig[i]?.sortName?.length }\" mat-sort-header>\r\n {{i18n.translate(columnsConfig[i].label)}} </th>\r\n \r\n <td mat-cell [ngClass]=\"{'account-disabled': element?.user?.disabledCleanUp===true}\" *matCellDef=\"let element\">\r\n <ng-container [ngSwitch]=\"columnsConfig[i].type\" *ngIf=\"rows.length\">\r\n <a [ngClass]=\"columnsConfig[i].type\" [href]=\"element[column]\" *ngSwitchCase=\"'link'\">\r\n {{ element[column] }}\r\n </a>\r\n \r\n <a [ngClass]=\"columnsConfig[i].type\" [routerLink]=\"[element.id]\" [href]=\"element[column]\"\r\n *ngSwitchCase=\"'rout'\">\r\n {{ element[column] }}\r\n </a>\r\n \r\n <span class=\"d-inline-flex align-items-center\" [ngClass]=\"columnsConfig[i].type\" *ngSwitchCase=\"'date'\">\r\n <span class=\"sfi sfi-clock text-color-coral\" *ngIf=\"!loading\"></span>\r\n <span class=\"mx-2\">\r\n <!-- {{ element?.Date.from }}\r\n <ng-container *ngIf=\"element?.Date.to\">\r\n : {{ element?.Date.to }}\r\n </ng-container> -->\r\n {{ element[column] | date: 'dd/MM/YYYY' }}\r\n </span>\r\n </span>\r\n \r\n <div class=\"d-inline-flex align-items-center\" [ngClass]=\"columnsConfig[i].type\" *ngSwitchCase=\"'sla'\">\r\n <app-sla [value]=\"element?.SLA.value\" [maxValue]=\"element?.SLA.max\" [canvasScale]=\"45\"\r\n [outerLineColor]=\"getSlaColor(element?.SLA.value, element?.SLA.max)\"></app-sla>\r\n </div>\r\n \r\n <div class=\"img-card table-img\" [ngClass]=\"columnsConfig[i].type\" *ngSwitchCase=\"'image'\">\r\n <img [src]=\"element?.image\" alt=\"\">\r\n </div>\r\n \r\n <span class=\"{{ element[column].type }}\" [ngClass]=\"columnsConfig[i].type\" *ngSwitchCase=\"'status'\">\r\n {{ element[column].label }}\r\n </span>\r\n \r\n \r\n <div class=\"d-flex mx-n1\" *ngSwitchCase=\"'RequestType'\">\r\n <div class=\"request-type mx-1 {{item.status}}\" *ngFor=\"let item of element?.RequestType\">\r\n {{ item.label }}\r\n <span class=\"mx-1\" *ngIf=\"item.status === 'need-action'\"></span>\r\n <span class=\"sfi sfi-info \" *ngIf=\"item.status === 'need-action'\"></span>\r\n </div>\r\n </div>\r\n \r\n \r\n <span class=\"{{ element[column].type }} {{ element[column] ? 'text-color-coral underline' : '' }}\"\r\n [ngClass]=\"columnsConfig[i].type\" *ngSwitchCase=\"'number'\">\r\n {{ element[column] ? element[column] : '-' }}\r\n </span>\r\n \r\n <div class=\"text-nowrap d-flex align-items-center\" [ngClass]=\"columnsConfig[i].type\"\r\n *ngSwitchCase=\"'group'\">\r\n <span>{{element?.Group.groupName}}</span>\r\n <span class=\"mx-2\"></span>\r\n <app-repeated-list type=\"users-avatar\" [listOfItems]=\"element?.Group.users\"></app-repeated-list>\r\n </div>\r\n \r\n <div class=\"d-flex align-items-center gap-2\" [ngClass]=\"columnsConfig[i].type\" *ngSwitchCase=\"'user'\">\r\n <span class=\"img-card circled-img small\" *ngIf=\"!loading\">\r\n <img src=\"{{'data:image/png;base64,' + element?.user?.personalPhoto}}\"\r\n onerror=\"this.onerror=null;this.src='assets/images/user.svg';\" alt=\"\">\r\n </span>\r\n <div class=\"d-flex flex-column\">\r\n <span class=\"font-14 font-weight-medium\">{{element?.user?.name}}</span>\r\n <span class=\"font-12 font-weight-normal text-color-dark-gray mt-1\">{{element?.user?.email}}</span>\r\n </div>\r\n </div>\r\n \r\n \r\n <div class=\"delegate d-flex align-items-center\" [ngClass]=\"columnsConfig[i].type\"\r\n *ngSwitchCase=\"'assigned'\">\r\n <div class=\"img-card x-small circled-img\">\r\n <img [src]=\"element?.AssignedTo.image\" alt=\"\">\r\n </div>\r\n <span class=\"mx-1\"></span>\r\n <span class=\"font-14 font-weight-medium text-color-onyx\">{{element?.AssignedTo.name}}</span>\r\n <span class=\"sfi sfi-close text-color-coral\"></span>\r\n </div>\r\n \r\n \r\n <ng-container *ngSwitchCase=\"'statusAction'\">\r\n <div class=\"table-action\">\r\n \r\n <div class=\"count-down mx-n1\" *ngIf=\"element[column] === 'need-action'\">\r\n <div class=\"item mx-1\">\r\n <span class=\"font-12 font-weight-medium text-color-onyx d-block\">01</span>\r\n <span class=\"font-8 font-weight-light text-color-onyx d-block\">Days</span>\r\n </div>\r\n <div class=\"item mx-1\">\r\n <span class=\"font-12 font-weight-medium text-color-onyx d-block\">18</span>\r\n <span class=\"font-8 font-weight-light text-color-onyx d-block\">Hours</span>\r\n </div>\r\n <div class=\"item mx-1\">\r\n <span class=\"font-12 font-weight-medium text-color-onyx d-block\">44</span>\r\n <span class=\"font-8 font-weight-light text-color-onyx d-block\">Mins</span>\r\n </div>\r\n </div>\r\n \r\n <div class=\"d-flex align-items-center\" *ngIf=\"element[column] === 'approved'\">\r\n <span class=\"status approved\">\r\n Approved\r\n </span>\r\n </div>\r\n \r\n <div class=\"d-flex align-items-center\" *ngIf=\"element[column] === 'sent-back'\">\r\n <span class=\"status rejected\">\r\n Sent Back\r\n </span>\r\n <span class=\"mx-2\"></span>\r\n <button mat-stroked-button class=\"btn button-primary square br-w-1 font-14 font-weight-medium\"\r\n (click)=\"sentBack()\">\r\n <span class=\"sfi sfi-chat-o\"></span>\r\n </button>\r\n </div>\r\n \r\n <div class=\"d-flex align-items-center\" *ngIf=\"element[column] === 'pending'\">\r\n <span class=\"status pending\">\r\n Pending\r\n </span>\r\n <span class=\"mx-2\"></span>\r\n \r\n <div class=\"d-flex align-items-center mx-n1\">\r\n <div class=\"img-card circled-img x-small mx-1\">\r\n <img [src]=\"element?.pendingWith.image\" alt=\"\">\r\n </div>\r\n \r\n <div class=\"d-flex flex-column mx-1\">\r\n <span class=\"font-8 font-weight-medium text-color-yellow text-nowrap\">Pending With</span>\r\n <span class=\"font-11 font-weight-medium text-nowrap\">{{element?.pendingWith.name}}</span>\r\n </div>\r\n </div>\r\n </div>\r\n \r\n \r\n </div>\r\n </ng-container>\r\n \r\n \r\n <ng-container *ngSwitchCase=\"'actions'\">\r\n \r\n <div class=\"d-flex justify-content-between mx-n2\">\r\n <ng-container *ngFor=\"let action of element[column]\">\r\n \r\n <div class=\"flex-grow-1\">\r\n <ng-container *ngIf=\"action.type.buttonType === 'stroked'\">\r\n <button mat-stroked-button (click)=\"buttonClicked(element,action.fn, $event)\"\r\n class=\"btn button-{{action.type.buttonClass}} mx-2\">\r\n {{action.label}}\r\n </button>\r\n </ng-container>\r\n \r\n <ng-container *ngIf=\"action.type.buttonType === 'flat'\">\r\n <button mat-flat-button (click)=\"buttonClicked(element,action.fn, $event)\"\r\n class=\"btn button-{{action.type.buttonClass}} mx-2\">\r\n {{action.label}}\r\n </button>\r\n </ng-container>\r\n \r\n <ng-container *ngIf=\"action.type.buttonType === 'icon'\">\r\n <button mat-icon-button (click)=\"buttonClicked(element,action.fn, $event)\"\r\n class=\"btn button-{{action.type.buttonClass}} mx-2\">\r\n <span class=\"sfi sfi-{{action.type.icon}}\"></span>\r\n </button>\r\n </ng-container>\r\n </div>\r\n \r\n <ng-container *ngIf=\"action.type.buttonType === 'all'\">\r\n <button mat-icon-button class=\"btn button-transparent square medium mx-2 text-end\"\r\n [matMenuTriggerFor]=\"menuAction\" (click)=\"$event.stopPropagation()\">\r\n <span class=\"sfi sfi-dots text-color-onyx\"></span>\r\n </button>\r\n <mat-menu #menuAction=\"matMenu\" xPosition=\"before\" class=\"actions-menu\">\r\n <button *ngIf=\"!element?.user?.email && element?.user?.disabledCleanUp!==true\" mat-menu-item class=\"text-color-onyx font-12\"\r\n (click)=\"buttonClicked(element,'CreateEmail', $event)\">\r\n {{i18n.translate('createEmail')}} \r\n </button>\r\n <button *ngIf=\"element?.user?.email && element?.user?.enabled==='true'\" mat-menu-item class=\"text-color-red font-12\"\r\n (click)=\"buttonClicked(element,'DisableEmail', $event)\">\r\n {{ i18n.translate('disableEmail')}}\r\n </button>\r\n <button *ngIf=\"element?.user?.email && element?.user?.disabledCleanUp===true\" mat-menu-item class=\"text-color-red font-12\"\r\n (click)=\"buttonClicked(element,'EnableEmail', $event)\">\r\n {{ i18n.translate('enableEmail')}}\r\n </button>\r\n <button *ngIf=\"element?.user!==null && element?.user?.disabledCleanUp!==true\" mat-menu-item class=\"text-color-onyx font-12\"\r\n (click)=\"buttonClicked(element,'CreateEntryPermission', $event)\">\r\n {{ i18n.translate('createCEP')}}\r\n </button>\r\n <!-- <button *ngIf=\"!element?.user?.email\" mat-menu-item class=\"text-color-red font-12\"\r\n (click)=\"buttonClicked(element,'DisableEntryPermission', $event)\">\r\n {{i18n.translate('disableEntryPermission')}}\r\n </button> -->\r\n <button *ngIf=\"!element?.user?.email && element?.user?.disabledCleanUp!==true\" mat-menu-item class=\"text-color-red font-12\"\r\n (click)=\"buttonClicked(element,'DeleteAccount', $event)\">\r\n {{i18n.translate('deleteAccount')}}\r\n </button>\r\n\r\n <button *ngIf=\"element?.user?.email && element?.user?.disabledCleanUp!==true\" [disabled]=\"!element?.mailExtensionAllowed\" mat-menu-item class=\"text-color-onyx font-12\"\r\n (click)=\"buttonClicked(element,'ExtendAccount', $event)\">\r\n {{ i18n.translate('extendAccount')}}\r\n </button>\r\n <button mat-menu-item class=\"text-color-onyx font-12\" *ngIf=\"element?.user?.disabledCleanUp!==true\" (click)=\"buttonClicked(element,'update', $event)\">\r\n {{ i18n.translate('updateEmploymentInformation')}}\r\n </button>\r\n </mat-menu>\r\n </ng-container>\r\n </ng-container>\r\n </div>\r\n </ng-container>\r\n \r\n <span class=\"text-nowrap\" [ngClass]=\"columnsConfig[i].type\" *ngSwitchDefault>\r\n {{ element[column] }}\r\n </span>\r\n </ng-container>\r\n <ng-container *ngIf=\"loading\">\r\n <span class=\" d-block loading-bg\"></span>\r\n </ng-container>\r\n \r\n </td>\r\n \r\n \r\n </ng-container>\r\n </ng-container>\r\n \r\n <tr mat-header-row *matHeaderRowDef=\"columns\"></tr>\r\n <tr mat-row *matRowDef=\"let row; columns: columns;\" class=\"cursor-pointer\" (click)=\"selectedRow(row)\"></tr>\r\n </table>\r\n </ng-container>\r\n <!-- <ng-container *ngIf=\"loading\">\r\n <span>loading...</span>\r\n </ng-container> -->\r\n <!-- <ng-container *ngIf=\"loading\">-->\r\n <!-- <td *matCellDef=\"let element\" >loading....</td>-->\r\n <!-- </ng-container>-->\r\n <!--{{this.rows | json}}-->\r\n \r\n<!-- <app-no-data-placeholder *ngIf=\"noData && !loading\" [noDataPlaceholder]=\"noDataObj\"></app-no-data-placeholder> -->\r\n\r\n <mat-paginator [pageSize]=\"10\" [length]=\"totalRecords\" (page)=\"onPageChange($event)\" \r\n [pageSizeOptions]=\"[5, 10, 25, 100]\" aria-label=\"Select page of users\"></mat-paginator>\r\n <!-- style-paginator -->\r\n <!-- showFirstLastButtons -->\r\n</div>", styles: [""], dependencies: [{ kind: "ngmodule", type: MatPaginatorModule }, { kind: "component", type: i1$5.MatPaginator, selector: "mat-paginator", inputs: ["color", "pageIndex", "length", "pageSize", "pageSizeOptions", "hidePageSize", "showFirstLastButtons", "selectConfig", "disabled"], outputs: ["page"], exportAs: ["matPaginator"] }, { kind: "ngmodule", type: MatTableModule }, { kind: "component", type: i2$3.MatTable, selector: "mat-table, table[mat-table]", exportAs: ["matTable"] }, { kind: "directive", type: i2$3.MatHeaderCellDef, selector: "[matHeaderCellDef]" }, { kind: "directive", type: i2$3.MatHeaderRowDef, selector: "[matHeaderRowDef]", inputs: ["matHeaderRowDef", "matHeaderRowDefSticky"] }, { kind: "directive", type: i2$3.MatColumnDef, selector: "[matColumnDef]", inputs: ["matColumnDef"] }, { kind: "directive", type: i2$3.MatCellDef, selector: "[matCellDef]" }, { kind: "directive", type: i2$3.MatRowDef, selector: "[matRowDef]", inputs: ["matRowDefColumns", "matRowDefWhen"] }, { kind: "directive", type: i2$3.MatHeaderCell, selector: "mat-header-cell, th[mat-header-cell]" }, { kind: "directive", type: i2$3.MatCell, selector: "mat-cell, td[mat-cell]" }, { kind: "component", type: i2$3.MatHeaderRow, selector: "mat-header-row, tr[mat-header-row]", exportAs: ["matHeaderRow"] }, { kind: "component", type: i2$3.MatRow, selector: "mat-row, tr[mat-row]", exportAs: ["matRow"] }, { kind: "directive", type: NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "directive", type: NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "pipe", type: DatePipe, name: "date" }, { kind: "component", type: RepeatedListComponent, selector: "app-repeated-list", inputs: ["listOfItems", "type"] }, { kind: "component", type: MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", exportAs: ["matButton"] }, { kind: "component", type: MatMenu, selector: "mat-menu", inputs: ["backdropClass", "aria-label", "aria-labelledby", "aria-describedby", "xPosition", "yPosition", "overlapTrigger", "hasBackdrop", "class", "classList"], outputs: ["closed", "close"], exportAs: ["matMenu"] }, { kind: "directive", type: MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", inputs: ["mat-menu-trigger-for", "matMenuTriggerFor", "matMenuTriggerData", "matMenuTriggerRestoreFocus"], outputs: ["menuOpened", "onMenuOpen", "menuClosed", "onMenuClose"], exportAs: ["matMenuTrigger"] }, { kind: "component", type: MatMenuItem, selector: "[mat-menu-item]", inputs: ["role", "disabled", "disableRipple"], exportAs: ["matMenuItem"] }, { kind: "directive", type: NgSwitchDefault, selector: "[ngSwitchDefault]" }] });
|
|
4545
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.8", type: TableListComponent, isStandalone: true, selector: "app-table-list", inputs: { columns: "columns", columnsConfig: "columnsConfig", rows: "rows", actions: "actions", totalRecords: "totalRecords", className: "className" }, outputs: { pageChanged: "pageChanged", buttonAction: "buttonAction", emitDataRow: "emitDataRow" }, usesInheritance: true, ngImport: i0, template: "<div class=\"overflow-auto\">\r\n <!-- #table (scroll)=\"onPageChange($event)\" -->\r\n <ng-container >\r\n <!-- (matSortChange)=\"sortData($event)\" -->\r\n <table mat-table [dataSource]=\"dataSource\" class=\"primary-table {{className}}\" matSort >\r\n <ng-container *ngFor=\"let column of columns; let i = index;\">\r\n <ng-container [matColumnDef]=\"column\">\r\n <th mat-header-cell *matHeaderCellDef [ngClass]=\"{'last-column' : columnsConfig[i].type === 'actions', 'sortArrow': columnsConfig[i]?.sortName?.length }\" mat-sort-header>\r\n {{i18n.translate(columnsConfig[i].label)}} </th>\r\n \r\n <td mat-cell [ngClass]=\"{'account-disabled': element?.user?.disabledCleanUp===true}\" *matCellDef=\"let element\">\r\n <ng-container [ngSwitch]=\"columnsConfig[i].type\" *ngIf=\"rows.length\">\r\n <a [ngClass]=\"columnsConfig[i].type\" [href]=\"element[column]\" *ngSwitchCase=\"'link'\">\r\n {{ element[column] }}\r\n </a>\r\n \r\n <a [ngClass]=\"columnsConfig[i].type\" [routerLink]=\"[element.id]\" [href]=\"element[column]\"\r\n *ngSwitchCase=\"'rout'\">\r\n {{ element[column] }}\r\n </a>\r\n \r\n <span class=\"d-inline-flex align-items-center\" [ngClass]=\"columnsConfig[i].type\" *ngSwitchCase=\"'date'\">\r\n <span class=\"sfi sfi-clock text-color-coral\" *ngIf=\"!loading\"></span>\r\n <span class=\"mx-2\">\r\n <!-- {{ element?.Date.from }}\r\n <ng-container *ngIf=\"element?.Date.to\">\r\n : {{ element?.Date.to }}\r\n </ng-container> -->\r\n {{ element[column] | date: 'dd/MM/YYYY' }}\r\n </span>\r\n </span>\r\n \r\n <div class=\"d-inline-flex align-items-center\" [ngClass]=\"columnsConfig[i].type\" *ngSwitchCase=\"'sla'\">\r\n <app-sla [value]=\"element?.SLA.value\" [maxValue]=\"element?.SLA.max\" [canvasScale]=\"45\"\r\n [outerLineColor]=\"getSlaColor(element?.SLA.value, element?.SLA.max)\"></app-sla>\r\n </div>\r\n \r\n <div class=\"img-card table-img\" [ngClass]=\"columnsConfig[i].type\" *ngSwitchCase=\"'image'\">\r\n <img [src]=\"element?.image\" alt=\"\">\r\n </div>\r\n \r\n <span class=\"{{ element[column].type }}\" [ngClass]=\"columnsConfig[i].type\" *ngSwitchCase=\"'status'\">\r\n {{ element[column].label }}\r\n </span>\r\n \r\n \r\n <div class=\"d-flex mx-n1\" *ngSwitchCase=\"'RequestType'\">\r\n <div class=\"request-type mx-1 {{item.status}}\" *ngFor=\"let item of element?.RequestType\">\r\n {{ item.label }}\r\n <span class=\"mx-1\" *ngIf=\"item.status === 'need-action'\"></span>\r\n <span class=\"sfi sfi-info \" *ngIf=\"item.status === 'need-action'\"></span>\r\n </div>\r\n </div>\r\n \r\n \r\n <span class=\"{{ element[column].type }} {{ element[column] ? 'text-color-coral underline' : '' }}\"\r\n [ngClass]=\"columnsConfig[i].type\" *ngSwitchCase=\"'number'\">\r\n {{ element[column] ? element[column] : '-' }}\r\n </span>\r\n \r\n <div class=\"text-nowrap d-flex align-items-center\" [ngClass]=\"columnsConfig[i].type\"\r\n *ngSwitchCase=\"'group'\">\r\n <span>{{element?.Group.groupName}}</span>\r\n <span class=\"mx-2\"></span>\r\n <app-repeated-list type=\"users-avatar\" [listOfItems]=\"element?.Group.users\"></app-repeated-list>\r\n </div>\r\n \r\n <div class=\"d-flex align-items-center gap-2\" [ngClass]=\"columnsConfig[i].type\" *ngSwitchCase=\"'user'\">\r\n <span class=\"img-card circled-img small\" *ngIf=\"!loading\">\r\n <img src=\"{{'data:image/png;base64,' + element?.user?.personalPhoto}}\"\r\n onerror=\"this.onerror=null;this.src='assets/images/user.svg';\" alt=\"\">\r\n </span>\r\n <div class=\"d-flex flex-column\">\r\n <span class=\"font-14 font-weight-medium\">{{element?.user?.name}}</span>\r\n <span class=\"font-12 font-weight-normal text-color-dark-gray mt-1\">{{element?.user?.email}}</span>\r\n </div>\r\n </div>\r\n \r\n \r\n <div class=\"delegate d-flex align-items-center\" [ngClass]=\"columnsConfig[i].type\"\r\n *ngSwitchCase=\"'assigned'\">\r\n <div class=\"img-card x-small circled-img\">\r\n <img [src]=\"element?.AssignedTo.image\" alt=\"\">\r\n </div>\r\n <span class=\"mx-1\"></span>\r\n <span class=\"font-14 font-weight-medium text-color-onyx\">{{element?.AssignedTo.name}}</span>\r\n <span class=\"sfi sfi-close text-color-coral\"></span>\r\n </div>\r\n \r\n \r\n <ng-container *ngSwitchCase=\"'statusAction'\">\r\n <div class=\"table-action\">\r\n \r\n <div class=\"count-down mx-n1\" *ngIf=\"element[column] === 'need-action'\">\r\n <div class=\"item mx-1\">\r\n <span class=\"font-12 font-weight-medium text-color-onyx d-block\">01</span>\r\n <span class=\"font-8 font-weight-light text-color-onyx d-block\">Days</span>\r\n </div>\r\n <div class=\"item mx-1\">\r\n <span class=\"font-12 font-weight-medium text-color-onyx d-block\">18</span>\r\n <span class=\"font-8 font-weight-light text-color-onyx d-block\">Hours</span>\r\n </div>\r\n <div class=\"item mx-1\">\r\n <span class=\"font-12 font-weight-medium text-color-onyx d-block\">44</span>\r\n <span class=\"font-8 font-weight-light text-color-onyx d-block\">Mins</span>\r\n </div>\r\n </div>\r\n \r\n <div class=\"d-flex align-items-center\" *ngIf=\"element[column] === 'approved'\">\r\n <span class=\"status approved\">\r\n Approved\r\n </span>\r\n </div>\r\n \r\n <div class=\"d-flex align-items-center\" *ngIf=\"element[column] === 'sent-back'\">\r\n <span class=\"status rejected\">\r\n Sent Back\r\n </span>\r\n <span class=\"mx-2\"></span>\r\n <button mat-stroked-button class=\"btn button-primary square br-w-1 font-14 font-weight-medium\"\r\n (click)=\"sentBack()\">\r\n <span class=\"sfi sfi-chat-o\"></span>\r\n </button>\r\n </div>\r\n \r\n <div class=\"d-flex align-items-center\" *ngIf=\"element[column] === 'pending'\">\r\n <span class=\"status pending\">\r\n Pending\r\n </span>\r\n <span class=\"mx-2\"></span>\r\n \r\n <div class=\"d-flex align-items-center mx-n1\">\r\n <div class=\"img-card circled-img x-small mx-1\">\r\n <img [src]=\"element?.pendingWith.image\" alt=\"\">\r\n </div>\r\n \r\n <div class=\"d-flex flex-column mx-1\">\r\n <span class=\"font-8 font-weight-medium text-color-yellow text-nowrap\">Pending With</span>\r\n <span class=\"font-11 font-weight-medium text-nowrap\">{{element?.pendingWith.name}}</span>\r\n </div>\r\n </div>\r\n </div>\r\n \r\n \r\n </div>\r\n </ng-container>\r\n \r\n \r\n <ng-container *ngSwitchCase=\"'actions'\">\r\n \r\n <div class=\"d-flex justify-content-between mx-n2\">\r\n <ng-container *ngFor=\"let action of element[column]\">\r\n \r\n <div class=\"flex-grow-1\">\r\n <ng-container *ngIf=\"action.type.buttonType === 'stroked'\">\r\n <button mat-stroked-button (click)=\"buttonClicked(element,action.fn, $event)\"\r\n class=\"btn button-{{action.type.buttonClass}} mx-2\">\r\n {{action.label}}\r\n </button>\r\n </ng-container>\r\n \r\n <ng-container *ngIf=\"action.type.buttonType === 'flat'\">\r\n <button mat-flat-button (click)=\"buttonClicked(element,action.fn, $event)\"\r\n class=\"btn button-{{action.type.buttonClass}} mx-2\">\r\n {{action.label}}\r\n </button>\r\n </ng-container>\r\n \r\n <ng-container *ngIf=\"action.type.buttonType === 'icon'\">\r\n <button mat-icon-button (click)=\"buttonClicked(element,action.fn, $event)\"\r\n class=\"btn button-{{action.type.buttonClass}} mx-2\">\r\n <span class=\"sfi sfi-{{action.type.icon}}\"></span>\r\n </button>\r\n </ng-container>\r\n </div>\r\n \r\n <ng-container *ngIf=\"action.type.buttonType === 'all'\">\r\n <button mat-icon-button class=\"btn button-transparent square medium mx-2 text-end\"\r\n [matMenuTriggerFor]=\"menuAction\" (click)=\"$event.stopPropagation()\">\r\n <span class=\"sfi sfi-dots text-color-onyx\"></span>\r\n </button>\r\n <mat-menu #menuAction=\"matMenu\" xPosition=\"before\" class=\"actions-menu\">\r\n <button *ngIf=\"!element?.user?.email && element?.user?.disabledCleanUp!==true\" mat-menu-item class=\"text-color-onyx font-12\"\r\n (click)=\"buttonClicked(element,'CreateEmail', $event)\">\r\n {{i18n.translate('createEmail')}} \r\n </button>\r\n <button *ngIf=\"element?.user?.email && element?.user?.enabled==='true'\" mat-menu-item class=\"text-color-red font-12\"\r\n (click)=\"buttonClicked(element,'DisableEmail', $event)\">\r\n {{ i18n.translate('disableEmail')}}\r\n </button>\r\n <button *ngIf=\"element?.user?.email && element?.user?.disabledCleanUp===true\" mat-menu-item class=\"text-color-red font-12\"\r\n (click)=\"buttonClicked(element,'EnableEmail', $event)\">\r\n {{ i18n.translate('enableEmail')}}\r\n </button>\r\n <button *ngIf=\"element?.user!==null && element?.user?.disabledCleanUp!==true\" mat-menu-item class=\"text-color-onyx font-12\"\r\n (click)=\"buttonClicked(element,'CreateEntryPermission', $event)\">\r\n {{ i18n.translate('createCEP')}}\r\n </button>\r\n <!-- <button *ngIf=\"!element?.user?.email\" mat-menu-item class=\"text-color-red font-12\"\r\n (click)=\"buttonClicked(element,'DisableEntryPermission', $event)\">\r\n {{i18n.translate('disableEntryPermission')}}\r\n </button> -->\r\n <button *ngIf=\"!element?.user?.email && element?.user?.disabledCleanUp!==true\" mat-menu-item class=\"text-color-red font-12\"\r\n (click)=\"buttonClicked(element,'DeleteAccount', $event)\">\r\n {{i18n.translate('deleteAccount')}}\r\n </button>\r\n\r\n <button *ngIf=\"element?.user?.email && element?.user?.disabledCleanUp!==true\" [disabled]=\"!element?.mailExtensionAllowed\" mat-menu-item class=\"text-color-onyx font-12\"\r\n (click)=\"buttonClicked(element,'ExtendAccount', $event)\">\r\n {{ i18n.translate('extendAccount')}}\r\n </button>\r\n <button mat-menu-item class=\"text-color-onyx font-12\" *ngIf=\"element?.user?.disabledCleanUp!==true\" (click)=\"buttonClicked(element,'update', $event)\">\r\n {{ i18n.translate('updateEmploymentInformation')}}\r\n </button>\r\n </mat-menu>\r\n </ng-container>\r\n </ng-container>\r\n </div>\r\n </ng-container>\r\n \r\n <span class=\"text-nowrap\" [ngClass]=\"columnsConfig[i].type\" *ngSwitchDefault>\r\n {{ element[column] }}\r\n </span>\r\n </ng-container>\r\n <ng-container *ngIf=\"loading\">\r\n <span class=\" d-block loading-bg\"></span>\r\n </ng-container>\r\n \r\n </td>\r\n \r\n \r\n </ng-container>\r\n </ng-container>\r\n \r\n <tr mat-header-row *matHeaderRowDef=\"columns\"></tr>\r\n <tr mat-row *matRowDef=\"let row; columns: columns;\" class=\"cursor-pointer\" (click)=\"selectedRow(row)\"></tr>\r\n </table>\r\n </ng-container>\r\n <!-- <ng-container *ngIf=\"loading\">\r\n <span>loading...</span>\r\n </ng-container> -->\r\n <!-- <ng-container *ngIf=\"loading\">-->\r\n <!-- <td *matCellDef=\"let element\" >loading....</td>-->\r\n <!-- </ng-container>-->\r\n <!--{{this.rows | json}}-->\r\n \r\n<!-- <app-no-data-placeholder *ngIf=\"noData && !loading\" [noDataPlaceholder]=\"noDataObj\"></app-no-data-placeholder> -->\r\n\r\n <mat-paginator [pageSize]=\"10\" [length]=\"totalRecords\" (page)=\"onPageChange($event)\" \r\n [pageSizeOptions]=\"[5, 10, 25, 100]\" aria-label=\"Select page of users\"></mat-paginator>\r\n <!-- style-paginator -->\r\n <!-- showFirstLastButtons -->\r\n</div>", styles: [""], dependencies: [{ kind: "ngmodule", type: MatPaginatorModule }, { kind: "component", type: i1$5.MatPaginator, selector: "mat-paginator", inputs: ["color", "pageIndex", "length", "pageSize", "pageSizeOptions", "hidePageSize", "showFirstLastButtons", "selectConfig", "disabled"], outputs: ["page"], exportAs: ["matPaginator"] }, { kind: "ngmodule", type: MatTableModule }, { kind: "component", type: i2$2.MatTable, selector: "mat-table, table[mat-table]", exportAs: ["matTable"] }, { kind: "directive", type: i2$2.MatHeaderCellDef, selector: "[matHeaderCellDef]" }, { kind: "directive", type: i2$2.MatHeaderRowDef, selector: "[matHeaderRowDef]", inputs: ["matHeaderRowDef", "matHeaderRowDefSticky"] }, { kind: "directive", type: i2$2.MatColumnDef, selector: "[matColumnDef]", inputs: ["matColumnDef"] }, { kind: "directive", type: i2$2.MatCellDef, selector: "[matCellDef]" }, { kind: "directive", type: i2$2.MatRowDef, selector: "[matRowDef]", inputs: ["matRowDefColumns", "matRowDefWhen"] }, { kind: "directive", type: i2$2.MatHeaderCell, selector: "mat-header-cell, th[mat-header-cell]" }, { kind: "directive", type: i2$2.MatCell, selector: "mat-cell, td[mat-cell]" }, { kind: "component", type: i2$2.MatHeaderRow, selector: "mat-header-row, tr[mat-header-row]", exportAs: ["matHeaderRow"] }, { kind: "component", type: i2$2.MatRow, selector: "mat-row, tr[mat-row]", exportAs: ["matRow"] }, { kind: "directive", type: NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "directive", type: NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "pipe", type: DatePipe, name: "date" }, { kind: "component", type: RepeatedListComponent, selector: "app-repeated-list", inputs: ["listOfItems", "type"] }, { kind: "component", type: MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", exportAs: ["matButton"] }, { kind: "component", type: MatMenu, selector: "mat-menu", inputs: ["backdropClass", "aria-label", "aria-labelledby", "aria-describedby", "xPosition", "yPosition", "overlapTrigger", "hasBackdrop", "class", "classList"], outputs: ["closed", "close"], exportAs: ["matMenu"] }, { kind: "directive", type: MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", inputs: ["mat-menu-trigger-for", "matMenuTriggerFor", "matMenuTriggerData", "matMenuTriggerRestoreFocus"], outputs: ["menuOpened", "onMenuOpen", "menuClosed", "onMenuClose"], exportAs: ["matMenuTrigger"] }, { kind: "component", type: MatMenuItem, selector: "[mat-menu-item]", inputs: ["role", "disabled", "disableRipple"], exportAs: ["matMenuItem"] }, { kind: "directive", type: NgSwitchDefault, selector: "[ngSwitchDefault]" }] });
|
|
4165
4546
|
}
|
|
4166
4547
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: TableListComponent, decorators: [{
|
|
4167
4548
|
type: Component,
|
|
@@ -4573,7 +4954,7 @@ class ApprovalsWorkflowComponent {
|
|
|
4573
4954
|
this.coreService.approvals = JSON.stringify(this.approvals);
|
|
4574
4955
|
this.sidenavService.publish('open', ApprovalsComponent);
|
|
4575
4956
|
}
|
|
4576
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: ApprovalsWorkflowComponent, deps: [{ token: CoreI18nService }, { token: SidenavService }, { token: CoreService }, { token:
|
|
4957
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: ApprovalsWorkflowComponent, deps: [{ token: CoreI18nService }, { token: SidenavService }, { token: CoreService }, { token: i3$2.ToastrService }], target: i0.ɵɵFactoryTarget.Component });
|
|
4577
4958
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: ApprovalsWorkflowComponent, isStandalone: true, selector: "lib-approvals-workflow", inputs: { section: "section", form: "form" }, ngImport: i0, template: "<ds-button\r\n color=\"white\" shape=\"text\" square size=\"small\"\r\n (click)=\"getApproves()\">\r\n <slot name=\"prefix\">\r\n @if (loading) {\r\n <ds-icon class=\"sfi sfi-spinner d-inline-block spin fc-coral fs-30-imp\"></ds-icon>\r\n } @else {\r\n <ds-icon icon=\"workflow\" class=\"fs-24\"></ds-icon>\r\n }\r\n </slot>\r\n</ds-button>\r\n", styles: ["::ng-deep .sat-popover-container.sat-popover-before .default-popover:before{display:none}\n"], dependencies: [{ kind: "ngmodule", type: SatPopoverModule }] });
|
|
4578
4959
|
}
|
|
4579
4960
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: ApprovalsWorkflowComponent, decorators: [{
|
|
@@ -4582,7 +4963,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
|
|
|
4582
4963
|
SatPopoverModule,
|
|
4583
4964
|
NgIf
|
|
4584
4965
|
], schemas: [CUSTOM_ELEMENTS_SCHEMA], template: "<ds-button\r\n color=\"white\" shape=\"text\" square size=\"small\"\r\n (click)=\"getApproves()\">\r\n <slot name=\"prefix\">\r\n @if (loading) {\r\n <ds-icon class=\"sfi sfi-spinner d-inline-block spin fc-coral fs-30-imp\"></ds-icon>\r\n } @else {\r\n <ds-icon icon=\"workflow\" class=\"fs-24\"></ds-icon>\r\n }\r\n </slot>\r\n</ds-button>\r\n", styles: ["::ng-deep .sat-popover-container.sat-popover-before .default-popover:before{display:none}\n"] }]
|
|
4585
|
-
}], ctorParameters: () => [{ type: CoreI18nService }, { type: SidenavService }, { type: CoreService }, { type:
|
|
4966
|
+
}], ctorParameters: () => [{ type: CoreI18nService }, { type: SidenavService }, { type: CoreService }, { type: i3$2.ToastrService }], propDecorators: { section: [{
|
|
4586
4967
|
type: Input
|
|
4587
4968
|
}], form: [{
|
|
4588
4969
|
type: Input
|
|
@@ -4681,7 +5062,7 @@ class ActionButtonsComponent {
|
|
|
4681
5062
|
}
|
|
4682
5063
|
return '';
|
|
4683
5064
|
}
|
|
4684
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: ActionButtonsComponent, deps: [{ token: CoreI18nService }, { token: ActionStateService }, { token: CoreService }, { token: i1$1.MatDialog }, { token:
|
|
5065
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: ActionButtonsComponent, deps: [{ token: CoreI18nService }, { token: ActionStateService }, { token: CoreService }, { token: i1$1.MatDialog }, { token: i3$2.ToastrService }, { token: i0.ChangeDetectorRef }, { token: SidenavService }], target: i0.ɵɵFactoryTarget.Component });
|
|
4685
5066
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: ActionButtonsComponent, isStandalone: true, selector: "lib-action-buttons", inputs: { lovOptions: "lovOptions", lovType: "lovType", fieldsForm: "fieldsForm", form: "form", section: "section", sections: "sections", showApprovalCycle: "showApprovalCycle", customCall: "customCall" }, outputs: { resetFormEmit: "resetFormEmit", customCallEmit: "customCallEmit" }, ngImport: i0, template: "<div class=\"mt-4\">\r\n @if (lovType === 'button') {\r\n <div class=\"d-flex align-items-center gap-3\">\r\n <ds-button shape=\"text\" color=\"red\" (click)=\"resetForm()\">\r\n <span class=\"fs-16 fw-medium\">{{ i18n.translate('reset') }}</span>\r\n </ds-button>\r\n @if (form?.sections?.length == 1 && showApprovalCycle) {\r\n <lib-approvals-workflow [section]=\"section\" [form]=\"form\"></lib-approvals-workflow>\r\n }\r\n <div class=\"d-flex flex-wrap align-items-center flex-grow-1 flex-row-reverse gap-3\">\r\n @for (item of lovOptions; track $index) {\r\n <ds-button\r\n loading=\"{{isSubmitting[item.value]}}\"\r\n [ngClass]=\"{'disabled': !actionStates[item.value] || submittingForm}\"\r\n shape=\"{{ buttonShape(item) }}\"\r\n color=\"{{ buttonColor(item) }}\"\r\n (click)=\"onSubmit(item?.value)\">\r\n {{ item?.['description'] }}\r\n </ds-button>\r\n }\r\n </div>\r\n </div>\r\n } @else {\r\n <div class=\"d-flex align-items-center gap-3\">\r\n <ds-button shape=\"text\" color=\"red\" (click)=\"resetForm()\">\r\n <span class=\"fs-16 fw-medium\">{{ i18n.translate('reset') }}</span>\r\n </ds-button>\r\n @if (form?.sections?.length == 1 && showApprovalCycle) {\r\n <lib-approvals-workflow [section]=\"section\" [form]=\"form\"></lib-approvals-workflow>\r\n }\r\n <div class=\"d-flex flex-wrap align-items-center flex-grow-1 flex-row-reverse gap-3\">\r\n <ds-button\r\n [ngClass]=\"{'disabled': !actionStates['SUBMIT'] || submittingForm}\"\r\n loading=\"{{isSubmitting['SUBMIT']}}\"\r\n (click)=\"onSubmit('SUBMIT')\">\r\n {{ i18n.translate('submit') }}\r\n </ds-button>\r\n </div>\r\n </div>\r\n }\r\n</div>\r\n", styles: [""], dependencies: [{ kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: ApprovalsWorkflowComponent, selector: "lib-approvals-workflow", inputs: ["section", "form"] }] });
|
|
4686
5067
|
}
|
|
4687
5068
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: ActionButtonsComponent, decorators: [{
|
|
@@ -4693,7 +5074,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
|
|
|
4693
5074
|
NgForOf,
|
|
4694
5075
|
ApprovalsWorkflowComponent
|
|
4695
5076
|
], template: "<div class=\"mt-4\">\r\n @if (lovType === 'button') {\r\n <div class=\"d-flex align-items-center gap-3\">\r\n <ds-button shape=\"text\" color=\"red\" (click)=\"resetForm()\">\r\n <span class=\"fs-16 fw-medium\">{{ i18n.translate('reset') }}</span>\r\n </ds-button>\r\n @if (form?.sections?.length == 1 && showApprovalCycle) {\r\n <lib-approvals-workflow [section]=\"section\" [form]=\"form\"></lib-approvals-workflow>\r\n }\r\n <div class=\"d-flex flex-wrap align-items-center flex-grow-1 flex-row-reverse gap-3\">\r\n @for (item of lovOptions; track $index) {\r\n <ds-button\r\n loading=\"{{isSubmitting[item.value]}}\"\r\n [ngClass]=\"{'disabled': !actionStates[item.value] || submittingForm}\"\r\n shape=\"{{ buttonShape(item) }}\"\r\n color=\"{{ buttonColor(item) }}\"\r\n (click)=\"onSubmit(item?.value)\">\r\n {{ item?.['description'] }}\r\n </ds-button>\r\n }\r\n </div>\r\n </div>\r\n } @else {\r\n <div class=\"d-flex align-items-center gap-3\">\r\n <ds-button shape=\"text\" color=\"red\" (click)=\"resetForm()\">\r\n <span class=\"fs-16 fw-medium\">{{ i18n.translate('reset') }}</span>\r\n </ds-button>\r\n @if (form?.sections?.length == 1 && showApprovalCycle) {\r\n <lib-approvals-workflow [section]=\"section\" [form]=\"form\"></lib-approvals-workflow>\r\n }\r\n <div class=\"d-flex flex-wrap align-items-center flex-grow-1 flex-row-reverse gap-3\">\r\n <ds-button\r\n [ngClass]=\"{'disabled': !actionStates['SUBMIT'] || submittingForm}\"\r\n loading=\"{{isSubmitting['SUBMIT']}}\"\r\n (click)=\"onSubmit('SUBMIT')\">\r\n {{ i18n.translate('submit') }}\r\n </ds-button>\r\n </div>\r\n </div>\r\n }\r\n</div>\r\n" }]
|
|
4696
|
-
}], ctorParameters: () => [{ type: CoreI18nService }, { type: ActionStateService }, { type: CoreService }, { type: i1$1.MatDialog }, { type:
|
|
5077
|
+
}], ctorParameters: () => [{ type: CoreI18nService }, { type: ActionStateService }, { type: CoreService }, { type: i1$1.MatDialog }, { type: i3$2.ToastrService }, { type: i0.ChangeDetectorRef }, { type: SidenavService }], propDecorators: { lovOptions: [{
|
|
4697
5078
|
type: Input
|
|
4698
5079
|
}], lovType: [{
|
|
4699
5080
|
type: Input
|
|
@@ -4722,27 +5103,22 @@ class FaqsComponent {
|
|
|
4722
5103
|
constructor(i18n) {
|
|
4723
5104
|
this.i18n = i18n;
|
|
4724
5105
|
}
|
|
4725
|
-
ngOnInit() {
|
|
4726
|
-
}
|
|
4727
5106
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: FaqsComponent, deps: [{ token: CoreI18nService }], target: i0.ɵɵFactoryTarget.Component });
|
|
4728
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
|
|
5107
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: FaqsComponent, isStandalone: true, selector: "app-faqs", inputs: { adminView: "adminView", faqs: "faqs" }, ngImport: i0, template: "<mat-accordion class=\"primary-accordion\">\r\n @for (item of faqs; track $index) {\r\n <mat-expansion-panel [expanded]=\"$index==0\" class=\"mb-4\" hideToggle #expansionPanel=\"matExpansionPanel\">\r\n @if (item.title) {\r\n <mat-expansion-panel-header class=\"expansion-header\">\r\n <mat-panel-title>\r\n <h3 class=\"fs-14 fw-medium fc-black mb-0 flex-grow-1 align-self-center\">{{ item.title }}</h3>\r\n @if (expansionPanel.expanded) {\r\n <ds-icon icon=\"minus\" class=\"fs-20 fc-dark-gray\"></ds-icon>\r\n } @else {\r\n <ds-icon icon=\"plus-1\" class=\"fs-20 fc-coral\"></ds-icon>\r\n }\r\n </mat-panel-title>\r\n\r\n </mat-expansion-panel-header>\r\n }\r\n <p class=\"fs-14 fc-dark-gray\">\r\n {{ item.content }}\r\n </p>\r\n </mat-expansion-panel>\r\n }\r\n</mat-accordion>\r\n", styles: ["::ng-deep .primary-accordion{--accordion-height: 60px;--accordion-radius: 6px;--accordion-bc: var(--light-gray);--accordion-bc-active: var(--white);--accordion-border: 0;--accordion-border-active: 0;--accordion-shadow: none;--accordion-shadow-active: 0 10px 7px rgba(var(--rgb-black), .06);--panel-body-padding: 0 1.5rem 1rem}::ng-deep .primary-accordion .mat-expansion-indicator{display:none}\n"], dependencies: [{ kind: "directive", type: MatAccordion, selector: "mat-accordion", inputs: ["hideToggle", "displayMode", "togglePosition"], exportAs: ["matAccordion"] }, { kind: "component", type: MatExpansionPanel, selector: "mat-expansion-panel", inputs: ["hideToggle", "togglePosition"], outputs: ["afterExpand", "afterCollapse"], exportAs: ["matExpansionPanel"] }, { kind: "directive", type: MatExpansionPanelTitle, selector: "mat-panel-title" }] });
|
|
4729
5108
|
}
|
|
4730
5109
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: FaqsComponent, decorators: [{
|
|
4731
5110
|
type: Component,
|
|
4732
5111
|
args: [{ selector: 'app-faqs', standalone: true, imports: [
|
|
4733
5112
|
MatAccordion,
|
|
4734
5113
|
MatExpansionPanel,
|
|
4735
|
-
MatExpansionPanelTitle
|
|
4736
|
-
|
|
4737
|
-
NgForOf
|
|
4738
|
-
], schemas: [CUSTOM_ELEMENTS_SCHEMA], template: "<mat-accordion class=\"primary-accordion\">\r\n <mat-expansion-panel [expanded]=\"i==0\" class=\"mb-4\" *ngFor=\"let item of faqs; let i = index;\" hideToggle #expansionPanel=\"matExpansionPanel\">\r\n <mat-expansion-panel-header *ngIf=\"item.title\" class=\"expansion-header\">\r\n\r\n <mat-panel-title>\r\n <h3 class=\"fs-14 fw-medium fc-black mb-0 flex-grow-1 align-self-center\">{{ item.title }}</h3>\r\n <ds-icon icon=\"plus-1\" class=\"fs-20 fc-coral\" *ngIf=\"!expansionPanel.expanded\"></ds-icon>\r\n <ds-icon icon=\"minus\" class=\"fs-20 fc-dark-gray\" *ngIf=\"expansionPanel.expanded\"></ds-icon>\r\n </mat-panel-title>\r\n\r\n </mat-expansion-panel-header>\r\n <p class=\"fs-14 fc-dark-gray\">\r\n {{ item.content }}\r\n </p>\r\n </mat-expansion-panel>\r\n</mat-accordion>\r\n", styles: ["::ng-deep .primary-accordion{--accordion-height: 60px;--accordion-radius: 6px;--accordion-bc: var(--light-gray);--accordion-bc-active: var(--white);--accordion-border: 0;--accordion-border-active: 0;--accordion-shadow: none;--accordion-shadow-active: 0 10px 7px rgba(var(--rgb-black), .06);--panel-body-padding: 0 1.5rem 1rem}::ng-deep .primary-accordion .mat-expansion-indicator{display:none}\n"] }]
|
|
5114
|
+
MatExpansionPanelTitle
|
|
5115
|
+
], schemas: [CUSTOM_ELEMENTS_SCHEMA], template: "<mat-accordion class=\"primary-accordion\">\r\n @for (item of faqs; track $index) {\r\n <mat-expansion-panel [expanded]=\"$index==0\" class=\"mb-4\" hideToggle #expansionPanel=\"matExpansionPanel\">\r\n @if (item.title) {\r\n <mat-expansion-panel-header class=\"expansion-header\">\r\n <mat-panel-title>\r\n <h3 class=\"fs-14 fw-medium fc-black mb-0 flex-grow-1 align-self-center\">{{ item.title }}</h3>\r\n @if (expansionPanel.expanded) {\r\n <ds-icon icon=\"minus\" class=\"fs-20 fc-dark-gray\"></ds-icon>\r\n } @else {\r\n <ds-icon icon=\"plus-1\" class=\"fs-20 fc-coral\"></ds-icon>\r\n }\r\n </mat-panel-title>\r\n\r\n </mat-expansion-panel-header>\r\n }\r\n <p class=\"fs-14 fc-dark-gray\">\r\n {{ item.content }}\r\n </p>\r\n </mat-expansion-panel>\r\n }\r\n</mat-accordion>\r\n", styles: ["::ng-deep .primary-accordion{--accordion-height: 60px;--accordion-radius: 6px;--accordion-bc: var(--light-gray);--accordion-bc-active: var(--white);--accordion-border: 0;--accordion-border-active: 0;--accordion-shadow: none;--accordion-shadow-active: 0 10px 7px rgba(var(--rgb-black), .06);--panel-body-padding: 0 1.5rem 1rem}::ng-deep .primary-accordion .mat-expansion-indicator{display:none}\n"] }]
|
|
4739
5116
|
}], ctorParameters: () => [{ type: CoreI18nService }], propDecorators: { adminView: [{
|
|
4740
5117
|
type: Input
|
|
4741
5118
|
}], faqs: [{
|
|
4742
5119
|
type: Input
|
|
4743
5120
|
}] } });
|
|
4744
5121
|
|
|
4745
|
-
/* eslint-disable @angular-eslint/component-selector */
|
|
4746
5122
|
class FaqSidenavComponent {
|
|
4747
5123
|
sidenavService;
|
|
4748
5124
|
i18n;
|
|
@@ -4751,9 +5127,6 @@ class FaqSidenavComponent {
|
|
|
4751
5127
|
this.sidenavService = sidenavService;
|
|
4752
5128
|
this.i18n = i18n;
|
|
4753
5129
|
}
|
|
4754
|
-
ngOnInit() {
|
|
4755
|
-
// this.data = this.sidenavService?.subject?.value['data'];
|
|
4756
|
-
}
|
|
4757
5130
|
closeSidenav() {
|
|
4758
5131
|
this.sidenavService.publish('close', FaqSidenavComponent);
|
|
4759
5132
|
}
|
|
@@ -5243,68 +5616,202 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
|
|
|
5243
5616
|
args: [{ selector: 'app-activities', standalone: true, imports: [], schemas: [CUSTOM_ELEMENTS_SCHEMA], template: "<section class=\"main-sidenav\">\r\n <div class=\"sidenav-title\">\r\n <h3>{{ i18n.translate('commentHistory') }}</h3>\r\n\r\n <ds-button (click)=\"closeSidenav()\" icon>\r\n <ds-icon icon=\"close\" class=\"fs-20 fc-black\"></ds-icon>\r\n </ds-button>\r\n\r\n </div>\r\n <div class=\"sidenav-body\">\r\n @if (coreService.activities) {\r\n <ds-activity-log activitiesData=\"{{parsedData}}\" readOnly (downloadEvent)=\"downloadFile($event)\">\r\n </ds-activity-log>\r\n } @else {\r\n <ds-message label=\"{{i18n.translate('NoData1')}}\"></ds-message>\r\n }\r\n </div>\r\n</section>\r\n" }]
|
|
5244
5617
|
}], ctorParameters: () => [{ type: SidenavService }, { type: CoreI18nService }, { type: CoreService }] });
|
|
5245
5618
|
|
|
5246
|
-
class
|
|
5247
|
-
|
|
5248
|
-
|
|
5249
|
-
|
|
5250
|
-
|
|
5251
|
-
|
|
5252
|
-
|
|
5253
|
-
|
|
5254
|
-
|
|
5255
|
-
|
|
5256
|
-
|
|
5619
|
+
class StatusStylePipe {
|
|
5620
|
+
transform(status) {
|
|
5621
|
+
let statusClass = {
|
|
5622
|
+
APPROVED: 'success',
|
|
5623
|
+
STORED: 'success',
|
|
5624
|
+
GM_APPROVAL: 'success',
|
|
5625
|
+
COMPLETED: 'success',
|
|
5626
|
+
COMPLETE: 'success',
|
|
5627
|
+
ACCEPTED: 'success',
|
|
5628
|
+
SUBMIT: 'success',
|
|
5629
|
+
SUBMIT_TRAINING: 'success',
|
|
5630
|
+
VEHICLE_IS_AVAILABLE: 'success',
|
|
5631
|
+
VEHICLE_RECEIVED: 'success',
|
|
5632
|
+
RETRY: 'success',
|
|
5633
|
+
REJECT: 'danger',
|
|
5634
|
+
REJECTED: 'danger',
|
|
5635
|
+
AUTO_REJECT: 'danger',
|
|
5636
|
+
VEHICLE_IS_NOT_AVAILABLE: 'danger',
|
|
5637
|
+
SEND_TO_SAFETY_INSPECTOR: 'success',
|
|
5638
|
+
SEND_TO_DESIGN_TEAM: 'success',
|
|
5639
|
+
SEND_TO_SECURITY_SUPERVISOR: 'success',
|
|
5640
|
+
PENDING: 'warning',
|
|
5641
|
+
QUEUED: 'warning',
|
|
5642
|
+
UNACCEPTABLE: 'success',
|
|
5643
|
+
RECEIVED: 'success',
|
|
5644
|
+
CLOSED: 'success',
|
|
5645
|
+
SENT: 'info',
|
|
5646
|
+
SENDBACKTOREQUESTER: 'send_back',
|
|
5647
|
+
'COLLECT_SITE_FEEDBACK': 'success',
|
|
5648
|
+
'COLLECT_SITE_VISIT_FEEDBACK': 'success',
|
|
5649
|
+
'SUBMIT_FEEDBACK': 'success',
|
|
5650
|
+
'CONFIRM_SITE_HANDOVER': 'success',
|
|
5651
|
+
// "SENDBACKTOREQUESTER": "send_back",
|
|
5652
|
+
SEND_BACK_TO_REQUESTER: 'send_back',
|
|
5653
|
+
'SEND BACK TO REQUESTER': 'send_back',
|
|
5654
|
+
SENDBACK: 'send_back',
|
|
5655
|
+
EXPIRED: 'expired',
|
|
5656
|
+
CANCELLED: 'pending',
|
|
5657
|
+
CANCELED: 'pending',
|
|
5658
|
+
SHIPMENT_DELIVERY_REJECTED: 'danger'
|
|
5659
|
+
};
|
|
5660
|
+
// status == 'SEND BACK TO REQUESTER' ? 'SENDBACKTOREQUESTER' : status
|
|
5661
|
+
return statusClass[status?.toUpperCase()] || 'success';
|
|
5662
|
+
}
|
|
5663
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: StatusStylePipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
|
|
5664
|
+
static ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "18.2.8", ngImport: i0, type: StatusStylePipe, isStandalone: true, name: "statusClass" });
|
|
5665
|
+
}
|
|
5666
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: StatusStylePipe, decorators: [{
|
|
5667
|
+
type: Pipe,
|
|
5668
|
+
args: [{
|
|
5669
|
+
name: 'statusClass',
|
|
5670
|
+
standalone: true,
|
|
5671
|
+
}]
|
|
5672
|
+
}] });
|
|
5673
|
+
|
|
5674
|
+
class PreviousRequestsComponent {
|
|
5675
|
+
dialog;
|
|
5676
|
+
sidenavService;
|
|
5677
|
+
coreService;
|
|
5678
|
+
i18n;
|
|
5679
|
+
previousRequests = [];
|
|
5680
|
+
loading;
|
|
5681
|
+
router = inject(Router);
|
|
5682
|
+
totalLength;
|
|
5683
|
+
constructor(dialog, sidenavService, coreService, i18n) {
|
|
5684
|
+
this.dialog = dialog;
|
|
5685
|
+
this.sidenavService = sidenavService;
|
|
5686
|
+
this.coreService = coreService;
|
|
5687
|
+
this.i18n = i18n;
|
|
5688
|
+
}
|
|
5689
|
+
ngOnInit() {
|
|
5690
|
+
}
|
|
5691
|
+
ngAfterViewInit() {
|
|
5692
|
+
this.getRequests();
|
|
5693
|
+
}
|
|
5694
|
+
getRequests() {
|
|
5695
|
+
let searchData = {
|
|
5696
|
+
year: new Date().getFullYear(),
|
|
5697
|
+
month: ""
|
|
5698
|
+
};
|
|
5699
|
+
this.coreService.myRequests(searchData).subscribe((response) => {
|
|
5700
|
+
if (response) {
|
|
5701
|
+
this.previousRequests = (response.history);
|
|
5702
|
+
}
|
|
5703
|
+
});
|
|
5704
|
+
}
|
|
5705
|
+
viewForm(formId) {
|
|
5706
|
+
if (formId) {
|
|
5707
|
+
window.open('/group/i-gate/wm-bpm/forms?formId=' + formId);
|
|
5708
|
+
}
|
|
5709
|
+
}
|
|
5710
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: PreviousRequestsComponent, deps: [{ token: i1$1.MatDialog }, { token: SidenavService }, { token: CoreService }, { token: CoreI18nService }], target: i0.ɵɵFactoryTarget.Component });
|
|
5711
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.8", type: PreviousRequestsComponent, isStandalone: true, selector: "app-history", ngImport: i0, template: "<section class=\"main-sidenav history-sidenav\">\r\n <div class=\"sidenav-title\">\r\n <h3>{{ i18n.translate('PreviousRequests') }}</h3>\r\n <ds-button class=\"close-sidenav\" (click)=\"sidenavService.closeSidenav()\" icon>\r\n <ds-icon icon=\"close\" class=\"fs-20 fc-black\"></ds-icon>\r\n </ds-button>\r\n </div>\r\n\r\n <div\r\n class=\"sidenav-body bc-light-gray\"\r\n >\r\n <section class=\"p-3\">\r\n <!-- <app-request-statistics class=\"d-block mb-4\"></app-request-statistics>-->\r\n <header class=\"d-flex align-items-center justify-content-between gap-2 mb-3\">\r\n <h2 class=\"fs-20 fw-medium fc-black mb-0 d-flex align-items-center flex-grow-1 gap-3\">\r\n {{ i18n.translate('AllRequests') }}\r\n <span class=\"title-count fs-14 fw-normal\">{{ previousRequests?.length ? previousRequests?.length : '0' }}</span>\r\n </h2>\r\n <mat-button-toggle-group\r\n class=\"icon-toggle flex-nowrap\"\r\n #pageView=\"matButtonToggleGroup\"\r\n (click)=\"$event.stopImmediatePropagation()\"\r\n value=\"list\"\r\n >\r\n <mat-button-toggle value=\"card\">\r\n <span class=\"sfi sfi-card fs-20\"></span>\r\n </mat-button-toggle>\r\n <mat-button-toggle value=\"list\">\r\n <span class=\"sfi sfi-list-dots fs-20\"></span>\r\n </mat-button-toggle>\r\n </mat-button-toggle-group>\r\n </header>\r\n\r\n <div class=\"history-cards-container\" *ngIf=\"pageView.value === 'card'\">\r\n <div class=\"p-4 line-height-1 bc-white radius-6 box-shadow\" *ngFor=\"let row of previousRequests\">\r\n <div class=\"d-flex align-items-center gap-2 mb-3\">\r\n <h3\r\n class=\"fs-16 fw-medium flex-grow-1 mb-0 cursor-pointer underline fw-bold\"\r\n (click)=\"viewForm(row?.form?.['formId'])\">{{ row?.form?.['formId'] }}</h3>\r\n </div>\r\n <div class=\"row g-3\">\r\n <div class=\"d-flex flex-column col-6\">\r\n <span class=\"fs-11 fc-dark-gray mb-2\">{{ i18n.translate('formTableCreationDate') }}</span>\r\n <span class=\"fs-12 fw-medium fc-black\">{{ row?.form?.['creationDate'] | date: 'dd/MM/yyyy hh:mm a' }}</span>\r\n </div>\r\n <div class=\"d-flex flex-column col-6 justify-content-end align-items-end\">\r\n\r\n <ds-status [attr.status]=\"row?.form?.formStatus?.key | statusClass\">\r\n {{ row?.form?.formStatus?.value }}\r\n </ds-status>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n\r\n <div class=\"table-responsive\" *ngIf=\"pageView.value === 'list'\">\r\n <table *ngIf=\"previousRequests?.length\">\r\n <thead>\r\n <tr>\r\n <th>{{ i18n.translate('formTableFormId') }}</th>\r\n <th>{{ i18n.translate('formTableCreationDate') }}</th>\r\n <th>{{ i18n.translate('Status') }}</th>\r\n </tr>\r\n </thead>\r\n\r\n <tbody *ngFor=\"let row of previousRequests\">\r\n <tr>\r\n <td>\r\n <span class=\"fw-medium cursor-pointer underline fw-bold \" (click)=\"viewForm(row?.form?.['formId'])\">\r\n {{ row?.form?.['formId'] }}\r\n </span>\r\n </td>\r\n <td>{{ row?.form?.['creationDate'] | date: 'dd/MM/yyyy hh:mm a' }}</td>\r\n <td>\r\n <ds-status [attr.status]=\"row?.form?.formStatus?.key | statusClass\">\r\n {{ row?.form?.formStatus?.value }}\r\n </ds-status>\r\n </td>\r\n </tr>\r\n </tbody>\r\n </table>\r\n <ds-loading-table *ngIf=\"loading\" [cols]=\"4\" [rows]=\"4\"></ds-loading-table>\r\n </div>\r\n <ds-message *ngIf=\"!previousRequests?.length && !loading\" type=\"emptyList\" [label]=\"i18n.translate('noData') \"></ds-message>\r\n </section>\r\n\r\n </div>\r\n</section>\r\n", styles: [".history-cards-container{display:grid;grid-template-columns:repeat(auto-fill,minmax(300px,1fr));gap:1rem;padding:1rem 0}.filter-section ::ng-deep .mat-form-field.mat-primary{margin-bottom:0}.filter-section ::ng-deep .select-form-field{--placeholder-fc: var(--dark-gray)}.filter-section ::ng-deep .select-datepicker{--input-width: 200px}table thead{display:none}:host .mat-button-toggle-group{--toggle-bg: var(--white);box-shadow:var(--box-shadow)}:host table{--th-bg: var(--gray);--td-bg: var(--white);--tr-even-bc: var(--white);--tr-odd-bc: var(--white)}ds-button[square]::part(base){--btn-padding: 0}@media (min-width: 768px){.history-sidenav{--sidenav-width: 800px}}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i3.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "pipe", type: i3.DatePipe, name: "date" }, { kind: "ngmodule", type: MatMenuModule }, { kind: "ngmodule", type: RouterModule }, { kind: "ngmodule", type: TranslateModule }, { kind: "ngmodule", type: MatDialogModule }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "ngmodule", type: MatButtonToggleModule }, { kind: "directive", type: i4$1.MatButtonToggleGroup, selector: "mat-button-toggle-group", inputs: ["appearance", "name", "vertical", "value", "multiple", "disabled", "disabledInteractive", "hideSingleSelectionIndicator", "hideMultipleSelectionIndicator"], outputs: ["valueChange", "change"], exportAs: ["matButtonToggleGroup"] }, { kind: "component", type: i4$1.MatButtonToggle, selector: "mat-button-toggle", inputs: ["aria-label", "aria-labelledby", "id", "name", "value", "tabIndex", "disableRipple", "appearance", "checked", "disabled", "disabledInteractive"], outputs: ["change"], exportAs: ["matButtonToggle"] }, { kind: "pipe", type: StatusStylePipe, name: "statusClass" }] });
|
|
5712
|
+
}
|
|
5713
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: PreviousRequestsComponent, decorators: [{
|
|
5714
|
+
type: Component,
|
|
5715
|
+
args: [{ selector: 'app-history', standalone: true, imports: [
|
|
5716
|
+
CommonModule,
|
|
5717
|
+
MatMenuModule,
|
|
5718
|
+
RouterModule,
|
|
5719
|
+
TranslateModule,
|
|
5720
|
+
MatDialogModule,
|
|
5721
|
+
ReactiveFormsModule,
|
|
5722
|
+
MatButtonToggleModule,
|
|
5723
|
+
StatusStylePipe
|
|
5724
|
+
], schemas: [CUSTOM_ELEMENTS_SCHEMA], template: "<section class=\"main-sidenav history-sidenav\">\r\n <div class=\"sidenav-title\">\r\n <h3>{{ i18n.translate('PreviousRequests') }}</h3>\r\n <ds-button class=\"close-sidenav\" (click)=\"sidenavService.closeSidenav()\" icon>\r\n <ds-icon icon=\"close\" class=\"fs-20 fc-black\"></ds-icon>\r\n </ds-button>\r\n </div>\r\n\r\n <div\r\n class=\"sidenav-body bc-light-gray\"\r\n >\r\n <section class=\"p-3\">\r\n <!-- <app-request-statistics class=\"d-block mb-4\"></app-request-statistics>-->\r\n <header class=\"d-flex align-items-center justify-content-between gap-2 mb-3\">\r\n <h2 class=\"fs-20 fw-medium fc-black mb-0 d-flex align-items-center flex-grow-1 gap-3\">\r\n {{ i18n.translate('AllRequests') }}\r\n <span class=\"title-count fs-14 fw-normal\">{{ previousRequests?.length ? previousRequests?.length : '0' }}</span>\r\n </h2>\r\n <mat-button-toggle-group\r\n class=\"icon-toggle flex-nowrap\"\r\n #pageView=\"matButtonToggleGroup\"\r\n (click)=\"$event.stopImmediatePropagation()\"\r\n value=\"list\"\r\n >\r\n <mat-button-toggle value=\"card\">\r\n <span class=\"sfi sfi-card fs-20\"></span>\r\n </mat-button-toggle>\r\n <mat-button-toggle value=\"list\">\r\n <span class=\"sfi sfi-list-dots fs-20\"></span>\r\n </mat-button-toggle>\r\n </mat-button-toggle-group>\r\n </header>\r\n\r\n <div class=\"history-cards-container\" *ngIf=\"pageView.value === 'card'\">\r\n <div class=\"p-4 line-height-1 bc-white radius-6 box-shadow\" *ngFor=\"let row of previousRequests\">\r\n <div class=\"d-flex align-items-center gap-2 mb-3\">\r\n <h3\r\n class=\"fs-16 fw-medium flex-grow-1 mb-0 cursor-pointer underline fw-bold\"\r\n (click)=\"viewForm(row?.form?.['formId'])\">{{ row?.form?.['formId'] }}</h3>\r\n </div>\r\n <div class=\"row g-3\">\r\n <div class=\"d-flex flex-column col-6\">\r\n <span class=\"fs-11 fc-dark-gray mb-2\">{{ i18n.translate('formTableCreationDate') }}</span>\r\n <span class=\"fs-12 fw-medium fc-black\">{{ row?.form?.['creationDate'] | date: 'dd/MM/yyyy hh:mm a' }}</span>\r\n </div>\r\n <div class=\"d-flex flex-column col-6 justify-content-end align-items-end\">\r\n\r\n <ds-status [attr.status]=\"row?.form?.formStatus?.key | statusClass\">\r\n {{ row?.form?.formStatus?.value }}\r\n </ds-status>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n\r\n <div class=\"table-responsive\" *ngIf=\"pageView.value === 'list'\">\r\n <table *ngIf=\"previousRequests?.length\">\r\n <thead>\r\n <tr>\r\n <th>{{ i18n.translate('formTableFormId') }}</th>\r\n <th>{{ i18n.translate('formTableCreationDate') }}</th>\r\n <th>{{ i18n.translate('Status') }}</th>\r\n </tr>\r\n </thead>\r\n\r\n <tbody *ngFor=\"let row of previousRequests\">\r\n <tr>\r\n <td>\r\n <span class=\"fw-medium cursor-pointer underline fw-bold \" (click)=\"viewForm(row?.form?.['formId'])\">\r\n {{ row?.form?.['formId'] }}\r\n </span>\r\n </td>\r\n <td>{{ row?.form?.['creationDate'] | date: 'dd/MM/yyyy hh:mm a' }}</td>\r\n <td>\r\n <ds-status [attr.status]=\"row?.form?.formStatus?.key | statusClass\">\r\n {{ row?.form?.formStatus?.value }}\r\n </ds-status>\r\n </td>\r\n </tr>\r\n </tbody>\r\n </table>\r\n <ds-loading-table *ngIf=\"loading\" [cols]=\"4\" [rows]=\"4\"></ds-loading-table>\r\n </div>\r\n <ds-message *ngIf=\"!previousRequests?.length && !loading\" type=\"emptyList\" [label]=\"i18n.translate('noData') \"></ds-message>\r\n </section>\r\n\r\n </div>\r\n</section>\r\n", styles: [".history-cards-container{display:grid;grid-template-columns:repeat(auto-fill,minmax(300px,1fr));gap:1rem;padding:1rem 0}.filter-section ::ng-deep .mat-form-field.mat-primary{margin-bottom:0}.filter-section ::ng-deep .select-form-field{--placeholder-fc: var(--dark-gray)}.filter-section ::ng-deep .select-datepicker{--input-width: 200px}table thead{display:none}:host .mat-button-toggle-group{--toggle-bg: var(--white);box-shadow:var(--box-shadow)}:host table{--th-bg: var(--gray);--td-bg: var(--white);--tr-even-bc: var(--white);--tr-odd-bc: var(--white)}ds-button[square]::part(base){--btn-padding: 0}@media (min-width: 768px){.history-sidenav{--sidenav-width: 800px}}\n"] }]
|
|
5725
|
+
}], ctorParameters: () => [{ type: i1$1.MatDialog }, { type: SidenavService }, { type: CoreService }, { type: CoreI18nService }] });
|
|
5726
|
+
|
|
5727
|
+
const StatusMap$1 = {
|
|
5728
|
+
[FORM_STATUS_REJECTED]: { class: 'danger', icon: 'close' },
|
|
5729
|
+
[FORM_STATUS_CANCELLED]: { class: 'danger', icon: 'close' },
|
|
5730
|
+
[FORM_STATUS_REJECT]: { class: 'danger', icon: 'close' },
|
|
5731
|
+
[SECTION_STATUS_UNSATISFIED]: { class: 'danger', icon: 'close' },
|
|
5732
|
+
[FORM_STATUS_CANCEL]: { class: 'danger', icon: 'close' },
|
|
5733
|
+
[FORM_STATUS_PENDING]: { class: 'warning', icon: 'clock' },
|
|
5734
|
+
'default': { class: 'success', icon: 'check' }
|
|
5735
|
+
};
|
|
5736
|
+
class ServiceHeaderComponent {
|
|
5737
|
+
cdRef;
|
|
5738
|
+
coreService;
|
|
5739
|
+
i18n;
|
|
5740
|
+
feedBackService;
|
|
5741
|
+
dialog;
|
|
5742
|
+
sidenavService;
|
|
5743
|
+
toasterService;
|
|
5744
|
+
form;
|
|
5745
|
+
showHistory = false;
|
|
5746
|
+
isLoading = false;
|
|
5747
|
+
showApprovalHistory = false;
|
|
5257
5748
|
approvalHistory;
|
|
5258
5749
|
creationDate;
|
|
5259
5750
|
formTitle;
|
|
5260
5751
|
section;
|
|
5261
|
-
|
|
5752
|
+
serviceFaq = [];
|
|
5262
5753
|
approvals = [];
|
|
5263
5754
|
feedBackIcon = null;
|
|
5264
5755
|
flagPriority;
|
|
5265
|
-
constructor(cdRef, coreService, i18n, feedBackService, dialog, sidenavService) {
|
|
5756
|
+
constructor(cdRef, coreService, i18n, feedBackService, dialog, sidenavService, toasterService) {
|
|
5266
5757
|
this.cdRef = cdRef;
|
|
5267
5758
|
this.coreService = coreService;
|
|
5268
5759
|
this.i18n = i18n;
|
|
5269
5760
|
this.feedBackService = feedBackService;
|
|
5270
5761
|
this.dialog = dialog;
|
|
5271
5762
|
this.sidenavService = sidenavService;
|
|
5763
|
+
this.toasterService = toasterService;
|
|
5272
5764
|
}
|
|
5765
|
+
/**
|
|
5766
|
+
* Executes after the view has been fully initialized.
|
|
5767
|
+
*
|
|
5768
|
+
* @return {void}
|
|
5769
|
+
*/
|
|
5273
5770
|
ngAfterViewInit() {
|
|
5274
|
-
this.getApprovalHistory();
|
|
5275
|
-
|
|
5276
|
-
|
|
5771
|
+
this.getApprovalHistory(this.approvalHistory);
|
|
5772
|
+
if (this.form?.header?.creationDate) {
|
|
5773
|
+
this.creationDate = format(new Date(this.form?.header?.creationDate), "dd/MM/yyyy hh:mm:ss");
|
|
5774
|
+
}
|
|
5277
5775
|
this.cdRef.detectChanges();
|
|
5278
5776
|
}
|
|
5777
|
+
/**
|
|
5778
|
+
* Handles the click event on the comments form.
|
|
5779
|
+
* Retrieves comments from the form, transforms them, and updates activities in the core service.
|
|
5780
|
+
* Finally, publishes an 'open' event to the sidenav service to open the ActivitiesComponent.
|
|
5781
|
+
*
|
|
5782
|
+
* @return {void}
|
|
5783
|
+
*/
|
|
5279
5784
|
onCommentsFormClick() {
|
|
5280
|
-
const
|
|
5281
|
-
const
|
|
5282
|
-
for (const
|
|
5283
|
-
|
|
5284
|
-
/*const obj =
|
|
5285
|
-
{
|
|
5286
|
-
name: item['employeeName'],
|
|
5287
|
-
title: item.jobPosition,
|
|
5288
|
-
image: item['profilePicture'],
|
|
5289
|
-
date: moment(item['commentDate']).locale('en-US').format('YYYY-MM-DD'),
|
|
5290
|
-
time: moment(item['commentDate']).locale('en-US').format('h:mm a'),
|
|
5291
|
-
comment: item['commentBody'],
|
|
5292
|
-
attachments: item['attachment']
|
|
5293
|
-
};*/
|
|
5294
|
-
const obj = {
|
|
5295
|
-
name: item['employeeName'],
|
|
5296
|
-
title: item.jobPosition,
|
|
5297
|
-
image: item['profilePicture'],
|
|
5298
|
-
date: format(new Date(item['commentDate']), 'yyyy-MM-dd'),
|
|
5299
|
-
time: format(new Date(item['commentDate']), 'h:mm a'),
|
|
5300
|
-
comment: item['commentBody'],
|
|
5301
|
-
attachments: item['attachment']
|
|
5302
|
-
};
|
|
5303
|
-
resultData.push(obj);
|
|
5785
|
+
const formComments = this.form.commentsDrop;
|
|
5786
|
+
const transformedComments = [];
|
|
5787
|
+
for (const comment of formComments) {
|
|
5788
|
+
transformedComments.push(this.transformCommentItem(comment));
|
|
5304
5789
|
}
|
|
5305
|
-
this.coreService.activities =
|
|
5790
|
+
this.coreService.activities = transformedComments;
|
|
5306
5791
|
this.sidenavService.publish('open', ActivitiesComponent);
|
|
5307
5792
|
}
|
|
5793
|
+
/**
|
|
5794
|
+
* Transforms a comment item into a different format for display.
|
|
5795
|
+
*
|
|
5796
|
+
* @param {Object} item - The original comment item to transform.
|
|
5797
|
+
* @return {Object} - The transformed comment item with specific properties including name, title, image, date, time, comment, and attachments.
|
|
5798
|
+
*/
|
|
5799
|
+
transformCommentItem(item) {
|
|
5800
|
+
return {
|
|
5801
|
+
name: item['employeeName'],
|
|
5802
|
+
title: item.jobPosition,
|
|
5803
|
+
image: item['profilePicture'],
|
|
5804
|
+
date: format(new Date(item['commentDate']), 'yyyy-MM-dd'),
|
|
5805
|
+
time: format(new Date(item['commentDate']), 'h:mm a'),
|
|
5806
|
+
comment: item['commentBody'],
|
|
5807
|
+
attachments: item['attachment']
|
|
5808
|
+
};
|
|
5809
|
+
}
|
|
5810
|
+
/**
|
|
5811
|
+
* Opens a dialog for providing feedback.
|
|
5812
|
+
*
|
|
5813
|
+
* @return {void}
|
|
5814
|
+
*/
|
|
5308
5815
|
feedback() {
|
|
5309
5816
|
this.dialog.open(FeedbackSectionComponent, {
|
|
5310
5817
|
panelClass: ['main-popup'],
|
|
@@ -5315,60 +5822,123 @@ class ServiceHeaderComponent {
|
|
|
5315
5822
|
}
|
|
5316
5823
|
});
|
|
5317
5824
|
}
|
|
5825
|
+
/**
|
|
5826
|
+
* Updates the sidenav with user profile information if not already loading.
|
|
5827
|
+
*
|
|
5828
|
+
* @return {void}
|
|
5829
|
+
*/
|
|
5318
5830
|
showUserInfo() {
|
|
5319
5831
|
if (!this.isLoading) {
|
|
5320
5832
|
this.sidenavService.data = this.form?.profileInfoDrop;
|
|
5321
5833
|
this.sidenavService.publish('open', ProfileSectionComponent);
|
|
5322
5834
|
}
|
|
5323
5835
|
}
|
|
5836
|
+
/**
|
|
5837
|
+
* Set the priority flag for the inbox item with the provided ID.
|
|
5838
|
+
*
|
|
5839
|
+
* @param {string} id - The ID of the priority flag to be set for the inbox item.
|
|
5840
|
+
* @return {void}
|
|
5841
|
+
*/
|
|
5324
5842
|
setFlagPriority(id) {
|
|
5325
5843
|
this.flagPriority = id;
|
|
5326
5844
|
this.form.inboxItem.flagPriority = id;
|
|
5327
|
-
|
|
5328
|
-
|
|
5329
|
-
|
|
5330
|
-
|
|
5331
|
-
|
|
5332
|
-
|
|
5333
|
-
|
|
5334
|
-
|
|
5335
|
-
|
|
5336
|
-
|
|
5337
|
-
|
|
5338
|
-
|
|
5339
|
-
return 'danger';
|
|
5340
|
-
}
|
|
5341
|
-
else if (status === FORM_STATUS_PENDING || status?.toLowerCase() === 'pending') {
|
|
5342
|
-
return 'warning';
|
|
5343
|
-
}
|
|
5344
|
-
else {
|
|
5345
|
-
return 'success';
|
|
5845
|
+
this.subscribeToSetFlagPriority(id);
|
|
5846
|
+
}
|
|
5847
|
+
/**
|
|
5848
|
+
* Subscribe to set flag priority for a specific identifier.
|
|
5849
|
+
*
|
|
5850
|
+
* @param {string} id - The identifier of the flag to set priority for.
|
|
5851
|
+
* @return {void}
|
|
5852
|
+
*/
|
|
5853
|
+
subscribeToSetFlagPriority(id) {
|
|
5854
|
+
this.coreService.setFlagPriority(id).subscribe((response) => {
|
|
5855
|
+
if (response) {
|
|
5856
|
+
this.toasterService.success(this.i18n.translate('flagStatusUpdated'));
|
|
5346
5857
|
}
|
|
5347
|
-
}
|
|
5348
|
-
else {
|
|
5349
|
-
return 'success';
|
|
5350
|
-
}
|
|
5858
|
+
});
|
|
5351
5859
|
}
|
|
5860
|
+
/**
|
|
5861
|
+
* Returns the CSS class associated with the input status.
|
|
5862
|
+
*
|
|
5863
|
+
* @param {string} status - The status for which the CSS class is needed.
|
|
5864
|
+
* @return {string} - The CSS class corresponding to the given status.
|
|
5865
|
+
*/
|
|
5866
|
+
statusClass(status) {
|
|
5867
|
+
// status = status ? status.toLowerCase() : '';
|
|
5868
|
+
let statusStrategy = StatusMap$1[status] || StatusMap$1['default'];
|
|
5869
|
+
return statusStrategy.class;
|
|
5870
|
+
}
|
|
5871
|
+
/**
|
|
5872
|
+
* Opens the FAQ side navigation.
|
|
5873
|
+
* @return {void}
|
|
5874
|
+
*/
|
|
5352
5875
|
openFaq() {
|
|
5353
|
-
this.sidenavService.publish('open', FaqSidenavComponent, 'end', 'over', this.
|
|
5354
|
-
}
|
|
5355
|
-
|
|
5356
|
-
|
|
5876
|
+
this.sidenavService.publish('open', FaqSidenavComponent, 'end', 'over', this.serviceFaq);
|
|
5877
|
+
}
|
|
5878
|
+
/**
|
|
5879
|
+
* Retrieves approval history information for each approval item in the provided array.
|
|
5880
|
+
*
|
|
5881
|
+
* @param {ApprovalHistoryItem[]} approvalHistory - The array containing approval history items.
|
|
5882
|
+
*
|
|
5883
|
+
* @return {void} - This method does not return any value. It updates the internal 'approvals' array.
|
|
5884
|
+
*/
|
|
5885
|
+
getApprovalHistory(approvalHistory) {
|
|
5886
|
+
approvalHistory?.forEach((approvalItem, index) => {
|
|
5887
|
+
let approvalStatus = this.getApprovalStatus(index);
|
|
5888
|
+
let approvalStatusLabel = this.getApprovalStatusLabel(index);
|
|
5357
5889
|
const obj = {
|
|
5358
5890
|
id: index + 1,
|
|
5359
|
-
name:
|
|
5360
|
-
title:
|
|
5361
|
-
image:
|
|
5362
|
-
status:
|
|
5363
|
-
statusLabel:
|
|
5891
|
+
name: approvalItem.approver.personName,
|
|
5892
|
+
title: approvalItem.positionType,
|
|
5893
|
+
image: this.getImageUrl(approvalItem.approver.personEmail),
|
|
5894
|
+
status: approvalStatus,
|
|
5895
|
+
statusLabel: approvalStatusLabel,
|
|
5364
5896
|
};
|
|
5365
5897
|
this.approvals.push(obj);
|
|
5366
5898
|
});
|
|
5367
5899
|
}
|
|
5368
|
-
|
|
5369
|
-
|
|
5900
|
+
/**
|
|
5901
|
+
* Retrieves the approval status for a specific section in the form.
|
|
5902
|
+
*
|
|
5903
|
+
* @param {number} index - The index of the section for which the approval status is required.
|
|
5904
|
+
* @return {string} The approval status of the specified section. Returns an empty string if the section does not exist.
|
|
5905
|
+
*/
|
|
5906
|
+
getApprovalStatus(index) {
|
|
5907
|
+
let status = '';
|
|
5908
|
+
if (this.form.sections[index + 1]) {
|
|
5909
|
+
status = this.statusClass(this.form.sections[index + 1].body.details.decision.key);
|
|
5910
|
+
}
|
|
5911
|
+
return status;
|
|
5912
|
+
}
|
|
5913
|
+
/**
|
|
5914
|
+
* Retrieves the approval status label from the form section based on the given index.
|
|
5915
|
+
*
|
|
5916
|
+
* @param {number} index - The index of the form section for which the approval status label will be retrieved.
|
|
5917
|
+
* @return {string} The approval status label retrieved from the specified form section.
|
|
5918
|
+
*/
|
|
5919
|
+
getApprovalStatusLabel(index) {
|
|
5920
|
+
let statusLabel = '';
|
|
5921
|
+
if (this.form.sections[index + 1]) {
|
|
5922
|
+
statusLabel = this.form.sections[index + 1].body.details.decision.value;
|
|
5923
|
+
}
|
|
5924
|
+
return statusLabel;
|
|
5925
|
+
}
|
|
5926
|
+
/**
|
|
5927
|
+
* Retrieves the URL of the user's portrait image based on the provided email.
|
|
5928
|
+
*
|
|
5929
|
+
* @param {string} email - The email address of the user for whom the portrait URL is to be retrieved.
|
|
5930
|
+
* @return {string} - The URL used to fetch the user's portrait image.
|
|
5931
|
+
*/
|
|
5932
|
+
getImageUrl(email) {
|
|
5933
|
+
return '/group/i-gate/wm-bpm/forms/-/proxy/portrait?email=' + email;
|
|
5934
|
+
}
|
|
5935
|
+
showPreviousRequests() {
|
|
5936
|
+
this.sidenavService.publish('open', PreviousRequestsComponent);
|
|
5937
|
+
}
|
|
5938
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: ServiceHeaderComponent, deps: [{ token: i0.ChangeDetectorRef }, { token: CoreService }, { token: CoreI18nService }, { token: FeedBackService }, { token: i1$1.MatDialog }, { token: SidenavService }, { token: i3$2.ToastrService }], target: i0.ɵɵFactoryTarget.Component });
|
|
5939
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: ServiceHeaderComponent, isStandalone: true, selector: "core-service-header", inputs: { form: "form", showHistory: "showHistory", isLoading: "isLoading", showApprovalHistory: "showApprovalHistory", approvalHistory: "approvalHistory", creationDate: "creationDate", formTitle: "formTitle", section: "section", serviceFaq: "serviceFaq" }, providers: [FeedBackService,
|
|
5370
5940
|
{ provide: MAT_DIALOG_DATA, useValue: {} },
|
|
5371
|
-
], ngImport: i0, template: "<ng-container *ngIf=\"!(form?.header?.status?.['key'] === 'NEW')\">\r\n <div class=\"d-flex align-items-center justify-content-end gap-2 my-2\" *ngIf=\"!(form?.header?.status?.['key'] === 'NEW')\">\r\n\r\n <!-- flag-->\r\n <ds-button\r\n *ngIf=\"form?.inboxItem && !form.sections[form.sections.length -1].header.readOnly && !isLoading\"\r\n square\r\n icon\r\n size=\"small\"\r\n [matMenuTriggerFor]=\"menu\"\r\n class=\"icon-btn-shadow\">\r\n <ds-icon\r\n [ngClass]=\"{'fc-purple' : (flagPriority === '0' || flagPriority === null),'fc-yellow' : flagPriority === '1','fc-green' : flagPriority === '2','fc-coral' : flagPriority === '3'}\"\r\n icon=\"flag-o\" class=\"fs-20 fs-md-17 fc-purple\">\r\n </ds-icon>\r\n </ds-button>\r\n <mat-menu #menu=\"matMenu\" panelClass=\"action-menu\">\r\n <button mat-menu-item (click)=\"setFlagPriority('0')\">\r\n <ds-icon icon=\"flag-o\" class=\"fc-purple fs-20 fs-md-17\"></ds-icon>\r\n </button>\r\n <button mat-menu-item (click)=\"setFlagPriority('1')\">\r\n <ds-icon icon=\"flag-o\" class=\"fc-yellow fs-20 fs-md-17\"></ds-icon>\r\n </button>\r\n <button mat-menu-item (click)=\"setFlagPriority('2')\">\r\n <ds-icon icon=\"flag-o\" class=\"fc-green fs-20 fs-md-17\"></ds-icon>\r\n </button>\r\n <button mat-menu-item (click)=\"setFlagPriority('3')\">\r\n <ds-icon icon=\"flag-o\" class=\"fc-coral fs-20 fs-md-17\"></ds-icon>\r\n </button>\r\n </mat-menu>\r\n\r\n <!-- print-->\r\n <ng-content></ng-content>\r\n </div>\r\n\r\n <header class=\"service-header bc-white p-3 p-sm-4 py-4 gap-3 {{statusClass(form?.header?.status?.['key'])}}\">\r\n\r\n <div class=\"service-header-icon\">\r\n <img\r\n alt=\"\"\r\n src=\"data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMzAiIGhlaWdodD0iMjkiIHZpZXdCb3g9IjAgMCAzMCAyOSIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZD0iTTI1LjEgMEg0LjlDMi4yIDAgMCAyLjIgMCA0LjlWMjguNkgyNS4xQzI3LjggMjguNiAzMCAyNi40IDMwIDIzLjdWNC45QzMwIDIuMiAyNy44IDAgMjUuMSAwWk0yIDQuOUMyIDMuMyAzLjMgMiA0LjkgMkgyNS4xQzI2LjcgMiAyOCAzLjMgMjggNC45VjIzLjdDMjggMjUuMyAyNi43IDI2LjYgMjUuMSAyNi42SDJWNC45Wk0xMS41IDYuM0M3LjEgNi4zIDMuNSA5LjkgMy41IDE0LjNDMy41IDE4LjcgNy4xIDIyLjMgMTEuNSAyMi4zQzE1LjkgMjIuMyAxOS41IDE4LjcgMTkuNSAxNC4zQzE5LjUgOS45IDE1LjkgNi4zIDExLjUgNi4zWk0xNS4xIDE5QzE0LjEgMTkuOCAxMi44IDIwLjIgMTEuNSAyMC4yQzEwLjIgMjAuMiA4LjkgMTkuOCA3LjkgMTlDOC43IDE3LjcgMTAgMTcgMTEuNSAxN0MxMyAxNyAxNC40IDE3LjggMTUuMSAxOVpNMTMuMSAxMy40QzEzLjEgMTQuMyAxMi40IDE1IDExLjUgMTVDMTAuNiAxNSA5LjkgMTQuMyA5LjkgMTMuNEM5LjkgMTIuNSAxMC42IDExLjggMTEuNSAxMS44QzEyLjQgMTEuOCAxMy4xIDEyLjUgMTMuMSAxMy40Wk0xNS4xIDEzLjRDMTUuMSAxMS40IDEzLjUgOS44IDExLjUgOS44QzkuNSA5LjggNy45IDExLjQgNy45IDEzLjRDNy45IDE0LjIgOC4yIDE1IDguNyAxNS43QzcuOCAxNi4xIDcuMSAxNi44IDYuNSAxNy42QzUuOCAxNi42IDUuNSAxNS41IDUuNSAxNC4zQzUuNSAxMSA4LjIgOC4zIDExLjUgOC4zQzE0LjggOC4zIDE3LjUgMTEgMTcuNSAxNC4zQzE3LjUgMTUuNSAxNy4yIDE2LjYgMTYuNSAxNy42QzE1LjkgMTYuOCAxNS4yIDE2LjIgMTQuMyAxNS43QzE0LjggMTUuMSAxNS4xIDE0LjIgMTUuMSAxMy40Wk0yMSA5LjFDMjEgOC42IDIxLjQgOC4xIDIyIDguMUgyNS41QzI2IDguMSAyNi41IDguNSAyNi41IDkuMUMyNi41IDkuNiAyNi4xIDEwLjEgMjUuNSAxMC4xSDIyQzIxLjQgMTAuMSAyMSA5LjYgMjEgOS4xWk0yMSAxMi41QzIxIDEyIDIxLjQgMTEuNSAyMiAxMS41SDI1LjVDMjYgMTEuNSAyNi41IDExLjkgMjYuNSAxMi41QzI2LjUgMTMgMjYuMSAxMy41IDI1LjUgMTMuNUgyMkMyMS40IDEzLjUgMjEgMTMuMSAyMSAxMi41Wk0yMSAxNkMyMSAxNS41IDIxLjQgMTUgMjIgMTVIMjUuNUMyNiAxNSAyNi41IDE1LjQgMjYuNSAxNkMyNi41IDE2LjUgMjYuMSAxNyAyNS41IDE3SDIyQzIxLjQgMTcgMjEgMTYuNiAyMSAxNlpNMjUuNSAyMC41SDIyQzIxLjUgMjAuNSAyMSAyMC4xIDIxIDE5LjVDMjEgMTguOSAyMS40IDE4LjUgMjIgMTguNUgyNS41QzI2IDE4LjUgMjYuNSAxOC45IDI2LjUgMTkuNUMyNi41IDIwLjEgMjYuMSAyMC41IDI1LjUgMjAuNVoiIGZpbGw9IiNGRjM3NUUiLz4KPC9zdmc+Cg==\"/>\r\n </div>\r\n\r\n <div class=\"flex-grow-1 d-flex flex-column flex-sm-row align-items-sm-center gap-2\">\r\n <div class=\"flex-grow-1\">\r\n <!-- title-->\r\n <h1 class=\"fs-20 fs-md-16 fw-bold fc-black header-title m-0\">{{ formTitle }}\r\n <ds-icon\r\n icon=\"info\" class=\"fs-22 fc-dark-gray cursor-pointer\" *ngIf=\"serviceBrief.length\"\r\n (click)=\"openFaq()\"></ds-icon>\r\n </h1>\r\n <div\r\n class=\"header-user d-flex align-items-sm-center gap-2 mt-sm-1\"\r\n *ngIf=\"form?.header?.status?.['key'] !== 'NEW' || isLoading\">\r\n <ds-avatar\r\n *ngIf=\"!isLoading\" image=\"{{form?.header?.requesterPhoto}}\" size=\"xx-small\"\r\n class=\"d-inline-flex cursor-pointer\" (click)=\"showUserInfo()\"></ds-avatar>\r\n <span\r\n class=\"fs-12 text-truncate d-sm-block cursor-pointer\" (click)=\"showUserInfo()\"\r\n [ngClass]=\"{'loading-bg loading-width': isLoading}\">{{ coreService.getShortName(form?.header?.requesterName) }}</span>\r\n <mat-divider class=\"divider circle mx-2 d-none d-sm-block\"></mat-divider>\r\n <span class=\"fs-12\" [ngClass]=\"{'loading-bg loading-width': isLoading}\">{{ form?.header?.formId }}</span>\r\n <mat-divider *ngIf=\"creationDate\" class=\"divider circle mx-2 d-none d-sm-block\"></mat-divider>\r\n <span *ngIf=\"creationDate\" class=\"fs-14\" [ngClass]=\"{'loading-bg loading-width': isLoading}\">{{ creationDate }}</span>\r\n </div>\r\n </div>\r\n <!-- header-actions-->\r\n <div\r\n class=\"header-actions d-flex flex-row flex-sm-column justify-content-between justify-content-sm-center gap-2 mt-2 mt-sm-0\"\r\n *ngIf=\"!(form?.header?.status?.['key'] === 'NEW')\">\r\n <ds-status\r\n *ngIf=\"form?.header?.status?.['key'] !== 'NEW' && !isLoading\"\r\n status=\"{{statusClass(form?.header?.status?.['key'])}}\" class=\"header-status\">{{ form?.header?.status?.['value'] }}\r\n </ds-status>\r\n\r\n <div class=\"d-flex align-items-center justify-content-end gap-2\">\r\n <!-- feedback-->\r\n<!-- *ngIf=\"form?.inboxItem && (form?.inboxItem?.canRequestFeedback ==='true'|| form?.inboxItem?.hasFeedback==='true') && !isLoading\"-->\r\n <!-- <ds-button\r\n square icon size=\"small\" (click)=\"feedback()\">\r\n <ds-icon\r\n icon=\"chat-o\" class=\"fs-20 fs-md-17 fc-coral\"\r\n [ngClass]=\"{'fc-green':feedBackIcon === 'feedbackResponded' , 'fc-red': feedBackIcon === 'respondToFeedback' , 'fc-yellow': feedBackIcon === 'waitingFeedback'}\">\r\n </ds-icon>\r\n </ds-button>-->\r\n <ds-button\r\n *ngIf=\"form?.commentsDrop?.length > 0 && !isLoading\" square icon size=\"small\"\r\n (click)=\"onCommentsFormClick()\" class=\"has-comments\">\r\n <ds-icon icon=\"clock\" class=\"fc-coral fs-20 fs-md-17\"></ds-icon>\r\n </ds-button>\r\n <ng-container *ngIf=\"showApprovalHistory\">\r\n <ds-button\r\n color=\"white\" shape=\"text\" square size=\"small\" [satPopoverAnchor]=\"workflow\"\r\n #workflowAnchor=\"satPopoverAnchor\" (click)=\"workflowAnchor.popover.open()\">\r\n <slot name=\"prefix\">\r\n <ds-icon icon=\"workflow\" class=\"fs-24\"></ds-icon>\r\n </slot>\r\n </ds-button>\r\n\r\n <sat-popover\r\n #workflow [anchor]=\"workflowAnchor\" [hasBackdrop]=\"true\" verticalAlign=\"below\"\r\n horizontalAlign=\"end\">\r\n <div class=\"default-popover p-3\" style=\"min-width: 330px;\">\r\n <ds-approvals *ngIf=\"approvalHistory\" class=\"popover-approvals\" approvalsData=\"{{approvals}}\">\r\n </ds-approvals>\r\n </div>\r\n </sat-popover>\r\n </ng-container>\r\n </div>\r\n </div>\r\n </div>\r\n\r\n </header>\r\n</ng-container>\r\n<header\r\n class=\"mb-4 mt-4 d-flex align-items-center justify-content-between align-items-end gap-2\"\r\n *ngIf=\"(form?.header?.status?.['key'] === 'NEW')\">\r\n <section>\r\n <h6 class=\"fs-14 fs-md-12 fw-normal fc-dark-gray mb-0\">\r\n {{ i18n.translate('Hello') }}\r\n {{ coreService.getShortName(form?.header?.requesterName) }}, {{ i18n.translate('welcomeBack') }}!\r\n </h6>\r\n <h1 class=\"fs-26 fs-md-20 fw-bold fc-black d-flex align-items-center gap-2 mb-1\">\r\n {{ formTitle }}\r\n <ds-icon icon=\"info\" class=\"fs-22 fc-dark-gray cursor-pointer\" *ngIf=\"serviceBrief.length\" (click)=\"openFaq()\">\r\n </ds-icon>\r\n </h1>\r\n </section>\r\n\r\n</header>\r\n", styles: [":host ::ng-deep .filter-section .select-form-field{--input-bg: var(--white);--input-border: var(--white);--placeholder-fc: var(--black);--input-width: 85px;--input-fs: .75rem;--placeholder-fs: .75rem;--label-fs: .75rem;--label-fw: var(--font-regular);--input-height: var(--default-size-sm);font-size:var(--label-fs);box-shadow:var(--box-shadow)}:host ::ng-deep ds-button::part(base){--default-size-sm: 30px;--btn-radius: 3px}@media (max-width: 576px){:host ::ng-deep ds-button::part(base){--default-size-sm: 25px}}:host ::ng-deep .loading-width{min-width:100px;width:40px;flex-grow:1}:host ::ng-deep ds-avatar::part(base){--default-size: 20px}:host ::ng-deep .service-header{--service-header-icon-size: var(--default-size-lg);--header-border-color: var(--coral);display:flex;align-items:flex-start;border-top:5px solid var(--header-border-color);box-shadow:0 7px 10px rgba(var(--rgb-black),3%)}@media (max-width: 576px){:host ::ng-deep .service-header{border-radius:3px 3px 0 0}}:host ::ng-deep .service-header.loading{--header-border-color: var(--off-white)}:host ::ng-deep .service-header.warning{--header-border-color: var(--yellow)}:host ::ng-deep .service-header.success{--header-border-color: var(--green)}:host ::ng-deep .service-header.danger{--header-border-color: var(--red)}@media (max-width: 576px){:host ::ng-deep .service-header{--service-header-icon-size: var(--default-size-sm)}}:host ::ng-deep .service-header .service-header-icon{min-width:var(--service-header-icon-size);width:var(--service-header-icon-size);height:var(--service-header-icon-size);display:inline-flex;align-items:center;justify-content:center;padding:.75rem;border-radius:6px 6px 6px 0;background-color:rgba(var(--rgb-coral),.1)}@media (max-width: 576px){:host ::ng-deep .service-header .service-header-icon{padding:.5rem}}:host ::ng-deep .service-header .header-title{text-align:start}:host ::ng-deep .service-header .divider.circle{min-width:5px;width:5px;min-height:5px;height:5px;border-radius:50%;background-color:var(--dark-gray)}:host ::ng-deep .service-header .header-actions{align-items:flex-end;justify-content:flex-end}:host ::ng-deep .service-header .header-actions .has-comments{position:relative}:host ::ng-deep .service-header .header-actions .has-comments:before{content:\"\";min-width:8px;height:8px;border-radius:50%;background-color:var(--coral);position:absolute;top:-3px;right:-3px;z-index:1}[dir=rtl] :host ::ng-deep .service-header .header-actions .has-comments:before{right:auto;left:-3px}:host ::ng-deep .service-header .header-actions ds-button::part(base){--btn-color: var(--coral);--btn-bg-color: var(--light-gray);--btn-border-color: var(--light-gray)}:host ::ng-deep .service-header .header-user{color:var(--dark-gray)}:host ::ng-deep .history-button::part(base){background-color:var(--white);--btn-height: var(--default-size-sm);--btn-shadow: 0 7px 10px rgba(var(--rgb-black), 3%)}@media (max-width: 576px){:host ::ng-deep .history-button::part(base){--btn-height: 35px;--btn-width: 35px}}@media (max-width: 576px){:host ::ng-deep .history-button::part(label){display:none}}\n"], dependencies: [{ kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: SatPopoverModule }, { kind: "component", type: i1$3.SatPopoverComponent, selector: "sat-popover", inputs: ["anchor", "horizontalAlign", "xAlign", "verticalAlign", "yAlign", "forceAlignment", "lockAlignment", "autoFocus", "restoreFocus", "scrollStrategy", "hasBackdrop", "interactiveClose", "openTransition", "closeTransition", "openAnimationStartAtScale", "closeAnimationEndAtScale", "backdropClass", "panelClass"], outputs: ["opened", "closed", "afterOpen", "afterClose", "backdropClicked", "overlayKeydown"] }, { kind: "directive", type: i1$3.SatPopoverAnchorDirective, selector: "[satPopoverAnchor]", inputs: ["satPopoverAnchor"], exportAs: ["satPopoverAnchor"] }, { kind: "component", type: MatDivider, selector: "mat-divider", inputs: ["vertical", "inset"] }, { kind: "directive", type: MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", inputs: ["mat-menu-trigger-for", "matMenuTriggerFor", "matMenuTriggerData", "matMenuTriggerRestoreFocus"], outputs: ["menuOpened", "onMenuOpen", "menuClosed", "onMenuClose"], exportAs: ["matMenuTrigger"] }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: MatMenu, selector: "mat-menu", inputs: ["backdropClass", "aria-label", "aria-labelledby", "aria-describedby", "xPosition", "yPosition", "overlapTrigger", "hasBackdrop", "class", "classList"], outputs: ["closed", "close"], exportAs: ["matMenu"] }, { kind: "component", type: MatMenuItem, selector: "[mat-menu-item]", inputs: ["role", "disabled", "disableRipple"], exportAs: ["matMenuItem"] }] });
|
|
5941
|
+
], ngImport: i0, template: "@if (form?.header?.status?.['key'] === 'NEW') {\r\n <section\r\n class=\"main-sidenav main-sidenav-full mb-4\"\r\n\r\n >\r\n <div class=\"sidenav-title\">\r\n <div class=\"d-flex align-items-center gap-3 w-100\">\r\n <!-- <ds-button icon class=\"rotate-arrow\" size=\"small\" (click)=\"goBack()\" *ngIf=\"!isInMobileApp() && showBack\">\r\n <ds-icon icon=\"arrow-right\" class=\"fs-19 fc-black\"></ds-icon>\r\n </ds-button>-->\r\n\r\n <!-- <h3 class=\"flex-grow-0\">\r\n {{ formTitle }}\r\n </h3>-->\r\n\r\n <section>\r\n <h6 class=\"fs-14 fs-md-12 fw-normal fc-dark-gray mb-0\">\r\n {{ i18n.translate('Hello') }}\r\n {{ coreService.getShortName(form?.header?.requesterName) }}, {{ i18n.translate('welcomeBack') }}!\r\n </h6>\r\n <h1 class=\"fs-26 fs-md-20 fw-bold fc-black d-flex align-items-center gap-2 mb-1\">\r\n {{ formTitle }}\r\n @if (serviceFaq.length) {\r\n <ds-icon icon=\"info\" class=\"fs-22 fc-dark-gray cursor-pointer\" (click)=\"openFaq()\">\r\n </ds-icon>\r\n }\r\n </h1>\r\n </section>\r\n <div class=\"d-flex align-items-center justify-content-end gap-2 flex-grow-1\">\r\n @if (serviceFaq.length) {\r\n <ds-button size=\"small\" icon>\r\n <ds-icon icon=\"info\" class=\"fs-22 fc-dark-gray cursor-pointer\" (click)=\"openFaq()\">\r\n </ds-icon>\r\n </ds-button>\r\n }\r\n <!-- <ds-button size=\"small\" icon (click)=\"openWorkflow()\">\r\n <ds-icon icon=\"bell-2-o\" class=\"fs-20 fc-coral\"></ds-icon>\r\n </ds-button> -->\r\n <ds-button size=\"small\" icon (click)=\"showPreviousRequests()\" >\r\n <ds-icon icon=\"clock\" class=\"fs-20 fc-coral\"></ds-icon>\r\n </ds-button>\r\n </div>\r\n </div>\r\n </div>\r\n </section>\r\n\r\n <!-- <header class=\"mb-4 mt-4 d-flex align-items-center justify-content-between align-items-end gap-2\">\r\n <section>\r\n <h6 class=\"fs-14 fs-md-12 fw-normal fc-dark-gray mb-0\">\r\n {{ i18n.translate('Hello') }}\r\n {{ coreService.getShortName(form?.header?.requesterName) }}, {{ i18n.translate('welcomeBack') }}!\r\n </h6>\r\n <h1 class=\"fs-26 fs-md-20 fw-bold fc-black d-flex align-items-center gap-2 mb-1\">\r\n {{ formTitle }}\r\n @if (serviceFaq.length) {\r\n <ds-icon icon=\"info\" class=\"fs-22 fc-dark-gray cursor-pointer\" (click)=\"openFaq()\">\r\n </ds-icon>\r\n }\r\n </h1>\r\n </section>\r\n </header>-->\r\n} @else {\r\n\r\n <div class=\"w-100\">\r\n <section class=\"request-main-info {{statusClass(form?.header?.status?.['key'])}}\">\r\n <section class=\"request-info\">\r\n <div class=\"request-info--body\">\r\n <div class=\"d-flex align-items-center gap-2 flex-grow-1\">\r\n <img\r\n alt=\"\"\r\n src=\"data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMzAiIGhlaWdodD0iMjkiIHZpZXdCb3g9IjAgMCAzMCAyOSIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZD0iTTI1LjEgMEg0LjlDMi4yIDAgMCAyLjIgMCA0LjlWMjguNkgyNS4xQzI3LjggMjguNiAzMCAyNi40IDMwIDIzLjdWNC45QzMwIDIuMiAyNy44IDAgMjUuMSAwWk0yIDQuOUMyIDMuMyAzLjMgMiA0LjkgMkgyNS4xQzI2LjcgMiAyOCAzLjMgMjggNC45VjIzLjdDMjggMjUuMyAyNi43IDI2LjYgMjUuMSAyNi42SDJWNC45Wk0xMS41IDYuM0M3LjEgNi4zIDMuNSA5LjkgMy41IDE0LjNDMy41IDE4LjcgNy4xIDIyLjMgMTEuNSAyMi4zQzE1LjkgMjIuMyAxOS41IDE4LjcgMTkuNSAxNC4zQzE5LjUgOS45IDE1LjkgNi4zIDExLjUgNi4zWk0xNS4xIDE5QzE0LjEgMTkuOCAxMi44IDIwLjIgMTEuNSAyMC4yQzEwLjIgMjAuMiA4LjkgMTkuOCA3LjkgMTlDOC43IDE3LjcgMTAgMTcgMTEuNSAxN0MxMyAxNyAxNC40IDE3LjggMTUuMSAxOVpNMTMuMSAxMy40QzEzLjEgMTQuMyAxMi40IDE1IDExLjUgMTVDMTAuNiAxNSA5LjkgMTQuMyA5LjkgMTMuNEM5LjkgMTIuNSAxMC42IDExLjggMTEuNSAxMS44QzEyLjQgMTEuOCAxMy4xIDEyLjUgMTMuMSAxMy40Wk0xNS4xIDEzLjRDMTUuMSAxMS40IDEzLjUgOS44IDExLjUgOS44QzkuNSA5LjggNy45IDExLjQgNy45IDEzLjRDNy45IDE0LjIgOC4yIDE1IDguNyAxNS43QzcuOCAxNi4xIDcuMSAxNi44IDYuNSAxNy42QzUuOCAxNi42IDUuNSAxNS41IDUuNSAxNC4zQzUuNSAxMSA4LjIgOC4zIDExLjUgOC4zQzE0LjggOC4zIDE3LjUgMTEgMTcuNSAxNC4zQzE3LjUgMTUuNSAxNy4yIDE2LjYgMTYuNSAxNy42QzE1LjkgMTYuOCAxNS4yIDE2LjIgMTQuMyAxNS43QzE0LjggMTUuMSAxNS4xIDE0LjIgMTUuMSAxMy40Wk0yMSA5LjFDMjEgOC42IDIxLjQgOC4xIDIyIDguMUgyNS41QzI2IDguMSAyNi41IDguNSAyNi41IDkuMUMyNi41IDkuNiAyNi4xIDEwLjEgMjUuNSAxMC4xSDIyQzIxLjQgMTAuMSAyMSA5LjYgMjEgOS4xWk0yMSAxMi41QzIxIDEyIDIxLjQgMTEuNSAyMiAxMS41SDI1LjVDMjYgMTEuNSAyNi41IDExLjkgMjYuNSAxMi41QzI2LjUgMTMgMjYuMSAxMy41IDI1LjUgMTMuNUgyMkMyMS40IDEzLjUgMjEgMTMuMSAyMSAxMi41Wk0yMSAxNkMyMSAxNS41IDIxLjQgMTUgMjIgMTVIMjUuNUMyNiAxNSAyNi41IDE1LjQgMjYuNSAxNkMyNi41IDE2LjUgMjYuMSAxNyAyNS41IDE3SDIyQzIxLjQgMTcgMjEgMTYuNiAyMSAxNlpNMjUuNSAyMC41SDIyQzIxLjUgMjAuNSAyMSAyMC4xIDIxIDE5LjVDMjEgMTguOSAyMS40IDE4LjUgMjIgMTguNUgyNS41QzI2IDE4LjUgMjYuNSAxOC45IDI2LjUgMTkuNUMyNi41IDIwLjEgMjYuMSAyMC41IDI1LjUgMjAuNVoiIGZpbGw9IiNGRjM3NUUiLz4KPC9zdmc+Cg==\"/>\r\n <h4 class=\"fs-22 fs-md-16 fc-black fw-medium mb-0 flex-grow-1 line-height-1-2\">\r\n {{ formTitle }}\r\n </h4>\r\n </div>\r\n <div class=\"d-flex align-items-center gap-2 request-info--status-action\">\r\n <div class=\"d-inline-flex flex-column align-items-end\">\r\n @if (!isLoading) {\r\n <ds-status\r\n status=\"{{statusClass(form?.header?.status?.['key'])}}\" class=\"header-status\">{{ form?.header?.status?.['value'] }}\r\n </ds-status>\r\n }\r\n </div>\r\n <div class=\"d-flex align-items-center gap-2\">\r\n <!-- <ds-button\r\n *ngIf=\"form?.inboxItem && (form?.inboxItem?.canRequestFeedback =='true'|| form?.inboxItem?.hasFeedback=='true')\"\r\n square icon size=\"small\">\r\n <ds-icon icon=\"chat-o\" class=\"fs-20 fs-md-17 fc-coral\">\r\n <!– [ngClass]=\"{'fc-green':feedBackIcon == 'feedbackResponded' , 'fc-red': feedBackIcon == 'respondToFeedback' , 'fc-yellow': feedBackIcon == 'waitingFeedback'}\"–>\r\n </ds-icon>\r\n </ds-button>-->\r\n <!-- history-->\r\n <ds-button\r\n *ngIf=\"form?.commentsDrop?.length > 0 && !isLoading\" square icon size=\"small\"\r\n (click)=\"onCommentsFormClick()\" class=\"has-comments\">\r\n <ds-icon icon=\"clock\" class=\"fc-coral fs-20 fs-md-17\"></ds-icon>\r\n </ds-button>\r\n <ng-content></ng-content>\r\n </div>\r\n </div>\r\n </div>\r\n\r\n <div class=\"request-info--footer\">\r\n @if (!isLoading) {\r\n <ds-avatar\r\n image=\"{{form?.header?.requesterPhoto}}\" size=\"xx-small\"\r\n class=\"d-inline-flex cursor-pointer\" (click)=\"showUserInfo()\"></ds-avatar>\r\n }\r\n <div\r\n class=\"d-flex align-items-center flex-wrap flex-grow-1 gap-1 gap-sm-2 line-height-1 request-info--header__details\">\r\n <span\r\n [ngClass]=\"{'loading-bg loading-width': isLoading}\"\r\n class=\"fs-12 fw-medium d-none d-sm-inline-block\">{{ coreService.getShortName(form?.header?.['requesterName']) }}</span>\r\n <span class=\"fs-20\">•</span>\r\n <span class=\"fs-12\" [ngClass]=\"{'loading-bg loading-width': isLoading}\"> {{ form?.header?.formId }}</span>\r\n <span class=\"fs-20\" *ngIf=\"creationDate\">•</span>\r\n <span class=\"fs-12\" [ngClass]=\"{'loading-bg loading-width': isLoading}\"> {{ creationDate }}</span>\r\n </div>\r\n </div>\r\n </section>\r\n </section>\r\n\r\n </div>\r\n\r\n\r\n <!--<ng-container>\r\n <div class=\"d-flex align-items-center justify-content-end gap-2 my-2\">\r\n <ds-button\r\n *ngIf=\"form?.inboxItem && !form.sections[form.sections.length -1].header.readOnly && !isLoading\"\r\n square\r\n icon\r\n size=\"small\"\r\n [matMenuTriggerFor]=\"menu\"\r\n class=\"icon-btn-shadow\">\r\n <ds-icon\r\n [ngClass]=\"{'fc-purple' : (flagPriority === '0' || flagPriority === null),'fc-yellow' : flagPriority === '1','fc-green' : flagPriority === '2','fc-coral' : flagPriority === '3'}\"\r\n icon=\"flag-o\" class=\"fs-20 fs-md-17 fc-purple\">\r\n </ds-icon>\r\n </ds-button>\r\n <mat-menu #menu=\"matMenu\" panelClass=\"action-menu\">\r\n <button mat-menu-item (click)=\"setFlagPriority('0')\">\r\n <ds-icon icon=\"flag-o\" class=\"fc-purple fs-20 fs-md-17\"></ds-icon>\r\n </button>\r\n <button mat-menu-item (click)=\"setFlagPriority('1')\">\r\n <ds-icon icon=\"flag-o\" class=\"fc-yellow fs-20 fs-md-17\"></ds-icon>\r\n </button>\r\n <button mat-menu-item (click)=\"setFlagPriority('2')\">\r\n <ds-icon icon=\"flag-o\" class=\"fc-green fs-20 fs-md-17\"></ds-icon>\r\n </button>\r\n <button mat-menu-item (click)=\"setFlagPriority('3')\">\r\n <ds-icon icon=\"flag-o\" class=\"fc-coral fs-20 fs-md-17\"></ds-icon>\r\n </button>\r\n </mat-menu>\r\n\r\n <ng-content></ng-content>\r\n </div>\r\n <header class=\"service-header bc-white p-3 p-sm-4 py-4 gap-3 {{statusClass(form?.header?.status?.['key'])}}\">\r\n\r\n <div class=\"service-header-icon\">\r\n <img\r\n alt=\"\"\r\n src=\"data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMzAiIGhlaWdodD0iMjkiIHZpZXdCb3g9IjAgMCAzMCAyOSIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZD0iTTI1LjEgMEg0LjlDMi4yIDAgMCAyLjIgMCA0LjlWMjguNkgyNS4xQzI3LjggMjguNiAzMCAyNi40IDMwIDIzLjdWNC45QzMwIDIuMiAyNy44IDAgMjUuMSAwWk0yIDQuOUMyIDMuMyAzLjMgMiA0LjkgMkgyNS4xQzI2LjcgMiAyOCAzLjMgMjggNC45VjIzLjdDMjggMjUuMyAyNi43IDI2LjYgMjUuMSAyNi42SDJWNC45Wk0xMS41IDYuM0M3LjEgNi4zIDMuNSA5LjkgMy41IDE0LjNDMy41IDE4LjcgNy4xIDIyLjMgMTEuNSAyMi4zQzE1LjkgMjIuMyAxOS41IDE4LjcgMTkuNSAxNC4zQzE5LjUgOS45IDE1LjkgNi4zIDExLjUgNi4zWk0xNS4xIDE5QzE0LjEgMTkuOCAxMi44IDIwLjIgMTEuNSAyMC4yQzEwLjIgMjAuMiA4LjkgMTkuOCA3LjkgMTlDOC43IDE3LjcgMTAgMTcgMTEuNSAxN0MxMyAxNyAxNC40IDE3LjggMTUuMSAxOVpNMTMuMSAxMy40QzEzLjEgMTQuMyAxMi40IDE1IDExLjUgMTVDMTAuNiAxNSA5LjkgMTQuMyA5LjkgMTMuNEM5LjkgMTIuNSAxMC42IDExLjggMTEuNSAxMS44QzEyLjQgMTEuOCAxMy4xIDEyLjUgMTMuMSAxMy40Wk0xNS4xIDEzLjRDMTUuMSAxMS40IDEzLjUgOS44IDExLjUgOS44QzkuNSA5LjggNy45IDExLjQgNy45IDEzLjRDNy45IDE0LjIgOC4yIDE1IDguNyAxNS43QzcuOCAxNi4xIDcuMSAxNi44IDYuNSAxNy42QzUuOCAxNi42IDUuNSAxNS41IDUuNSAxNC4zQzUuNSAxMSA4LjIgOC4zIDExLjUgOC4zQzE0LjggOC4zIDE3LjUgMTEgMTcuNSAxNC4zQzE3LjUgMTUuNSAxNy4yIDE2LjYgMTYuNSAxNy42QzE1LjkgMTYuOCAxNS4yIDE2LjIgMTQuMyAxNS43QzE0LjggMTUuMSAxNS4xIDE0LjIgMTUuMSAxMy40Wk0yMSA5LjFDMjEgOC42IDIxLjQgOC4xIDIyIDguMUgyNS41QzI2IDguMSAyNi41IDguNSAyNi41IDkuMUMyNi41IDkuNiAyNi4xIDEwLjEgMjUuNSAxMC4xSDIyQzIxLjQgMTAuMSAyMSA5LjYgMjEgOS4xWk0yMSAxMi41QzIxIDEyIDIxLjQgMTEuNSAyMiAxMS41SDI1LjVDMjYgMTEuNSAyNi41IDExLjkgMjYuNSAxMi41QzI2LjUgMTMgMjYuMSAxMy41IDI1LjUgMTMuNUgyMkMyMS40IDEzLjUgMjEgMTMuMSAyMSAxMi41Wk0yMSAxNkMyMSAxNS41IDIxLjQgMTUgMjIgMTVIMjUuNUMyNiAxNSAyNi41IDE1LjQgMjYuNSAxNkMyNi41IDE2LjUgMjYuMSAxNyAyNS41IDE3SDIyQzIxLjQgMTcgMjEgMTYuNiAyMSAxNlpNMjUuNSAyMC41SDIyQzIxLjUgMjAuNSAyMSAyMC4xIDIxIDE5LjVDMjEgMTguOSAyMS40IDE4LjUgMjIgMTguNUgyNS41QzI2IDE4LjUgMjYuNSAxOC45IDI2LjUgMTkuNUMyNi41IDIwLjEgMjYuMSAyMC41IDI1LjUgMjAuNVoiIGZpbGw9IiNGRjM3NUUiLz4KPC9zdmc+Cg==\"/>\r\n </div>\r\n\r\n <div class=\"flex-grow-1 d-flex flex-column flex-sm-row align-items-sm-center gap-2\">\r\n <div class=\"flex-grow-1\">\r\n <h1 class=\"fs-20 fs-md-16 fw-bold fc-black header-title m-0\">{{ formTitle }}\r\n @if (serviceFaq.length) {\r\n <ds-icon icon=\"info\" class=\"fs-22 fc-dark-gray cursor-pointer\" (click)=\"openFaq()\">\r\n </ds-icon>\r\n }\r\n </h1>\r\n <div class=\"header-user d-flex align-items-sm-center gap-2 mt-sm-1\">\r\n @if (!isLoading) {\r\n <ds-avatar\r\n image=\"{{form?.header?.requesterPhoto}}\" size=\"xx-small\"\r\n class=\"d-inline-flex cursor-pointer\" (click)=\"showUserInfo()\"></ds-avatar>\r\n }\r\n <span\r\n class=\"fs-12 text-truncate d-sm-block cursor-pointer\" (click)=\"showUserInfo()\"\r\n [ngClass]=\"{'loading-bg loading-width': isLoading}\">{{ coreService.getShortName(form?.header?.requesterName) }}</span>\r\n <mat-divider class=\"divider circle mx-2 d-none d-sm-block\"></mat-divider>\r\n <span class=\"fs-12\" [ngClass]=\"{'loading-bg loading-width': isLoading}\">{{ form?.header?.formId }}</span>\r\n @if (creationDate) {\r\n <mat-divider class=\"divider circle mx-2 d-none d-sm-block\"></mat-divider>\r\n <span class=\"fs-14\" [ngClass]=\"{'loading-bg loading-width': isLoading}\">{{ creationDate }}</span>\r\n }\r\n </div>\r\n\r\n </div>\r\n <div class=\"header-actions d-flex flex-row flex-sm-column justify-content-between justify-content-sm-center gap-2 mt-2 mt-sm-0\">\r\n @if (!isLoading) {\r\n <ds-status\r\n status=\"{{statusClass(form?.header?.status?.['key'])}}\" class=\"header-status\">{{ form?.header?.status?.['value'] }}\r\n </ds-status>\r\n }\r\n <div class=\"d-flex align-items-center justify-content-end gap-2\">\r\n <!– feedback–>\r\n <!– *ngIf=\"form?.inboxItem && (form?.inboxItem?.canRequestFeedback ==='true'|| form?.inboxItem?.hasFeedback==='true') && !isLoading\"–>\r\n <!– <ds-button\r\n square icon size=\"small\" (click)=\"feedback()\">\r\n <ds-icon\r\n icon=\"chat-o\" class=\"fs-20 fs-md-17 fc-coral\"\r\n [ngClass]=\"{'fc-green':feedBackIcon === 'feedbackResponded' , 'fc-red': feedBackIcon === 'respondToFeedback' , 'fc-yellow': feedBackIcon === 'waitingFeedback'}\">\r\n </ds-icon>\r\n </ds-button>–>\r\n <ds-button\r\n *ngIf=\"form?.commentsDrop?.length > 0 && !isLoading\" square icon size=\"small\"\r\n (click)=\"onCommentsFormClick()\" class=\"has-comments\">\r\n <ds-icon icon=\"clock\" class=\"fc-coral fs-20 fs-md-17\"></ds-icon>\r\n </ds-button>\r\n @if (showApprovalHistory) {\r\n <ng-container>\r\n <ds-button\r\n color=\"white\" shape=\"text\" square size=\"small\" [satPopoverAnchor]=\"workflow\"\r\n #workflowAnchor=\"satPopoverAnchor\" (click)=\"workflowAnchor.popover.open()\">\r\n <slot name=\"prefix\">\r\n <ds-icon icon=\"workflow\" class=\"fs-24\"></ds-icon>\r\n </slot>\r\n </ds-button>\r\n <sat-popover\r\n #workflow [anchor]=\"workflowAnchor\" [hasBackdrop]=\"true\" verticalAlign=\"below\"\r\n horizontalAlign=\"end\">\r\n <div class=\"default-popover p-3\" style=\"min-width: 330px;\">\r\n <ds-approvals *ngIf=\"approvalHistory\" class=\"popover-approvals\" approvalsData=\"{{approvals}}\">\r\n </ds-approvals>\r\n </div>\r\n </sat-popover>\r\n </ng-container>\r\n }\r\n </div>\r\n </div>\r\n </div>\r\n\r\n </header>\r\n </ng-container>-->\r\n}\r\n", styles: [".loading-width{min-width:100px;width:40px;flex-grow:1}.request-main-info{--item-bg: var(--light-gray);--item-fc: var(--black);--status-container-bc: #e8ebec;--status-container-brc: var(--dark-gray)}.request-main-info.warning{--item-bg: var(--yellow);--status-container-bc: #fff8d9;--status-container-brc: var(--yellow)}.request-main-info.pending{--item-bg: #eff0f1;--status-container-bc: #e8ebec;--status-container-brc: #c8ced1}.request-main-info.expired{--item-bg: var(--dark-gray);--status-container-bc: #e8ebec;--status-container-brc: var(--dark-gray)}.request-main-info.success{--item-bg: var(--green);--status-container-bc: #e6f9f4;--status-container-brc: var(--green)}.request-main-info.info{--item-bg: var(--sea-light);--status-container-bc: #fff8d9;--status-container-brc: var(--sea-light)}.request-main-info.danger{--item-bg: var(--red);--status-container-bc: #fae9ec;--status-container-brc: var(--red)}.request-main-info.orange,.request-main-info.send_back{--item-bg: var(--orange);--status-container-bc: #fff0eb;--status-container-brc: var(--orange)}.request-info{border-radius:0;box-shadow:var(--box-shadow);background-color:var(--white);border-top:5px solid var(--item-bg)}.request-info--footer{padding:.3rem 2rem;min-height:45px;display:flex;align-items:center;gap:.75rem;border-top:1px solid var(--light-gray)}@media (max-width: 578px){.request-info--footer{padding:.3rem 1rem}}.request-info--footer__details{color:var(--item-fc)}.request-info--body{padding:2rem;display:flex;align-items:center;gap:.75rem;background-color:#fff}@media (max-width: 578px){.request-info--body{padding:1rem;flex-direction:column;align-items:stretch}}.request-info--body figure{min-width:30px;width:30px;text-align:center}.request-info--body figure svg{width:100%}@media (max-width: 578px){.request-info--status-action{justify-content:space-between}}.request-info--history{margin-top:-.5rem}.request-info--comment{background-color:#fff0eb;color:var(--orange);border-radius:0 0 4px 4px}.status-container{min-height:40px;padding:.5rem 1rem;display:flex;flex-direction:column;justify-content:center;gap:.5rem;margin-bottom:1.5rem}.status-container.danger{--item-bg: var(--red);--status-container-bc: #fae9ec;--status-container-brc: var(--red)}.status-container ::ng-deep ds-avatar .avatar{--default-size: 18px}.circle-status::part(base){--status-radius: 50%;--status-size: 19px;--status-fs: 100%}ds-button[square]::part(base){--btn-padding: 0;--default-size-sm: 30px}.send-back-container{background-color:#fff0eb;color:var(--orange);padding:.5rem;border-radius:4px}object,iframe,embed{height:79vh}::ng-deep .history-popup{--popup-width: 100vw;--popup-max-width: 100vw;--popup-radius: 15px 15px 0 0;position:absolute!important;bottom:0}:host ::ng-deep .mat-expansion-panel-content{background:#fff!important}:host .main-sidenav.main-sidenav-full .sidenav-title{border-bottom:transparent!important}:host .main-sidenav .sidenav-title{background-color:transparent!important}:host .main-sidenav{height:60px;min-height:10px!important}:host .mat-expansion-panel-content{background:#fff!important}:host .approval-panel-container{display:grid;grid-template-columns:40% calc(60% - 45px) 20px;grid-template-areas:\"title details toggle\";gap:.75rem;place-content:space-between;align-items:center;flex-grow:1;width:100%}@media (max-width: 991px){:host .approval-panel-container{grid-template-columns:calc(100% - 45px) 20px;grid-template-areas:\"title toggle\" \"details details\"}}:host .approval-panel-container .approval-panel-title{grid-area:title}:host .approval-panel-container .panel-user-name{max-width:120px}@media (max-width: 768px){:host .approval-panel-container .panel-user-name.panel-ueser-only{max-width:140px}:host .approval-panel-container .panel-user-name:not(.panel-ueser-only){max-width:90px}}:host .approval-panel-container .approval-panel-details{display:flex;align-items:center;justify-content:space-between;grid-area:details}:host .approval-panel-container .approval-panel-toggle{grid-area:toggle;display:flex;align-items:center;justify-content:center;width:20px}:host ::ng-deep ds-avatar.user-avatar .avatar{--default-size: 25px}@media (min-width: 768px){:host ::ng-deep ds-avatar.user-avatar .avatar{--default-size: 31px;--avatar-border: 3px solid var(--light-gray)}}@media (min-width: 768px){:host ::ng-deep .user-avatar-name{padding-inline-end:1rem!important}}:host .circle-status::part(base){--status-radius: 50%;--status-size: 18px;--status-fs: 80% }:host .panel-title{min-width:40%;width:40%}@media (max-width: 576px){:host .panel-title{min-width:100%!important;width:100%!important}}:host .panel-user-status{min-width:60%;width:60%;display:flex;align-items:center;justify-content:space-between}@media (max-width: 576px){:host .panel-user-status{min-width:100%!important;width:100%!important}:host .panel-user-status .user-delegate{min-width:auto}:host .panel-user-status .main-status::part(base){--status-width: 50px}}\n"], dependencies: [{ kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: SatPopoverModule }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }] });
|
|
5372
5942
|
}
|
|
5373
5943
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: ServiceHeaderComponent, decorators: [{
|
|
5374
5944
|
type: Component,
|
|
@@ -5382,8 +5952,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
|
|
|
5382
5952
|
MatMenuItem
|
|
5383
5953
|
], schemas: [CUSTOM_ELEMENTS_SCHEMA], providers: [FeedBackService,
|
|
5384
5954
|
{ provide: MAT_DIALOG_DATA, useValue: {} },
|
|
5385
|
-
], template: "<ng-container *ngIf=\"!(form?.header?.status?.['key'] === 'NEW')\">\r\n <div class=\"d-flex align-items-center justify-content-end gap-2 my-2\" *ngIf=\"!(form?.header?.status?.['key'] === 'NEW')\">\r\n\r\n <!-- flag-->\r\n <ds-button\r\n *ngIf=\"form?.inboxItem && !form.sections[form.sections.length -1].header.readOnly && !isLoading\"\r\n square\r\n icon\r\n size=\"small\"\r\n [matMenuTriggerFor]=\"menu\"\r\n class=\"icon-btn-shadow\">\r\n <ds-icon\r\n [ngClass]=\"{'fc-purple' : (flagPriority === '0' || flagPriority === null),'fc-yellow' : flagPriority === '1','fc-green' : flagPriority === '2','fc-coral' : flagPriority === '3'}\"\r\n icon=\"flag-o\" class=\"fs-20 fs-md-17 fc-purple\">\r\n </ds-icon>\r\n </ds-button>\r\n <mat-menu #menu=\"matMenu\" panelClass=\"action-menu\">\r\n <button mat-menu-item (click)=\"setFlagPriority('0')\">\r\n <ds-icon icon=\"flag-o\" class=\"fc-purple fs-20 fs-md-17\"></ds-icon>\r\n </button>\r\n <button mat-menu-item (click)=\"setFlagPriority('1')\">\r\n <ds-icon icon=\"flag-o\" class=\"fc-yellow fs-20 fs-md-17\"></ds-icon>\r\n </button>\r\n <button mat-menu-item (click)=\"setFlagPriority('2')\">\r\n <ds-icon icon=\"flag-o\" class=\"fc-green fs-20 fs-md-17\"></ds-icon>\r\n </button>\r\n <button mat-menu-item (click)=\"setFlagPriority('3')\">\r\n <ds-icon icon=\"flag-o\" class=\"fc-coral fs-20 fs-md-17\"></ds-icon>\r\n </button>\r\n </mat-menu>\r\n\r\n <!-- print-->\r\n <ng-content></ng-content>\r\n </div>\r\n\r\n <header class=\"service-header bc-white p-3 p-sm-4 py-4 gap-3 {{statusClass(form?.header?.status?.['key'])}}\">\r\n\r\n <div class=\"service-header-icon\">\r\n <img\r\n alt=\"\"\r\n src=\"data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMzAiIGhlaWdodD0iMjkiIHZpZXdCb3g9IjAgMCAzMCAyOSIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZD0iTTI1LjEgMEg0LjlDMi4yIDAgMCAyLjIgMCA0LjlWMjguNkgyNS4xQzI3LjggMjguNiAzMCAyNi40IDMwIDIzLjdWNC45QzMwIDIuMiAyNy44IDAgMjUuMSAwWk0yIDQuOUMyIDMuMyAzLjMgMiA0LjkgMkgyNS4xQzI2LjcgMiAyOCAzLjMgMjggNC45VjIzLjdDMjggMjUuMyAyNi43IDI2LjYgMjUuMSAyNi42SDJWNC45Wk0xMS41IDYuM0M3LjEgNi4zIDMuNSA5LjkgMy41IDE0LjNDMy41IDE4LjcgNy4xIDIyLjMgMTEuNSAyMi4zQzE1LjkgMjIuMyAxOS41IDE4LjcgMTkuNSAxNC4zQzE5LjUgOS45IDE1LjkgNi4zIDExLjUgNi4zWk0xNS4xIDE5QzE0LjEgMTkuOCAxMi44IDIwLjIgMTEuNSAyMC4yQzEwLjIgMjAuMiA4LjkgMTkuOCA3LjkgMTlDOC43IDE3LjcgMTAgMTcgMTEuNSAxN0MxMyAxNyAxNC40IDE3LjggMTUuMSAxOVpNMTMuMSAxMy40QzEzLjEgMTQuMyAxMi40IDE1IDExLjUgMTVDMTAuNiAxNSA5LjkgMTQuMyA5LjkgMTMuNEM5LjkgMTIuNSAxMC42IDExLjggMTEuNSAxMS44QzEyLjQgMTEuOCAxMy4xIDEyLjUgMTMuMSAxMy40Wk0xNS4xIDEzLjRDMTUuMSAxMS40IDEzLjUgOS44IDExLjUgOS44QzkuNSA5LjggNy45IDExLjQgNy45IDEzLjRDNy45IDE0LjIgOC4yIDE1IDguNyAxNS43QzcuOCAxNi4xIDcuMSAxNi44IDYuNSAxNy42QzUuOCAxNi42IDUuNSAxNS41IDUuNSAxNC4zQzUuNSAxMSA4LjIgOC4zIDExLjUgOC4zQzE0LjggOC4zIDE3LjUgMTEgMTcuNSAxNC4zQzE3LjUgMTUuNSAxNy4yIDE2LjYgMTYuNSAxNy42QzE1LjkgMTYuOCAxNS4yIDE2LjIgMTQuMyAxNS43QzE0LjggMTUuMSAxNS4xIDE0LjIgMTUuMSAxMy40Wk0yMSA5LjFDMjEgOC42IDIxLjQgOC4xIDIyIDguMUgyNS41QzI2IDguMSAyNi41IDguNSAyNi41IDkuMUMyNi41IDkuNiAyNi4xIDEwLjEgMjUuNSAxMC4xSDIyQzIxLjQgMTAuMSAyMSA5LjYgMjEgOS4xWk0yMSAxMi41QzIxIDEyIDIxLjQgMTEuNSAyMiAxMS41SDI1LjVDMjYgMTEuNSAyNi41IDExLjkgMjYuNSAxMi41QzI2LjUgMTMgMjYuMSAxMy41IDI1LjUgMTMuNUgyMkMyMS40IDEzLjUgMjEgMTMuMSAyMSAxMi41Wk0yMSAxNkMyMSAxNS41IDIxLjQgMTUgMjIgMTVIMjUuNUMyNiAxNSAyNi41IDE1LjQgMjYuNSAxNkMyNi41IDE2LjUgMjYuMSAxNyAyNS41IDE3SDIyQzIxLjQgMTcgMjEgMTYuNiAyMSAxNlpNMjUuNSAyMC41SDIyQzIxLjUgMjAuNSAyMSAyMC4xIDIxIDE5LjVDMjEgMTguOSAyMS40IDE4LjUgMjIgMTguNUgyNS41QzI2IDE4LjUgMjYuNSAxOC45IDI2LjUgMTkuNUMyNi41IDIwLjEgMjYuMSAyMC41IDI1LjUgMjAuNVoiIGZpbGw9IiNGRjM3NUUiLz4KPC9zdmc+Cg==\"/>\r\n </div>\r\n\r\n <div class=\"flex-grow-1 d-flex flex-column flex-sm-row align-items-sm-center gap-2\">\r\n <div class=\"flex-grow-1\">\r\n <!-- title-->\r\n <h1 class=\"fs-20 fs-md-16 fw-bold fc-black header-title m-0\">{{ formTitle }}\r\n <ds-icon\r\n icon=\"info\" class=\"fs-22 fc-dark-gray cursor-pointer\" *ngIf=\"serviceBrief.length\"\r\n (click)=\"openFaq()\"></ds-icon>\r\n </h1>\r\n <div\r\n class=\"header-user d-flex align-items-sm-center gap-2 mt-sm-1\"\r\n *ngIf=\"form?.header?.status?.['key'] !== 'NEW' || isLoading\">\r\n <ds-avatar\r\n *ngIf=\"!isLoading\" image=\"{{form?.header?.requesterPhoto}}\" size=\"xx-small\"\r\n class=\"d-inline-flex cursor-pointer\" (click)=\"showUserInfo()\"></ds-avatar>\r\n <span\r\n class=\"fs-12 text-truncate d-sm-block cursor-pointer\" (click)=\"showUserInfo()\"\r\n [ngClass]=\"{'loading-bg loading-width': isLoading}\">{{ coreService.getShortName(form?.header?.requesterName) }}</span>\r\n <mat-divider class=\"divider circle mx-2 d-none d-sm-block\"></mat-divider>\r\n <span class=\"fs-12\" [ngClass]=\"{'loading-bg loading-width': isLoading}\">{{ form?.header?.formId }}</span>\r\n <mat-divider *ngIf=\"creationDate\" class=\"divider circle mx-2 d-none d-sm-block\"></mat-divider>\r\n <span *ngIf=\"creationDate\" class=\"fs-14\" [ngClass]=\"{'loading-bg loading-width': isLoading}\">{{ creationDate }}</span>\r\n </div>\r\n </div>\r\n <!-- header-actions-->\r\n <div\r\n class=\"header-actions d-flex flex-row flex-sm-column justify-content-between justify-content-sm-center gap-2 mt-2 mt-sm-0\"\r\n *ngIf=\"!(form?.header?.status?.['key'] === 'NEW')\">\r\n <ds-status\r\n *ngIf=\"form?.header?.status?.['key'] !== 'NEW' && !isLoading\"\r\n status=\"{{statusClass(form?.header?.status?.['key'])}}\" class=\"header-status\">{{ form?.header?.status?.['value'] }}\r\n </ds-status>\r\n\r\n <div class=\"d-flex align-items-center justify-content-end gap-2\">\r\n <!-- feedback-->\r\n<!-- *ngIf=\"form?.inboxItem && (form?.inboxItem?.canRequestFeedback ==='true'|| form?.inboxItem?.hasFeedback==='true') && !isLoading\"-->\r\n <!-- <ds-button\r\n square icon size=\"small\" (click)=\"feedback()\">\r\n <ds-icon\r\n icon=\"chat-o\" class=\"fs-20 fs-md-17 fc-coral\"\r\n [ngClass]=\"{'fc-green':feedBackIcon === 'feedbackResponded' , 'fc-red': feedBackIcon === 'respondToFeedback' , 'fc-yellow': feedBackIcon === 'waitingFeedback'}\">\r\n </ds-icon>\r\n </ds-button>-->\r\n <ds-button\r\n *ngIf=\"form?.commentsDrop?.length > 0 && !isLoading\" square icon size=\"small\"\r\n (click)=\"onCommentsFormClick()\" class=\"has-comments\">\r\n <ds-icon icon=\"clock\" class=\"fc-coral fs-20 fs-md-17\"></ds-icon>\r\n </ds-button>\r\n <ng-container *ngIf=\"showApprovalHistory\">\r\n <ds-button\r\n color=\"white\" shape=\"text\" square size=\"small\" [satPopoverAnchor]=\"workflow\"\r\n #workflowAnchor=\"satPopoverAnchor\" (click)=\"workflowAnchor.popover.open()\">\r\n <slot name=\"prefix\">\r\n <ds-icon icon=\"workflow\" class=\"fs-24\"></ds-icon>\r\n </slot>\r\n </ds-button>\r\n\r\n <sat-popover\r\n #workflow [anchor]=\"workflowAnchor\" [hasBackdrop]=\"true\" verticalAlign=\"below\"\r\n horizontalAlign=\"end\">\r\n <div class=\"default-popover p-3\" style=\"min-width: 330px;\">\r\n <ds-approvals *ngIf=\"approvalHistory\" class=\"popover-approvals\" approvalsData=\"{{approvals}}\">\r\n </ds-approvals>\r\n </div>\r\n </sat-popover>\r\n </ng-container>\r\n </div>\r\n </div>\r\n </div>\r\n\r\n </header>\r\n</ng-container>\r\n<header\r\n class=\"mb-4 mt-4 d-flex align-items-center justify-content-between align-items-end gap-2\"\r\n *ngIf=\"(form?.header?.status?.['key'] === 'NEW')\">\r\n <section>\r\n <h6 class=\"fs-14 fs-md-12 fw-normal fc-dark-gray mb-0\">\r\n {{ i18n.translate('Hello') }}\r\n {{ coreService.getShortName(form?.header?.requesterName) }}, {{ i18n.translate('welcomeBack') }}!\r\n </h6>\r\n <h1 class=\"fs-26 fs-md-20 fw-bold fc-black d-flex align-items-center gap-2 mb-1\">\r\n {{ formTitle }}\r\n <ds-icon icon=\"info\" class=\"fs-22 fc-dark-gray cursor-pointer\" *ngIf=\"serviceBrief.length\" (click)=\"openFaq()\">\r\n </ds-icon>\r\n </h1>\r\n </section>\r\n\r\n</header>\r\n", styles: [":host ::ng-deep .filter-section .select-form-field{--input-bg: var(--white);--input-border: var(--white);--placeholder-fc: var(--black);--input-width: 85px;--input-fs: .75rem;--placeholder-fs: .75rem;--label-fs: .75rem;--label-fw: var(--font-regular);--input-height: var(--default-size-sm);font-size:var(--label-fs);box-shadow:var(--box-shadow)}:host ::ng-deep ds-button::part(base){--default-size-sm: 30px;--btn-radius: 3px}@media (max-width: 576px){:host ::ng-deep ds-button::part(base){--default-size-sm: 25px}}:host ::ng-deep .loading-width{min-width:100px;width:40px;flex-grow:1}:host ::ng-deep ds-avatar::part(base){--default-size: 20px}:host ::ng-deep .service-header{--service-header-icon-size: var(--default-size-lg);--header-border-color: var(--coral);display:flex;align-items:flex-start;border-top:5px solid var(--header-border-color);box-shadow:0 7px 10px rgba(var(--rgb-black),3%)}@media (max-width: 576px){:host ::ng-deep .service-header{border-radius:3px 3px 0 0}}:host ::ng-deep .service-header.loading{--header-border-color: var(--off-white)}:host ::ng-deep .service-header.warning{--header-border-color: var(--yellow)}:host ::ng-deep .service-header.success{--header-border-color: var(--green)}:host ::ng-deep .service-header.danger{--header-border-color: var(--red)}@media (max-width: 576px){:host ::ng-deep .service-header{--service-header-icon-size: var(--default-size-sm)}}:host ::ng-deep .service-header .service-header-icon{min-width:var(--service-header-icon-size);width:var(--service-header-icon-size);height:var(--service-header-icon-size);display:inline-flex;align-items:center;justify-content:center;padding:.75rem;border-radius:6px 6px 6px 0;background-color:rgba(var(--rgb-coral),.1)}@media (max-width: 576px){:host ::ng-deep .service-header .service-header-icon{padding:.5rem}}:host ::ng-deep .service-header .header-title{text-align:start}:host ::ng-deep .service-header .divider.circle{min-width:5px;width:5px;min-height:5px;height:5px;border-radius:50%;background-color:var(--dark-gray)}:host ::ng-deep .service-header .header-actions{align-items:flex-end;justify-content:flex-end}:host ::ng-deep .service-header .header-actions .has-comments{position:relative}:host ::ng-deep .service-header .header-actions .has-comments:before{content:\"\";min-width:8px;height:8px;border-radius:50%;background-color:var(--coral);position:absolute;top:-3px;right:-3px;z-index:1}[dir=rtl] :host ::ng-deep .service-header .header-actions .has-comments:before{right:auto;left:-3px}:host ::ng-deep .service-header .header-actions ds-button::part(base){--btn-color: var(--coral);--btn-bg-color: var(--light-gray);--btn-border-color: var(--light-gray)}:host ::ng-deep .service-header .header-user{color:var(--dark-gray)}:host ::ng-deep .history-button::part(base){background-color:var(--white);--btn-height: var(--default-size-sm);--btn-shadow: 0 7px 10px rgba(var(--rgb-black), 3%)}@media (max-width: 576px){:host ::ng-deep .history-button::part(base){--btn-height: 35px;--btn-width: 35px}}@media (max-width: 576px){:host ::ng-deep .history-button::part(label){display:none}}\n"] }]
|
|
5386
|
-
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: CoreService }, { type: CoreI18nService }, { type: FeedBackService }, { type: i1$1.MatDialog }, { type: SidenavService }], propDecorators: { form: [{
|
|
5955
|
+
], template: "@if (form?.header?.status?.['key'] === 'NEW') {\r\n <section\r\n class=\"main-sidenav main-sidenav-full mb-4\"\r\n\r\n >\r\n <div class=\"sidenav-title\">\r\n <div class=\"d-flex align-items-center gap-3 w-100\">\r\n <!-- <ds-button icon class=\"rotate-arrow\" size=\"small\" (click)=\"goBack()\" *ngIf=\"!isInMobileApp() && showBack\">\r\n <ds-icon icon=\"arrow-right\" class=\"fs-19 fc-black\"></ds-icon>\r\n </ds-button>-->\r\n\r\n <!-- <h3 class=\"flex-grow-0\">\r\n {{ formTitle }}\r\n </h3>-->\r\n\r\n <section>\r\n <h6 class=\"fs-14 fs-md-12 fw-normal fc-dark-gray mb-0\">\r\n {{ i18n.translate('Hello') }}\r\n {{ coreService.getShortName(form?.header?.requesterName) }}, {{ i18n.translate('welcomeBack') }}!\r\n </h6>\r\n <h1 class=\"fs-26 fs-md-20 fw-bold fc-black d-flex align-items-center gap-2 mb-1\">\r\n {{ formTitle }}\r\n @if (serviceFaq.length) {\r\n <ds-icon icon=\"info\" class=\"fs-22 fc-dark-gray cursor-pointer\" (click)=\"openFaq()\">\r\n </ds-icon>\r\n }\r\n </h1>\r\n </section>\r\n <div class=\"d-flex align-items-center justify-content-end gap-2 flex-grow-1\">\r\n @if (serviceFaq.length) {\r\n <ds-button size=\"small\" icon>\r\n <ds-icon icon=\"info\" class=\"fs-22 fc-dark-gray cursor-pointer\" (click)=\"openFaq()\">\r\n </ds-icon>\r\n </ds-button>\r\n }\r\n <!-- <ds-button size=\"small\" icon (click)=\"openWorkflow()\">\r\n <ds-icon icon=\"bell-2-o\" class=\"fs-20 fc-coral\"></ds-icon>\r\n </ds-button> -->\r\n <ds-button size=\"small\" icon (click)=\"showPreviousRequests()\" >\r\n <ds-icon icon=\"clock\" class=\"fs-20 fc-coral\"></ds-icon>\r\n </ds-button>\r\n </div>\r\n </div>\r\n </div>\r\n </section>\r\n\r\n <!-- <header class=\"mb-4 mt-4 d-flex align-items-center justify-content-between align-items-end gap-2\">\r\n <section>\r\n <h6 class=\"fs-14 fs-md-12 fw-normal fc-dark-gray mb-0\">\r\n {{ i18n.translate('Hello') }}\r\n {{ coreService.getShortName(form?.header?.requesterName) }}, {{ i18n.translate('welcomeBack') }}!\r\n </h6>\r\n <h1 class=\"fs-26 fs-md-20 fw-bold fc-black d-flex align-items-center gap-2 mb-1\">\r\n {{ formTitle }}\r\n @if (serviceFaq.length) {\r\n <ds-icon icon=\"info\" class=\"fs-22 fc-dark-gray cursor-pointer\" (click)=\"openFaq()\">\r\n </ds-icon>\r\n }\r\n </h1>\r\n </section>\r\n </header>-->\r\n} @else {\r\n\r\n <div class=\"w-100\">\r\n <section class=\"request-main-info {{statusClass(form?.header?.status?.['key'])}}\">\r\n <section class=\"request-info\">\r\n <div class=\"request-info--body\">\r\n <div class=\"d-flex align-items-center gap-2 flex-grow-1\">\r\n <img\r\n alt=\"\"\r\n src=\"data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMzAiIGhlaWdodD0iMjkiIHZpZXdCb3g9IjAgMCAzMCAyOSIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZD0iTTI1LjEgMEg0LjlDMi4yIDAgMCAyLjIgMCA0LjlWMjguNkgyNS4xQzI3LjggMjguNiAzMCAyNi40IDMwIDIzLjdWNC45QzMwIDIuMiAyNy44IDAgMjUuMSAwWk0yIDQuOUMyIDMuMyAzLjMgMiA0LjkgMkgyNS4xQzI2LjcgMiAyOCAzLjMgMjggNC45VjIzLjdDMjggMjUuMyAyNi43IDI2LjYgMjUuMSAyNi42SDJWNC45Wk0xMS41IDYuM0M3LjEgNi4zIDMuNSA5LjkgMy41IDE0LjNDMy41IDE4LjcgNy4xIDIyLjMgMTEuNSAyMi4zQzE1LjkgMjIuMyAxOS41IDE4LjcgMTkuNSAxNC4zQzE5LjUgOS45IDE1LjkgNi4zIDExLjUgNi4zWk0xNS4xIDE5QzE0LjEgMTkuOCAxMi44IDIwLjIgMTEuNSAyMC4yQzEwLjIgMjAuMiA4LjkgMTkuOCA3LjkgMTlDOC43IDE3LjcgMTAgMTcgMTEuNSAxN0MxMyAxNyAxNC40IDE3LjggMTUuMSAxOVpNMTMuMSAxMy40QzEzLjEgMTQuMyAxMi40IDE1IDExLjUgMTVDMTAuNiAxNSA5LjkgMTQuMyA5LjkgMTMuNEM5LjkgMTIuNSAxMC42IDExLjggMTEuNSAxMS44QzEyLjQgMTEuOCAxMy4xIDEyLjUgMTMuMSAxMy40Wk0xNS4xIDEzLjRDMTUuMSAxMS40IDEzLjUgOS44IDExLjUgOS44QzkuNSA5LjggNy45IDExLjQgNy45IDEzLjRDNy45IDE0LjIgOC4yIDE1IDguNyAxNS43QzcuOCAxNi4xIDcuMSAxNi44IDYuNSAxNy42QzUuOCAxNi42IDUuNSAxNS41IDUuNSAxNC4zQzUuNSAxMSA4LjIgOC4zIDExLjUgOC4zQzE0LjggOC4zIDE3LjUgMTEgMTcuNSAxNC4zQzE3LjUgMTUuNSAxNy4yIDE2LjYgMTYuNSAxNy42QzE1LjkgMTYuOCAxNS4yIDE2LjIgMTQuMyAxNS43QzE0LjggMTUuMSAxNS4xIDE0LjIgMTUuMSAxMy40Wk0yMSA5LjFDMjEgOC42IDIxLjQgOC4xIDIyIDguMUgyNS41QzI2IDguMSAyNi41IDguNSAyNi41IDkuMUMyNi41IDkuNiAyNi4xIDEwLjEgMjUuNSAxMC4xSDIyQzIxLjQgMTAuMSAyMSA5LjYgMjEgOS4xWk0yMSAxMi41QzIxIDEyIDIxLjQgMTEuNSAyMiAxMS41SDI1LjVDMjYgMTEuNSAyNi41IDExLjkgMjYuNSAxMi41QzI2LjUgMTMgMjYuMSAxMy41IDI1LjUgMTMuNUgyMkMyMS40IDEzLjUgMjEgMTMuMSAyMSAxMi41Wk0yMSAxNkMyMSAxNS41IDIxLjQgMTUgMjIgMTVIMjUuNUMyNiAxNSAyNi41IDE1LjQgMjYuNSAxNkMyNi41IDE2LjUgMjYuMSAxNyAyNS41IDE3SDIyQzIxLjQgMTcgMjEgMTYuNiAyMSAxNlpNMjUuNSAyMC41SDIyQzIxLjUgMjAuNSAyMSAyMC4xIDIxIDE5LjVDMjEgMTguOSAyMS40IDE4LjUgMjIgMTguNUgyNS41QzI2IDE4LjUgMjYuNSAxOC45IDI2LjUgMTkuNUMyNi41IDIwLjEgMjYuMSAyMC41IDI1LjUgMjAuNVoiIGZpbGw9IiNGRjM3NUUiLz4KPC9zdmc+Cg==\"/>\r\n <h4 class=\"fs-22 fs-md-16 fc-black fw-medium mb-0 flex-grow-1 line-height-1-2\">\r\n {{ formTitle }}\r\n </h4>\r\n </div>\r\n <div class=\"d-flex align-items-center gap-2 request-info--status-action\">\r\n <div class=\"d-inline-flex flex-column align-items-end\">\r\n @if (!isLoading) {\r\n <ds-status\r\n status=\"{{statusClass(form?.header?.status?.['key'])}}\" class=\"header-status\">{{ form?.header?.status?.['value'] }}\r\n </ds-status>\r\n }\r\n </div>\r\n <div class=\"d-flex align-items-center gap-2\">\r\n <!-- <ds-button\r\n *ngIf=\"form?.inboxItem && (form?.inboxItem?.canRequestFeedback =='true'|| form?.inboxItem?.hasFeedback=='true')\"\r\n square icon size=\"small\">\r\n <ds-icon icon=\"chat-o\" class=\"fs-20 fs-md-17 fc-coral\">\r\n <!– [ngClass]=\"{'fc-green':feedBackIcon == 'feedbackResponded' , 'fc-red': feedBackIcon == 'respondToFeedback' , 'fc-yellow': feedBackIcon == 'waitingFeedback'}\"–>\r\n </ds-icon>\r\n </ds-button>-->\r\n <!-- history-->\r\n <ds-button\r\n *ngIf=\"form?.commentsDrop?.length > 0 && !isLoading\" square icon size=\"small\"\r\n (click)=\"onCommentsFormClick()\" class=\"has-comments\">\r\n <ds-icon icon=\"clock\" class=\"fc-coral fs-20 fs-md-17\"></ds-icon>\r\n </ds-button>\r\n <ng-content></ng-content>\r\n </div>\r\n </div>\r\n </div>\r\n\r\n <div class=\"request-info--footer\">\r\n @if (!isLoading) {\r\n <ds-avatar\r\n image=\"{{form?.header?.requesterPhoto}}\" size=\"xx-small\"\r\n class=\"d-inline-flex cursor-pointer\" (click)=\"showUserInfo()\"></ds-avatar>\r\n }\r\n <div\r\n class=\"d-flex align-items-center flex-wrap flex-grow-1 gap-1 gap-sm-2 line-height-1 request-info--header__details\">\r\n <span\r\n [ngClass]=\"{'loading-bg loading-width': isLoading}\"\r\n class=\"fs-12 fw-medium d-none d-sm-inline-block\">{{ coreService.getShortName(form?.header?.['requesterName']) }}</span>\r\n <span class=\"fs-20\">•</span>\r\n <span class=\"fs-12\" [ngClass]=\"{'loading-bg loading-width': isLoading}\"> {{ form?.header?.formId }}</span>\r\n <span class=\"fs-20\" *ngIf=\"creationDate\">•</span>\r\n <span class=\"fs-12\" [ngClass]=\"{'loading-bg loading-width': isLoading}\"> {{ creationDate }}</span>\r\n </div>\r\n </div>\r\n </section>\r\n </section>\r\n\r\n </div>\r\n\r\n\r\n <!--<ng-container>\r\n <div class=\"d-flex align-items-center justify-content-end gap-2 my-2\">\r\n <ds-button\r\n *ngIf=\"form?.inboxItem && !form.sections[form.sections.length -1].header.readOnly && !isLoading\"\r\n square\r\n icon\r\n size=\"small\"\r\n [matMenuTriggerFor]=\"menu\"\r\n class=\"icon-btn-shadow\">\r\n <ds-icon\r\n [ngClass]=\"{'fc-purple' : (flagPriority === '0' || flagPriority === null),'fc-yellow' : flagPriority === '1','fc-green' : flagPriority === '2','fc-coral' : flagPriority === '3'}\"\r\n icon=\"flag-o\" class=\"fs-20 fs-md-17 fc-purple\">\r\n </ds-icon>\r\n </ds-button>\r\n <mat-menu #menu=\"matMenu\" panelClass=\"action-menu\">\r\n <button mat-menu-item (click)=\"setFlagPriority('0')\">\r\n <ds-icon icon=\"flag-o\" class=\"fc-purple fs-20 fs-md-17\"></ds-icon>\r\n </button>\r\n <button mat-menu-item (click)=\"setFlagPriority('1')\">\r\n <ds-icon icon=\"flag-o\" class=\"fc-yellow fs-20 fs-md-17\"></ds-icon>\r\n </button>\r\n <button mat-menu-item (click)=\"setFlagPriority('2')\">\r\n <ds-icon icon=\"flag-o\" class=\"fc-green fs-20 fs-md-17\"></ds-icon>\r\n </button>\r\n <button mat-menu-item (click)=\"setFlagPriority('3')\">\r\n <ds-icon icon=\"flag-o\" class=\"fc-coral fs-20 fs-md-17\"></ds-icon>\r\n </button>\r\n </mat-menu>\r\n\r\n <ng-content></ng-content>\r\n </div>\r\n <header class=\"service-header bc-white p-3 p-sm-4 py-4 gap-3 {{statusClass(form?.header?.status?.['key'])}}\">\r\n\r\n <div class=\"service-header-icon\">\r\n <img\r\n alt=\"\"\r\n src=\"data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMzAiIGhlaWdodD0iMjkiIHZpZXdCb3g9IjAgMCAzMCAyOSIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZD0iTTI1LjEgMEg0LjlDMi4yIDAgMCAyLjIgMCA0LjlWMjguNkgyNS4xQzI3LjggMjguNiAzMCAyNi40IDMwIDIzLjdWNC45QzMwIDIuMiAyNy44IDAgMjUuMSAwWk0yIDQuOUMyIDMuMyAzLjMgMiA0LjkgMkgyNS4xQzI2LjcgMiAyOCAzLjMgMjggNC45VjIzLjdDMjggMjUuMyAyNi43IDI2LjYgMjUuMSAyNi42SDJWNC45Wk0xMS41IDYuM0M3LjEgNi4zIDMuNSA5LjkgMy41IDE0LjNDMy41IDE4LjcgNy4xIDIyLjMgMTEuNSAyMi4zQzE1LjkgMjIuMyAxOS41IDE4LjcgMTkuNSAxNC4zQzE5LjUgOS45IDE1LjkgNi4zIDExLjUgNi4zWk0xNS4xIDE5QzE0LjEgMTkuOCAxMi44IDIwLjIgMTEuNSAyMC4yQzEwLjIgMjAuMiA4LjkgMTkuOCA3LjkgMTlDOC43IDE3LjcgMTAgMTcgMTEuNSAxN0MxMyAxNyAxNC40IDE3LjggMTUuMSAxOVpNMTMuMSAxMy40QzEzLjEgMTQuMyAxMi40IDE1IDExLjUgMTVDMTAuNiAxNSA5LjkgMTQuMyA5LjkgMTMuNEM5LjkgMTIuNSAxMC42IDExLjggMTEuNSAxMS44QzEyLjQgMTEuOCAxMy4xIDEyLjUgMTMuMSAxMy40Wk0xNS4xIDEzLjRDMTUuMSAxMS40IDEzLjUgOS44IDExLjUgOS44QzkuNSA5LjggNy45IDExLjQgNy45IDEzLjRDNy45IDE0LjIgOC4yIDE1IDguNyAxNS43QzcuOCAxNi4xIDcuMSAxNi44IDYuNSAxNy42QzUuOCAxNi42IDUuNSAxNS41IDUuNSAxNC4zQzUuNSAxMSA4LjIgOC4zIDExLjUgOC4zQzE0LjggOC4zIDE3LjUgMTEgMTcuNSAxNC4zQzE3LjUgMTUuNSAxNy4yIDE2LjYgMTYuNSAxNy42QzE1LjkgMTYuOCAxNS4yIDE2LjIgMTQuMyAxNS43QzE0LjggMTUuMSAxNS4xIDE0LjIgMTUuMSAxMy40Wk0yMSA5LjFDMjEgOC42IDIxLjQgOC4xIDIyIDguMUgyNS41QzI2IDguMSAyNi41IDguNSAyNi41IDkuMUMyNi41IDkuNiAyNi4xIDEwLjEgMjUuNSAxMC4xSDIyQzIxLjQgMTAuMSAyMSA5LjYgMjEgOS4xWk0yMSAxMi41QzIxIDEyIDIxLjQgMTEuNSAyMiAxMS41SDI1LjVDMjYgMTEuNSAyNi41IDExLjkgMjYuNSAxMi41QzI2LjUgMTMgMjYuMSAxMy41IDI1LjUgMTMuNUgyMkMyMS40IDEzLjUgMjEgMTMuMSAyMSAxMi41Wk0yMSAxNkMyMSAxNS41IDIxLjQgMTUgMjIgMTVIMjUuNUMyNiAxNSAyNi41IDE1LjQgMjYuNSAxNkMyNi41IDE2LjUgMjYuMSAxNyAyNS41IDE3SDIyQzIxLjQgMTcgMjEgMTYuNiAyMSAxNlpNMjUuNSAyMC41SDIyQzIxLjUgMjAuNSAyMSAyMC4xIDIxIDE5LjVDMjEgMTguOSAyMS40IDE4LjUgMjIgMTguNUgyNS41QzI2IDE4LjUgMjYuNSAxOC45IDI2LjUgMTkuNUMyNi41IDIwLjEgMjYuMSAyMC41IDI1LjUgMjAuNVoiIGZpbGw9IiNGRjM3NUUiLz4KPC9zdmc+Cg==\"/>\r\n </div>\r\n\r\n <div class=\"flex-grow-1 d-flex flex-column flex-sm-row align-items-sm-center gap-2\">\r\n <div class=\"flex-grow-1\">\r\n <h1 class=\"fs-20 fs-md-16 fw-bold fc-black header-title m-0\">{{ formTitle }}\r\n @if (serviceFaq.length) {\r\n <ds-icon icon=\"info\" class=\"fs-22 fc-dark-gray cursor-pointer\" (click)=\"openFaq()\">\r\n </ds-icon>\r\n }\r\n </h1>\r\n <div class=\"header-user d-flex align-items-sm-center gap-2 mt-sm-1\">\r\n @if (!isLoading) {\r\n <ds-avatar\r\n image=\"{{form?.header?.requesterPhoto}}\" size=\"xx-small\"\r\n class=\"d-inline-flex cursor-pointer\" (click)=\"showUserInfo()\"></ds-avatar>\r\n }\r\n <span\r\n class=\"fs-12 text-truncate d-sm-block cursor-pointer\" (click)=\"showUserInfo()\"\r\n [ngClass]=\"{'loading-bg loading-width': isLoading}\">{{ coreService.getShortName(form?.header?.requesterName) }}</span>\r\n <mat-divider class=\"divider circle mx-2 d-none d-sm-block\"></mat-divider>\r\n <span class=\"fs-12\" [ngClass]=\"{'loading-bg loading-width': isLoading}\">{{ form?.header?.formId }}</span>\r\n @if (creationDate) {\r\n <mat-divider class=\"divider circle mx-2 d-none d-sm-block\"></mat-divider>\r\n <span class=\"fs-14\" [ngClass]=\"{'loading-bg loading-width': isLoading}\">{{ creationDate }}</span>\r\n }\r\n </div>\r\n\r\n </div>\r\n <div class=\"header-actions d-flex flex-row flex-sm-column justify-content-between justify-content-sm-center gap-2 mt-2 mt-sm-0\">\r\n @if (!isLoading) {\r\n <ds-status\r\n status=\"{{statusClass(form?.header?.status?.['key'])}}\" class=\"header-status\">{{ form?.header?.status?.['value'] }}\r\n </ds-status>\r\n }\r\n <div class=\"d-flex align-items-center justify-content-end gap-2\">\r\n <!– feedback–>\r\n <!– *ngIf=\"form?.inboxItem && (form?.inboxItem?.canRequestFeedback ==='true'|| form?.inboxItem?.hasFeedback==='true') && !isLoading\"–>\r\n <!– <ds-button\r\n square icon size=\"small\" (click)=\"feedback()\">\r\n <ds-icon\r\n icon=\"chat-o\" class=\"fs-20 fs-md-17 fc-coral\"\r\n [ngClass]=\"{'fc-green':feedBackIcon === 'feedbackResponded' , 'fc-red': feedBackIcon === 'respondToFeedback' , 'fc-yellow': feedBackIcon === 'waitingFeedback'}\">\r\n </ds-icon>\r\n </ds-button>–>\r\n <ds-button\r\n *ngIf=\"form?.commentsDrop?.length > 0 && !isLoading\" square icon size=\"small\"\r\n (click)=\"onCommentsFormClick()\" class=\"has-comments\">\r\n <ds-icon icon=\"clock\" class=\"fc-coral fs-20 fs-md-17\"></ds-icon>\r\n </ds-button>\r\n @if (showApprovalHistory) {\r\n <ng-container>\r\n <ds-button\r\n color=\"white\" shape=\"text\" square size=\"small\" [satPopoverAnchor]=\"workflow\"\r\n #workflowAnchor=\"satPopoverAnchor\" (click)=\"workflowAnchor.popover.open()\">\r\n <slot name=\"prefix\">\r\n <ds-icon icon=\"workflow\" class=\"fs-24\"></ds-icon>\r\n </slot>\r\n </ds-button>\r\n <sat-popover\r\n #workflow [anchor]=\"workflowAnchor\" [hasBackdrop]=\"true\" verticalAlign=\"below\"\r\n horizontalAlign=\"end\">\r\n <div class=\"default-popover p-3\" style=\"min-width: 330px;\">\r\n <ds-approvals *ngIf=\"approvalHistory\" class=\"popover-approvals\" approvalsData=\"{{approvals}}\">\r\n </ds-approvals>\r\n </div>\r\n </sat-popover>\r\n </ng-container>\r\n }\r\n </div>\r\n </div>\r\n </div>\r\n\r\n </header>\r\n </ng-container>-->\r\n}\r\n", styles: [".loading-width{min-width:100px;width:40px;flex-grow:1}.request-main-info{--item-bg: var(--light-gray);--item-fc: var(--black);--status-container-bc: #e8ebec;--status-container-brc: var(--dark-gray)}.request-main-info.warning{--item-bg: var(--yellow);--status-container-bc: #fff8d9;--status-container-brc: var(--yellow)}.request-main-info.pending{--item-bg: #eff0f1;--status-container-bc: #e8ebec;--status-container-brc: #c8ced1}.request-main-info.expired{--item-bg: var(--dark-gray);--status-container-bc: #e8ebec;--status-container-brc: var(--dark-gray)}.request-main-info.success{--item-bg: var(--green);--status-container-bc: #e6f9f4;--status-container-brc: var(--green)}.request-main-info.info{--item-bg: var(--sea-light);--status-container-bc: #fff8d9;--status-container-brc: var(--sea-light)}.request-main-info.danger{--item-bg: var(--red);--status-container-bc: #fae9ec;--status-container-brc: var(--red)}.request-main-info.orange,.request-main-info.send_back{--item-bg: var(--orange);--status-container-bc: #fff0eb;--status-container-brc: var(--orange)}.request-info{border-radius:0;box-shadow:var(--box-shadow);background-color:var(--white);border-top:5px solid var(--item-bg)}.request-info--footer{padding:.3rem 2rem;min-height:45px;display:flex;align-items:center;gap:.75rem;border-top:1px solid var(--light-gray)}@media (max-width: 578px){.request-info--footer{padding:.3rem 1rem}}.request-info--footer__details{color:var(--item-fc)}.request-info--body{padding:2rem;display:flex;align-items:center;gap:.75rem;background-color:#fff}@media (max-width: 578px){.request-info--body{padding:1rem;flex-direction:column;align-items:stretch}}.request-info--body figure{min-width:30px;width:30px;text-align:center}.request-info--body figure svg{width:100%}@media (max-width: 578px){.request-info--status-action{justify-content:space-between}}.request-info--history{margin-top:-.5rem}.request-info--comment{background-color:#fff0eb;color:var(--orange);border-radius:0 0 4px 4px}.status-container{min-height:40px;padding:.5rem 1rem;display:flex;flex-direction:column;justify-content:center;gap:.5rem;margin-bottom:1.5rem}.status-container.danger{--item-bg: var(--red);--status-container-bc: #fae9ec;--status-container-brc: var(--red)}.status-container ::ng-deep ds-avatar .avatar{--default-size: 18px}.circle-status::part(base){--status-radius: 50%;--status-size: 19px;--status-fs: 100%}ds-button[square]::part(base){--btn-padding: 0;--default-size-sm: 30px}.send-back-container{background-color:#fff0eb;color:var(--orange);padding:.5rem;border-radius:4px}object,iframe,embed{height:79vh}::ng-deep .history-popup{--popup-width: 100vw;--popup-max-width: 100vw;--popup-radius: 15px 15px 0 0;position:absolute!important;bottom:0}:host ::ng-deep .mat-expansion-panel-content{background:#fff!important}:host .main-sidenav.main-sidenav-full .sidenav-title{border-bottom:transparent!important}:host .main-sidenav .sidenav-title{background-color:transparent!important}:host .main-sidenav{height:60px;min-height:10px!important}:host .mat-expansion-panel-content{background:#fff!important}:host .approval-panel-container{display:grid;grid-template-columns:40% calc(60% - 45px) 20px;grid-template-areas:\"title details toggle\";gap:.75rem;place-content:space-between;align-items:center;flex-grow:1;width:100%}@media (max-width: 991px){:host .approval-panel-container{grid-template-columns:calc(100% - 45px) 20px;grid-template-areas:\"title toggle\" \"details details\"}}:host .approval-panel-container .approval-panel-title{grid-area:title}:host .approval-panel-container .panel-user-name{max-width:120px}@media (max-width: 768px){:host .approval-panel-container .panel-user-name.panel-ueser-only{max-width:140px}:host .approval-panel-container .panel-user-name:not(.panel-ueser-only){max-width:90px}}:host .approval-panel-container .approval-panel-details{display:flex;align-items:center;justify-content:space-between;grid-area:details}:host .approval-panel-container .approval-panel-toggle{grid-area:toggle;display:flex;align-items:center;justify-content:center;width:20px}:host ::ng-deep ds-avatar.user-avatar .avatar{--default-size: 25px}@media (min-width: 768px){:host ::ng-deep ds-avatar.user-avatar .avatar{--default-size: 31px;--avatar-border: 3px solid var(--light-gray)}}@media (min-width: 768px){:host ::ng-deep .user-avatar-name{padding-inline-end:1rem!important}}:host .circle-status::part(base){--status-radius: 50%;--status-size: 18px;--status-fs: 80% }:host .panel-title{min-width:40%;width:40%}@media (max-width: 576px){:host .panel-title{min-width:100%!important;width:100%!important}}:host .panel-user-status{min-width:60%;width:60%;display:flex;align-items:center;justify-content:space-between}@media (max-width: 576px){:host .panel-user-status{min-width:100%!important;width:100%!important}:host .panel-user-status .user-delegate{min-width:auto}:host .panel-user-status .main-status::part(base){--status-width: 50px}}\n"] }]
|
|
5956
|
+
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: CoreService }, { type: CoreI18nService }, { type: FeedBackService }, { type: i1$1.MatDialog }, { type: SidenavService }, { type: i3$2.ToastrService }], propDecorators: { form: [{
|
|
5387
5957
|
type: Input
|
|
5388
5958
|
}], showHistory: [{
|
|
5389
5959
|
type: Input
|
|
@@ -5399,7 +5969,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
|
|
|
5399
5969
|
type: Input
|
|
5400
5970
|
}], section: [{
|
|
5401
5971
|
type: Input
|
|
5402
|
-
}],
|
|
5972
|
+
}], serviceFaq: [{
|
|
5403
5973
|
type: Input
|
|
5404
5974
|
}] } });
|
|
5405
5975
|
|
|
@@ -5437,12 +6007,20 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
|
|
|
5437
6007
|
type: Input
|
|
5438
6008
|
}] } });
|
|
5439
6009
|
|
|
6010
|
+
const StatusMap = {
|
|
6011
|
+
[FORM_STATUS_REJECTED]: { class: 'danger', icon: 'close' },
|
|
6012
|
+
[FORM_STATUS_CANCELLED]: { class: 'danger', icon: 'close' },
|
|
6013
|
+
[FORM_STATUS_REJECT]: { class: 'danger', icon: 'close' },
|
|
6014
|
+
[SECTION_STATUS_UNSATISFIED]: { class: 'danger', icon: 'close' },
|
|
6015
|
+
[FORM_STATUS_CANCEL]: { class: 'danger', icon: 'close' },
|
|
6016
|
+
[FORM_STATUS_PENDING]: { class: 'warning', icon: 'clock' },
|
|
6017
|
+
'default': { class: 'success', icon: 'check' }
|
|
6018
|
+
};
|
|
5440
6019
|
class FormSectionComponent {
|
|
5441
6020
|
i18n;
|
|
5442
6021
|
coreService;
|
|
5443
6022
|
sidenavService;
|
|
5444
6023
|
userType = 'recipient';
|
|
5445
|
-
// @ViewChild('popover') popover?: any;
|
|
5446
6024
|
popoverType = 'recipient';
|
|
5447
6025
|
requestDetails;
|
|
5448
6026
|
userPopoverInfo = {};
|
|
@@ -5450,14 +6028,10 @@ class FormSectionComponent {
|
|
|
5450
6028
|
form;
|
|
5451
6029
|
lov;
|
|
5452
6030
|
isReadOnly;
|
|
5453
|
-
// @Input() isOpen: boolean;
|
|
5454
|
-
// @Input() isFinalApproval: boolean;
|
|
5455
6031
|
controllers;
|
|
5456
6032
|
segmentDynamicLoaderService;
|
|
5457
6033
|
sectionFormComponent = null;
|
|
5458
6034
|
sectionName = 'SECTION_NAME.requestDetails';
|
|
5459
|
-
sectionNumber;
|
|
5460
|
-
sectionStatusValue;
|
|
5461
6035
|
sectionStatusKey;
|
|
5462
6036
|
recipient = {
|
|
5463
6037
|
isShowing: false,
|
|
@@ -5468,114 +6042,178 @@ class FormSectionComponent {
|
|
|
5468
6042
|
profile: null
|
|
5469
6043
|
};
|
|
5470
6044
|
input;
|
|
5471
|
-
// highlightFlag: boolean;
|
|
5472
6045
|
processingDate;
|
|
5473
|
-
randomID = Math.floor(Math.random() * (999999 - 100000)) + 100000;
|
|
5474
6046
|
constructor(i18n, coreService, sidenavService) {
|
|
5475
6047
|
this.i18n = i18n;
|
|
5476
6048
|
this.coreService = coreService;
|
|
5477
6049
|
this.sidenavService = sidenavService;
|
|
5478
|
-
// this.highlightFlag = false;
|
|
5479
6050
|
}
|
|
6051
|
+
/**
|
|
6052
|
+
* Method to initialize various components when the component is initialized.
|
|
6053
|
+
*
|
|
6054
|
+
* @return {void}
|
|
6055
|
+
*/
|
|
5480
6056
|
ngOnInit() {
|
|
6057
|
+
this.initSectionFormComponent();
|
|
6058
|
+
this.initSectionName();
|
|
6059
|
+
this.initInput();
|
|
6060
|
+
this.initProcessingDate();
|
|
6061
|
+
}
|
|
6062
|
+
/**
|
|
6063
|
+
* Initializes the section form component by fetching it from the segment dynamic loader service.
|
|
6064
|
+
*
|
|
6065
|
+
* @return {void}
|
|
6066
|
+
*/
|
|
6067
|
+
initSectionFormComponent() {
|
|
5481
6068
|
this.sectionFormComponent = this.segmentDynamicLoaderService.getComponent(this.section.id);
|
|
5482
|
-
|
|
5483
|
-
|
|
6069
|
+
}
|
|
6070
|
+
/**
|
|
6071
|
+
* Initializes the section name based on the provided section data.
|
|
6072
|
+
* If the section's body contains a 'stageName' property, the section name is set to the value of that property.
|
|
6073
|
+
* Otherwise, the section name is retrieved using the segmentDynamicLoaderService based on the section ID.
|
|
6074
|
+
*
|
|
6075
|
+
* @return {void}
|
|
6076
|
+
*/
|
|
6077
|
+
initSectionName() {
|
|
6078
|
+
if (this.section.body.details?.['stageName']) {
|
|
6079
|
+
this.sectionName = this.section.body.details['stageName'];
|
|
5484
6080
|
}
|
|
5485
6081
|
else {
|
|
5486
6082
|
this.sectionName = this.segmentDynamicLoaderService.getSectionName(this.section.id);
|
|
5487
6083
|
}
|
|
6084
|
+
}
|
|
6085
|
+
/**
|
|
6086
|
+
* Initializes the input object with the provided values for read-only status, list of values, section, and form.
|
|
6087
|
+
*
|
|
6088
|
+
* @return {void}
|
|
6089
|
+
*/
|
|
6090
|
+
initInput() {
|
|
5488
6091
|
this.input = {
|
|
5489
6092
|
isReadOnly: this.isReadOnly,
|
|
5490
6093
|
lov: this.lov,
|
|
5491
6094
|
section: this.section,
|
|
5492
|
-
// controllers: this.controllers,
|
|
5493
|
-
// requestDetails: this.requestDetails,
|
|
5494
6095
|
form: this.form
|
|
5495
6096
|
};
|
|
5496
|
-
if (this.section.header && this.section.header.processingDate) {
|
|
5497
|
-
this.processingDate = moment(this.section.header.processingDate)
|
|
5498
|
-
.locale('en-US')
|
|
5499
|
-
.format('DD/MM/YYYY HH:mm:ss');
|
|
5500
|
-
}
|
|
5501
|
-
// this.highlightFlag = this.isOpen;
|
|
5502
|
-
const x = document.querySelectorAll('#collapse' + this.sectionId());
|
|
5503
|
-
if (x.length > 0) {
|
|
5504
|
-
this.sectionNumber = x.length;
|
|
5505
|
-
}
|
|
5506
6097
|
}
|
|
6098
|
+
/**
|
|
6099
|
+
* Initializes the processing date based on the section's header processing date.
|
|
6100
|
+
* If the processing date is available in the section header, it formats the processing date
|
|
6101
|
+
* and assigns it to the processingDate property of the instance.
|
|
6102
|
+
*
|
|
6103
|
+
* @return {void}
|
|
6104
|
+
*/
|
|
6105
|
+
initProcessingDate() {
|
|
6106
|
+
if (this.section?.header?.processingDate) {
|
|
6107
|
+
this.processingDate = format(new Date(this.section.header.processingDate), "dd/MM/yyyy hh:mm:ss");
|
|
6108
|
+
}
|
|
6109
|
+
}
|
|
6110
|
+
/**
|
|
6111
|
+
* Check if the section is expanded.
|
|
6112
|
+
*
|
|
6113
|
+
* @return {boolean} Returns true if the section is expanded, false otherwise.
|
|
6114
|
+
*/
|
|
5507
6115
|
get isExpanded() {
|
|
5508
|
-
const
|
|
5509
|
-
|
|
5510
|
-
|
|
5511
|
-
|
|
5512
|
-
|
|
5513
|
-
|
|
5514
|
-
|
|
5515
|
-
|
|
6116
|
+
const hasSections = Boolean(this.form?.sections?.length);
|
|
6117
|
+
const isAnySectionExpandable = hasSections && this.form.sections.some(section => 'expandStage' in (section?.body?.details || {}));
|
|
6118
|
+
return isAnySectionExpandable ? (this.section?.body?.details?.['expandStage'] === 'true') : true;
|
|
6119
|
+
}
|
|
6120
|
+
/**
|
|
6121
|
+
* Create a ProfileInfoDrop object from the response object.
|
|
6122
|
+
*
|
|
6123
|
+
* @param {any} response - The response object containing user profile information.
|
|
6124
|
+
*
|
|
6125
|
+
* @return {ProfileInfoDrop} A ProfileInfoDrop object created from the response data.
|
|
6126
|
+
*/
|
|
5516
6127
|
createUserProfileFromResponse(response) {
|
|
5517
|
-
|
|
5518
|
-
|
|
6128
|
+
const user = response?.["Users"][0];
|
|
6129
|
+
return new ProfileInfoDrop(false, user?.employeeNumber, user?.email, user?.name, user?.generalDepartment?.name, user?.position?.name, user?.sector?.name, user?.department?.name, user?.generalDepartment?.code, user?.location, user?.nationality?.desc, user?.contact?.mobile, user?.manager?.name, user?.seniorSectorName?.name);
|
|
6130
|
+
}
|
|
6131
|
+
/**
|
|
6132
|
+
* Method to open or create a user profile.
|
|
6133
|
+
*
|
|
6134
|
+
* @param {ProfileInfoDrop} userData - The user profile data to open or create.
|
|
6135
|
+
* @param {string} personType - The type of person this profile belongs to.
|
|
6136
|
+
*
|
|
6137
|
+
* @return {void}
|
|
6138
|
+
*/
|
|
5519
6139
|
openOrCreateUserProfile(userData, personType) {
|
|
5520
6140
|
this.sidenavService.data = userData;
|
|
5521
6141
|
this.userPopoverInfo = userData;
|
|
5522
6142
|
this[personType].profile = userData;
|
|
5523
6143
|
this.sidenavService.publish('open', ProfileSectionComponent);
|
|
5524
6144
|
}
|
|
6145
|
+
/**
|
|
6146
|
+
* Toggles the display of small profile information for a given person type
|
|
6147
|
+
*
|
|
6148
|
+
* @param {any} event - The event that triggered the toggle
|
|
6149
|
+
* @param {string} personType - The type of person for which to display the profile information
|
|
6150
|
+
*
|
|
6151
|
+
* @return {void}
|
|
6152
|
+
*/
|
|
5525
6153
|
toggleSmallProfileInfo(event, personType) {
|
|
5526
6154
|
this.userType = personType;
|
|
5527
6155
|
event.stopPropagation();
|
|
5528
6156
|
let userInfo = this[personType];
|
|
5529
|
-
if (userInfo.profile
|
|
6157
|
+
if (!userInfo.profile) {
|
|
5530
6158
|
this.popoverType = personType;
|
|
5531
|
-
let userEmail =
|
|
5532
|
-
this.
|
|
5533
|
-
if (response) {
|
|
5534
|
-
let userData = this.createUserProfileFromResponse(response);
|
|
5535
|
-
this.openOrCreateUserProfile(userData, personType);
|
|
5536
|
-
}
|
|
5537
|
-
});
|
|
6159
|
+
let userEmail = this.getUserEmail(personType);
|
|
6160
|
+
this.fetchAndSetUserProfile(userEmail, personType);
|
|
5538
6161
|
}
|
|
5539
6162
|
else {
|
|
5540
|
-
this.openOrCreateUserProfile(
|
|
5541
|
-
}
|
|
5542
|
-
}
|
|
5543
|
-
|
|
5544
|
-
|
|
5545
|
-
|
|
5546
|
-
|
|
5547
|
-
|
|
5548
|
-
|
|
5549
|
-
|
|
5550
|
-
|
|
5551
|
-
|
|
5552
|
-
|
|
5553
|
-
|
|
6163
|
+
this.openOrCreateUserProfile(userInfo.profile, personType);
|
|
6164
|
+
}
|
|
6165
|
+
}
|
|
6166
|
+
/**
|
|
6167
|
+
* Retrieves the email of the user based on the personType parameter.
|
|
6168
|
+
*
|
|
6169
|
+
* @param {string} personType - Type of the person ('recipient' or others).
|
|
6170
|
+
* @return {string} - The email address of the user.
|
|
6171
|
+
*/
|
|
6172
|
+
getUserEmail(personType) {
|
|
6173
|
+
return (personType === 'recipient'
|
|
6174
|
+
? this.section.header.personToThumbnail.split('=')[1]
|
|
6175
|
+
: this?.section?.header?.delegatedToThumbnail.split('=')[1]);
|
|
6176
|
+
}
|
|
6177
|
+
/**
|
|
6178
|
+
* Fetches the user profile using the provided user email and person type, then sets the profile.
|
|
6179
|
+
*
|
|
6180
|
+
* @param {string} userEmail - The email of the user whose profile is to be fetched and set.
|
|
6181
|
+
* @param {string} personType - The type of person (e.g., employee, customer) for whom the profile is being fetched.
|
|
6182
|
+
*
|
|
6183
|
+
* @return {void}
|
|
6184
|
+
*/
|
|
6185
|
+
fetchAndSetUserProfile(userEmail, personType) {
|
|
6186
|
+
this.coreService.employeeProfile(userEmail).subscribe((response) => {
|
|
6187
|
+
if (response) {
|
|
6188
|
+
let userData = this.createUserProfileFromResponse(response);
|
|
6189
|
+
this.openOrCreateUserProfile(userData, personType);
|
|
5554
6190
|
}
|
|
5555
|
-
}
|
|
5556
|
-
else {
|
|
5557
|
-
return 'success';
|
|
5558
|
-
}
|
|
6191
|
+
});
|
|
5559
6192
|
}
|
|
6193
|
+
/**
|
|
6194
|
+
* Returns the CSS class associated with the input status.
|
|
6195
|
+
*
|
|
6196
|
+
* @param {string} status - The status for which the CSS class is needed.
|
|
6197
|
+
* @return {string} - The CSS class corresponding to the given status.
|
|
6198
|
+
*/
|
|
6199
|
+
statusClass(status) {
|
|
6200
|
+
status = status ? status.toLowerCase() : '';
|
|
6201
|
+
let statusStrategy = StatusMap[status] || StatusMap['default'];
|
|
6202
|
+
return statusStrategy.class;
|
|
6203
|
+
}
|
|
6204
|
+
/**
|
|
6205
|
+
* Returns the icon associated with the provided status.
|
|
6206
|
+
*
|
|
6207
|
+
* @param {string} status - The status for which to retrieve the icon.
|
|
6208
|
+
* @return {string} The icon corresponding to the provided status.
|
|
6209
|
+
*/
|
|
5560
6210
|
statusIcon(status) {
|
|
5561
|
-
|
|
5562
|
-
|
|
5563
|
-
|
|
5564
|
-
return 'close';
|
|
5565
|
-
}
|
|
5566
|
-
else if (status === FORM_STATUS_PENDING || status.toLowerCase() === 'pending') {
|
|
5567
|
-
return 'clock';
|
|
5568
|
-
}
|
|
5569
|
-
else {
|
|
5570
|
-
return 'check';
|
|
5571
|
-
}
|
|
5572
|
-
}
|
|
5573
|
-
else {
|
|
5574
|
-
return 'check';
|
|
5575
|
-
}
|
|
6211
|
+
status = status ? status.toLowerCase() : '';
|
|
6212
|
+
let statusStrategy = StatusMap[status] || StatusMap['default'];
|
|
6213
|
+
return statusStrategy.icon;
|
|
5576
6214
|
}
|
|
5577
6215
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: FormSectionComponent, deps: [{ token: CoreI18nService }, { token: CoreService }, { token: SidenavService }], target: i0.ɵɵFactoryTarget.Component });
|
|
5578
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
|
|
6216
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: FormSectionComponent, isStandalone: true, selector: "app-form-section", inputs: { requestDetails: "requestDetails", section: "section", form: "form", lov: "lov", isReadOnly: "isReadOnly", controllers: "controllers", segmentDynamicLoaderService: "segmentDynamicLoaderService", sectionFormComponent: "sectionFormComponent", sectionName: "sectionName" }, ngImport: i0, template: "<mat-expansion-panel class=\"mb-4\" [expanded]=\"isExpanded\" hideToggle #approvalPanel=\"matExpansionPanel\">\r\n <mat-expansion-panel-header>\r\n\r\n <div class=\"approval-panel-container\">\r\n <div class=\"d-flex gap-2 flex-grow-1 approval-panel-title\">\r\n <ds-status\r\n status=\"{{statusClass(sectionStatusKey)}}\" no-opacity icon\r\n class=\"circle-status d-none d-sm-inline-block\">\r\n <ds-icon icon=\"{{statusIcon(sectionStatusKey)}}\"></ds-icon>\r\n </ds-status>\r\n <div class=\"d-flex flex-column flex-grow-1\">\r\n <span class=\"fs-16 fw-medium m-0\"> {{ sectionName }}</span>\r\n @if (section.header?.processedBy) {\r\n <bdi class=\"fs-12 fc-dark-gray fw-normal line-height-1 d-block mt-1\">\r\n {{ processingDate }}\r\n </bdi>\r\n }\r\n </div>\r\n </div>\r\n <div class=\"approval-panel-details gap-1\">\r\n @if (!section?.body?.details?.['stage0']?.['isStage0'] || section?.body?.details?.['stage0']?.['isStage0'] === 'false') {\r\n <ng-container>\r\n @if (section?.header?.personTo) {\r\n <div\r\n class=\"d-flex align-items-center gap-3\"\r\n (click)=\"$event.stopImmediatePropagation();\">\r\n <div\r\n (click)=\"toggleSmallProfileInfo($event, 'recipient')\"\r\n class=\"d-flex align-items-center gap-2 radius-3 h-40\"\r\n [ngClass]=\"{'user-avatar-name px-0 px-md-2': !section?.header?.delegatedTo, 'p-0': section?.header?.delegatedTo}\">\r\n <ds-avatar image=\"{{section?.header?.personToThumbnail}}\" size=\"small\" class=\"user-avatar\"></ds-avatar>\r\n @if (!section?.header?.delegatedTo) {\r\n <span\r\n class=\"fs-14 fw-medium d-inline-block panel-user-name text-truncate\"\r\n [ngClass]=\"{'panel-user-only': !section?.header?.delegatedTo}\"\r\n >{{ section?.header?.personTo }}</span>\r\n }\r\n </div>\r\n @if (section?.header?.delegatedTo) {\r\n <div\r\n class=\"d-flex align-items-center gap-3\"\r\n (click)=\"toggleSmallProfileInfo($event, 'delegate')\">\r\n <img\r\n class=\"rotate-arrow\"\r\n alt=\"\"\r\n src=\"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyMSIgaGVpZ2h0PSIxMyIgdmlld0JveD0iMCAwIDIxIDEzIj48cGF0aCBkPSJNMjEsNy43NjNhMS42MjEsMS42MjEsMCwwLDEtLjQ0Ny41OTMsMS4zMDYsMS4zMDYsMCwwLDEtLjc1LjE5NGMtNy4yODQsMC04LjU2OCwwLTE1Ljg1MywwSDMuNjY5TDMuNjMsOC42Yy4wNzcuMDY0LjE1OC4xMjQuMjI5LjE5NHExLjcxLDEuNjksMy40MiwzLjM4MWExLjAyMywxLjAyMywwLDAsMSwuMjkxLDEuMDc5Ljk5Mi45OTIsMCwwLDEtLjguNzE5LDEuMDUzLDEuMDUzLDAsMCwxLTEtLjMzMVEzLjgzMSwxMS43MTksMS44ODYsOS44Yy0uNDQyLS40MzctLjg3OS0uODgxLTEuMzMtMS4zMDlBNC41NzIsNC41NzIsMCwwLDEsMCw3LjgxNFY3LjE4NUEzMC43ODMsMzAuNzgzLDAsMCwxLDIuNzMsNC4zNzFjMS0xLjAyNywyLjAzOC0yLjAyNSwzLjA2My0zLjAzMkExLjA0OSwxLjA0OSwwLDEsMSw3LjI3NywyLjgyQzYuNCwzLjcsNS41MDksNC41Nyw0LjYyNSw1LjQ0NmMtLjMyMy4zMjEtLjY0NC42NDUtLjk3My45NzYuMDg0LjA1OS4xODEuMDI3LjI3LjAyNyw3LjI1OCwwLDguNTE2LDAsMTUuNzc1LDBBMS4xMjksMS4xMjksMCwwLDEsMjEsNy4yOXYuNDcyWiIgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMCAtMC45OTkpIiBmaWxsPSIjYTU0ZWUxIi8+PC9zdmc+\"/>\r\n <div class=\"d-flex align-items-center gap-2 px-0 px-md-2 radius-3 user-avatar-name h-40\">\r\n <ds-avatar image=\"{{section?.header?.delegatedToThumbnail}}\" size=\"small\" class=\"user-avatar\"></ds-avatar>\r\n <span\r\n class=\"fs-14 fw-medium d-inline-block panel-user-name text-truncate\">{{ section?.header?.delegatedTo }}</span>\r\n </div>\r\n </div>\r\n }\r\n </div>\r\n }\r\n </ng-container>\r\n }\r\n\r\n @if (section?.body?.details?.['decision']?.key) {\r\n <ds-status\r\n class=\"main-status\"\r\n status=\"{{statusClass(section?.body?.details?.['decision']?.key)}}\">{{ section?.body?.details?.['decision']?.value }}\r\n </ds-status>\r\n }\r\n </div>\r\n\r\n <div class=\"approval-panel-toggle\">\r\n @if (approvalPanel.expanded) {\r\n <ds-icon icon=\"minus\" class=\"fs-20 fc-dark-gray\"></ds-icon>\r\n } @else {\r\n <ds-icon icon=\"plus-1\" class=\"fs-20 fc-coral\"></ds-icon>\r\n }\r\n </div>\r\n\r\n </div>\r\n </mat-expansion-panel-header>\r\n <section class=\"border-top pt-4\">\r\n <ng-container *ngComponentOutlet=\"sectionFormComponent; ndcDynamicInputs: input\"></ng-container>\r\n </section>\r\n\r\n</mat-expansion-panel>\r\n", styles: [":host ::ng-deep .mat-expansion-panel-content{background:#fff!important}:host .mat-expansion-panel-content{background:#fff!important}:host .approval-panel-container{display:grid;grid-template-columns:40% calc(60% - 45px) 20px;grid-template-areas:\"title details toggle\";gap:.75rem;place-content:space-between;align-items:center;flex-grow:1;width:100%}@media (max-width: 991px){:host .approval-panel-container{grid-template-columns:calc(100% - 45px) 20px;grid-template-areas:\"title toggle\" \"details details\"}}:host .approval-panel-container .approval-panel-title{grid-area:title}:host .approval-panel-container .panel-user-name{max-width:120px}@media (max-width: 768px){:host .approval-panel-container .panel-user-name.panel-ueser-only{max-width:140px}:host .approval-panel-container .panel-user-name:not(.panel-ueser-only){max-width:90px}}:host .approval-panel-container .approval-panel-details{display:flex;align-items:center;justify-content:space-between;grid-area:details}:host .approval-panel-container .approval-panel-toggle{grid-area:toggle;display:flex;align-items:center;justify-content:center;width:20px}:host ::ng-deep ds-avatar.user-avatar .avatar{--default-size: 25px}@media (min-width: 768px){:host ::ng-deep ds-avatar.user-avatar .avatar{--default-size: 31px;--avatar-border: 3px solid var(--light-gray)}}@media (min-width: 768px){:host ::ng-deep .user-avatar-name{padding-inline-end:1rem!important}}:host .circle-status::part(base){--status-radius: 50%;--status-size: 18px;--status-fs: 80% }:host .panel-title{min-width:40%;width:40%}@media (max-width: 576px){:host .panel-title{min-width:100%!important;width:100%!important}}:host .panel-user-status{min-width:60%;width:60%;display:flex;align-items:center;justify-content:space-between}@media (max-width: 576px){:host .panel-user-status{min-width:100%!important;width:100%!important}:host .panel-user-status .user-delegate{min-width:auto}:host .panel-user-status .main-status::part(base){--status-width: 50px}}\n"], dependencies: [{ kind: "ngmodule", type: MatExpansionModule }, { kind: "component", type: i2$3.MatExpansionPanel, selector: "mat-expansion-panel", inputs: ["hideToggle", "togglePosition"], outputs: ["afterExpand", "afterCollapse"], exportAs: ["matExpansionPanel"] }, { kind: "component", type: i2$3.MatExpansionPanelHeader, selector: "mat-expansion-panel-header", inputs: ["expandedHeight", "collapsedHeight", "tabIndex"] }, { kind: "directive", type: NgComponentOutlet, selector: "[ngComponentOutlet]", inputs: ["ngComponentOutlet", "ngComponentOutletInputs", "ngComponentOutletInjector", "ngComponentOutletContent", "ngComponentOutletNgModule", "ngComponentOutletNgModuleFactory"] }, { kind: "directive", type: ComponentOutletIoDirective, selector: "[ngComponentOutletNdcDynamicInputs],[ngComponentOutletNdcDynamicOutputs]", inputs: ["ngComponentOutletNdcDynamicInputs", "ngComponentOutletNdcDynamicOutputs"], exportAs: ["ndcDynamicIo"] }, { kind: "ngmodule", type: SatPopoverModule }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "ngmodule", type: DynamicModule }, { kind: "directive", type: i3$3.ComponentOutletInjectorDirective, selector: "[ngComponentOutlet]", exportAs: ["ndcComponentOutletInjector"] }] });
|
|
5579
6217
|
}
|
|
5580
6218
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: FormSectionComponent, decorators: [{
|
|
5581
6219
|
type: Component,
|
|
@@ -5588,7 +6226,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
|
|
|
5588
6226
|
SatPopoverModule,
|
|
5589
6227
|
NgClass,
|
|
5590
6228
|
DynamicModule
|
|
5591
|
-
], schemas: [CUSTOM_ELEMENTS_SCHEMA], template: "<mat-expansion-panel
|
|
6229
|
+
], schemas: [CUSTOM_ELEMENTS_SCHEMA], template: "<mat-expansion-panel class=\"mb-4\" [expanded]=\"isExpanded\" hideToggle #approvalPanel=\"matExpansionPanel\">\r\n <mat-expansion-panel-header>\r\n\r\n <div class=\"approval-panel-container\">\r\n <div class=\"d-flex gap-2 flex-grow-1 approval-panel-title\">\r\n <ds-status\r\n status=\"{{statusClass(sectionStatusKey)}}\" no-opacity icon\r\n class=\"circle-status d-none d-sm-inline-block\">\r\n <ds-icon icon=\"{{statusIcon(sectionStatusKey)}}\"></ds-icon>\r\n </ds-status>\r\n <div class=\"d-flex flex-column flex-grow-1\">\r\n <span class=\"fs-16 fw-medium m-0\"> {{ sectionName }}</span>\r\n @if (section.header?.processedBy) {\r\n <bdi class=\"fs-12 fc-dark-gray fw-normal line-height-1 d-block mt-1\">\r\n {{ processingDate }}\r\n </bdi>\r\n }\r\n </div>\r\n </div>\r\n <div class=\"approval-panel-details gap-1\">\r\n @if (!section?.body?.details?.['stage0']?.['isStage0'] || section?.body?.details?.['stage0']?.['isStage0'] === 'false') {\r\n <ng-container>\r\n @if (section?.header?.personTo) {\r\n <div\r\n class=\"d-flex align-items-center gap-3\"\r\n (click)=\"$event.stopImmediatePropagation();\">\r\n <div\r\n (click)=\"toggleSmallProfileInfo($event, 'recipient')\"\r\n class=\"d-flex align-items-center gap-2 radius-3 h-40\"\r\n [ngClass]=\"{'user-avatar-name px-0 px-md-2': !section?.header?.delegatedTo, 'p-0': section?.header?.delegatedTo}\">\r\n <ds-avatar image=\"{{section?.header?.personToThumbnail}}\" size=\"small\" class=\"user-avatar\"></ds-avatar>\r\n @if (!section?.header?.delegatedTo) {\r\n <span\r\n class=\"fs-14 fw-medium d-inline-block panel-user-name text-truncate\"\r\n [ngClass]=\"{'panel-user-only': !section?.header?.delegatedTo}\"\r\n >{{ section?.header?.personTo }}</span>\r\n }\r\n </div>\r\n @if (section?.header?.delegatedTo) {\r\n <div\r\n class=\"d-flex align-items-center gap-3\"\r\n (click)=\"toggleSmallProfileInfo($event, 'delegate')\">\r\n <img\r\n class=\"rotate-arrow\"\r\n alt=\"\"\r\n src=\"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyMSIgaGVpZ2h0PSIxMyIgdmlld0JveD0iMCAwIDIxIDEzIj48cGF0aCBkPSJNMjEsNy43NjNhMS42MjEsMS42MjEsMCwwLDEtLjQ0Ny41OTMsMS4zMDYsMS4zMDYsMCwwLDEtLjc1LjE5NGMtNy4yODQsMC04LjU2OCwwLTE1Ljg1MywwSDMuNjY5TDMuNjMsOC42Yy4wNzcuMDY0LjE1OC4xMjQuMjI5LjE5NHExLjcxLDEuNjksMy40MiwzLjM4MWExLjAyMywxLjAyMywwLDAsMSwuMjkxLDEuMDc5Ljk5Mi45OTIsMCwwLDEtLjguNzE5LDEuMDUzLDEuMDUzLDAsMCwxLTEtLjMzMVEzLjgzMSwxMS43MTksMS44ODYsOS44Yy0uNDQyLS40MzctLjg3OS0uODgxLTEuMzMtMS4zMDlBNC41NzIsNC41NzIsMCwwLDEsMCw3LjgxNFY3LjE4NUEzMC43ODMsMzAuNzgzLDAsMCwxLDIuNzMsNC4zNzFjMS0xLjAyNywyLjAzOC0yLjAyNSwzLjA2My0zLjAzMkExLjA0OSwxLjA0OSwwLDEsMSw3LjI3NywyLjgyQzYuNCwzLjcsNS41MDksNC41Nyw0LjYyNSw1LjQ0NmMtLjMyMy4zMjEtLjY0NC42NDUtLjk3My45NzYuMDg0LjA1OS4xODEuMDI3LjI3LjAyNyw3LjI1OCwwLDguNTE2LDAsMTUuNzc1LDBBMS4xMjksMS4xMjksMCwwLDEsMjEsNy4yOXYuNDcyWiIgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMCAtMC45OTkpIiBmaWxsPSIjYTU0ZWUxIi8+PC9zdmc+\"/>\r\n <div class=\"d-flex align-items-center gap-2 px-0 px-md-2 radius-3 user-avatar-name h-40\">\r\n <ds-avatar image=\"{{section?.header?.delegatedToThumbnail}}\" size=\"small\" class=\"user-avatar\"></ds-avatar>\r\n <span\r\n class=\"fs-14 fw-medium d-inline-block panel-user-name text-truncate\">{{ section?.header?.delegatedTo }}</span>\r\n </div>\r\n </div>\r\n }\r\n </div>\r\n }\r\n </ng-container>\r\n }\r\n\r\n @if (section?.body?.details?.['decision']?.key) {\r\n <ds-status\r\n class=\"main-status\"\r\n status=\"{{statusClass(section?.body?.details?.['decision']?.key)}}\">{{ section?.body?.details?.['decision']?.value }}\r\n </ds-status>\r\n }\r\n </div>\r\n\r\n <div class=\"approval-panel-toggle\">\r\n @if (approvalPanel.expanded) {\r\n <ds-icon icon=\"minus\" class=\"fs-20 fc-dark-gray\"></ds-icon>\r\n } @else {\r\n <ds-icon icon=\"plus-1\" class=\"fs-20 fc-coral\"></ds-icon>\r\n }\r\n </div>\r\n\r\n </div>\r\n </mat-expansion-panel-header>\r\n <section class=\"border-top pt-4\">\r\n <ng-container *ngComponentOutlet=\"sectionFormComponent; ndcDynamicInputs: input\"></ng-container>\r\n </section>\r\n\r\n</mat-expansion-panel>\r\n", styles: [":host ::ng-deep .mat-expansion-panel-content{background:#fff!important}:host .mat-expansion-panel-content{background:#fff!important}:host .approval-panel-container{display:grid;grid-template-columns:40% calc(60% - 45px) 20px;grid-template-areas:\"title details toggle\";gap:.75rem;place-content:space-between;align-items:center;flex-grow:1;width:100%}@media (max-width: 991px){:host .approval-panel-container{grid-template-columns:calc(100% - 45px) 20px;grid-template-areas:\"title toggle\" \"details details\"}}:host .approval-panel-container .approval-panel-title{grid-area:title}:host .approval-panel-container .panel-user-name{max-width:120px}@media (max-width: 768px){:host .approval-panel-container .panel-user-name.panel-ueser-only{max-width:140px}:host .approval-panel-container .panel-user-name:not(.panel-ueser-only){max-width:90px}}:host .approval-panel-container .approval-panel-details{display:flex;align-items:center;justify-content:space-between;grid-area:details}:host .approval-panel-container .approval-panel-toggle{grid-area:toggle;display:flex;align-items:center;justify-content:center;width:20px}:host ::ng-deep ds-avatar.user-avatar .avatar{--default-size: 25px}@media (min-width: 768px){:host ::ng-deep ds-avatar.user-avatar .avatar{--default-size: 31px;--avatar-border: 3px solid var(--light-gray)}}@media (min-width: 768px){:host ::ng-deep .user-avatar-name{padding-inline-end:1rem!important}}:host .circle-status::part(base){--status-radius: 50%;--status-size: 18px;--status-fs: 80% }:host .panel-title{min-width:40%;width:40%}@media (max-width: 576px){:host .panel-title{min-width:100%!important;width:100%!important}}:host .panel-user-status{min-width:60%;width:60%;display:flex;align-items:center;justify-content:space-between}@media (max-width: 576px){:host .panel-user-status{min-width:100%!important;width:100%!important}:host .panel-user-status .user-delegate{min-width:auto}:host .panel-user-status .main-status::part(base){--status-width: 50px}}\n"] }]
|
|
5592
6230
|
}], ctorParameters: () => [{ type: CoreI18nService }, { type: CoreService }, { type: SidenavService }], propDecorators: { requestDetails: [{
|
|
5593
6231
|
type: Input
|
|
5594
6232
|
}], section: [{
|
|
@@ -5618,19 +6256,18 @@ class MainRequestDetailsComponent {
|
|
|
5618
6256
|
this.i18n = i18n;
|
|
5619
6257
|
}
|
|
5620
6258
|
get isExpanded() {
|
|
5621
|
-
return this.section?.body?.details?.expandStage === 'true';
|
|
6259
|
+
return this.section?.body?.details?.['expandStage'] === 'true';
|
|
5622
6260
|
}
|
|
5623
6261
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: MainRequestDetailsComponent, deps: [{ token: CoreI18nService }], target: i0.ɵɵFactoryTarget.Component });
|
|
5624
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
|
|
6262
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: MainRequestDetailsComponent, isStandalone: true, selector: "app-main-request-details", inputs: { section: "section", lov: "lov", form: "form" }, ngImport: i0, template: "<mat-accordion class=\"primary-accordion main-request-accordion border-top\">\r\n <mat-expansion-panel [expanded]=\"isExpanded || (form?.sections?.length === 1 )\" class=\"mb-3\" hideToggle #requestPanel=\"matExpansionPanel\">\r\n <mat-expansion-panel-header>\r\n <h2 class=\"fs-16 fw-medium fc-coral m-0 flex-grow-1\">{{ i18n.translate('requestDetailsTitle') }}</h2>\r\n @if (requestPanel.expanded) {\r\n <div class=\"d-inline-flex align-items-center gap-2\">\r\n <ds-icon icon=\"minus\" class=\"fs-20 fc-dark-gray\"></ds-icon>\r\n </div>\r\n } @else {\r\n <div class=\"d-inline-flex align-items-center gap-2\">\r\n <ds-icon icon=\"plus-1\" class=\"fs-20 fc-coral\"></ds-icon>\r\n </div>\r\n }\r\n </mat-expansion-panel-header>\r\n <section class=\"default-box box-shadow p-4\">\r\n <ng-content></ng-content>\r\n </section>\r\n </mat-expansion-panel>\r\n</mat-accordion>\r\n", styles: [".main-request-accordion{--accordion-height: 65px;--accordion-radius: 0 0 4px 4px;--accordion-shadow: 0 7px 10px rgba(var(--rgb-black), 3%);--accordion-border: 1px solid var(--light-gray);--accordion-border-active: 1px solid var(--gray);--panel-padding: 0 1.5rem;--panel-body-padding: 0 0 1.5rem;position:relative;z-index:1}@media (max-width: 576px){.main-request-accordion{--accordion-height: 55px;--panel-padding: 0 1rem;--panel-body-padding: 0 1rem 1rem}}.main-request-accordion .inner-accordion{--accordion-height: 44px;--accordion-bc: var(--light-gray);--accordion-bc-active: var(--white);--accordion-border: 1px solid var(--light-gray);--accordion-border-active: 1px solid var(--light-gray);--panel-body-padding: 0;--accordion-shadow: none;--panel-padding: 0 1.5rem}\n"], dependencies: [{ kind: "ngmodule", type: MatExpansionModule }, { kind: "directive", type: i2$3.MatAccordion, selector: "mat-accordion", inputs: ["hideToggle", "displayMode", "togglePosition"], exportAs: ["matAccordion"] }, { kind: "component", type: i2$3.MatExpansionPanel, selector: "mat-expansion-panel", inputs: ["hideToggle", "togglePosition"], outputs: ["afterExpand", "afterCollapse"], exportAs: ["matExpansionPanel"] }, { kind: "component", type: i2$3.MatExpansionPanelHeader, selector: "mat-expansion-panel-header", inputs: ["expandedHeight", "collapsedHeight", "tabIndex"] }] });
|
|
5625
6263
|
}
|
|
5626
6264
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: MainRequestDetailsComponent, decorators: [{
|
|
5627
6265
|
type: Component,
|
|
5628
6266
|
args: [{ selector: 'app-main-request-details', standalone: true, schemas: [CUSTOM_ELEMENTS_SCHEMA], imports: [
|
|
5629
6267
|
MatExpansionModule,
|
|
5630
6268
|
MatAccordion,
|
|
5631
|
-
MatExpansionPanel
|
|
5632
|
-
|
|
5633
|
-
], template: "<mat-accordion class=\"primary-accordion main-request-accordion border-top\">\r\n <mat-expansion-panel [expanded]=\"isExpanded || (form?.sections?.length === 1 )\" class=\"mb-3\" hideToggle #requestPanel=\"matExpansionPanel\">\r\n <mat-expansion-panel-header>\r\n <h2 class=\"fs-16 fw-medium fc-coral m-0 flex-grow-1\">{{i18n.translate('requestDetailsTitle')}}</h2>\r\n <div class=\"d-inline-flex align-items-center gap-2\" *ngIf=\"!requestPanel.expanded\">\r\n <ds-icon icon=\"plus-1\" class=\"fs-20 fc-coral\"></ds-icon>\r\n </div>\r\n <div class=\"d-inline-flex align-items-center gap-2\" *ngIf=\"requestPanel.expanded\">\r\n <ds-icon icon=\"minus\" class=\"fs-20 fc-dark-gray\"></ds-icon>\r\n </div>\r\n </mat-expansion-panel-header>\r\n <section class=\"default-box box-shadow p-4\">\r\n <ng-content ></ng-content>\r\n </section>\r\n </mat-expansion-panel>\r\n</mat-accordion>\r\n", styles: [".main-request-accordion{--accordion-height: 65px;--accordion-radius: 0 0 4px 4px;--accordion-shadow: 0 7px 10px rgba(var(--rgb-black), 3%);--accordion-border: 1px solid var(--light-gray);--accordion-border-active: 1px solid var(--gray);--panel-padding: 0 1.5rem;--panel-body-padding: 0 0 1.5rem;position:relative;z-index:1}@media (max-width: 576px){.main-request-accordion{--accordion-height: 55px;--panel-padding: 0 1rem;--panel-body-padding: 0 1rem 1rem}}.main-request-accordion .inner-accordion{--accordion-height: 44px;--accordion-bc: var(--light-gray);--accordion-bc-active: var(--white);--accordion-border: 1px solid var(--light-gray);--accordion-border-active: 1px solid var(--light-gray);--panel-body-padding: 0;--accordion-shadow: none;--panel-padding: 0 1.5rem}\n"] }]
|
|
6269
|
+
MatExpansionPanel
|
|
6270
|
+
], template: "<mat-accordion class=\"primary-accordion main-request-accordion border-top\">\r\n <mat-expansion-panel [expanded]=\"isExpanded || (form?.sections?.length === 1 )\" class=\"mb-3\" hideToggle #requestPanel=\"matExpansionPanel\">\r\n <mat-expansion-panel-header>\r\n <h2 class=\"fs-16 fw-medium fc-coral m-0 flex-grow-1\">{{ i18n.translate('requestDetailsTitle') }}</h2>\r\n @if (requestPanel.expanded) {\r\n <div class=\"d-inline-flex align-items-center gap-2\">\r\n <ds-icon icon=\"minus\" class=\"fs-20 fc-dark-gray\"></ds-icon>\r\n </div>\r\n } @else {\r\n <div class=\"d-inline-flex align-items-center gap-2\">\r\n <ds-icon icon=\"plus-1\" class=\"fs-20 fc-coral\"></ds-icon>\r\n </div>\r\n }\r\n </mat-expansion-panel-header>\r\n <section class=\"default-box box-shadow p-4\">\r\n <ng-content></ng-content>\r\n </section>\r\n </mat-expansion-panel>\r\n</mat-accordion>\r\n", styles: [".main-request-accordion{--accordion-height: 65px;--accordion-radius: 0 0 4px 4px;--accordion-shadow: 0 7px 10px rgba(var(--rgb-black), 3%);--accordion-border: 1px solid var(--light-gray);--accordion-border-active: 1px solid var(--gray);--panel-padding: 0 1.5rem;--panel-body-padding: 0 0 1.5rem;position:relative;z-index:1}@media (max-width: 576px){.main-request-accordion{--accordion-height: 55px;--panel-padding: 0 1rem;--panel-body-padding: 0 1rem 1rem}}.main-request-accordion .inner-accordion{--accordion-height: 44px;--accordion-bc: var(--light-gray);--accordion-bc-active: var(--white);--accordion-border: 1px solid var(--light-gray);--accordion-border-active: 1px solid var(--light-gray);--panel-body-padding: 0;--accordion-shadow: none;--panel-padding: 0 1.5rem}\n"] }]
|
|
5634
6271
|
}], ctorParameters: () => [{ type: CoreI18nService }], propDecorators: { section: [{
|
|
5635
6272
|
type: Input
|
|
5636
6273
|
}], lov: [{
|
|
@@ -5791,68 +6428,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
|
|
|
5791
6428
|
type: Input
|
|
5792
6429
|
}] } });
|
|
5793
6430
|
|
|
5794
|
-
class CommentSectionComponent {
|
|
5795
|
-
i18n;
|
|
5796
|
-
sidenavService;
|
|
5797
|
-
commentFormVisibility;
|
|
5798
|
-
comments;
|
|
5799
|
-
form;
|
|
5800
|
-
close = new EventEmitter();
|
|
5801
|
-
constructor(i18n, sidenavService) {
|
|
5802
|
-
this.i18n = i18n;
|
|
5803
|
-
this.sidenavService = sidenavService;
|
|
5804
|
-
this.form = sidenavService.data.form,
|
|
5805
|
-
this.comments = sidenavService.data.form.commentsDrop;
|
|
5806
|
-
this.commentFormVisibility = true;
|
|
5807
|
-
}
|
|
5808
|
-
CloseMenu() {
|
|
5809
|
-
this.sidenavService.publish('close', null);
|
|
5810
|
-
this.close.emit();
|
|
5811
|
-
}
|
|
5812
|
-
downloadAttachment(event, field) {
|
|
5813
|
-
let placeholder = event.target.nextElementSibling;
|
|
5814
|
-
if (placeholder == null) {
|
|
5815
|
-
placeholder = document.getElementById('downloadBtn').nextElementSibling;
|
|
5816
|
-
}
|
|
5817
|
-
/* this.stateMachineService.dispatch(Constants.STATE_MACHINE_ACTION_LOAD_FILE, field).then((responseObject: any) => {
|
|
5818
|
-
const fileInformation = responseObject.body;
|
|
5819
|
-
const fileBlob = this.dataURItoBlob(fileInformation.fileContents);
|
|
5820
|
-
const file = new File([fileBlob], fileInformation.fileName, { type: fileInformation.mimeType });
|
|
5821
|
-
placeholder['href'] = URL.createObjectURL(file);
|
|
5822
|
-
placeholder['download'] = file.name;
|
|
5823
|
-
placeholder.click();
|
|
5824
|
-
});*/
|
|
5825
|
-
}
|
|
5826
|
-
dataURItoBlob(dataURI) {
|
|
5827
|
-
const byteString = atob(dataURI);
|
|
5828
|
-
const arrayBuffer = new ArrayBuffer(byteString.length);
|
|
5829
|
-
const int8Array = new Uint8Array(arrayBuffer);
|
|
5830
|
-
for (let i = 0; i < byteString.length; i++) {
|
|
5831
|
-
int8Array[i] = byteString.charCodeAt(i);
|
|
5832
|
-
}
|
|
5833
|
-
const blob = new Blob([arrayBuffer], { type: 'image/jpeg' });
|
|
5834
|
-
return blob;
|
|
5835
|
-
}
|
|
5836
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: CommentSectionComponent, deps: [{ token: CoreI18nService }, { token: SidenavService }], target: i0.ɵɵFactoryTarget.Component });
|
|
5837
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.8", type: CommentSectionComponent, isStandalone: true, selector: "app-comment-section", inputs: { commentFormVisibility: "commentFormVisibility", comments: "comments", form: "form" }, outputs: { close: "close" }, ngImport: i0, template: "\r\n<div class=\"overlay-menu view-overlay\" (click)=\"CloseMenu()\"></div>\r\n\r\n<div class=\"side-menu open-side-menu\" >\r\n <div class=\"head\">\r\n <span (click)=\"CloseMenu()\" class=\"close-menu sfi sfi-close\">\r\n </span>\r\n <span class=\"txt\">\r\n {{i18n.translate('commentHistory')}}\r\n </span>\r\n </div>\r\n\r\n <div *ngIf=\"form?.commentsDrop\" class=\"flex-grow-1 overflow-auto\">\r\n <div class=\"side-menu-content\" *ngFor=\"let comment of form.commentsDrop\">\r\n <div class=\"side-menu-detail\">\r\n <div class=\"dots\">\r\n <svg xmlns=\"http://www.w3.org/2000/svg\" width=\"24\" height=\"24\" viewBox=\"0 0 24 24\">\r\n <g id=\"Group_16648\" data-name=\"Group 16648\" transform=\"translate(-952.156 -107.008)\">\r\n <g id=\"Ellipse_592\" data-name=\"Ellipse 592\" transform=\"translate(952.156 107.008)\" fill=\"none\"\r\n stroke=\"#e3e3e3\" stroke-width=\"1\">\r\n <circle cx=\"12\" cy=\"12\" r=\"12\" stroke=\"none\" />\r\n <circle cx=\"12\" cy=\"12\" r=\"11.5\" fill=\"none\" />\r\n </g>\r\n <circle id=\"Ellipse_595\" data-name=\"Ellipse 595\" cx=\"8\" cy=\"8\" r=\"8\"\r\n transform=\"translate(956.156 111.008)\" fill=\"#e3e3e3\" />\r\n </g>\r\n </svg>\r\n </div>\r\n <ds-avatar image={{comment?.profilePicture}} size=\"small\" class=\"d-inline-flex cursor-pointer\"></ds-avatar>\r\n <div class=\"request-details\">\r\n <div class=\"d-flex justify-content-between\">\r\n <div>\r\n <h2 class=\"user-name\">{{comment?.employeeName}}</h2>\r\n <span class=\"user-position\">{{comment?.jobPosition}}</span>\r\n </div>\r\n <div class=\"req-history\">\r\n <span>{{comment?.commentDate | date :'dd/MM/yyyy HH:mm:ss'}}</span>\r\n </div>\r\n </div>\r\n\r\n <div class=\"comment\" *ngIf=\"comment?.commentBody\">\r\n <p>{{comment?.commentBody}} </p>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n\r\n</div>\r\n", styles: [".head{display:flex;align-items:center;border-bottom:1px solid rgba(0,0,0,.12);padding:20px}.head .txt{color:#8e9aa0;width:100%;display:flex;justify-content:center;font-size:19px;font-weight:500}.head .close-menu{cursor:pointer}.side-menu-content{padding:30px 30px 0}.side-menu-content .side-menu-detail{position:relative;display:flex;width:100%;justify-content:space-between;margin-top:-7px}.side-menu-content .side-menu-detail .user-img{height:55px;width:55px;min-width:55px;background:var(--off-white);border-radius:50%;display:flex;align-items:center;justify-content:center;overflow:hidden}.side-menu-content .side-menu-detail .user-img img{width:100%;height:100%;object-fit:cover}.side-menu-content .side-menu-detail .user-name{font-size:16px;font-weight:500;margin-bottom:10px}.side-menu-content .side-menu-detail .req-history{color:#8e9aa0;font-size:14px;margin-top:-3px}.side-menu-content .comment{padding:10px;background-color:#f3f3f1;font-size:14px;color:#8e9aa0;font-weight:400;margin-top:20px;max-width:100%;word-break:break-all}.side-menu-content .comment p{margin:0}.side-menu-content .user-position{font-size:14px}.side-menu-content .request-details{margin-left:10px;border-bottom:1px solid rgba(0,0,0,.12);padding-bottom:25px;width:100%;text-align:start}[dir=rtl] .side-menu-content .request-details{margin-left:0;margin-right:10px}.side-menu-content .dots{margin-right:20px}.side-menu-content .dots:after{content:\"\";position:absolute;top:24px;left:11px;width:1px;height:100%;color:#e3e3e3;background:#e3e3e3}@media (max-width: 768px){.side-menu-content .dots{margin-right:10px}}[dir=rtl] .side-menu-content .dots{margin-right:0;margin-left:20px}@media (max-width: 768px){[dir=rtl] .side-menu-content .dots{margin-right:0;margin-left:10px}}[dir=rtl] .side-menu-content .dots:after{right:11px;left:auto}.side-menu-content:last-of-type .request-details{border:0}.side-menu-content:last-of-type .dots:after{display:none}@media (max-width: 520px){.side-menu-content{padding:10px 10px 0}}\n"], dependencies: [{ kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "pipe", type: DatePipe, name: "date" }] });
|
|
5838
|
-
}
|
|
5839
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: CommentSectionComponent, decorators: [{
|
|
5840
|
-
type: Component,
|
|
5841
|
-
args: [{ selector: 'app-comment-section', standalone: true, imports: [
|
|
5842
|
-
NgIf,
|
|
5843
|
-
NgForOf,
|
|
5844
|
-
DatePipe
|
|
5845
|
-
], schemas: [CUSTOM_ELEMENTS_SCHEMA], template: "\r\n<div class=\"overlay-menu view-overlay\" (click)=\"CloseMenu()\"></div>\r\n\r\n<div class=\"side-menu open-side-menu\" >\r\n <div class=\"head\">\r\n <span (click)=\"CloseMenu()\" class=\"close-menu sfi sfi-close\">\r\n </span>\r\n <span class=\"txt\">\r\n {{i18n.translate('commentHistory')}}\r\n </span>\r\n </div>\r\n\r\n <div *ngIf=\"form?.commentsDrop\" class=\"flex-grow-1 overflow-auto\">\r\n <div class=\"side-menu-content\" *ngFor=\"let comment of form.commentsDrop\">\r\n <div class=\"side-menu-detail\">\r\n <div class=\"dots\">\r\n <svg xmlns=\"http://www.w3.org/2000/svg\" width=\"24\" height=\"24\" viewBox=\"0 0 24 24\">\r\n <g id=\"Group_16648\" data-name=\"Group 16648\" transform=\"translate(-952.156 -107.008)\">\r\n <g id=\"Ellipse_592\" data-name=\"Ellipse 592\" transform=\"translate(952.156 107.008)\" fill=\"none\"\r\n stroke=\"#e3e3e3\" stroke-width=\"1\">\r\n <circle cx=\"12\" cy=\"12\" r=\"12\" stroke=\"none\" />\r\n <circle cx=\"12\" cy=\"12\" r=\"11.5\" fill=\"none\" />\r\n </g>\r\n <circle id=\"Ellipse_595\" data-name=\"Ellipse 595\" cx=\"8\" cy=\"8\" r=\"8\"\r\n transform=\"translate(956.156 111.008)\" fill=\"#e3e3e3\" />\r\n </g>\r\n </svg>\r\n </div>\r\n <ds-avatar image={{comment?.profilePicture}} size=\"small\" class=\"d-inline-flex cursor-pointer\"></ds-avatar>\r\n <div class=\"request-details\">\r\n <div class=\"d-flex justify-content-between\">\r\n <div>\r\n <h2 class=\"user-name\">{{comment?.employeeName}}</h2>\r\n <span class=\"user-position\">{{comment?.jobPosition}}</span>\r\n </div>\r\n <div class=\"req-history\">\r\n <span>{{comment?.commentDate | date :'dd/MM/yyyy HH:mm:ss'}}</span>\r\n </div>\r\n </div>\r\n\r\n <div class=\"comment\" *ngIf=\"comment?.commentBody\">\r\n <p>{{comment?.commentBody}} </p>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n\r\n</div>\r\n", styles: [".head{display:flex;align-items:center;border-bottom:1px solid rgba(0,0,0,.12);padding:20px}.head .txt{color:#8e9aa0;width:100%;display:flex;justify-content:center;font-size:19px;font-weight:500}.head .close-menu{cursor:pointer}.side-menu-content{padding:30px 30px 0}.side-menu-content .side-menu-detail{position:relative;display:flex;width:100%;justify-content:space-between;margin-top:-7px}.side-menu-content .side-menu-detail .user-img{height:55px;width:55px;min-width:55px;background:var(--off-white);border-radius:50%;display:flex;align-items:center;justify-content:center;overflow:hidden}.side-menu-content .side-menu-detail .user-img img{width:100%;height:100%;object-fit:cover}.side-menu-content .side-menu-detail .user-name{font-size:16px;font-weight:500;margin-bottom:10px}.side-menu-content .side-menu-detail .req-history{color:#8e9aa0;font-size:14px;margin-top:-3px}.side-menu-content .comment{padding:10px;background-color:#f3f3f1;font-size:14px;color:#8e9aa0;font-weight:400;margin-top:20px;max-width:100%;word-break:break-all}.side-menu-content .comment p{margin:0}.side-menu-content .user-position{font-size:14px}.side-menu-content .request-details{margin-left:10px;border-bottom:1px solid rgba(0,0,0,.12);padding-bottom:25px;width:100%;text-align:start}[dir=rtl] .side-menu-content .request-details{margin-left:0;margin-right:10px}.side-menu-content .dots{margin-right:20px}.side-menu-content .dots:after{content:\"\";position:absolute;top:24px;left:11px;width:1px;height:100%;color:#e3e3e3;background:#e3e3e3}@media (max-width: 768px){.side-menu-content .dots{margin-right:10px}}[dir=rtl] .side-menu-content .dots{margin-right:0;margin-left:20px}@media (max-width: 768px){[dir=rtl] .side-menu-content .dots{margin-right:0;margin-left:10px}}[dir=rtl] .side-menu-content .dots:after{right:11px;left:auto}.side-menu-content:last-of-type .request-details{border:0}.side-menu-content:last-of-type .dots:after{display:none}@media (max-width: 520px){.side-menu-content{padding:10px 10px 0}}\n"] }]
|
|
5846
|
-
}], ctorParameters: () => [{ type: CoreI18nService }, { type: SidenavService }], propDecorators: { commentFormVisibility: [{
|
|
5847
|
-
type: Input
|
|
5848
|
-
}], comments: [{
|
|
5849
|
-
type: Input
|
|
5850
|
-
}], form: [{
|
|
5851
|
-
type: Input
|
|
5852
|
-
}], close: [{
|
|
5853
|
-
type: Output
|
|
5854
|
-
}] } });
|
|
5855
|
-
|
|
5856
6431
|
class HeaderComponent {
|
|
5857
6432
|
translate;
|
|
5858
6433
|
sidenavService;
|
|
@@ -5925,8 +6500,8 @@ class HeaderComponent {
|
|
|
5925
6500
|
// this.sidenavSubscription.unsubscribe()
|
|
5926
6501
|
}
|
|
5927
6502
|
location = location;
|
|
5928
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: HeaderComponent, deps: [{ token: CoreI18nService }, { token: SidenavService }, { token: CoreService }, { token: i2$
|
|
5929
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.8", type: HeaderComponent, isStandalone: true, selector: "app-header", ngImport: i0, template: "<ng-container *ngIf=\"!isMobile\">\r\n <mat-toolbar\r\n class=\"align-items-center justify-content-between gap-3 border-bottom\"\r\n >\r\n <div class=\"d-flex align-items-center gap-3\">\r\n <ds-button\r\n shape=\"flat\"\r\n icon\r\n color=\"light-gray\"\r\n square\r\n (click)=\"toggleSideNav()\"\r\n >\r\n <ds-icon icon=\"burger-menu-1\" class=\"fs-24 fc-dark-gray\"></ds-icon>\r\n </ds-button>\r\n\r\n <a [href]=\"location.origin\">\r\n <figure class=\"m-0 d-flex\">\r\n <img class=\"main-logo\" src=\"assets/images/hub.svg\" alt=\"\" />\r\n </figure>\r\n </a>\r\n </div>\r\n\r\n <div class=\"d-flex align-items-center gap-3\">\r\n <ds-button\r\n shape=\"flat\"\r\n color=\"light-gray\"\r\n class=\"user-menu-btn\"\r\n [matMenuTriggerFor]=\"userMenu\"\r\n >\r\n <ds-avatar\r\n image=\"/group/i-gate/wm-bpm/forms/-/proxy/portrait?email={{userData?.email}}\"\r\n onerror=\"this.onerror=null;this.src='assets/images/user2.jpg'\"\r\n slot=\"prefix\"\r\n class=\"avatar\"\r\n >\r\n </ds-avatar>\r\n\r\n <span class=\"fs-14 fw-medium fc-black\">\r\n {{ coreService.getShortName( coreService?.loggedInUserData?.['name']) }}\r\n </span>\r\n\r\n <ds-icon\r\n slot=\"suffix\"\r\n icon=\"arrow\"\r\n class=\"fc-dark-gray fs-16\"\r\n ></ds-icon>\r\n </ds-button>\r\n </div>\r\n </mat-toolbar>\r\n\r\n <!-- User Menu -->\r\n <mat-menu #userMenu=\"matMenu\" class=\"user-menu\">\r\n <div mat-menu-item>\r\n <span class=\"fs-14\">{{ translate.translate('welcome') }}, </span>\r\n <br />\r\n <span class=\"fs-14 fw-medium line-height-1\">{{ coreService.getShortName( coreService?.loggedInUserData?.['name']) }}</span>\r\n </div>\r\n <button mat-menu-item (click)=\"setLanguage()\">\r\n <div class=\"d-flex align-items-center gap-2\">\r\n <ds-icon icon=\"globe\" class=\"fs-25 fc-purple\"></ds-icon>\r\n <span class=\"fs-14 fw-medium fc-black\">{{\r\n translate.translate('otherLang')\r\n }}</span>\r\n </div>\r\n </button>\r\n <button mat-menu-item (click)=\"logout()\">\r\n <div class=\"d-flex align-items-center gap-2\">\r\n <ds-icon icon=\"logout\" class=\"fs-25 fc-red\"></ds-icon>\r\n <span class=\"fs-14 fw-medium fc-black\">{{\r\n translate.translate('logout')\r\n }}</span>\r\n </div>\r\n </button>\r\n </mat-menu>\r\n</ng-container>\r\n", styles: [".test-user-agent{position:fixed;top:90px;width:100%;z-index:99999;color:#fff}ds-button[square].burger-menu::part(base){--btn-padding: 10px;margin-bottom:-1px;width:37px;height:37px;--default-size: 37px}[dir=rtl] :host ds-button::part(overlay){inset:0}mat-toolbar{background-color:var(--main-toolbar-bc);height:var(--main-toolbar-height);position:fixed;top:0;z-index:var(--main-toolbar-zIndex);border-bottom:1px solid var(--light-gray)!important}mat-toolbar .logo img{min-width:100px}@media (max-width: 991px){.user-menu-btn::part(base){border:0px;padding:0;--default-size: 40px}.user-menu-btn::part(overlay){border-radius:50%}.user-menu-btn::part(label),.user-menu-btn::part(suffix){display:none}}:host::ng-deep .avatar{min-width:24px;width:24px;height:24px;background-color:transparent}:host::ng-deep ds-button.add::part(base){--btn-bg-color: var(--coral)}@media (max-width: 991px){:host::ng-deep .avatar{min-width:40px;width:40px;height:40px}:host::ng-deep .avatar .avatar--x-small{--default-size: 40px}}.linkS{position:fixed;z-index:2;bottom:100px;right:20px}.dashboard-menu-icon{display:inline-flex;align-items:center;justify-content:center;min-width:56px;width:56px;height:56px;border-radius:50%;background-color:var(--coral);margin-bottom:10px}::ng-deep .inside-mobile-app{--main-toolbar-height: 0px}::ng-deep ds-button.transparent::part(base){--btn-bg-color: transparent;--btn-border-color: transparent;--btn-overlay-color: transparent}::ng-deep .mat-divider-vertical{border-right-color:var(--black)}.mat-divider{--mat-divider-width: 1px;--mat-divider-color: var(--dark-gray)}.header-search{width:500px}@media (max-width: 1130px){.header-search{width:200px}}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type:
|
|
6503
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: HeaderComponent, deps: [{ token: CoreI18nService }, { token: SidenavService }, { token: CoreService }, { token: i2$4.Router }, { token: PLATFORM_ID }], target: i0.ɵɵFactoryTarget.Component });
|
|
6504
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.8", type: HeaderComponent, isStandalone: true, selector: "app-header", ngImport: i0, template: "<ng-container *ngIf=\"!isMobile\">\r\n <mat-toolbar\r\n class=\"align-items-center justify-content-between gap-3 border-bottom\"\r\n >\r\n <div class=\"d-flex align-items-center gap-3\">\r\n <ds-button\r\n shape=\"flat\"\r\n icon\r\n color=\"light-gray\"\r\n square\r\n (click)=\"toggleSideNav()\"\r\n >\r\n <ds-icon icon=\"burger-menu-1\" class=\"fs-24 fc-dark-gray\"></ds-icon>\r\n </ds-button>\r\n\r\n <a [href]=\"location.origin\">\r\n <figure class=\"m-0 d-flex\">\r\n <img class=\"main-logo\" src=\"assets/images/hub.svg\" alt=\"\" />\r\n </figure>\r\n </a>\r\n </div>\r\n\r\n <div class=\"d-flex align-items-center gap-3\">\r\n <ds-button\r\n shape=\"flat\"\r\n color=\"light-gray\"\r\n class=\"user-menu-btn\"\r\n [matMenuTriggerFor]=\"userMenu\"\r\n >\r\n <ds-avatar\r\n image=\"/group/i-gate/wm-bpm/forms/-/proxy/portrait?email={{userData?.email}}\"\r\n onerror=\"this.onerror=null;this.src='assets/images/user2.jpg'\"\r\n slot=\"prefix\"\r\n class=\"avatar\"\r\n >\r\n </ds-avatar>\r\n\r\n <span class=\"fs-14 fw-medium fc-black\">\r\n {{ coreService.getShortName( coreService?.loggedInUserData?.['name']) }}\r\n </span>\r\n\r\n <ds-icon\r\n slot=\"suffix\"\r\n icon=\"arrow\"\r\n class=\"fc-dark-gray fs-16\"\r\n ></ds-icon>\r\n </ds-button>\r\n </div>\r\n </mat-toolbar>\r\n\r\n <!-- User Menu -->\r\n <mat-menu #userMenu=\"matMenu\" class=\"user-menu\">\r\n <div mat-menu-item>\r\n <span class=\"fs-14\">{{ translate.translate('welcome') }}, </span>\r\n <br />\r\n <span class=\"fs-14 fw-medium line-height-1\">{{ coreService.getShortName( coreService?.loggedInUserData?.['name']) }}</span>\r\n </div>\r\n <button mat-menu-item (click)=\"setLanguage()\">\r\n <div class=\"d-flex align-items-center gap-2\">\r\n <ds-icon icon=\"globe\" class=\"fs-25 fc-purple\"></ds-icon>\r\n <span class=\"fs-14 fw-medium fc-black\">{{\r\n translate.translate('otherLang')\r\n }}</span>\r\n </div>\r\n </button>\r\n <button mat-menu-item (click)=\"logout()\">\r\n <div class=\"d-flex align-items-center gap-2\">\r\n <ds-icon icon=\"logout\" class=\"fs-25 fc-red\"></ds-icon>\r\n <span class=\"fs-14 fw-medium fc-black\">{{\r\n translate.translate('logout')\r\n }}</span>\r\n </div>\r\n </button>\r\n </mat-menu>\r\n</ng-container>\r\n", styles: [".test-user-agent{position:fixed;top:90px;width:100%;z-index:99999;color:#fff}ds-button[square].burger-menu::part(base){--btn-padding: 10px;margin-bottom:-1px;width:37px;height:37px;--default-size: 37px}[dir=rtl] :host ds-button::part(overlay){inset:0}mat-toolbar{background-color:var(--main-toolbar-bc);height:var(--main-toolbar-height);position:fixed;top:0;z-index:var(--main-toolbar-zIndex);border-bottom:1px solid var(--light-gray)!important}mat-toolbar .logo img{min-width:100px}@media (max-width: 991px){.user-menu-btn::part(base){border:0px;padding:0;--default-size: 40px}.user-menu-btn::part(overlay){border-radius:50%}.user-menu-btn::part(label),.user-menu-btn::part(suffix){display:none}}:host::ng-deep .avatar{min-width:24px;width:24px;height:24px;background-color:transparent}:host::ng-deep ds-button.add::part(base){--btn-bg-color: var(--coral)}@media (max-width: 991px){:host::ng-deep .avatar{min-width:40px;width:40px;height:40px}:host::ng-deep .avatar .avatar--x-small{--default-size: 40px}}.linkS{position:fixed;z-index:2;bottom:100px;right:20px}.dashboard-menu-icon{display:inline-flex;align-items:center;justify-content:center;min-width:56px;width:56px;height:56px;border-radius:50%;background-color:var(--coral);margin-bottom:10px}::ng-deep .inside-mobile-app{--main-toolbar-height: 0px}::ng-deep ds-button.transparent::part(base){--btn-bg-color: transparent;--btn-border-color: transparent;--btn-overlay-color: transparent}::ng-deep .mat-divider-vertical{border-right-color:var(--black)}.mat-divider{--mat-divider-width: 1px;--mat-divider-color: var(--dark-gray)}.header-search{width:500px}@media (max-width: 1130px){.header-search{width:200px}}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "ngmodule", type: RouterModule }, { kind: "ngmodule", type: MatMenuModule }, { kind: "component", type: i5.MatMenu, selector: "mat-menu", inputs: ["backdropClass", "aria-label", "aria-labelledby", "aria-describedby", "xPosition", "yPosition", "overlapTrigger", "hasBackdrop", "class", "classList"], outputs: ["closed", "close"], exportAs: ["matMenu"] }, { kind: "component", type: i5.MatMenuItem, selector: "[mat-menu-item]", inputs: ["role", "disabled", "disableRipple"], exportAs: ["matMenuItem"] }, { kind: "directive", type: i5.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", inputs: ["mat-menu-trigger-for", "matMenuTriggerFor", "matMenuTriggerData", "matMenuTriggerRestoreFocus"], outputs: ["menuOpened", "onMenuOpen", "menuClosed", "onMenuClose"], exportAs: ["matMenuTrigger"] }, { kind: "ngmodule", type: MatToolbarModule }, { kind: "component", type: i6.MatToolbar, selector: "mat-toolbar", inputs: ["color"], exportAs: ["matToolbar"] }] });
|
|
5930
6505
|
}
|
|
5931
6506
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: HeaderComponent, decorators: [{
|
|
5932
6507
|
type: Component,
|
|
@@ -5937,7 +6512,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
|
|
|
5937
6512
|
MatMenuModule,
|
|
5938
6513
|
MatToolbarModule
|
|
5939
6514
|
], schemas: [CUSTOM_ELEMENTS_SCHEMA], template: "<ng-container *ngIf=\"!isMobile\">\r\n <mat-toolbar\r\n class=\"align-items-center justify-content-between gap-3 border-bottom\"\r\n >\r\n <div class=\"d-flex align-items-center gap-3\">\r\n <ds-button\r\n shape=\"flat\"\r\n icon\r\n color=\"light-gray\"\r\n square\r\n (click)=\"toggleSideNav()\"\r\n >\r\n <ds-icon icon=\"burger-menu-1\" class=\"fs-24 fc-dark-gray\"></ds-icon>\r\n </ds-button>\r\n\r\n <a [href]=\"location.origin\">\r\n <figure class=\"m-0 d-flex\">\r\n <img class=\"main-logo\" src=\"assets/images/hub.svg\" alt=\"\" />\r\n </figure>\r\n </a>\r\n </div>\r\n\r\n <div class=\"d-flex align-items-center gap-3\">\r\n <ds-button\r\n shape=\"flat\"\r\n color=\"light-gray\"\r\n class=\"user-menu-btn\"\r\n [matMenuTriggerFor]=\"userMenu\"\r\n >\r\n <ds-avatar\r\n image=\"/group/i-gate/wm-bpm/forms/-/proxy/portrait?email={{userData?.email}}\"\r\n onerror=\"this.onerror=null;this.src='assets/images/user2.jpg'\"\r\n slot=\"prefix\"\r\n class=\"avatar\"\r\n >\r\n </ds-avatar>\r\n\r\n <span class=\"fs-14 fw-medium fc-black\">\r\n {{ coreService.getShortName( coreService?.loggedInUserData?.['name']) }}\r\n </span>\r\n\r\n <ds-icon\r\n slot=\"suffix\"\r\n icon=\"arrow\"\r\n class=\"fc-dark-gray fs-16\"\r\n ></ds-icon>\r\n </ds-button>\r\n </div>\r\n </mat-toolbar>\r\n\r\n <!-- User Menu -->\r\n <mat-menu #userMenu=\"matMenu\" class=\"user-menu\">\r\n <div mat-menu-item>\r\n <span class=\"fs-14\">{{ translate.translate('welcome') }}, </span>\r\n <br />\r\n <span class=\"fs-14 fw-medium line-height-1\">{{ coreService.getShortName( coreService?.loggedInUserData?.['name']) }}</span>\r\n </div>\r\n <button mat-menu-item (click)=\"setLanguage()\">\r\n <div class=\"d-flex align-items-center gap-2\">\r\n <ds-icon icon=\"globe\" class=\"fs-25 fc-purple\"></ds-icon>\r\n <span class=\"fs-14 fw-medium fc-black\">{{\r\n translate.translate('otherLang')\r\n }}</span>\r\n </div>\r\n </button>\r\n <button mat-menu-item (click)=\"logout()\">\r\n <div class=\"d-flex align-items-center gap-2\">\r\n <ds-icon icon=\"logout\" class=\"fs-25 fc-red\"></ds-icon>\r\n <span class=\"fs-14 fw-medium fc-black\">{{\r\n translate.translate('logout')\r\n }}</span>\r\n </div>\r\n </button>\r\n </mat-menu>\r\n</ng-container>\r\n", styles: [".test-user-agent{position:fixed;top:90px;width:100%;z-index:99999;color:#fff}ds-button[square].burger-menu::part(base){--btn-padding: 10px;margin-bottom:-1px;width:37px;height:37px;--default-size: 37px}[dir=rtl] :host ds-button::part(overlay){inset:0}mat-toolbar{background-color:var(--main-toolbar-bc);height:var(--main-toolbar-height);position:fixed;top:0;z-index:var(--main-toolbar-zIndex);border-bottom:1px solid var(--light-gray)!important}mat-toolbar .logo img{min-width:100px}@media (max-width: 991px){.user-menu-btn::part(base){border:0px;padding:0;--default-size: 40px}.user-menu-btn::part(overlay){border-radius:50%}.user-menu-btn::part(label),.user-menu-btn::part(suffix){display:none}}:host::ng-deep .avatar{min-width:24px;width:24px;height:24px;background-color:transparent}:host::ng-deep ds-button.add::part(base){--btn-bg-color: var(--coral)}@media (max-width: 991px){:host::ng-deep .avatar{min-width:40px;width:40px;height:40px}:host::ng-deep .avatar .avatar--x-small{--default-size: 40px}}.linkS{position:fixed;z-index:2;bottom:100px;right:20px}.dashboard-menu-icon{display:inline-flex;align-items:center;justify-content:center;min-width:56px;width:56px;height:56px;border-radius:50%;background-color:var(--coral);margin-bottom:10px}::ng-deep .inside-mobile-app{--main-toolbar-height: 0px}::ng-deep ds-button.transparent::part(base){--btn-bg-color: transparent;--btn-border-color: transparent;--btn-overlay-color: transparent}::ng-deep .mat-divider-vertical{border-right-color:var(--black)}.mat-divider{--mat-divider-width: 1px;--mat-divider-color: var(--dark-gray)}.header-search{width:500px}@media (max-width: 1130px){.header-search{width:200px}}\n"] }]
|
|
5940
|
-
}], ctorParameters: () => [{ type: CoreI18nService }, { type: SidenavService }, { type: CoreService }, { type: i2$
|
|
6515
|
+
}], ctorParameters: () => [{ type: CoreI18nService }, { type: SidenavService }, { type: CoreService }, { type: i2$4.Router }, { type: undefined, decorators: [{
|
|
5941
6516
|
type: Inject,
|
|
5942
6517
|
args: [PLATFORM_ID]
|
|
5943
6518
|
}] }] });
|
|
@@ -6079,13 +6654,13 @@ class SideNavComponent {
|
|
|
6079
6654
|
}
|
|
6080
6655
|
this.router.navigate([url]);
|
|
6081
6656
|
}
|
|
6082
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: SideNavComponent, deps: [{ token: SidenavService }, { token: i2$
|
|
6083
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: SideNavComponent, isStandalone: true, selector: "app-side-nav", inputs: { isOpened: "isOpened" }, viewQueries: [{ propertyName: "MenuTrigger", first: true, predicate: ["MenuTrigger"], descendants: true }], ngImport: i0, template: "<aside>\r\n <div class=\"header d-flex d-lg-none\">\r\n <div class=\"d-flex h-100 mt-auto justify-content-between w-100\">\r\n <h1 class=\"fs-26 fw-bold fc-white logo\">academy</h1>\r\n <ds-button size=\"small\" color=\"purple\" class=\"close purple\" (click)=\"closeSidenav()\">\r\n <ds-icon icon=\"close\" class=\"fs-15 fc-white\"></ds-icon>\r\n </ds-button>\r\n </div>\r\n </div>\r\n <nav>\r\n <ul>\r\n <!-- (mouseenter)=\"menuMobile ? null : MenuTrigger.openMenu()\"-->\r\n <!-- (click)=\"goto(item.routerLink,item.matmenu) -->\r\n @for (item of Menu; track $index) {\r\n @if (item.matmenu) {\r\n <li\r\n (click)=\"closeSidenav();navigateTo(item)\" matTooltipPosition=\"right\" matTooltip=\"{{item.name }}\"\r\n [routerLinkActive]=\"'active'\" (click)=\"goto(item.routerLink!,item.matmenu)\" #MenuTrigger=\"matMenuTrigger\"\r\n [matMenuTriggerFor]=\"menuMenu\" [routerLinkActiveOptions]=\"{ exact: true }\" class=\"cursor-pointer\">\r\n <ds-icon icon=\"{{item.icon}}\" class=\"icon\"></ds-icon>\r\n <span class=\"menu-label\">\r\n {{ item.name }}\r\n </span>\r\n </li>\r\n <mat-menu #menuMenu=\"matMenu\" class=\"aside-menu visible-{{item.matmenu}}\">\r\n <app-mat-menu [title]=\"item.name \" [icon]=\"item.icon\" [list]=\"item.List\"></app-mat-menu>\r\n </mat-menu>\r\n } @else {\r\n <li\r\n (click)=\"closeSidenav();navigateTo(item)\" matTooltipPosition=\"right\" matTooltip=\"{{item.name }}\"\r\n [routerLinkActive]=\"'active'\" [routerLinkActiveOptions]=\"{ exact: true }\" class=\"cursor-pointer\">\r\n <ds-icon icon=\"{{item.icon}}\" class=\"icon\"></ds-icon>\r\n <span class=\"menu-label\">\r\n {{ item.name }}\r\n </span>\r\n </li>\r\n }\r\n }\r\n </ul>\r\n </nav>\r\n</aside>\r\n", styles: [":host ::ng-deep aside{min-width:var(--main-aside-width);width:var(--main-aside-width);height:calc(100vh - var(--main-toolbar-height));display:flex;position:var(--main-aside-position);right:var(--main-aside-right);left:var(--main-aside-left);top:var(--main-toolbar-height);z-index:var(--main-toolbar-zIndex);background-color:var(--main-aside-bc);transform:var(--main-aside-transform);transition:all .5s cubic-bezier(.685,.0473,.346,1)}@media (max-width: 1024px){:host ::ng-deep aside{height:100%;flex-direction:column;--main-toolbar-height: 0}}:host ::ng-deep aside nav{width:100%}:host ::ng-deep aside ul{display:flex;flex-direction:column;align-items:flex-start;justify-content:center;gap:20px;padding:0rem;margin:37px 0;list-style:none;counter-reset:itemCounter}:host ::ng-deep aside ul li{display:flex;align-items:center;flex-wrap:nowrap;overflow:hidden;max-width:calc(var(--main-aside-width-active) - 15px);width:100%;gap:var(--gap-width, 2.5rem);padding:3px 0 3px 10px;cursor:pointer;color:var(--main-aside-item-fc);border-radius:0;transition:var(--default-transition)}[dir=rtl] :host ::ng-deep aside ul li{padding:3px 10px 3px 0!important}@media (max-width: 1024px){@keyframes liAnimation{0%{transform:translateY(-500px)}to{transform:translateY(0)}}}:host ::ng-deep aside ul li.active,:host ::ng-deep aside ul li:hover{background-color:var(--main-aside-item-bc)}[dir=ltr] :host ::ng-deep aside ul li.active,[dir=ltr] :host ::ng-deep aside ul li:hover{border-left:5px solid var(--coral)}[dir=rtl] :host ::ng-deep aside ul li.active,[dir=rtl] :host ::ng-deep aside ul li:hover{border-right:5px solid var(--coral)}:host ::ng-deep aside ul li .menu-label{font-size:var(--main-aside-item-fs);flex-grow:1;opacity:1;min-width:calc(var(--main-aside-width-active) - 2rem - 40px);display:var(--main-aside-item-display)}:host ::ng-deep aside .header{background-color:#0003!important;padding:15px;flex-direction:row}:host ::ng-deep aside .header div{display:flex;align-items:center;margin-top:auto}:host ::ng-deep aside .footer{margin-top:auto;margin-bottom:80px;padding:0 30px}:host ::ng-deep aside ds-icon{font-size:1.55rem;display:inline-flex;align-items:center;justify-content:center;border-radius:3px;min-width:40px;width:40px;height:40px}:host ::ng-deep ds-button.close::part(base){height:37px;width:37px}:host ::ng-deep ds-button.close ds-icon{font-size:18px;min-width:18px;width:18px;height:18px}:host ::ng-deep .viewAll:hover{background-color:var(--purple)}:host ::ng-deep .viewAll:hover span{color:var(--white)}:host ::ng-deep .justify-content-between{justify-content:space-between}:host ::ng-deep .flex-column{flex-direction:column}:host ::ng-deep .d-flex{display:flex}:host ::ng-deep .w-100{width:100%}:host ::ng-deep .gap-3{gap:1rem!important}:host ::ng-deep ds-button.purple::part(base){--btn-border-color: var(--purple)}:host ::ng-deep ds-button.purple::part(overlay){--btn-overlay-color: var(--purple)}:host ::ng-deep ds-button.secondary::part(base){--btn-border-color: var(--secondary)}:host ::ng-deep ds-button.secondary::part(overlay){--btn-overlay-color: var(--secondary)}@media (min-width: 1024px){:host ::ng-deep .d-md-none{display:none!important}}@media (max-height: 430px){:host ::ng-deep aside .header{margin-bottom:50px}:host ::ng-deep aside nav{padding:15px 0 0;overflow:auto}:host ::ng-deep aside .footer{margin-bottom:20px}}@media (max-height: 300px){:host ::ng-deep aside .header{margin-bottom:5px}}:host ::ng-deep .logo{color:#fff}::ng-deep .aside-menu .mat-mdc-menu-content{border:none;box-shadow:none;padding:0!important}\n"], dependencies: [{ kind: "directive", type: RouterLinkActive, selector: "[routerLinkActive]", inputs: ["routerLinkActiveOptions", "ariaCurrentWhenActive", "routerLinkActive"], outputs: ["isActiveChange"], exportAs: ["routerLinkActive"] }, { kind: "ngmodule", type: MatTooltipModule }, { kind: "directive", type: i3$
|
|
6657
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: SideNavComponent, deps: [{ token: SidenavService }, { token: i2$4.Router }], target: i0.ɵɵFactoryTarget.Component });
|
|
6658
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: SideNavComponent, isStandalone: true, selector: "app-side-nav", inputs: { isOpened: "isOpened" }, viewQueries: [{ propertyName: "MenuTrigger", first: true, predicate: ["MenuTrigger"], descendants: true }], ngImport: i0, template: "<aside>\r\n <div class=\"header d-flex d-lg-none\">\r\n <div class=\"d-flex h-100 mt-auto justify-content-between w-100\">\r\n <h1 class=\"fs-26 fw-bold fc-white logo\">academy</h1>\r\n <ds-button size=\"small\" color=\"purple\" class=\"close purple\" (click)=\"closeSidenav()\">\r\n <ds-icon icon=\"close\" class=\"fs-15 fc-white\"></ds-icon>\r\n </ds-button>\r\n </div>\r\n </div>\r\n <nav>\r\n <ul>\r\n <!-- (mouseenter)=\"menuMobile ? null : MenuTrigger.openMenu()\"-->\r\n <!-- (click)=\"goto(item.routerLink,item.matmenu) -->\r\n @for (item of Menu; track $index) {\r\n @if (item.matmenu) {\r\n <li\r\n (click)=\"closeSidenav();navigateTo(item)\" matTooltipPosition=\"right\" matTooltip=\"{{item.name }}\"\r\n [routerLinkActive]=\"'active'\" (click)=\"goto(item.routerLink!,item.matmenu)\" #MenuTrigger=\"matMenuTrigger\"\r\n [matMenuTriggerFor]=\"menuMenu\" [routerLinkActiveOptions]=\"{ exact: true }\" class=\"cursor-pointer\">\r\n <ds-icon icon=\"{{item.icon}}\" class=\"icon\"></ds-icon>\r\n <span class=\"menu-label\">\r\n {{ item.name }}\r\n </span>\r\n </li>\r\n <mat-menu #menuMenu=\"matMenu\" class=\"aside-menu visible-{{item.matmenu}}\">\r\n <app-mat-menu [title]=\"item.name \" [icon]=\"item.icon\" [list]=\"item.List\"></app-mat-menu>\r\n </mat-menu>\r\n } @else {\r\n <li\r\n (click)=\"closeSidenav();navigateTo(item)\" matTooltipPosition=\"right\" matTooltip=\"{{item.name }}\"\r\n [routerLinkActive]=\"'active'\" [routerLinkActiveOptions]=\"{ exact: true }\" class=\"cursor-pointer\">\r\n <ds-icon icon=\"{{item.icon}}\" class=\"icon\"></ds-icon>\r\n <span class=\"menu-label\">\r\n {{ item.name }}\r\n </span>\r\n </li>\r\n }\r\n }\r\n </ul>\r\n </nav>\r\n</aside>\r\n", styles: [":host ::ng-deep aside{min-width:var(--main-aside-width);width:var(--main-aside-width);height:calc(100vh - var(--main-toolbar-height));display:flex;position:var(--main-aside-position);right:var(--main-aside-right);left:var(--main-aside-left);top:var(--main-toolbar-height);z-index:var(--main-toolbar-zIndex);background-color:var(--main-aside-bc);transform:var(--main-aside-transform);transition:all .5s cubic-bezier(.685,.0473,.346,1)}@media (max-width: 1024px){:host ::ng-deep aside{height:100%;flex-direction:column;--main-toolbar-height: 0}}:host ::ng-deep aside nav{width:100%}:host ::ng-deep aside ul{display:flex;flex-direction:column;align-items:flex-start;justify-content:center;gap:20px;padding:0rem;margin:37px 0;list-style:none;counter-reset:itemCounter}:host ::ng-deep aside ul li{display:flex;align-items:center;flex-wrap:nowrap;overflow:hidden;max-width:calc(var(--main-aside-width-active) - 15px);width:100%;gap:var(--gap-width, 2.5rem);padding:3px 0 3px 10px;cursor:pointer;color:var(--main-aside-item-fc);border-radius:0;transition:var(--default-transition)}[dir=rtl] :host ::ng-deep aside ul li{padding:3px 10px 3px 0!important}@media (max-width: 1024px){@keyframes liAnimation{0%{transform:translateY(-500px)}to{transform:translateY(0)}}}:host ::ng-deep aside ul li.active,:host ::ng-deep aside ul li:hover{background-color:var(--main-aside-item-bc)}[dir=ltr] :host ::ng-deep aside ul li.active,[dir=ltr] :host ::ng-deep aside ul li:hover{border-left:5px solid var(--coral)}[dir=rtl] :host ::ng-deep aside ul li.active,[dir=rtl] :host ::ng-deep aside ul li:hover{border-right:5px solid var(--coral)}:host ::ng-deep aside ul li .menu-label{font-size:var(--main-aside-item-fs);flex-grow:1;opacity:1;min-width:calc(var(--main-aside-width-active) - 2rem - 40px);display:var(--main-aside-item-display)}:host ::ng-deep aside .header{background-color:#0003!important;padding:15px;flex-direction:row}:host ::ng-deep aside .header div{display:flex;align-items:center;margin-top:auto}:host ::ng-deep aside .footer{margin-top:auto;margin-bottom:80px;padding:0 30px}:host ::ng-deep aside ds-icon{font-size:1.55rem;display:inline-flex;align-items:center;justify-content:center;border-radius:3px;min-width:40px;width:40px;height:40px}:host ::ng-deep ds-button.close::part(base){height:37px;width:37px}:host ::ng-deep ds-button.close ds-icon{font-size:18px;min-width:18px;width:18px;height:18px}:host ::ng-deep .viewAll:hover{background-color:var(--purple)}:host ::ng-deep .viewAll:hover span{color:var(--white)}:host ::ng-deep .justify-content-between{justify-content:space-between}:host ::ng-deep .flex-column{flex-direction:column}:host ::ng-deep .d-flex{display:flex}:host ::ng-deep .w-100{width:100%}:host ::ng-deep .gap-3{gap:1rem!important}:host ::ng-deep ds-button.purple::part(base){--btn-border-color: var(--purple)}:host ::ng-deep ds-button.purple::part(overlay){--btn-overlay-color: var(--purple)}:host ::ng-deep ds-button.secondary::part(base){--btn-border-color: var(--secondary)}:host ::ng-deep ds-button.secondary::part(overlay){--btn-overlay-color: var(--secondary)}@media (min-width: 1024px){:host ::ng-deep .d-md-none{display:none!important}}@media (max-height: 430px){:host ::ng-deep aside .header{margin-bottom:50px}:host ::ng-deep aside nav{padding:15px 0 0;overflow:auto}:host ::ng-deep aside .footer{margin-bottom:20px}}@media (max-height: 300px){:host ::ng-deep aside .header{margin-bottom:5px}}:host ::ng-deep .logo{color:#fff}::ng-deep .aside-menu .mat-mdc-menu-content{border:none;box-shadow:none;padding:0!important}\n"], dependencies: [{ kind: "directive", type: RouterLinkActive, selector: "[routerLinkActive]", inputs: ["routerLinkActiveOptions", "ariaCurrentWhenActive", "routerLinkActive"], outputs: ["isActiveChange"], exportAs: ["routerLinkActive"] }, { kind: "ngmodule", type: MatTooltipModule }, { kind: "directive", type: i3$4.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "component", type: MatMenu, selector: "mat-menu", inputs: ["backdropClass", "aria-label", "aria-labelledby", "aria-describedby", "xPosition", "yPosition", "overlapTrigger", "hasBackdrop", "class", "classList"], outputs: ["closed", "close"], exportAs: ["matMenu"] }, { kind: "directive", type: MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", inputs: ["mat-menu-trigger-for", "matMenuTriggerFor", "matMenuTriggerData", "matMenuTriggerRestoreFocus"], outputs: ["menuOpened", "onMenuOpen", "menuClosed", "onMenuClose"], exportAs: ["matMenuTrigger"] }] });
|
|
6084
6659
|
}
|
|
6085
6660
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: SideNavComponent, decorators: [{
|
|
6086
6661
|
type: Component,
|
|
6087
6662
|
args: [{ selector: 'app-side-nav', standalone: true, imports: [RouterLinkActive, RouterLink, MatTooltipModule, MatMenu, MatMenuTrigger], schemas: [CUSTOM_ELEMENTS_SCHEMA], template: "<aside>\r\n <div class=\"header d-flex d-lg-none\">\r\n <div class=\"d-flex h-100 mt-auto justify-content-between w-100\">\r\n <h1 class=\"fs-26 fw-bold fc-white logo\">academy</h1>\r\n <ds-button size=\"small\" color=\"purple\" class=\"close purple\" (click)=\"closeSidenav()\">\r\n <ds-icon icon=\"close\" class=\"fs-15 fc-white\"></ds-icon>\r\n </ds-button>\r\n </div>\r\n </div>\r\n <nav>\r\n <ul>\r\n <!-- (mouseenter)=\"menuMobile ? null : MenuTrigger.openMenu()\"-->\r\n <!-- (click)=\"goto(item.routerLink,item.matmenu) -->\r\n @for (item of Menu; track $index) {\r\n @if (item.matmenu) {\r\n <li\r\n (click)=\"closeSidenav();navigateTo(item)\" matTooltipPosition=\"right\" matTooltip=\"{{item.name }}\"\r\n [routerLinkActive]=\"'active'\" (click)=\"goto(item.routerLink!,item.matmenu)\" #MenuTrigger=\"matMenuTrigger\"\r\n [matMenuTriggerFor]=\"menuMenu\" [routerLinkActiveOptions]=\"{ exact: true }\" class=\"cursor-pointer\">\r\n <ds-icon icon=\"{{item.icon}}\" class=\"icon\"></ds-icon>\r\n <span class=\"menu-label\">\r\n {{ item.name }}\r\n </span>\r\n </li>\r\n <mat-menu #menuMenu=\"matMenu\" class=\"aside-menu visible-{{item.matmenu}}\">\r\n <app-mat-menu [title]=\"item.name \" [icon]=\"item.icon\" [list]=\"item.List\"></app-mat-menu>\r\n </mat-menu>\r\n } @else {\r\n <li\r\n (click)=\"closeSidenav();navigateTo(item)\" matTooltipPosition=\"right\" matTooltip=\"{{item.name }}\"\r\n [routerLinkActive]=\"'active'\" [routerLinkActiveOptions]=\"{ exact: true }\" class=\"cursor-pointer\">\r\n <ds-icon icon=\"{{item.icon}}\" class=\"icon\"></ds-icon>\r\n <span class=\"menu-label\">\r\n {{ item.name }}\r\n </span>\r\n </li>\r\n }\r\n }\r\n </ul>\r\n </nav>\r\n</aside>\r\n", styles: [":host ::ng-deep aside{min-width:var(--main-aside-width);width:var(--main-aside-width);height:calc(100vh - var(--main-toolbar-height));display:flex;position:var(--main-aside-position);right:var(--main-aside-right);left:var(--main-aside-left);top:var(--main-toolbar-height);z-index:var(--main-toolbar-zIndex);background-color:var(--main-aside-bc);transform:var(--main-aside-transform);transition:all .5s cubic-bezier(.685,.0473,.346,1)}@media (max-width: 1024px){:host ::ng-deep aside{height:100%;flex-direction:column;--main-toolbar-height: 0}}:host ::ng-deep aside nav{width:100%}:host ::ng-deep aside ul{display:flex;flex-direction:column;align-items:flex-start;justify-content:center;gap:20px;padding:0rem;margin:37px 0;list-style:none;counter-reset:itemCounter}:host ::ng-deep aside ul li{display:flex;align-items:center;flex-wrap:nowrap;overflow:hidden;max-width:calc(var(--main-aside-width-active) - 15px);width:100%;gap:var(--gap-width, 2.5rem);padding:3px 0 3px 10px;cursor:pointer;color:var(--main-aside-item-fc);border-radius:0;transition:var(--default-transition)}[dir=rtl] :host ::ng-deep aside ul li{padding:3px 10px 3px 0!important}@media (max-width: 1024px){@keyframes liAnimation{0%{transform:translateY(-500px)}to{transform:translateY(0)}}}:host ::ng-deep aside ul li.active,:host ::ng-deep aside ul li:hover{background-color:var(--main-aside-item-bc)}[dir=ltr] :host ::ng-deep aside ul li.active,[dir=ltr] :host ::ng-deep aside ul li:hover{border-left:5px solid var(--coral)}[dir=rtl] :host ::ng-deep aside ul li.active,[dir=rtl] :host ::ng-deep aside ul li:hover{border-right:5px solid var(--coral)}:host ::ng-deep aside ul li .menu-label{font-size:var(--main-aside-item-fs);flex-grow:1;opacity:1;min-width:calc(var(--main-aside-width-active) - 2rem - 40px);display:var(--main-aside-item-display)}:host ::ng-deep aside .header{background-color:#0003!important;padding:15px;flex-direction:row}:host ::ng-deep aside .header div{display:flex;align-items:center;margin-top:auto}:host ::ng-deep aside .footer{margin-top:auto;margin-bottom:80px;padding:0 30px}:host ::ng-deep aside ds-icon{font-size:1.55rem;display:inline-flex;align-items:center;justify-content:center;border-radius:3px;min-width:40px;width:40px;height:40px}:host ::ng-deep ds-button.close::part(base){height:37px;width:37px}:host ::ng-deep ds-button.close ds-icon{font-size:18px;min-width:18px;width:18px;height:18px}:host ::ng-deep .viewAll:hover{background-color:var(--purple)}:host ::ng-deep .viewAll:hover span{color:var(--white)}:host ::ng-deep .justify-content-between{justify-content:space-between}:host ::ng-deep .flex-column{flex-direction:column}:host ::ng-deep .d-flex{display:flex}:host ::ng-deep .w-100{width:100%}:host ::ng-deep .gap-3{gap:1rem!important}:host ::ng-deep ds-button.purple::part(base){--btn-border-color: var(--purple)}:host ::ng-deep ds-button.purple::part(overlay){--btn-overlay-color: var(--purple)}:host ::ng-deep ds-button.secondary::part(base){--btn-border-color: var(--secondary)}:host ::ng-deep ds-button.secondary::part(overlay){--btn-overlay-color: var(--secondary)}@media (min-width: 1024px){:host ::ng-deep .d-md-none{display:none!important}}@media (max-height: 430px){:host ::ng-deep aside .header{margin-bottom:50px}:host ::ng-deep aside nav{padding:15px 0 0;overflow:auto}:host ::ng-deep aside .footer{margin-bottom:20px}}@media (max-height: 300px){:host ::ng-deep aside .header{margin-bottom:5px}}:host ::ng-deep .logo{color:#fff}::ng-deep .aside-menu .mat-mdc-menu-content{border:none;box-shadow:none;padding:0!important}\n"] }]
|
|
6088
|
-
}], ctorParameters: () => [{ type: SidenavService }, { type: i2$
|
|
6663
|
+
}], ctorParameters: () => [{ type: SidenavService }, { type: i2$4.Router }], propDecorators: { isOpened: [{
|
|
6089
6664
|
type: Input
|
|
6090
6665
|
}], MenuTrigger: [{
|
|
6091
6666
|
type: ViewChild,
|
|
@@ -6144,8 +6719,8 @@ class LayoutComponent {
|
|
|
6144
6719
|
closeSideNav() {
|
|
6145
6720
|
this.sidenav.close().then(r => { });
|
|
6146
6721
|
}
|
|
6147
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: LayoutComponent, deps: [{ token: DOCUMENT }, { token: i2$
|
|
6148
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.8", type: LayoutComponent, isStandalone: true, selector: "core-layout", inputs: { form: "form", formTitle: "formTitle", isLoading: "isLoading", serviceBrief: "serviceBrief" }, viewQueries: [{ propertyName: "sidenav", first: true, predicate: ["sidenav"], descendants: true, static: true }], ngImport: i0, template: "<app-header></app-header>\r\n<section class=\"d-flex\">\r\n <app-side-nav></app-side-nav>\r\n <mat-sidenav-container\r\n class=\"flex-grow-1\"\r\n [hasBackdrop]=\"true\"\r\n (backdropClick)=\"backdropClick()\"\r\n >\r\n <mat-sidenav\r\n #sidenav\r\n autoFocus=\"false\"\r\n fixedInViewport\r\n [position]=\"'end'\"\r\n (closedStart)=\"onClose()\"\r\n >\r\n <ng-container *ngComponentOutlet=\"sideContent\">\r\n <app-side-nav></app-side-nav>\r\n </ng-container>\r\n </mat-sidenav>\r\n <mat-sidenav-content>\r\n <main\r\n class=\"hadPadding service-wrapper\"\r\n [ngClass]=\"form?.header?.status?.key == 'NEW' ? 'hub-container-mini' : 'hub-container'\">\r\n\r\n <ng-content ></ng-content>\r\n <ng-content select=\"[workflow]\"></ng-content>\r\n\r\n </main>\r\n </mat-sidenav-content>\r\n </mat-sidenav-container>\r\n</section>\r\n", styles: [":host ::ng-deep .mat-drawer-container{overflow:visible;margin-top:var(--main-toolbar-height);min-height:calc(100vh - var(--main-toolbar-height));background-color:var(--body-bg)!important;z-index:initial!important;min-width:calc(100% - var(--main-aside-width));width:calc(100% - var(--main-aside-width))}:host ::ng-deep .mat-drawer-container .mat-drawer-content{display:flex;flex-direction:column;overflow:visible}.hup-wrapper :host ::ng-deep .mat-drawer-container .mat-drawer-content{min-height:auto}:host ::ng-deep footer{bottom:-65px}.mat-drawer{border-radius:10px!important;margin:1rem;box-shadow:0 8px 16px 7px rgba(var(--rgb-black),.06);background-color:var(--white)}@media (max-width: 767px){.mat-drawer{padding:0;border-radius:0;margin:0;width:100%}}.customize-btn{min-width:166px}.zer-pt{padding-top:0!important}\n"], dependencies: [{ kind: "component", type: HeaderComponent, selector: "app-header" }, { kind: "component", type: SideNavComponent, selector: "app-side-nav", inputs: ["isOpened"] }, { kind: "ngmodule", type: MatSidenavModule }, { kind: "component", type: i3$
|
|
6722
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: LayoutComponent, deps: [{ token: DOCUMENT }, { token: i2$4.Router }, { token: SidenavService }], target: i0.ɵɵFactoryTarget.Component });
|
|
6723
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.8", type: LayoutComponent, isStandalone: true, selector: "core-layout", inputs: { form: "form", formTitle: "formTitle", isLoading: "isLoading", serviceBrief: "serviceBrief" }, viewQueries: [{ propertyName: "sidenav", first: true, predicate: ["sidenav"], descendants: true, static: true }], ngImport: i0, template: "<app-header></app-header>\r\n<section class=\"d-flex\">\r\n <app-side-nav></app-side-nav>\r\n <mat-sidenav-container\r\n class=\"flex-grow-1\"\r\n [hasBackdrop]=\"true\"\r\n (backdropClick)=\"backdropClick()\"\r\n >\r\n <mat-sidenav\r\n #sidenav\r\n autoFocus=\"false\"\r\n fixedInViewport\r\n [position]=\"'end'\"\r\n (closedStart)=\"onClose()\"\r\n >\r\n <ng-container *ngComponentOutlet=\"sideContent\">\r\n <app-side-nav></app-side-nav>\r\n </ng-container>\r\n </mat-sidenav>\r\n <mat-sidenav-content>\r\n <main\r\n class=\"hadPadding service-wrapper\"\r\n [ngClass]=\"form?.header?.status?.key == 'NEW' ? 'hub-container-mini' : 'hub-container'\">\r\n\r\n <ng-content ></ng-content>\r\n <ng-content select=\"[workflow]\"></ng-content>\r\n\r\n </main>\r\n </mat-sidenav-content>\r\n </mat-sidenav-container>\r\n</section>\r\n", styles: [":host ::ng-deep .mat-drawer-container{overflow:visible;margin-top:var(--main-toolbar-height);min-height:calc(100vh - var(--main-toolbar-height));background-color:var(--body-bg)!important;z-index:initial!important;min-width:calc(100% - var(--main-aside-width));width:calc(100% - var(--main-aside-width))}:host ::ng-deep .mat-drawer-container .mat-drawer-content{display:flex;flex-direction:column;overflow:visible}.hup-wrapper :host ::ng-deep .mat-drawer-container .mat-drawer-content{min-height:auto}:host ::ng-deep footer{bottom:-65px}.mat-drawer{border-radius:10px!important;margin:1rem;box-shadow:0 8px 16px 7px rgba(var(--rgb-black),.06);background-color:var(--white)}@media (max-width: 767px){.mat-drawer{padding:0;border-radius:0;margin:0;width:100%}}.customize-btn{min-width:166px}.zer-pt{padding-top:0!important}\n"], dependencies: [{ kind: "component", type: HeaderComponent, selector: "app-header" }, { kind: "component", type: SideNavComponent, selector: "app-side-nav", inputs: ["isOpened"] }, { kind: "ngmodule", type: MatSidenavModule }, { kind: "component", type: i3$5.MatSidenav, selector: "mat-sidenav", inputs: ["fixedInViewport", "fixedTopGap", "fixedBottomGap"], exportAs: ["matSidenav"] }, { kind: "component", type: i3$5.MatSidenavContainer, selector: "mat-sidenav-container", exportAs: ["matSidenavContainer"] }, { kind: "component", type: i3$5.MatSidenavContent, selector: "mat-sidenav-content" }, { kind: "directive", type: NgComponentOutlet, selector: "[ngComponentOutlet]", inputs: ["ngComponentOutlet", "ngComponentOutletInputs", "ngComponentOutletInjector", "ngComponentOutletContent", "ngComponentOutletNgModule", "ngComponentOutletNgModuleFactory"] }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }] });
|
|
6149
6724
|
}
|
|
6150
6725
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: LayoutComponent, decorators: [{
|
|
6151
6726
|
type: Component,
|
|
@@ -6153,7 +6728,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
|
|
|
6153
6728
|
}], ctorParameters: () => [{ type: Document, decorators: [{
|
|
6154
6729
|
type: Inject,
|
|
6155
6730
|
args: [DOCUMENT]
|
|
6156
|
-
}] }, { type: i2$
|
|
6731
|
+
}] }, { type: i2$4.Router }, { type: SidenavService }], propDecorators: { sidenav: [{
|
|
6157
6732
|
type: ViewChild,
|
|
6158
6733
|
args: ["sidenav", { static: true }]
|
|
6159
6734
|
}], form: [{
|
|
@@ -6209,11 +6784,14 @@ class RequestDetailsSectionComponent {
|
|
|
6209
6784
|
});
|
|
6210
6785
|
this.formGroup = this.fb.group({
|
|
6211
6786
|
input: new FormControl('', [Validators.required, Validators.maxLength(3), Validators.minLength(2)]),
|
|
6787
|
+
currencyInput: new FormControl('', Validators.required),
|
|
6788
|
+
emailInput: new FormControl('', [Validators.required, Validators.pattern(RegexPatterns.email)]),
|
|
6789
|
+
numberInput: new FormControl('', [Validators.required]),
|
|
6212
6790
|
customSearchable: new FormControl('', Validators.required),
|
|
6213
6791
|
checkbox: new FormControl(true, Validators.requiredTrue),
|
|
6214
6792
|
textArea: new FormControl('', [Validators.required, Validators.maxLength(10), Validators.minLength(5)]),
|
|
6215
|
-
currencyInput: new FormControl(''),
|
|
6216
6793
|
datePicker: new FormControl('', Validators.required),
|
|
6794
|
+
datePickerRange: new FormControl('', Validators.required),
|
|
6217
6795
|
...newForm,
|
|
6218
6796
|
});
|
|
6219
6797
|
this.formGroup.valueChanges.subscribe(value => {
|
|
@@ -6251,7 +6829,7 @@ class RequestDetailsSectionComponent {
|
|
|
6251
6829
|
this.formGroup.reset();
|
|
6252
6830
|
}
|
|
6253
6831
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: RequestDetailsSectionComponent, deps: [{ token: CoreI18nService }, { token: i2.FormBuilder }, { token: ActionStateService }], target: i0.ɵɵFactoryTarget.Component });
|
|
6254
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: RequestDetailsSectionComponent, isStandalone: true, selector: "app-request-details-section", inputs: { isReadOnly: "isReadOnly", section: "section", form: "form", lov: "lov", className: "className" }, ngImport: i0, template: "<div\r\n [ngClass]=\"{'form-section-divide form-section':!section?.header?.readOnly,'info-section':section?.header?.readOnly}\">\r\n
|
|
6832
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: RequestDetailsSectionComponent, isStandalone: true, selector: "app-request-details-section", inputs: { isReadOnly: "isReadOnly", section: "section", form: "form", lov: "lov", className: "className" }, ngImport: i0, template: "<div\r\n [ngClass]=\"{'form-section-divide form-section':!section?.header?.readOnly,'info-section':section?.header?.readOnly}\">\r\n<form [formGroup]=\"formGroup\">\r\n <app-input [loading]=\"true\" type=\"enOnly\" formControlName=\"input\" label=\"Input\" class=\"section-item\"></app-input>\r\n <app-input-currency formControlName=\"currencyInput\" label=\"currency\"></app-input-currency>\r\n <app-input-email formControlName=\"emailInput\" label=\"email\"></app-input-email>\r\n <app-input-number formControlName=\"numberInput\" label=\"number\"></app-input-number>\r\n <app-custom-searchable class=\"section-item\" formControlName=\"customSearchable\" label=\"Custom-searchable\" [options]=\"lov?.['approverActions']?.options\" [displayedLable]=\"'name'\"\r\n [key]=\"'name'\"\r\n ></app-custom-searchable>\r\n <app-checkbox formControlName=\"checkbox\" termsLabel=\"Terms and condtions\" [containTerms]=\"true\"></app-checkbox>\r\n <app-textarea formControlName=\"textArea\" label=\"Text-area\"></app-textarea>\r\n <app-datepicker formControlName=\"datePicker\" [matSuffix]=\"true\" label=\"Date-picker\" minDate=\"today\" maxDate=\"today\"></app-datepicker>\r\n <app-date-range-picker formControlName=\"datePickerRange\" label=\"Date-picker-range\" [matSuffix]=\"true\" minDate=\"today\" minDate=\"today\" maxDate=\"today\"></app-date-range-picker>\r\n <app-input formControlName=\"input1\"></app-input>\r\n</form>\r\n<ds-button\r\n(click)=\"formValue(formGroup)\"\r\n[ngClass]=\"{'disabled': !formGroup.valid}\"\r\n>\r\n{{ i18n.translate('submit') }}\r\n</ds-button>\r\n <ds-alert class=\"full\" type=\"warning\" icon=\"info\">\r\n <div class=\"d-flex gap-2\">\r\n Request details working fine\r\n </div>\r\n </ds-alert>\r\n <!-- <form [formGroup]=\"fieldsForm\">\r\n <app-input formControlName=\"input1\" ></app-input>\r\n </form> -->\r\n</div>\r\n@if (!section?.header?.readOnly) {\r\n <div class=\"mt-4\">\r\n <lib-action-buttons\r\n [lovOptions]=\"lov?.['decision']?.options\"\r\n [lovType]=\"lov?.['decision']?.type\"\r\n [section]=\"section\"\r\n [form]=\"form\"\r\n [sections]=\"form.sections\"\r\n [showApprovalCycle]=\"true\"\r\n [customCall]=\"false\"\r\n [fieldsForm]=\"formGroup\"\r\n (customCallEmit)=\"customCallSubmit($event)\"\r\n (resetFormEmit)=\"resetForm()\"\r\n />\r\n </div>\r\n}\r\n", styles: [".form-section-divide{--form-section-columns: 1fr 1fr}@media (max-width: 756px){.form-section-divide{--form-section-columns: 100%}}.form-section-divide .full{grid-column:1/-1}.head-title{position:relative;margin-bottom:12px}.head-title h3{display:inline-block;color:#8e9aa0;font-size:14px;font-weight:500;background-color:#fff;padding-inline-end:20px;position:relative;z-index:2;margin:0}.head-title:after{content:\"\";position:absolute;width:100%;height:1px;background-color:#dee0e2;top:50%;left:0;right:0;transform:translateY(-50%);z-index:1}.chamber{margin-bottom:20px}.chamber .chamber-content{background-color:#f8f8f8;padding:20px}.chamber .chamber-content .chamber-select{display:flex}.chamber .chamber-content mat-checkbox{font-size:14px}\n"], dependencies: [{ kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: InputComponent, selector: "app-input", inputs: ["tooltip", "floatLabel", "className", "iconPrefixName", "iconSuffixName", "emitedChangedValue1"] }, { kind: "component", type: ActionButtonsComponent, selector: "lib-action-buttons", inputs: ["lovOptions", "lovType", "fieldsForm", "form", "section", "sections", "showApprovalCycle", "customCall"], outputs: ["resetFormEmit", "customCallEmit"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i2.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "component", type: CustomSearchableComponent, selector: "app-custom-searchable", inputs: ["options", "disabled", "name", "displayedLable", "key", "floatLabel", "className"], outputs: ["selectedValue", "isLengthGreaterThan4"] }, { kind: "component", type: CheckBoxComponent, selector: "app-checkbox", inputs: ["containTerms", "termsLabel", "linkText", "hrefLink", "link", "name", "randomID", "termsBody"], outputs: ["downloadCheckBox"] }, { kind: "component", type: TextareaComponent, selector: "app-textarea", inputs: ["className", "preventSpecailChar"] }, { kind: "component", type: InputCurrencyComponent, selector: "app-input-currency", inputs: ["tooltip", "floatLabel", "className", "iconPrefixName", "iconSuffixName", "numberSuffixName"] }, { kind: "component", type: DatePickerComponent, selector: "app-datepicker", inputs: ["tooltip", "className", "calendarType", "showLabel", "yearOnly", "resetDate", "error", "format"], outputs: ["dateValue"] }, { kind: "component", type: DateRangePickerComponent, selector: "app-date-range-picker", inputs: ["tooltip", "className", "yearOnly"] }, { kind: "component", type: InputEmailComponent, selector: "app-input-email", inputs: ["tooltip", "floatLabel", "className", "matPrefix", "iconPrefixName", "iconSuffixName", "numberSuffixName"] }, { kind: "component", type: InputNumberComponent, selector: "app-input-number", inputs: ["tooltip", "floatLabel", "className", "iconPrefixName", "iconSuffixName", "numberSuffixName", "allowedPattern"], outputs: ["emitedChangedValue"] }] });
|
|
6255
6833
|
}
|
|
6256
6834
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: RequestDetailsSectionComponent, decorators: [{
|
|
6257
6835
|
type: Component,
|
|
@@ -6267,8 +6845,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
|
|
|
6267
6845
|
CheckBoxComponent,
|
|
6268
6846
|
TextareaComponent,
|
|
6269
6847
|
InputCurrencyComponent,
|
|
6270
|
-
DatePickerComponent
|
|
6271
|
-
|
|
6848
|
+
DatePickerComponent,
|
|
6849
|
+
DateRangePickerComponent,
|
|
6850
|
+
InputEmailComponent,
|
|
6851
|
+
InputNumberComponent
|
|
6852
|
+
], template: "<div\r\n [ngClass]=\"{'form-section-divide form-section':!section?.header?.readOnly,'info-section':section?.header?.readOnly}\">\r\n<form [formGroup]=\"formGroup\">\r\n <app-input [loading]=\"true\" type=\"enOnly\" formControlName=\"input\" label=\"Input\" class=\"section-item\"></app-input>\r\n <app-input-currency formControlName=\"currencyInput\" label=\"currency\"></app-input-currency>\r\n <app-input-email formControlName=\"emailInput\" label=\"email\"></app-input-email>\r\n <app-input-number formControlName=\"numberInput\" label=\"number\"></app-input-number>\r\n <app-custom-searchable class=\"section-item\" formControlName=\"customSearchable\" label=\"Custom-searchable\" [options]=\"lov?.['approverActions']?.options\" [displayedLable]=\"'name'\"\r\n [key]=\"'name'\"\r\n ></app-custom-searchable>\r\n <app-checkbox formControlName=\"checkbox\" termsLabel=\"Terms and condtions\" [containTerms]=\"true\"></app-checkbox>\r\n <app-textarea formControlName=\"textArea\" label=\"Text-area\"></app-textarea>\r\n <app-datepicker formControlName=\"datePicker\" [matSuffix]=\"true\" label=\"Date-picker\" minDate=\"today\" maxDate=\"today\"></app-datepicker>\r\n <app-date-range-picker formControlName=\"datePickerRange\" label=\"Date-picker-range\" [matSuffix]=\"true\" minDate=\"today\" minDate=\"today\" maxDate=\"today\"></app-date-range-picker>\r\n <app-input formControlName=\"input1\"></app-input>\r\n</form>\r\n<ds-button\r\n(click)=\"formValue(formGroup)\"\r\n[ngClass]=\"{'disabled': !formGroup.valid}\"\r\n>\r\n{{ i18n.translate('submit') }}\r\n</ds-button>\r\n <ds-alert class=\"full\" type=\"warning\" icon=\"info\">\r\n <div class=\"d-flex gap-2\">\r\n Request details working fine\r\n </div>\r\n </ds-alert>\r\n <!-- <form [formGroup]=\"fieldsForm\">\r\n <app-input formControlName=\"input1\" ></app-input>\r\n </form> -->\r\n</div>\r\n@if (!section?.header?.readOnly) {\r\n <div class=\"mt-4\">\r\n <lib-action-buttons\r\n [lovOptions]=\"lov?.['decision']?.options\"\r\n [lovType]=\"lov?.['decision']?.type\"\r\n [section]=\"section\"\r\n [form]=\"form\"\r\n [sections]=\"form.sections\"\r\n [showApprovalCycle]=\"true\"\r\n [customCall]=\"false\"\r\n [fieldsForm]=\"formGroup\"\r\n (customCallEmit)=\"customCallSubmit($event)\"\r\n (resetFormEmit)=\"resetForm()\"\r\n />\r\n </div>\r\n}\r\n", styles: [".form-section-divide{--form-section-columns: 1fr 1fr}@media (max-width: 756px){.form-section-divide{--form-section-columns: 100%}}.form-section-divide .full{grid-column:1/-1}.head-title{position:relative;margin-bottom:12px}.head-title h3{display:inline-block;color:#8e9aa0;font-size:14px;font-weight:500;background-color:#fff;padding-inline-end:20px;position:relative;z-index:2;margin:0}.head-title:after{content:\"\";position:absolute;width:100%;height:1px;background-color:#dee0e2;top:50%;left:0;right:0;transform:translateY(-50%);z-index:1}.chamber{margin-bottom:20px}.chamber .chamber-content{background-color:#f8f8f8;padding:20px}.chamber .chamber-content .chamber-select{display:flex}.chamber .chamber-content mat-checkbox{font-size:14px}\n"] }]
|
|
6272
6853
|
}], ctorParameters: () => [{ type: CoreI18nService }, { type: i2.FormBuilder }, { type: ActionStateService }], propDecorators: { isReadOnly: [{
|
|
6273
6854
|
type: Input
|
|
6274
6855
|
}], section: [{
|
|
@@ -6343,7 +6924,7 @@ class GeneralApproverSectionComponent {
|
|
|
6343
6924
|
this.fieldsForm.reset();
|
|
6344
6925
|
}
|
|
6345
6926
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: GeneralApproverSectionComponent, deps: [{ token: CoreI18nService }, { token: i2.FormBuilder }, { token: ActionStateService }], target: i0.ɵɵFactoryTarget.Component });
|
|
6346
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: GeneralApproverSectionComponent, isStandalone: true, selector: "app-general-approver-section", inputs: { isReadOnly: "isReadOnly", section: "section", form: "form", lov: "lov", className: "className" }, ngImport: i0, template: "<div\r\n [ngClass]=\"{'form-section-divide form-section':!section?.header?.readOnly,'info-section':section?.header?.readOnly}\">\r\n\r\n <ds-alert class=\"full\" type=\"warning\" icon=\"info\">\r\n\r\n <div class=\"d-flex gap-2\">\r\n\r\n Request details working fine\r\n\r\n </div>\r\n\r\n </ds-alert>\r\n\r\n <form [formGroup]=\"fieldsForm\">\r\n <app-input formControlName=\"input1\"></app-input>\r\n </form>\r\n\r\n</div>\r\n@if (!section?.header?.readOnly) {\r\n <div class=\"mt-4\">\r\n <lib-action-buttons\r\n [lovOptions]=\"lov?.['decision']?.options\"\r\n [lovType]=\"lov?.['decision']?.type\"\r\n [section]=\"section\"\r\n [form]=\"form\"\r\n [sections]=\"form.sections\"\r\n [showApprovalCycle]=\"true\"\r\n [customCall]=\"false\"\r\n [fieldsForm]=\"fieldsForm\"\r\n (customCallEmit)=\"customCallSubmit($event)\"\r\n (resetFormEmit)=\"resetForm()\"\r\n />\r\n </div>\r\n}\r\n", styles: [".form-section-divide{--form-section-columns: 1fr 1fr}@media (max-width: 756px){.form-section-divide{--form-section-columns: 100%}}.form-section-divide .full{grid-column:1/-1}.head-title{position:relative;margin-bottom:12px}.head-title h3{display:inline-block;color:#8e9aa0;font-size:14px;font-weight:500;background-color:#fff;padding-inline-end:20px;position:relative;z-index:2;margin:0}.head-title:after{content:\"\";position:absolute;width:100%;height:1px;background-color:#dee0e2;top:50%;left:0;right:0;transform:translateY(-50%);z-index:1}.chamber{margin-bottom:20px}.chamber .chamber-content{background-color:#f8f8f8;padding:20px}.chamber .chamber-content .chamber-select{display:flex}.chamber .chamber-content mat-checkbox{font-size:14px}\n"], dependencies: [{ kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: InputComponent, selector: "app-input", inputs: ["
|
|
6927
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: GeneralApproverSectionComponent, isStandalone: true, selector: "app-general-approver-section", inputs: { isReadOnly: "isReadOnly", section: "section", form: "form", lov: "lov", className: "className" }, ngImport: i0, template: "<div\r\n [ngClass]=\"{'form-section-divide form-section':!section?.header?.readOnly,'info-section':section?.header?.readOnly}\">\r\n\r\n <ds-alert class=\"full\" type=\"warning\" icon=\"info\">\r\n\r\n <div class=\"d-flex gap-2\">\r\n\r\n Request details working fine\r\n\r\n </div>\r\n\r\n </ds-alert>\r\n\r\n <form [formGroup]=\"fieldsForm\">\r\n <app-input formControlName=\"input1\"></app-input>\r\n </form>\r\n\r\n</div>\r\n@if (!section?.header?.readOnly) {\r\n <div class=\"mt-4\">\r\n <lib-action-buttons\r\n [lovOptions]=\"lov?.['decision']?.options\"\r\n [lovType]=\"lov?.['decision']?.type\"\r\n [section]=\"section\"\r\n [form]=\"form\"\r\n [sections]=\"form.sections\"\r\n [showApprovalCycle]=\"true\"\r\n [customCall]=\"false\"\r\n [fieldsForm]=\"fieldsForm\"\r\n (customCallEmit)=\"customCallSubmit($event)\"\r\n (resetFormEmit)=\"resetForm()\"\r\n />\r\n </div>\r\n}\r\n", styles: [".form-section-divide{--form-section-columns: 1fr 1fr}@media (max-width: 756px){.form-section-divide{--form-section-columns: 100%}}.form-section-divide .full{grid-column:1/-1}.head-title{position:relative;margin-bottom:12px}.head-title h3{display:inline-block;color:#8e9aa0;font-size:14px;font-weight:500;background-color:#fff;padding-inline-end:20px;position:relative;z-index:2;margin:0}.head-title:after{content:\"\";position:absolute;width:100%;height:1px;background-color:#dee0e2;top:50%;left:0;right:0;transform:translateY(-50%);z-index:1}.chamber{margin-bottom:20px}.chamber .chamber-content{background-color:#f8f8f8;padding:20px}.chamber .chamber-content .chamber-select{display:flex}.chamber .chamber-content mat-checkbox{font-size:14px}\n"], dependencies: [{ kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: InputComponent, selector: "app-input", inputs: ["tooltip", "floatLabel", "className", "iconPrefixName", "iconSuffixName", "emitedChangedValue1"] }, { kind: "component", type: ActionButtonsComponent, selector: "lib-action-buttons", inputs: ["lovOptions", "lovType", "fieldsForm", "form", "section", "sections", "showApprovalCycle", "customCall"], outputs: ["resetFormEmit", "customCallEmit"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i2.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }] });
|
|
6347
6928
|
}
|
|
6348
6929
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: GeneralApproverSectionComponent, decorators: [{
|
|
6349
6930
|
type: Component,
|
|
@@ -6496,12 +7077,12 @@ class CoreAppComponent {
|
|
|
6496
7077
|
}
|
|
6497
7078
|
window.scrollTo(0, 0);
|
|
6498
7079
|
}
|
|
6499
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: CoreAppComponent, deps: [{ token: SegmentDynamicLoaderService }, { token: DOCUMENT }, { token: i2$
|
|
7080
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: CoreAppComponent, deps: [{ token: SegmentDynamicLoaderService }, { token: DOCUMENT }, { token: i2$4.Router }, { token: SidenavService }, { token: CoreService }], target: i0.ɵɵFactoryTarget.Component });
|
|
6500
7081
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: CoreAppComponent, isStandalone: true, selector: "lib-app", providers: [
|
|
6501
7082
|
{ provide: DynamicComponentInjectorToken, useValue: { /* your value here */} }
|
|
6502
7083
|
], ngImport: i0, template: "<core-layout>\r\n @if (!loading['form']) {\r\n <core-service-header\r\n [isLoading]=\"false\"\r\n [formTitle]=\"formTitle\"\r\n [form]=\"form\">\r\n </core-service-header>\r\n <app-workflow-section\r\n workflow\r\n [form]=\"form\"\r\n [segmentDynamicLoaderService]=\"segmentDynamicLoader\"\r\n [sections]=\"form?.sections\">\r\n\r\n <app-request-details-section [form]=\"form\" [section]=\"form?.sections[0]\" [lov]=\"form?.lovs\" className=\"form-section\"></app-request-details-section>\r\n <!-- [isReadOnly]=\"form.sections[0].header.readOnly\"-->\r\n </app-workflow-section>\r\n } @else {\r\n <core-service-header header [formTitle]=\"formTitle\" [isLoading]=\"true\">\r\n </core-service-header>\r\n }\r\n</core-layout>\r\n", styles: [""], dependencies: [{ kind: "component", type:
|
|
6503
7084
|
// DynamicModule,
|
|
6504
|
-
LayoutComponent, selector: "core-layout", inputs: ["form", "formTitle", "isLoading", "serviceBrief"] }, { kind: "component", type: ServiceHeaderComponent, selector: "core-service-header", inputs: ["form", "showHistory", "isLoading", "showApprovalHistory", "approvalHistory", "creationDate", "formTitle", "section", "
|
|
7085
|
+
LayoutComponent, selector: "core-layout", inputs: ["form", "formTitle", "isLoading", "serviceBrief"] }, { kind: "component", type: ServiceHeaderComponent, selector: "core-service-header", inputs: ["form", "showHistory", "isLoading", "showApprovalHistory", "approvalHistory", "creationDate", "formTitle", "section", "serviceFaq"] }, { kind: "component", type: WorkflowSectionComponent, selector: "app-workflow-section", inputs: ["sections", "isReadOnly", "isLoading", "form", "contentClass", "sectionsController", "segmentDynamicLoaderService", "sectionFormComponent", "sectionName"], outputs: ["sectionSubmitted"] }, { kind: "component", type: RequestDetailsSectionComponent, selector: "app-request-details-section", inputs: ["isReadOnly", "section", "form", "lov", "className"] }] });
|
|
6505
7086
|
}
|
|
6506
7087
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: CoreAppComponent, decorators: [{
|
|
6507
7088
|
type: Component,
|
|
@@ -6517,7 +7098,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
|
|
|
6517
7098
|
}], ctorParameters: () => [{ type: SegmentDynamicLoaderService }, { type: Document, decorators: [{
|
|
6518
7099
|
type: Inject,
|
|
6519
7100
|
args: [DOCUMENT]
|
|
6520
|
-
}] }, { type: i2$
|
|
7101
|
+
}] }, { type: i2$4.Router }, { type: SidenavService }, { type: CoreService }] });
|
|
6521
7102
|
|
|
6522
7103
|
function encodePassword(formId, password) {
|
|
6523
7104
|
const formIdString = Array.from(new TextEncoder().encode(formId), (x) => String.fromCodePoint(x)).join('');
|
|
@@ -6676,105 +7257,6 @@ class BuiltInCustomValidators {
|
|
|
6676
7257
|
}
|
|
6677
7258
|
}
|
|
6678
7259
|
|
|
6679
|
-
/* eslint-disable @typescript-eslint/no-empty-function */
|
|
6680
|
-
/* eslint-disable @angular-eslint/directive-selector */
|
|
6681
|
-
class ArOnlyDirective {
|
|
6682
|
-
specialKeys = ['Backspace', 'ArrowRight', 'ArrowLeft', 'ArrowUp', 'ArrowDown', 'Control'];
|
|
6683
|
-
constructor() {
|
|
6684
|
-
}
|
|
6685
|
-
regex = /^[~`!@#$%^&*()_+=[\]\{}|;':",.\/<>?0-9-]+$/;
|
|
6686
|
-
onKeyDown(event) {
|
|
6687
|
-
const text = event.key;
|
|
6688
|
-
if (event.ctrlKey && (text == 'c' || text == 'v' || text == 'x' || text == 'a' || text == 'z')) {
|
|
6689
|
-
return;
|
|
6690
|
-
}
|
|
6691
|
-
const arabicAlphabetDigits = /[\u0600-\u06ff]|[\u0750-\u077f]|[\ufb50-\ufc3f]|[\ufe70-\ufefc]|[\u0200]|[\u00A0]/g;
|
|
6692
|
-
if (arabicAlphabetDigits.test(text) || text == " " || text == 'Backspace' || this.regex.test(text)) {
|
|
6693
|
-
return;
|
|
6694
|
-
}
|
|
6695
|
-
else {
|
|
6696
|
-
event.preventDefault();
|
|
6697
|
-
}
|
|
6698
|
-
}
|
|
6699
|
-
onPaste(event) {
|
|
6700
|
-
const data = event.clipboardData.getData('text/plain');
|
|
6701
|
-
if (!(/[\u0600-\u06ff]|[\u0750-\u077f]|[\ufb50-\ufc3f]|[\ufe70-\ufefc]|[\u0200]|[\u00A0]/g.test(data))) {
|
|
6702
|
-
event.preventDefault();
|
|
6703
|
-
}
|
|
6704
|
-
}
|
|
6705
|
-
onDrop(event) {
|
|
6706
|
-
const data = event.dataTransfer.getData("text/plain");
|
|
6707
|
-
if (!(/[\u0600-\u06ff]|[\u0750-\u077f]|[\ufb50-\ufc3f]|[\ufe70-\ufefc]|[\u0200]|[\u00A0]/g.test(data))) {
|
|
6708
|
-
event.preventDefault();
|
|
6709
|
-
}
|
|
6710
|
-
}
|
|
6711
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: ArOnlyDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
6712
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.2.8", type: ArOnlyDirective, selector: "[arOnly]", host: { listeners: { "keydown": "onKeyDown($event)", "paste": "onPaste($event)", "drop": "onDrop($event)" } }, ngImport: i0 });
|
|
6713
|
-
}
|
|
6714
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: ArOnlyDirective, decorators: [{
|
|
6715
|
-
type: Directive,
|
|
6716
|
-
args: [{
|
|
6717
|
-
selector: '[arOnly]'
|
|
6718
|
-
}]
|
|
6719
|
-
}], ctorParameters: () => [], propDecorators: { onKeyDown: [{
|
|
6720
|
-
type: HostListener,
|
|
6721
|
-
args: ['keydown', ['$event']]
|
|
6722
|
-
}], onPaste: [{
|
|
6723
|
-
type: HostListener,
|
|
6724
|
-
args: ['paste', ['$event']]
|
|
6725
|
-
}], onDrop: [{
|
|
6726
|
-
type: HostListener,
|
|
6727
|
-
args: ['drop', ['$event']]
|
|
6728
|
-
}] } });
|
|
6729
|
-
|
|
6730
|
-
/* eslint-disable @angular-eslint/directive-selector */
|
|
6731
|
-
/* eslint-disable @typescript-eslint/no-empty-function */
|
|
6732
|
-
class EnOnlyDirective {
|
|
6733
|
-
specialKeys = ['Backspace', 'ArrowRight', 'ArrowLeft', 'ArrowUp', 'ArrowDown', 'Control'];
|
|
6734
|
-
constructor() {
|
|
6735
|
-
}
|
|
6736
|
-
regex = /^[~`!@#$%^&*()_+=[\]\{}|;':",.\/<>?a-zA-Z0-9- ]+$/;
|
|
6737
|
-
onKeyDown(event) {
|
|
6738
|
-
const text = event.key;
|
|
6739
|
-
const english = /^[a-zA-Z ]*$/;
|
|
6740
|
-
if (this.regex.test(text) || text == " " || text == 'Backspace' || (event.ctrlKey && (text == 'c' || text == 'ؤ' || text == 'v' || text == 'ر' || text == 'x' || text == 'ء' || text == 'a' || text == 'ش' || text == 'z' || text == 'ئ'))) {
|
|
6741
|
-
return;
|
|
6742
|
-
}
|
|
6743
|
-
else {
|
|
6744
|
-
event.preventDefault();
|
|
6745
|
-
}
|
|
6746
|
-
}
|
|
6747
|
-
onPaste(event) {
|
|
6748
|
-
const data = event.clipboardData.getData('text/plain');
|
|
6749
|
-
if (!(this.regex.test(data))) {
|
|
6750
|
-
event.preventDefault();
|
|
6751
|
-
}
|
|
6752
|
-
}
|
|
6753
|
-
onDrop(event) {
|
|
6754
|
-
const data = event.dataTransfer.getData("text/plain");
|
|
6755
|
-
if (!(this.regex.test(data))) {
|
|
6756
|
-
event.preventDefault();
|
|
6757
|
-
}
|
|
6758
|
-
}
|
|
6759
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: EnOnlyDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
6760
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.2.8", type: EnOnlyDirective, selector: "[enOnly]", host: { listeners: { "keydown": "onKeyDown($event)", "paste": "onPaste($event)", "drop": "onDrop($event)" } }, ngImport: i0 });
|
|
6761
|
-
}
|
|
6762
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: EnOnlyDirective, decorators: [{
|
|
6763
|
-
type: Directive,
|
|
6764
|
-
args: [{
|
|
6765
|
-
selector: '[enOnly]'
|
|
6766
|
-
}]
|
|
6767
|
-
}], ctorParameters: () => [], propDecorators: { onKeyDown: [{
|
|
6768
|
-
type: HostListener,
|
|
6769
|
-
args: ['keydown', ['$event']]
|
|
6770
|
-
}], onPaste: [{
|
|
6771
|
-
type: HostListener,
|
|
6772
|
-
args: ['paste', ['$event']]
|
|
6773
|
-
}], onDrop: [{
|
|
6774
|
-
type: HostListener,
|
|
6775
|
-
args: ['drop', ['$event']]
|
|
6776
|
-
}] } });
|
|
6777
|
-
|
|
6778
7260
|
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
6779
7261
|
function validateSAID() {
|
|
6780
7262
|
if (this?.personalInfoFormTemp) {
|
|
@@ -6920,76 +7402,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
|
|
|
6920
7402
|
}]
|
|
6921
7403
|
}] });
|
|
6922
7404
|
|
|
6923
|
-
|
|
6924
|
-
|
|
6925
|
-
|
|
6926
|
-
elementRef;
|
|
6927
|
-
formatcurrencypipe;
|
|
6928
|
-
el;
|
|
6929
|
-
decimals;
|
|
6930
|
-
constructor(elementRef, formatcurrencypipe) {
|
|
6931
|
-
this.elementRef = elementRef;
|
|
6932
|
-
this.formatcurrencypipe = formatcurrencypipe;
|
|
6933
|
-
this.el = this.elementRef.nativeElement;
|
|
6934
|
-
}
|
|
6935
|
-
ngOnInit() {
|
|
6936
|
-
this.el.value = this.formatcurrencypipe.transform(this.el.value);
|
|
6937
|
-
}
|
|
6938
|
-
onFocus(value, event) {
|
|
6939
|
-
this.el.value = this.formatcurrencypipe.parse(value); // opossite of transform
|
|
6940
|
-
if (event.which == 9) {
|
|
6941
|
-
return false;
|
|
6942
|
-
}
|
|
6943
|
-
return this.el.select();
|
|
6944
|
-
}
|
|
6945
|
-
onBlur(value) {
|
|
6946
|
-
this.el.value = this.formatcurrencypipe.transform(value);
|
|
6947
|
-
}
|
|
6948
|
-
onKeyDown(event) {
|
|
6949
|
-
const e = event;
|
|
6950
|
-
if (e.key == 'و' || e.key == 'ز') {
|
|
6951
|
-
e.preventDefault();
|
|
6952
|
-
}
|
|
6953
|
-
if ([46, 8, 9, 27, 13, 110, 190].indexOf(e.keyCode) !== -1 ||
|
|
6954
|
-
// Allow: Ctrl+A
|
|
6955
|
-
(e.keyCode === 65 && (e.ctrlKey || e.metaKey)) ||
|
|
6956
|
-
// Allow: Ctrl+C
|
|
6957
|
-
(e.keyCode === 67 && (e.ctrlKey || e.metaKey)) ||
|
|
6958
|
-
// Allow: Ctrl+V
|
|
6959
|
-
(e.keyCode === 86 && (e.ctrlKey || e.metaKey)) ||
|
|
6960
|
-
// Allow: Ctrl+X
|
|
6961
|
-
(e.keyCode === 88 && (e.ctrlKey || e.metaKey)) ||
|
|
6962
|
-
(e.keyCode === 188) ||
|
|
6963
|
-
// Allow: home, end, left, right
|
|
6964
|
-
(e.keyCode >= 35 && e.keyCode <= 39)) {
|
|
6965
|
-
// let it happen, don't do anything
|
|
6966
|
-
return;
|
|
6967
|
-
}
|
|
6968
|
-
// Ensure that it is a number and stop the keypress
|
|
6969
|
-
if ((e.shiftKey || (e.keyCode < 48 || e.keyCode > 57)) && (e.keyCode < 96 || e.keyCode > 105)) {
|
|
6970
|
-
e.preventDefault();
|
|
6971
|
-
}
|
|
6972
|
-
}
|
|
6973
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: MycurrencyDirective, deps: [{ token: i0.ElementRef }, { token: MycurrencyPipe }], target: i0.ɵɵFactoryTarget.Directive });
|
|
6974
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.2.8", type: MycurrencyDirective, selector: "[appMycurrency]", inputs: { decimals: "decimals" }, host: { listeners: { "focus": "onFocus($event.target.value,$event)", "blur": "onBlur($event.target.value)", "keydown": "onKeyDown($event)" } }, ngImport: i0 });
|
|
6975
|
-
}
|
|
6976
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: MycurrencyDirective, decorators: [{
|
|
6977
|
-
type: Directive,
|
|
6978
|
-
args: [{
|
|
6979
|
-
selector: '[appMycurrency]'
|
|
6980
|
-
}]
|
|
6981
|
-
}], ctorParameters: () => [{ type: i0.ElementRef }, { type: MycurrencyPipe }], propDecorators: { decimals: [{
|
|
6982
|
-
type: Input
|
|
6983
|
-
}], onFocus: [{
|
|
6984
|
-
type: HostListener,
|
|
6985
|
-
args: ["focus", ["$event.target.value", "$event"]]
|
|
6986
|
-
}], onBlur: [{
|
|
6987
|
-
type: HostListener,
|
|
6988
|
-
args: ["blur", ["$event.target.value"]]
|
|
6989
|
-
}], onKeyDown: [{
|
|
6990
|
-
type: HostListener,
|
|
6991
|
-
args: ['keydown', ['$event']]
|
|
6992
|
-
}] } });
|
|
7405
|
+
// export * from './ar.directive';
|
|
7406
|
+
// export * from './en.directive';
|
|
7407
|
+
// export * from './currency.directive';
|
|
6993
7408
|
|
|
6994
7409
|
/*
|
|
6995
7410
|
* Public API Surface of bpm-core
|
|
@@ -7000,5 +7415,5 @@ const MY_LIB_CONFIG_TOKEN = new InjectionToken('MyLibConfig');
|
|
|
7000
7415
|
* Generated bundle index. Do not edit.
|
|
7001
7416
|
*/
|
|
7002
7417
|
|
|
7003
|
-
export { APPROVERS, ActionButtonsComponent, ActionStateService,
|
|
7418
|
+
export { APPROVERS, ActionButtonsComponent, ActionStateService, AttachmentSectionComponent, AttachmentSectionDataComponent, BaseComponent, BuiltInCustomValidators, COMMENT_CONTAINER, CheckBoxComponent, CommentsDrop, ConfirmDialogComponent, ConfirmationPopupComponent, CoreAppComponent, CoreI18nService, CoreService, CustomSearchableComponent, DATE_DASH, DATE_SLASH, DATE_TIME, DONT_SHOW, DatePickerComponent, DateRangePickerComponent, DeleteDialogComponent, DeletePopupComponent, DocsUploaderComponent, FALSE_BOOL, FALSE_STRING, FEEDBACK_CONTAINER, FEEDBACK_STATUS_REQUEST, FEEDBACK_STATUS_RESPOND, FEEDBACK_STATUS_RESPONDED, FEEDBACK_STATUS_WAITING, FORM_STATUS_APPROVE, FORM_STATUS_APPROVED, FORM_STATUS_CANCEL, FORM_STATUS_CANCELLED, FORM_STATUS_COMPLETED, FORM_STATUS_NEW, FORM_STATUS_PENDING, FORM_STATUS_REJECT, FORM_STATUS_REJECTED, FORM_STATUS_SEND_BACK, FeedBackService, FeedbackSectionComponent, Form, FormLabelComponent, FormSectionComponent, FormValidation, FormatAsPasswordPipe, FormatTimePipe, GETSIPORTENTRYGROUPS, GETSIPORTENTRYLOCATIONS, HAS_COMMENTS, HEADER_CONTENT_TYPE_FORM, HTTP_METHOD_GET, HTTP_METHOD_POST, HTTP_METHOD_PUT, HTTP_PROTOCOL_HTTP, HTTP_PROTOCOL_HTTPS, Header, IGATE_STATIC_ASSET_PROFILE_PHOTO_URL, INBOX_STATUS_PENDING, INBOX_STATUS_PROCESSED, INBOX_STATUS_SENT, InboxItem, InfoItemComponent, InputComponent, InputCurrencyComponent, InputEmailComponent, InputMaskComponent, InputNumberComponent, InputTelephoneComponent, LANGUAGE_CODE_AR, LANGUAGE_CODE_EN, LOGOUT_URL, LayoutComponent, MY_LIB_CONFIG_TOKEN, MainRequestDetailsComponent, Messages, MycurrencyPipe, NO_COMMENTS, NO_VALUE, PROCESS_NAME_CODE, PROFILE_CONTAINER, ProfileInfoDrop, ProfileSectionComponent, READ_ONLY, REPORT, ROLE_REQUESTER, RadioComponent, RepeatedListComponent, SECTION_ID_APPROVAL_PARTIAL_NAME, SECTION_ID_DM_PARTIAL_ROLE, SECTION_ID_EMP_INFO_APPROVAL_PARTIAL_ROLE, SECTION_ID_EXECUTE_PARTIAL_ROLE, SECTION_ID_GM_PARTIAL_ROLE, SECTION_ID_NOTHING_PARTIAL_NAME, SECTION_ID_PAYROLL_APPROVAL_PARTIAL_ROLE, SECTION_ID_PERFORM_PARTIAL_ROLE, SECTION_ID_REQUESTER_PARTIAL_NAME, SECTION_ID_REQUEST_DETAILS, SECTION_ID_SM_PARTIAL_ROLE, SECTION_ID_SVP_PARTIAL_ROLE, SECTION_ID_VP_PARTIAL_ROLE, SECTION_STATUS_APPROVED, SECTION_STATUS_PENDING, SECTION_STATUS_UNSATISFIED, SERVICE_NAME_CEP, SERVICE_NAME_DP_CREATE_FEEDBACK, SERVICE_NAME_DP_INBOX_ITEM, SERVICE_NAME_DP_LOAD_HISTORY, SERVICE_NAME_DP_SEARCH_EMPLOYEE, SERVICE_NAME_DP_UPDATE_FEEDBACK, SERVICE_NAME_DP_UPDATE_INBOX_ITEM, SERVICE_NAME_MAF, SERVICE_NAME_WM_CHILD_FORM, SERVICE_NAME_WM_DRAFT_FORM, SERVICE_NAME_WM_FORM, SERVICE_NAME_WM_GET_APPROVED_REQUEST, SERVICE_NAME_WM_GET_MY_APPROVED_REQUEST, SERVICE_NAME_WM_HTML_GENERATOR, STATE_MACHINE_ACTION_CALC, STATE_MACHINE_ACTION_COMMONAPI, STATE_MACHINE_ACTION_CONVERT, STATE_MACHINE_ACTION_EMPLOYEE_PROFILE, STATE_MACHINE_ACTION_FAILURE, STATE_MACHINE_ACTION_GET_APPROVED_REQUEST, STATE_MACHINE_ACTION_GET_APPROVED_REQUEST_RESPONSE, STATE_MACHINE_ACTION_GET_FEEDBACK, STATE_MACHINE_ACTION_GET_INBOX_ITEM, STATE_MACHINE_ACTION_HANDLE_ERROR, STATE_MACHINE_ACTION_INBOX_ITEM_RESPONSE, STATE_MACHINE_ACTION_LOAD_FILE, STATE_MACHINE_ACTION_LOAD_FORM, STATE_MACHINE_ACTION_LOAD_HISTORY, STATE_MACHINE_ACTION_PDF, STATE_MACHINE_ACTION_PPROVED_REQUESTS, STATE_MACHINE_ACTION_PROJECT_CEP, STATE_MACHINE_ACTION_PROJECT_MAF, STATE_MACHINE_ACTION_SEARCH, STATE_MACHINE_ACTION_SEARCH_EMPLOYEE, STATE_MACHINE_ACTION_SET_FLAG, STATE_MACHINE_ACTION_SHOW_PRINT, STATE_MACHINE_ACTION_SUBMIT_FEEDBACK, STATE_MACHINE_ACTION_SUBMIT_FORM, STATE_MACHINE_ACTION_SUCCESS, STATE_MACHINE_ACTION_SUCCESS_HISTORY, STATE_MACHINE_ACTION_SUCCESS_INBOX_ITEM, STATE_MACHINE_ACTION_SUCCESS_PRINT, STATE_MACHINE_ACTION_SUCCESS_RESPONSE, STATE_MACHINE_ACTION_SUCCESS_SERVICES, STATE_MACHINE_ACTION_SUCCESS_USERS, STATE_MACHINE_ACTION_SUCCESS_WM, STATE_MACHINE_ACTION_UPDATE_FEEDBACK, STATE_MACHINE_ACTION_USER_CEP, STATE_MACHINE_ACTION_USER_MAF, STATE_MACHINE_STATUS_ERROR, STATE_MACHINE_STATUS_FETCHING, STATE_MACHINE_STATUS_IDLE, STATE_MACHINE_STATUS_RESULT, STATE_MACHINE_STATUS_SENDING, STATE_NAME_DP_GET_FEEDBACK, SearchEmployeeComponent, Section, SectionHeader, SelectComponent, ServiceHeaderComponent, SidenavService, SpecialCharacterDirective, StatusComponent, SubmitDialogComponent, TARGET_SERVER_DP, TARGET_SERVER_WM, TRUE_BOOL, TRUE_STRING, TableListComponent, TermsConditionsComponent, TextDirective, TextareaComponent, TitleSectionComponent, ToggleButtonComponent, URL_SEPARATOR, WM_ACTION_SAVE, WM_ACTION_SAVE_CHANGES, WM_ACTION_SUBMIT, WORKFLOW_ITEMS, WRITE_MODE, WorkflowSectionComponent, dataURItoBlob, encodePassword, handelErrorResponse, isValidData, stringToBooleanPipe, validateSAID };
|
|
7004
7419
|
//# sourceMappingURL=bpm-core.mjs.map
|