@seniorsistemas/exclusion-process-component 0.2.1 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundles/seniorsistemas-exclusion-process-component.umd.js +103 -75
- package/bundles/seniorsistemas-exclusion-process-component.umd.js.map +1 -1
- package/bundles/seniorsistemas-exclusion-process-component.umd.min.js +2 -2
- package/bundles/seniorsistemas-exclusion-process-component.umd.min.js.map +1 -1
- package/esm2015/exclusion-details/exclusion-details.component.js +82 -63
- package/esm2015/exclusions-list/exclusions-list.component.js +21 -15
- package/esm2015/exclusions-list/exclusions-list.routing.js +2 -2
- package/esm5/exclusion-details/exclusion-details.component.js +87 -65
- package/esm5/exclusions-list/exclusions-list.component.js +21 -15
- package/esm5/exclusions-list/exclusions-list.routing.js +2 -2
- package/exclusion-details/exclusion-details.component.d.ts +11 -11
- package/exclusions-list/exclusions-list.component.d.ts +7 -5
- package/fesm2015/seniorsistemas-exclusion-process-component.js +101 -76
- package/fesm2015/seniorsistemas-exclusion-process-component.js.map +1 -1
- package/fesm5/seniorsistemas-exclusion-process-component.js +105 -77
- package/fesm5/seniorsistemas-exclusion-process-component.js.map +1 -1
- package/package.json +1 -1
- package/seniorsistemas-exclusion-process-component.metadata.json +1 -1
|
@@ -3,9 +3,9 @@ import { CommonModule } from '@angular/common';
|
|
|
3
3
|
import { InjectionToken, Inject, Injectable, Output, Component, ViewEncapsulation, NgModule, ChangeDetectorRef, ViewChild } from '@angular/core';
|
|
4
4
|
import { PanelModule } from 'primeng/panel';
|
|
5
5
|
import { TableModule } from 'primeng/table';
|
|
6
|
-
import {
|
|
6
|
+
import { EnumBadgeColors, EnumColumnFieldType, SidebarModule, ButtonModule, TableModule as TableModule$1, LoadingStateModule, LocaleModule, EmptyStateModule, FieldType, FormField, LocaleService, ControlErrorsModule, InfoSignModule, DynamicFormModule, TokenListModule } from '@seniorsistemas/angular-components';
|
|
7
7
|
import * as moment from 'moment';
|
|
8
|
-
import {
|
|
8
|
+
import { ActivatedRoute, Router, RouterModule } from '@angular/router';
|
|
9
9
|
import { TranslateService, TranslateModule } from '@ngx-translate/core';
|
|
10
10
|
import { throwError, Subject } from 'rxjs';
|
|
11
11
|
import { catchError, map, takeUntil, finalize } from 'rxjs/operators';
|
|
@@ -166,18 +166,36 @@ LogicalDeleteService = __decorate([
|
|
|
166
166
|
Injectable()
|
|
167
167
|
], LogicalDeleteService);
|
|
168
168
|
|
|
169
|
+
const EXCLUSION_PROCESS_STATUS_BADGE = [
|
|
170
|
+
{
|
|
171
|
+
enumValue: EnumExclusionProcessStatus.ERROR,
|
|
172
|
+
color: EnumBadgeColors.RED
|
|
173
|
+
},
|
|
174
|
+
{
|
|
175
|
+
enumValue: EnumExclusionProcessStatus.PENDING,
|
|
176
|
+
color: EnumBadgeColors.YELLOW
|
|
177
|
+
},
|
|
178
|
+
{
|
|
179
|
+
enumValue: EnumExclusionProcessStatus.PROCESSING,
|
|
180
|
+
color: EnumBadgeColors.BLUE
|
|
181
|
+
},
|
|
182
|
+
{
|
|
183
|
+
enumValue: EnumExclusionProcessStatus.SUCCESS,
|
|
184
|
+
color: EnumBadgeColors.GREEN
|
|
185
|
+
}
|
|
186
|
+
];
|
|
169
187
|
let ExclusionDetailsComponent = class ExclusionDetailsComponent {
|
|
170
|
-
constructor(
|
|
171
|
-
this.router = router;
|
|
188
|
+
constructor(route, translate, logicalDeleteService, projectConfigs) {
|
|
172
189
|
this.route = route;
|
|
173
190
|
this.translate = translate;
|
|
174
191
|
this.logicalDeleteService = logicalDeleteService;
|
|
175
192
|
this.projectConfigs = projectConfigs;
|
|
176
|
-
this.
|
|
193
|
+
this.expandedRows = {};
|
|
177
194
|
this._isVisible = false;
|
|
178
195
|
this._isLoading = false;
|
|
179
|
-
this.
|
|
180
|
-
this.
|
|
196
|
+
this._processGroupData = [];
|
|
197
|
+
this._processGroupColumns = [];
|
|
198
|
+
this._processStepColumns = [];
|
|
181
199
|
this.ngUnsubscribe = new Subject();
|
|
182
200
|
}
|
|
183
201
|
get isVisible() {
|
|
@@ -186,11 +204,14 @@ let ExclusionDetailsComponent = class ExclusionDetailsComponent {
|
|
|
186
204
|
get isLoading() {
|
|
187
205
|
return this._isLoading;
|
|
188
206
|
}
|
|
189
|
-
get
|
|
190
|
-
return this.
|
|
207
|
+
get processGroupData() {
|
|
208
|
+
return this._processGroupData;
|
|
191
209
|
}
|
|
192
|
-
get
|
|
193
|
-
return this.
|
|
210
|
+
get processGroupColumns() {
|
|
211
|
+
return this._processGroupColumns;
|
|
212
|
+
}
|
|
213
|
+
get processStepColumns() {
|
|
214
|
+
return this._processStepColumns;
|
|
194
215
|
}
|
|
195
216
|
ngOnInit() {
|
|
196
217
|
this.route.data
|
|
@@ -198,7 +219,8 @@ let ExclusionDetailsComponent = class ExclusionDetailsComponent {
|
|
|
198
219
|
.subscribe((data) => {
|
|
199
220
|
this.locale = data.localeConfig;
|
|
200
221
|
});
|
|
201
|
-
this.
|
|
222
|
+
this._processGroupColumns = this.getGroupColumns();
|
|
223
|
+
this._processStepColumns = this.getStepColumns();
|
|
202
224
|
}
|
|
203
225
|
ngOnDestroy() {
|
|
204
226
|
this.ngUnsubscribe.next();
|
|
@@ -207,9 +229,8 @@ let ExclusionDetailsComponent = class ExclusionDetailsComponent {
|
|
|
207
229
|
}
|
|
208
230
|
showDetails(details) {
|
|
209
231
|
this._exclusionDetails = details;
|
|
210
|
-
this._entityName = details.entityName;
|
|
211
232
|
this._isVisible = true;
|
|
212
|
-
this.
|
|
233
|
+
this._processGroupData = [];
|
|
213
234
|
this.processDetails = null;
|
|
214
235
|
this.entityDescription = details.entityDescription;
|
|
215
236
|
this.loadProcessDetails(details);
|
|
@@ -221,17 +242,9 @@ let ExclusionDetailsComponent = class ExclusionDetailsComponent {
|
|
|
221
242
|
closeDetails() {
|
|
222
243
|
this._isVisible = false;
|
|
223
244
|
this._exclusionDetails = null;
|
|
224
|
-
this.
|
|
245
|
+
this._processGroupData = [];
|
|
225
246
|
this.disconnectWebSocket();
|
|
226
247
|
}
|
|
227
|
-
openExclusions() {
|
|
228
|
-
this.closeDetails();
|
|
229
|
-
this.router.navigate(["exclusions-list", this._entityName], {
|
|
230
|
-
queryParams: {
|
|
231
|
-
entityDescription: this.entityDescription
|
|
232
|
-
}
|
|
233
|
-
});
|
|
234
|
-
}
|
|
235
248
|
getRecordDescription() {
|
|
236
249
|
var _a;
|
|
237
250
|
if (!((_a = this.processDetails) === null || _a === void 0 ? void 0 : _a.description)) {
|
|
@@ -281,15 +294,15 @@ let ExclusionDetailsComponent = class ExclusionDetailsComponent {
|
|
|
281
294
|
getEmptyStateDescription() {
|
|
282
295
|
return this.translate.instant(`${this.projectConfigs.getTranslationPrefix()}.logical_delete_empty_state_description`);
|
|
283
296
|
}
|
|
284
|
-
|
|
297
|
+
getGroupColumns() {
|
|
285
298
|
return [
|
|
286
299
|
{
|
|
287
300
|
field: "description",
|
|
288
301
|
attributes: ["description"],
|
|
289
|
-
header: this.translate.instant(`${this.projectConfigs.getTranslationPrefix()}.
|
|
302
|
+
header: this.translate.instant(`${this.projectConfigs.getTranslationPrefix()}.logical_delete_group`),
|
|
290
303
|
type: EnumColumnFieldType.STRING,
|
|
291
304
|
style: {
|
|
292
|
-
width: "
|
|
305
|
+
width: "340px"
|
|
293
306
|
}
|
|
294
307
|
},
|
|
295
308
|
{
|
|
@@ -302,24 +315,32 @@ let ExclusionDetailsComponent = class ExclusionDetailsComponent {
|
|
|
302
315
|
width: "100px"
|
|
303
316
|
},
|
|
304
317
|
tooltip: this.getColumnStatusTooltip,
|
|
305
|
-
badgeConfigs:
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
]
|
|
318
|
+
badgeConfigs: EXCLUSION_PROCESS_STATUS_BADGE
|
|
319
|
+
}
|
|
320
|
+
];
|
|
321
|
+
}
|
|
322
|
+
getStepColumns() {
|
|
323
|
+
return [
|
|
324
|
+
{
|
|
325
|
+
field: "description",
|
|
326
|
+
attributes: ["description"],
|
|
327
|
+
header: this.translate.instant(`${this.projectConfigs.getTranslationPrefix()}.logical_delete_step`),
|
|
328
|
+
type: EnumColumnFieldType.STRING,
|
|
329
|
+
style: {
|
|
330
|
+
width: "340px"
|
|
331
|
+
}
|
|
332
|
+
},
|
|
333
|
+
{
|
|
334
|
+
field: "status",
|
|
335
|
+
attributes: ["status"],
|
|
336
|
+
header: this.translate.instant(`${this.projectConfigs.getTranslationPrefix()}.logical_delete_status`),
|
|
337
|
+
type: EnumColumnFieldType.ENUM,
|
|
338
|
+
enumPrefix: `${this.projectConfigs.getTranslationPrefix()}.logical_delete_enum_exclusion_process_status_`,
|
|
339
|
+
style: {
|
|
340
|
+
width: "100px"
|
|
341
|
+
},
|
|
342
|
+
tooltip: this.getColumnStatusTooltip,
|
|
343
|
+
badgeConfigs: EXCLUSION_PROCESS_STATUS_BADGE
|
|
323
344
|
}
|
|
324
345
|
];
|
|
325
346
|
}
|
|
@@ -342,7 +363,14 @@ let ExclusionDetailsComponent = class ExclusionDetailsComponent {
|
|
|
342
363
|
return;
|
|
343
364
|
}
|
|
344
365
|
this.processDetails = process;
|
|
345
|
-
this.
|
|
366
|
+
this._processGroupData = this.sortGroupsByStartDate(process.groups)
|
|
367
|
+
.map(p => (Object.assign(Object.assign({}, p), { steps: this.sortStepsByStartDate(p.steps) })));
|
|
368
|
+
this.expandedRows = {};
|
|
369
|
+
this._processGroupData
|
|
370
|
+
.filter(p => p.status !== EnumExclusionProcessStatus.SUCCESS)
|
|
371
|
+
.forEach(p => {
|
|
372
|
+
this.expandedRows[p.id] = true;
|
|
373
|
+
});
|
|
346
374
|
});
|
|
347
375
|
}
|
|
348
376
|
sortByDate(startDate, finishDate) {
|
|
@@ -360,20 +388,6 @@ let ExclusionDetailsComponent = class ExclusionDetailsComponent {
|
|
|
360
388
|
sortStepsByStartDate(steps) {
|
|
361
389
|
return steps.sort((a, b) => this.sortByDate(a.startDate, b.finishDate));
|
|
362
390
|
}
|
|
363
|
-
loadProcessSummary(process) {
|
|
364
|
-
const stepLogs = [];
|
|
365
|
-
this.sortGroupsByStartDate(process.groups)
|
|
366
|
-
.forEach(group => {
|
|
367
|
-
const steps = this.sortStepsByStartDate(group.steps)
|
|
368
|
-
.map(step => ({
|
|
369
|
-
description: step.description,
|
|
370
|
-
status: step.status,
|
|
371
|
-
errorMessage: step.errorMessage
|
|
372
|
-
}));
|
|
373
|
-
stepLogs.push(...steps);
|
|
374
|
-
});
|
|
375
|
-
this._processSummaryData = stepLogs;
|
|
376
|
-
}
|
|
377
391
|
disconnectWebSocket() {
|
|
378
392
|
if (this._exclusionProcessStatusChangedSubscribe) {
|
|
379
393
|
this._exclusionProcessStatusChangedSubscribe.unsubscribe();
|
|
@@ -423,7 +437,6 @@ let ExclusionDetailsComponent = class ExclusionDetailsComponent {
|
|
|
423
437
|
}
|
|
424
438
|
};
|
|
425
439
|
ExclusionDetailsComponent.ctorParameters = () => [
|
|
426
|
-
{ type: Router },
|
|
427
440
|
{ type: ActivatedRoute },
|
|
428
441
|
{ type: TranslateService },
|
|
429
442
|
{ type: LogicalDeleteService },
|
|
@@ -437,20 +450,26 @@ __decorate([
|
|
|
437
450
|
], ExclusionDetailsComponent.prototype, "isLoading", null);
|
|
438
451
|
__decorate([
|
|
439
452
|
Output()
|
|
440
|
-
], ExclusionDetailsComponent.prototype, "
|
|
453
|
+
], ExclusionDetailsComponent.prototype, "processGroupData", null);
|
|
441
454
|
__decorate([
|
|
442
455
|
Output()
|
|
443
|
-
], ExclusionDetailsComponent.prototype, "
|
|
456
|
+
], ExclusionDetailsComponent.prototype, "processGroupColumns", null);
|
|
457
|
+
__decorate([
|
|
458
|
+
Output()
|
|
459
|
+
], ExclusionDetailsComponent.prototype, "processStepColumns", null);
|
|
444
460
|
__decorate([
|
|
445
461
|
Output()
|
|
446
462
|
], ExclusionDetailsComponent.prototype, "processDetails", void 0);
|
|
447
463
|
__decorate([
|
|
448
464
|
Output()
|
|
449
465
|
], ExclusionDetailsComponent.prototype, "entityDescription", void 0);
|
|
466
|
+
__decorate([
|
|
467
|
+
Output()
|
|
468
|
+
], ExclusionDetailsComponent.prototype, "expandedRows", void 0);
|
|
450
469
|
ExclusionDetailsComponent = __decorate([
|
|
451
470
|
Component({
|
|
452
471
|
selector: "s-exclusion-details",
|
|
453
|
-
template: "<s-sidebar [visible]=\"isVisible\" (visibleChange)=\"onVisibilityChanged($event)\" [header]=\"getSidebarTitle()\">\n <s-loading-state [loading]=\"isLoading\">\n <p-panel [showHeader]=\"false\" styleClass=\"s-exclusion-details-record-details-panel\">\n <div class=\"s-exclusion-details-record-details-container\">\n <div class=\"s-exclusion-details-record-icon-background\">\n <em class=\"far fa-file-alt s-exclusion-details-record-icon\"></em>\n </div>\n\n <div class=\"s-exclusion-details-record-details-recordinfo\">\n <span class=\"s-exclusion-details-record-details-type\">\n {{entityDescription}}\n </span>\n <span>\n {{getRecordDescription()}}\n </span>\n </div>\n\n <div class=\"s-exclusion-details-record-details-dateinfo\">\n <span>\n {{getStartDateLabel()}}: {{getInicialDate()}}\n </span>\n <span *ngIf=\"isFinished()\">\n {{getFinishDateLabel()}}: {{getFinishDate()}}\n </span>\n </div>\n </div>\n </p-panel>\n\n <p-panel>\n <p-header>\n {{getSummaryLabel()}}\n </p-header>\n\n <s-empty-state\n *ngIf=\"
|
|
472
|
+
template: "<s-sidebar [visible]=\"isVisible\" (visibleChange)=\"onVisibilityChanged($event)\" [header]=\"getSidebarTitle()\">\n <s-loading-state [loading]=\"isLoading\">\n <p-panel [showHeader]=\"false\" styleClass=\"s-exclusion-details-record-details-panel\">\n <div class=\"s-exclusion-details-record-details-container\">\n <div class=\"s-exclusion-details-record-icon-background\">\n <em class=\"far fa-file-alt s-exclusion-details-record-icon\"></em>\n </div>\n\n <div class=\"s-exclusion-details-record-details-recordinfo\">\n <span class=\"s-exclusion-details-record-details-type\">\n {{entityDescription}}\n </span>\n <span>\n {{getRecordDescription()}}\n </span>\n </div>\n\n <div class=\"s-exclusion-details-record-details-dateinfo\">\n <span>\n {{getStartDateLabel()}}: {{getInicialDate()}}\n </span>\n <span *ngIf=\"isFinished()\">\n {{getFinishDateLabel()}}: {{getFinishDate()}}\n </span>\n </div>\n </div>\n </p-panel>\n\n <p-panel>\n <p-header>\n {{getSummaryLabel()}}\n </p-header>\n\n <s-empty-state\n *ngIf=\"processGroupData && !processGroupData.length\"\n [title]=\"getEmptyStateTitle()\"\n [description]=\"getEmptyStateDescription()\">\n [showPrimaryAction]=\"false\"\n </s-empty-state>\n\n <p-table\n [value]=\"processGroupData\"\n [columns]=\"processGroupColumns\"\n dataKey=\"id\"\n [lazy]=\"false\"\n [scrollable]=\"false\"\n [paginator]=\"false\"\n *ngIf=\"processGroupData && processGroupData.length\"\n [expandedRowKeys]=\"expandedRows\">\n\n <ng-template pTemplate=\"header\" let-columns>\n <tr>\n <th id=\"expend-column\" style=\"width: 40px;\"></th>\n <th *ngFor=\"let col of columns\"\n [id]=\"col.field\"\n [ngStyle]=\"col.style\"\n [pSortableColumn]=\"col.field\">\n <div class=\"senior-header\">\n <span class=\"senior-header-title\">{{ col.header }}</span>\n <p-sortIcon [field]=\"col.field\" ></p-sortIcon>\n </div>\n </th>\n </tr>\n </ng-template>\n\n <ng-template pTemplate=\"body\" let-rowData let-columns=\"columns\" let-expanded=\"expanded\">\n <tr sNavigation [sRowToggler]=\"rowData\">\n <td style=\"width: 40px;\" tabindex=\"0\">\n <em class=\"fa fa-{{ expanded ? 'minus' : 'plus' }}\"></em>\n </td>\n <s-table-columns\n [columns]=\"columns\"\n [rowValue]=\"rowData\"\n [locale]=\"locale\">\n </s-table-columns>\n </tr>\n </ng-template>\n\n <ng-template pTemplate=\"rowexpansion\" let-rowData let-columns=\"columns\">\n <tr class=\"sds-expanded-row\">\n <td [attr.colspan]=\"columns.length + 1\">\n <p-table \n [value]=\"rowData.steps\"\n [columns]=\"processStepColumns\"\n dataKey=\"id\"\n [paginator]=\"false\"\n [responsive]=\"true\"\n [scrollable]=\"false\"\n [lazy]=\"false\">\n\n <ng-template pTemplate=\"header\" let-columns>\n <tr>\n <th *ngFor=\"let col of columns\"\n [id]=\"col.field\"\n [ngStyle]=\"col.style\"\n [pSortableColumn]=\"col.field\">\n <div class=\"senior-header\">\n <span class=\"senior-header-title\">{{ col.header }}</span>\n <p-sortIcon [field]=\"col.field\" ></p-sortIcon>\n </div>\n </th>\n </tr>\n </ng-template>\n \n <ng-template pTemplate=\"body\" let-rowData let-columns=\"columns\">\n <tr>\n <s-table-columns\n [columns]=\"columns\"\n [rowValue]=\"rowData\"\n [locale]=\"locale\">\n </s-table-columns>\n </tr>\n </ng-template>\n </p-table>\n </td>\n </tr>\n </ng-template>\n </p-table>\n </p-panel>\n </s-loading-state>\n\n <s-footer>\n <div class=\"ui-fluid\">\n <div class=\"ui-g\">\n <s-button [label]=\"getCloseButtonLabel()\" priority=\"link\" (onClick)=\"closeDetails()\"></s-button>\n </div>\n </div>\n </s-footer>\n</s-sidebar>\n",
|
|
454
473
|
encapsulation: ViewEncapsulation.None,
|
|
455
474
|
styles: [".s-exclusion-details-record-details-panel{margin-bottom:10px}.s-exclusion-details-record-details-container{display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-align:center;align-items:center}.s-exclusion-details-record-details-recordinfo{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;margin-left:10px;-ms-flex:1;flex:1}.s-exclusion-details-record-details-dateinfo{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;margin-left:10px;-ms-flex-align:end;align-items:flex-end;font-size:12px}.s-exclusion-details-record-details-type{color:#999}.s-exclusion-details-record-icon{font-size:22pt;color:#7e8d95}.s-exclusion-details-record-icon-background{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;padding:16px;background-color:#c1cad1;border-radius:50%;height:60px;width:60px}"]
|
|
456
475
|
})
|
|
@@ -581,7 +600,8 @@ var ExclusionsListComponent_1;
|
|
|
581
600
|
const HTTP_CODE_SERVER_ERROR_START = 500;
|
|
582
601
|
const HTTP_CODE_SERVER_ERROR_END = 600;
|
|
583
602
|
let ExclusionsListComponent = ExclusionsListComponent_1 = class ExclusionsListComponent {
|
|
584
|
-
constructor(route, translate, formBuilder, changeDetectorRef, logicalDeleteService, filterService, projectConfigs) {
|
|
603
|
+
constructor(router, route, translate, formBuilder, changeDetectorRef, logicalDeleteService, filterService, projectConfigs, cdr) {
|
|
604
|
+
this.router = router;
|
|
585
605
|
this.route = route;
|
|
586
606
|
this.translate = translate;
|
|
587
607
|
this.formBuilder = formBuilder;
|
|
@@ -589,6 +609,7 @@ let ExclusionsListComponent = ExclusionsListComponent_1 = class ExclusionsListCo
|
|
|
589
609
|
this.logicalDeleteService = logicalDeleteService;
|
|
590
610
|
this.filterService = filterService;
|
|
591
611
|
this.projectConfigs = projectConfigs;
|
|
612
|
+
this.cdr = cdr;
|
|
592
613
|
this.currentListParams = { page: 0, size: 10, sort: [], filterData: {} };
|
|
593
614
|
this.showLoader = false;
|
|
594
615
|
this.totalRecords = 0;
|
|
@@ -606,30 +627,32 @@ let ExclusionsListComponent = ExclusionsListComponent_1 = class ExclusionsListCo
|
|
|
606
627
|
.subscribe((data) => {
|
|
607
628
|
this.locale = data.localeConfig;
|
|
608
629
|
});
|
|
609
|
-
this.route.params
|
|
610
|
-
.pipe(takeUntil(this.ngUnsubscribe))
|
|
611
|
-
.subscribe((params) => {
|
|
612
|
-
this.entityName = params.entityName;
|
|
613
|
-
this.showBasedOnRoute();
|
|
614
|
-
});
|
|
615
630
|
this.route.queryParams
|
|
616
631
|
.pipe(takeUntil(this.ngUnsubscribe))
|
|
617
632
|
.subscribe((queryParams) => {
|
|
633
|
+
this.entityName = queryParams.entityName;
|
|
618
634
|
this.entityDescription = queryParams.entityDescription;
|
|
619
635
|
this.processId = queryParams.processId;
|
|
620
|
-
this.showBasedOnRoute();
|
|
621
636
|
});
|
|
622
637
|
}
|
|
623
|
-
|
|
638
|
+
ngAfterViewInit() {
|
|
624
639
|
if (this.entityName && this.entityDescription && this.processId) {
|
|
625
640
|
this.exclusionDetailsComponent.showDetails({
|
|
626
641
|
processId: this.processId,
|
|
627
642
|
entityDescription: this.entityDescription,
|
|
628
643
|
entityName: this.entityName
|
|
629
644
|
});
|
|
645
|
+
this.cdr.detectChanges();
|
|
630
646
|
}
|
|
631
647
|
}
|
|
632
648
|
ngOnDestroy() {
|
|
649
|
+
var _a;
|
|
650
|
+
const params = Object.assign({}, (_a = this.route.snapshot) === null || _a === void 0 ? void 0 : _a.queryParams);
|
|
651
|
+
if (params) {
|
|
652
|
+
delete params.entityName;
|
|
653
|
+
delete params.entityDescription;
|
|
654
|
+
this.router.navigate([], { queryParams: params });
|
|
655
|
+
}
|
|
633
656
|
this.ngUnsubscribe.next();
|
|
634
657
|
this.ngUnsubscribe.complete();
|
|
635
658
|
}
|
|
@@ -637,8 +660,8 @@ let ExclusionsListComponent = ExclusionsListComponent_1 = class ExclusionsListCo
|
|
|
637
660
|
return this.formBuilder.group({
|
|
638
661
|
description: [undefined, Validators.compose([])],
|
|
639
662
|
status: [undefined, Validators.compose([])],
|
|
640
|
-
startDate: [{ value:
|
|
641
|
-
endDate: [{ value:
|
|
663
|
+
startDate: [{ value: null, disabled: false }, Validators.compose([])],
|
|
664
|
+
endDate: [{ value: null, disabled: false }, Validators.compose([])]
|
|
642
665
|
});
|
|
643
666
|
}
|
|
644
667
|
getGridColumns() {
|
|
@@ -899,13 +922,15 @@ let ExclusionsListComponent = ExclusionsListComponent_1 = class ExclusionsListCo
|
|
|
899
922
|
};
|
|
900
923
|
ExclusionsListComponent.DATE_FORMAT = "YYYY-MM-DD";
|
|
901
924
|
ExclusionsListComponent.ctorParameters = () => [
|
|
925
|
+
{ type: Router },
|
|
902
926
|
{ type: ActivatedRoute },
|
|
903
927
|
{ type: TranslateService },
|
|
904
928
|
{ type: FormBuilder },
|
|
905
929
|
{ type: ChangeDetectorRef },
|
|
906
930
|
{ type: LogicalDeleteService },
|
|
907
931
|
{ type: FilterService },
|
|
908
|
-
{ type: LogicalDeleteConfigService }
|
|
932
|
+
{ type: LogicalDeleteConfigService },
|
|
933
|
+
{ type: ChangeDetectorRef }
|
|
909
934
|
];
|
|
910
935
|
__decorate([
|
|
911
936
|
ViewChild("exclusionsTable")
|
|
@@ -993,7 +1018,7 @@ const routes = [
|
|
|
993
1018
|
},
|
|
994
1019
|
children: [
|
|
995
1020
|
{
|
|
996
|
-
path: "
|
|
1021
|
+
path: "",
|
|
997
1022
|
component: ExclusionsListComponent
|
|
998
1023
|
}
|
|
999
1024
|
]
|