@smartbit4all/ng-client 3.0.32 → 3.0.33
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/esm2020/lib/view-context/smart-view-context-dialog.service.mjs +10 -10
- package/esm2020/lib/view-context/smart-view-context.service.mjs +8 -5
- package/fesm2015/smartbit4all-ng-client.mjs +16 -14
- package/fesm2015/smartbit4all-ng-client.mjs.map +1 -1
- package/fesm2020/smartbit4all-ng-client.mjs +16 -13
- package/fesm2020/smartbit4all-ng-client.mjs.map +1 -1
- package/lib/view-context/smart-view-context-dialog.service.d.ts +1 -3
- package/package.json +1 -1
- package/smartbit4all-ng-client-3.0.33.tgz +0 -0
- package/smartbit4all-ng-client-3.0.32.tgz +0 -0
|
@@ -2497,13 +2497,13 @@ class SmartViewContextDialogService {
|
|
|
2497
2497
|
this.router = router;
|
|
2498
2498
|
}
|
|
2499
2499
|
createDialog(smartDialog, component) {
|
|
2500
|
-
|
|
2501
|
-
|
|
2502
|
-
|
|
2500
|
+
let dialogData = smartDialog;
|
|
2501
|
+
let dialogRef = this.dialog.open(component, { data: dialogData });
|
|
2502
|
+
dialogRef.afterClosed().subscribe((result) => {
|
|
2503
2503
|
this.handleAfterClosed(result);
|
|
2504
|
-
this.closeDialog();
|
|
2504
|
+
this.closeDialog(dialogRef, dialogData);
|
|
2505
2505
|
});
|
|
2506
|
-
return
|
|
2506
|
+
return dialogRef;
|
|
2507
2507
|
}
|
|
2508
2508
|
createDialogRef(smartDialog, component) {
|
|
2509
2509
|
const dialogRef = this.dialog.open(component, { data: smartDialog });
|
|
@@ -2527,15 +2527,15 @@ class SmartViewContextDialogService {
|
|
|
2527
2527
|
openDialog() {
|
|
2528
2528
|
throw new Error('openDialog function is not implemented!');
|
|
2529
2529
|
}
|
|
2530
|
-
async closeDialog() {
|
|
2531
|
-
if (
|
|
2530
|
+
async closeDialog(dialogRef, dialogData) {
|
|
2531
|
+
if (dialogData?.outlets) {
|
|
2532
2532
|
await this.router.navigate([
|
|
2533
2533
|
{
|
|
2534
|
-
outlets:
|
|
2534
|
+
outlets: dialogData.outlets,
|
|
2535
2535
|
},
|
|
2536
2536
|
]);
|
|
2537
2537
|
}
|
|
2538
|
-
|
|
2538
|
+
dialogRef?.close();
|
|
2539
2539
|
}
|
|
2540
2540
|
}
|
|
2541
2541
|
SmartViewContextDialogService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartViewContextDialogService, deps: [{ token: i1$2.MatDialog }, { token: i2.Router }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
@@ -2746,10 +2746,13 @@ class SmartViewContextService {
|
|
|
2746
2746
|
this.performAction(view.uuid, { code: DefaultUiActionCode_CLOSE, params: {} });
|
|
2747
2747
|
});
|
|
2748
2748
|
}
|
|
2749
|
-
this.dialogRefs.
|
|
2750
|
-
|
|
2751
|
-
|
|
2752
|
-
|
|
2749
|
+
let refIsAlradyAdded = this.dialogRefs.some((ref) => ref.uuid === view.uuid);
|
|
2750
|
+
if (!refIsAlradyAdded) {
|
|
2751
|
+
this.dialogRefs.push({
|
|
2752
|
+
uuid: view.uuid,
|
|
2753
|
+
dialogRef,
|
|
2754
|
+
});
|
|
2755
|
+
}
|
|
2753
2756
|
}
|
|
2754
2757
|
else if (view.type === ViewType.Normal) {
|
|
2755
2758
|
if (viewHandler.route === undefined) {
|