@memberjunction/ng-explorer-core 4.3.1 → 5.0.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/dist/app-routing.module.js +4 -4
- package/dist/app-routing.module.js.map +1 -1
- package/dist/generic/Events.types.d.ts +174 -0
- package/dist/generic/Events.types.d.ts.map +1 -0
- package/dist/generic/Events.types.js +220 -0
- package/dist/generic/Events.types.js.map +1 -0
- package/dist/lib/app-view/application-view.component.d.ts +65 -0
- package/dist/lib/app-view/application-view.component.d.ts.map +1 -0
- package/dist/lib/app-view/application-view.component.js +611 -0
- package/dist/lib/app-view/application-view.component.js.map +1 -0
- package/dist/lib/auth-button/auth-button.component.d.ts +13 -0
- package/dist/lib/auth-button/auth-button.component.d.ts.map +1 -0
- package/dist/lib/auth-button/auth-button.component.js +36 -0
- package/dist/lib/auth-button/auth-button.component.js.map +1 -0
- package/dist/lib/base-browser-component/base-browser-component.d.ts +44 -0
- package/dist/lib/base-browser-component/base-browser-component.d.ts.map +1 -0
- package/dist/lib/base-browser-component/base-browser-component.js +195 -0
- package/dist/lib/base-browser-component/base-browser-component.js.map +1 -0
- package/dist/lib/chat-wrapper/chat-wrapper.component.d.ts +54 -0
- package/dist/lib/chat-wrapper/chat-wrapper.component.d.ts.map +1 -0
- package/dist/lib/chat-wrapper/chat-wrapper.component.js +257 -0
- package/dist/lib/chat-wrapper/chat-wrapper.component.js.map +1 -0
- package/dist/lib/dashboard-browser-component/dashboard-browser.component.d.ts +32 -0
- package/dist/lib/dashboard-browser-component/dashboard-browser.component.d.ts.map +1 -0
- package/dist/lib/dashboard-browser-component/dashboard-browser.component.js +244 -0
- package/dist/lib/dashboard-browser-component/dashboard-browser.component.js.map +1 -0
- package/dist/lib/dashboard-preferences-dialog/dashboard-preferences-dialog.component.d.ts +2 -2
- package/dist/lib/dashboard-preferences-dialog/dashboard-preferences-dialog.component.d.ts.map +1 -1
- package/dist/lib/dashboard-preferences-dialog/dashboard-preferences-dialog.component.js.map +1 -1
- package/dist/lib/data-browser-component/data-browser.component.d.ts +23 -0
- package/dist/lib/data-browser-component/data-browser.component.d.ts.map +1 -0
- package/dist/lib/data-browser-component/data-browser.component.js +267 -0
- package/dist/lib/data-browser-component/data-browser.component.js.map +1 -0
- package/dist/lib/expansion-panel-component/expansion-panel-component.d.ts +21 -0
- package/dist/lib/expansion-panel-component/expansion-panel-component.d.ts.map +1 -0
- package/dist/lib/expansion-panel-component/expansion-panel-component.js +158 -0
- package/dist/lib/expansion-panel-component/expansion-panel-component.js.map +1 -0
- package/dist/lib/favorites/favorites.component.d.ts +15 -0
- package/dist/lib/favorites/favorites.component.d.ts.map +1 -0
- package/dist/lib/favorites/favorites.component.js +135 -0
- package/dist/lib/favorites/favorites.component.js.map +1 -0
- package/dist/lib/files/files.component.d.ts +10 -0
- package/dist/lib/files/files.component.d.ts.map +1 -0
- package/dist/lib/files/files.component.js +41 -0
- package/dist/lib/files/files.component.js.map +1 -0
- package/dist/lib/generic-browse-list/generic-browse-list.component.d.ts +30 -0
- package/dist/lib/generic-browse-list/generic-browse-list.component.d.ts.map +1 -0
- package/dist/lib/generic-browse-list/generic-browse-list.component.js +171 -0
- package/dist/lib/generic-browse-list/generic-browse-list.component.js.map +1 -0
- package/dist/lib/generic-browser-list/generic-browser-list.component.d.ts +120 -0
- package/dist/lib/generic-browser-list/generic-browser-list.component.d.ts.map +1 -0
- package/dist/lib/generic-browser-list/generic-browser-list.component.js +1093 -0
- package/dist/lib/generic-browser-list/generic-browser-list.component.js.map +1 -0
- package/dist/lib/header/MSFT_UserImageService.d.ts +12 -0
- package/dist/lib/header/MSFT_UserImageService.d.ts.map +1 -0
- package/dist/lib/header/MSFT_UserImageService.js +25 -0
- package/dist/lib/header/MSFT_UserImageService.js.map +1 -0
- package/dist/lib/header/header.component.d.ts +69 -0
- package/dist/lib/header/header.component.d.ts.map +1 -0
- package/dist/lib/header/header.component.js +342 -0
- package/dist/lib/header/header.component.js.map +1 -0
- package/dist/lib/home-component/home.component.d.ts +22 -0
- package/dist/lib/home-component/home.component.d.ts.map +1 -0
- package/dist/lib/home-component/home.component.js +194 -0
- package/dist/lib/home-component/home.component.js.map +1 -0
- package/dist/lib/home-wrapper/home-wrapper.component.d.ts +7 -0
- package/dist/lib/home-wrapper/home-wrapper.component.d.ts.map +1 -0
- package/dist/lib/home-wrapper/home-wrapper.component.js +30 -0
- package/dist/lib/home-wrapper/home-wrapper.component.js.map +1 -0
- package/dist/lib/list-view/list-view.component.d.ts +45 -0
- package/dist/lib/list-view/list-view.component.d.ts.map +1 -0
- package/dist/lib/list-view/list-view.component.js +329 -0
- package/dist/lib/list-view/list-view.component.js.map +1 -0
- package/dist/lib/navigation/navigation.component.d.ts +142 -0
- package/dist/lib/navigation/navigation.component.d.ts.map +1 -0
- package/dist/lib/navigation/navigation.component.js +1212 -0
- package/dist/lib/navigation/navigation.component.js.map +1 -0
- package/dist/lib/query-browser-component/query-browser.component.d.ts +75 -0
- package/dist/lib/query-browser-component/query-browser.component.d.ts.map +1 -0
- package/dist/lib/query-browser-component/query-browser.component.js +908 -0
- package/dist/lib/query-browser-component/query-browser.component.js.map +1 -0
- package/dist/lib/report-browser-component/report-browser.component.d.ts +22 -0
- package/dist/lib/report-browser-component/report-browser.component.d.ts.map +1 -0
- package/dist/lib/report-browser-component/report-browser.component.js +80 -0
- package/dist/lib/report-browser-component/report-browser.component.js.map +1 -0
- package/dist/lib/resource-browser/resource-browser.component.d.ts +178 -0
- package/dist/lib/resource-browser/resource-browser.component.d.ts.map +1 -0
- package/dist/lib/resource-browser/resource-browser.component.js +1012 -0
- package/dist/lib/resource-browser/resource-browser.component.js.map +1 -0
- package/dist/lib/resource-wrappers/chat-conversations-resource.component.d.ts +17 -5
- package/dist/lib/resource-wrappers/chat-conversations-resource.component.d.ts.map +1 -1
- package/dist/lib/resource-wrappers/chat-conversations-resource.component.js +60 -5
- package/dist/lib/resource-wrappers/chat-conversations-resource.component.js.map +1 -1
- package/dist/lib/resource-wrappers/dashboard-resource.component.d.ts +3 -3
- package/dist/lib/resource-wrappers/dashboard-resource.component.d.ts.map +1 -1
- package/dist/lib/resource-wrappers/dashboard-resource.component.js.map +1 -1
- package/dist/lib/resource-wrappers/report-resource.component.d.ts +13 -0
- package/dist/lib/resource-wrappers/report-resource.component.d.ts.map +1 -0
- package/dist/lib/resource-wrappers/report-resource.component.js +49 -0
- package/dist/lib/resource-wrappers/report-resource.component.js.map +1 -0
- package/dist/lib/resource-wrappers/view-resource.component.js +1 -1
- package/dist/lib/resource-wrappers/view-resource.component.js.map +1 -1
- package/dist/lib/shared/custom-icon/custom-icon.component.d.ts +11 -0
- package/dist/lib/shared/custom-icon/custom-icon.component.d.ts.map +1 -0
- package/dist/lib/shared/custom-icon/custom-icon.component.js +44 -0
- package/dist/lib/shared/custom-icon/custom-icon.component.js.map +1 -0
- package/dist/lib/shell/components/header/app-nav.component.d.ts +0 -5
- package/dist/lib/shell/components/header/app-nav.component.d.ts.map +1 -1
- package/dist/lib/shell/components/header/app-nav.component.js +5 -17
- package/dist/lib/shell/components/header/app-nav.component.js.map +1 -1
- package/dist/lib/shell/components/tabs/tab-container.component.js.map +1 -1
- package/dist/lib/shell/shell.component.d.ts +1 -1
- package/dist/lib/shell/shell.component.d.ts.map +1 -1
- package/dist/lib/shell/shell.component.js +7 -7
- package/dist/lib/shell/shell.component.js.map +1 -1
- package/dist/lib/single-application/single-application.component.d.ts +24 -0
- package/dist/lib/single-application/single-application.component.d.ts.map +1 -0
- package/dist/lib/single-application/single-application.component.js +122 -0
- package/dist/lib/single-application/single-application.component.js.map +1 -0
- package/dist/lib/single-dashboard/Components/add-item/add-item.component.d.ts +2 -2
- package/dist/lib/single-dashboard/Components/add-item/add-item.component.d.ts.map +1 -1
- package/dist/lib/single-dashboard/Components/add-item/add-item.component.js +3 -3
- package/dist/lib/single-dashboard/Components/add-item/add-item.component.js.map +1 -1
- package/dist/lib/single-dashboard/Components/delete-item/delete-item.component.js +1 -1
- package/dist/lib/single-dashboard/Components/edit-dashboard/edit-dashboard.component.js +1 -1
- package/dist/lib/single-dashboard/single-dashboard.component.d.ts +2 -2
- package/dist/lib/single-dashboard/single-dashboard.component.d.ts.map +1 -1
- package/dist/lib/single-dashboard/single-dashboard.component.js +1 -1
- package/dist/lib/single-dashboard/single-dashboard.component.js.map +1 -1
- package/dist/lib/single-entity/single-entity.component.d.ts +34 -0
- package/dist/lib/single-entity/single-entity.component.d.ts.map +1 -0
- package/dist/lib/single-entity/single-entity.component.js +245 -0
- package/dist/lib/single-entity/single-entity.component.js.map +1 -0
- package/dist/lib/single-list-detail/single-list-detail.component.d.ts +2 -2
- package/dist/lib/single-list-detail/single-list-detail.component.d.ts.map +1 -1
- package/dist/lib/single-list-detail/single-list-detail.component.js +7 -7
- package/dist/lib/single-list-detail/single-list-detail.component.js.map +1 -1
- package/dist/lib/single-query/single-query.component.d.ts +2 -2
- package/dist/lib/single-query/single-query.component.d.ts.map +1 -1
- package/dist/lib/single-query/single-query.component.js +1 -1
- package/dist/lib/single-query/single-query.component.js.map +1 -1
- package/dist/lib/single-report/single-report.component.d.ts +17 -0
- package/dist/lib/single-report/single-report.component.d.ts.map +1 -0
- package/dist/lib/single-report/single-report.component.js +55 -0
- package/dist/lib/single-report/single-report.component.js.map +1 -0
- package/dist/lib/single-view/single-view.component.d.ts +43 -0
- package/dist/lib/single-view/single-view.component.d.ts.map +1 -0
- package/dist/lib/single-view/single-view.component.js +207 -0
- package/dist/lib/single-view/single-view.component.js.map +1 -0
- package/dist/lib/style-guide-test/style-guide-test.component.d.ts +70 -0
- package/dist/lib/style-guide-test/style-guide-test.component.d.ts.map +1 -0
- package/dist/lib/style-guide-test/style-guide-test.component.js +1024 -0
- package/dist/lib/style-guide-test/style-guide-test.component.js.map +1 -0
- package/dist/lib/tabbed-dashboard/tabbed-dashboard.component.d.ts +46 -0
- package/dist/lib/tabbed-dashboard/tabbed-dashboard.component.d.ts.map +1 -0
- package/dist/lib/tabbed-dashboard/tabbed-dashboard.component.js +547 -0
- package/dist/lib/tabbed-dashboard/tabbed-dashboard.component.js.map +1 -0
- package/dist/lib/user-menu/user-menu.types.d.ts +2 -2
- package/dist/lib/user-menu/user-menu.types.d.ts.map +1 -1
- package/dist/lib/user-notifications/user-notifications.component.d.ts +16 -16
- package/dist/lib/user-notifications/user-notifications.component.d.ts.map +1 -1
- package/dist/lib/user-notifications/user-notifications.component.js +6 -6
- package/dist/lib/user-notifications/user-notifications.component.js.map +1 -1
- package/dist/lib/user-profile/user-profile.component.js.map +1 -1
- package/dist/module.d.ts +13 -14
- package/dist/module.d.ts.map +1 -1
- package/dist/module.js +0 -4
- package/dist/module.js.map +1 -1
- package/package.json +34 -35
|
@@ -0,0 +1,611 @@
|
|
|
1
|
+
import { Component, Input, ViewChild } from '@angular/core';
|
|
2
|
+
import { Metadata, LogError, RunView } from '@memberjunction/core';
|
|
3
|
+
import { ItemType } from '../../generic/Item.types';
|
|
4
|
+
import { BaseBrowserComponent } from '../base-browser-component/base-browser-component';
|
|
5
|
+
import * as i0 from "@angular/core";
|
|
6
|
+
import * as i1 from "@angular/router";
|
|
7
|
+
import * as i2 from "@angular/common";
|
|
8
|
+
import * as i3 from "@memberjunction/ng-shared";
|
|
9
|
+
import * as i4 from "@progress/kendo-angular-buttons";
|
|
10
|
+
import * as i5 from "@memberjunction/ng-user-view-properties";
|
|
11
|
+
import * as i6 from "@memberjunction/ng-record-selector";
|
|
12
|
+
import * as i7 from "@memberjunction/ng-resource-permissions";
|
|
13
|
+
import * as i8 from "@memberjunction/ng-generic-dialog";
|
|
14
|
+
import * as i9 from "@memberjunction/ng-shared-generic";
|
|
15
|
+
import * as i10 from "../resource-browser/resource-browser.component";
|
|
16
|
+
const _c0 = ["entityRow"];
|
|
17
|
+
const _c1 = ["userViewDialog"];
|
|
18
|
+
const _c2 = ["availableResourcesComponent"];
|
|
19
|
+
function ApplicationViewComponent_div_0_div_13_Template(rf, ctx) { if (rf & 1) {
|
|
20
|
+
i0.ɵɵelementStart(0, "div", 24);
|
|
21
|
+
i0.ɵɵelement(1, "span", 25);
|
|
22
|
+
i0.ɵɵelementEnd();
|
|
23
|
+
} if (rf & 2) {
|
|
24
|
+
const ctx_r1 = i0.ɵɵnextContext(2);
|
|
25
|
+
i0.ɵɵadvance();
|
|
26
|
+
i0.ɵɵproperty("ngClass", ctx_r1.app.Icon);
|
|
27
|
+
} }
|
|
28
|
+
function ApplicationViewComponent_div_0_div_17_Template(rf, ctx) { if (rf & 1) {
|
|
29
|
+
i0.ɵɵelementStart(0, "div", 26);
|
|
30
|
+
i0.ɵɵelement(1, "i", 27);
|
|
31
|
+
i0.ɵɵtext(2);
|
|
32
|
+
i0.ɵɵelementEnd();
|
|
33
|
+
} if (rf & 2) {
|
|
34
|
+
const ctx_r1 = i0.ɵɵnextContext(2);
|
|
35
|
+
i0.ɵɵadvance(2);
|
|
36
|
+
i0.ɵɵtextInterpolate1(" ", ctx_r1.app.Description, " ");
|
|
37
|
+
} }
|
|
38
|
+
function ApplicationViewComponent_div_0_div_21_button_2_i_1_Template(rf, ctx) { if (rf & 1) {
|
|
39
|
+
i0.ɵɵelement(0, "i", 33);
|
|
40
|
+
} if (rf & 2) {
|
|
41
|
+
const item_r4 = i0.ɵɵnextContext().$implicit;
|
|
42
|
+
i0.ɵɵproperty("ngClass", item_r4.Icon);
|
|
43
|
+
} }
|
|
44
|
+
function ApplicationViewComponent_div_0_div_21_button_2_Template(rf, ctx) { if (rf & 1) {
|
|
45
|
+
const _r3 = i0.ɵɵgetCurrentView();
|
|
46
|
+
i0.ɵɵelementStart(0, "button", 31);
|
|
47
|
+
i0.ɵɵlistener("click", function ApplicationViewComponent_div_0_div_21_button_2_Template_button_click_0_listener() { const item_r4 = i0.ɵɵrestoreView(_r3).$implicit; const ctx_r1 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r1.onAppEntityButtonClicked(item_r4)); });
|
|
48
|
+
i0.ɵɵtemplate(1, ApplicationViewComponent_div_0_div_21_button_2_i_1_Template, 1, 1, "i", 32);
|
|
49
|
+
i0.ɵɵelementStart(2, "span");
|
|
50
|
+
i0.ɵɵtext(3);
|
|
51
|
+
i0.ɵɵelementEnd()();
|
|
52
|
+
} if (rf & 2) {
|
|
53
|
+
const item_r4 = ctx.$implicit;
|
|
54
|
+
const ctx_r1 = i0.ɵɵnextContext(3);
|
|
55
|
+
i0.ɵɵclassProp("mj-entity-btn-active", ctx_r1.IsEntitySelected(item_r4));
|
|
56
|
+
i0.ɵɵproperty("title", item_r4.Description || item_r4.Name);
|
|
57
|
+
i0.ɵɵadvance();
|
|
58
|
+
i0.ɵɵproperty("ngIf", item_r4.Icon && item_r4.Icon.length > 0);
|
|
59
|
+
i0.ɵɵadvance(2);
|
|
60
|
+
i0.ɵɵtextInterpolate(item_r4.Name);
|
|
61
|
+
} }
|
|
62
|
+
function ApplicationViewComponent_div_0_div_21_Template(rf, ctx) { if (rf & 1) {
|
|
63
|
+
i0.ɵɵelementStart(0, "div", 28)(1, "div", 29);
|
|
64
|
+
i0.ɵɵtemplate(2, ApplicationViewComponent_div_0_div_21_button_2_Template, 4, 5, "button", 30);
|
|
65
|
+
i0.ɵɵelementEnd()();
|
|
66
|
+
} if (rf & 2) {
|
|
67
|
+
const ctx_r1 = i0.ɵɵnextContext(2);
|
|
68
|
+
i0.ɵɵadvance(2);
|
|
69
|
+
i0.ɵɵproperty("ngForOf", ctx_r1.SelectedAppEntities);
|
|
70
|
+
} }
|
|
71
|
+
function ApplicationViewComponent_div_0_div_22_Template(rf, ctx) { if (rf & 1) {
|
|
72
|
+
const _r5 = i0.ɵɵgetCurrentView();
|
|
73
|
+
i0.ɵɵelementStart(0, "div", 34);
|
|
74
|
+
i0.ɵɵelement(1, "i", 35);
|
|
75
|
+
i0.ɵɵelementStart(2, "h3");
|
|
76
|
+
i0.ɵɵtext(3, "No Entities Selected");
|
|
77
|
+
i0.ɵɵelementEnd();
|
|
78
|
+
i0.ɵɵelementStart(4, "p");
|
|
79
|
+
i0.ɵɵtext(5, "Configure which entities you'd like to work with in this application");
|
|
80
|
+
i0.ɵɵelementEnd();
|
|
81
|
+
i0.ɵɵelementStart(6, "button", 36);
|
|
82
|
+
i0.ɵɵlistener("click", function ApplicationViewComponent_div_0_div_22_Template_button_click_6_listener() { i0.ɵɵrestoreView(_r5); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.ShowAppEntitySelectionDialog()); });
|
|
83
|
+
i0.ɵɵelementStart(7, "span", 37);
|
|
84
|
+
i0.ɵɵelement(8, "i", 15);
|
|
85
|
+
i0.ɵɵtext(9, " Configure Entities ");
|
|
86
|
+
i0.ɵɵelementEnd()()();
|
|
87
|
+
} }
|
|
88
|
+
function ApplicationViewComponent_div_0_div_23_Template(rf, ctx) { if (rf & 1) {
|
|
89
|
+
i0.ɵɵelementStart(0, "div", 38);
|
|
90
|
+
i0.ɵɵelement(1, "mj-loading", 39);
|
|
91
|
+
i0.ɵɵelementEnd();
|
|
92
|
+
} }
|
|
93
|
+
function ApplicationViewComponent_div_0_div_24_Template(rf, ctx) { if (rf & 1) {
|
|
94
|
+
const _r6 = i0.ɵɵgetCurrentView();
|
|
95
|
+
i0.ɵɵelementStart(0, "div", 40)(1, "mj-resource-browser", 41);
|
|
96
|
+
i0.ɵɵlistener("ResourceSelected", function ApplicationViewComponent_div_0_div_24_Template_mj_resource_browser_ResourceSelected_1_listener($event) { i0.ɵɵrestoreView(_r6); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.onItemClick($event)); })("NavigateToParentEvent", function ApplicationViewComponent_div_0_div_24_Template_mj_resource_browser_NavigateToParentEvent_1_listener() { i0.ɵɵrestoreView(_r6); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.navigateToParentFolder()); })("EditItemEvent", function ApplicationViewComponent_div_0_div_24_Template_mj_resource_browser_EditItemEvent_1_listener($event) { i0.ɵɵrestoreView(_r6); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.editView($event)); });
|
|
97
|
+
i0.ɵɵelementEnd()();
|
|
98
|
+
} if (rf & 2) {
|
|
99
|
+
const ctx_r1 = i0.ɵɵnextContext(2);
|
|
100
|
+
i0.ɵɵadvance();
|
|
101
|
+
i0.ɵɵproperty("EnableCategories", true)("CategoryEntityID", ctx_r1.currentlySelectedAppEntity == null ? null : ctx_r1.currentlySelectedAppEntity.ID)("CurrentCategoryID", ctx_r1.selectedFolderID)("Title", ctx_r1.currentlySelectedAppEntity == null ? null : ctx_r1.currentlySelectedAppEntity.Name)("ItemFilter", ctx_r1.ResourceItemFilter)("NewItemOptions", ctx_r1.NewItemOptions);
|
|
102
|
+
} }
|
|
103
|
+
function ApplicationViewComponent_div_0_mj_available_resources_29_Template(rf, ctx) { if (rf & 1) {
|
|
104
|
+
i0.ɵɵelement(0, "mj-available-resources", 42, 1);
|
|
105
|
+
} if (rf & 2) {
|
|
106
|
+
const ctx_r1 = i0.ɵɵnextContext(2);
|
|
107
|
+
i0.ɵɵproperty("User", ctx_r1.currentUser)("ResourceTypeID", ctx_r1.ViewResourceTypeID)("ResourceExtraFilter", ctx_r1.FilterOutCurrentUserViews);
|
|
108
|
+
} }
|
|
109
|
+
function ApplicationViewComponent_div_0_Template(rf, ctx) { if (rf & 1) {
|
|
110
|
+
const _r1 = i0.ɵɵgetCurrentView();
|
|
111
|
+
i0.ɵɵelementStart(0, "div", 3)(1, "nav", 4)(2, "span", 5);
|
|
112
|
+
i0.ɵɵlistener("click", function ApplicationViewComponent_div_0_Template_span_click_2_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.GoHome($event)); });
|
|
113
|
+
i0.ɵɵelement(3, "i", 6);
|
|
114
|
+
i0.ɵɵtext(4, " Home ");
|
|
115
|
+
i0.ɵɵelementEnd();
|
|
116
|
+
i0.ɵɵelement(5, "i", 7);
|
|
117
|
+
i0.ɵɵelementStart(6, "span", 5);
|
|
118
|
+
i0.ɵɵlistener("click", function ApplicationViewComponent_div_0_Template_span_click_6_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.GoToApps($event)); });
|
|
119
|
+
i0.ɵɵtext(7, "Applications");
|
|
120
|
+
i0.ɵɵelementEnd();
|
|
121
|
+
i0.ɵɵelement(8, "i", 7);
|
|
122
|
+
i0.ɵɵelementStart(9, "span", 8);
|
|
123
|
+
i0.ɵɵtext(10);
|
|
124
|
+
i0.ɵɵelementEnd()();
|
|
125
|
+
i0.ɵɵelementStart(11, "div", 9)(12, "div", 10);
|
|
126
|
+
i0.ɵɵtemplate(13, ApplicationViewComponent_div_0_div_13_Template, 2, 1, "div", 11);
|
|
127
|
+
i0.ɵɵelementStart(14, "div")(15, "h1");
|
|
128
|
+
i0.ɵɵtext(16);
|
|
129
|
+
i0.ɵɵelementEnd();
|
|
130
|
+
i0.ɵɵtemplate(17, ApplicationViewComponent_div_0_div_17_Template, 3, 1, "div", 12);
|
|
131
|
+
i0.ɵɵelementEnd()();
|
|
132
|
+
i0.ɵɵelementStart(18, "div", 13)(19, "button", 14);
|
|
133
|
+
i0.ɵɵlistener("click", function ApplicationViewComponent_div_0_Template_button_click_19_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.ShowAppEntitySelectionDialog()); });
|
|
134
|
+
i0.ɵɵelement(20, "i", 15);
|
|
135
|
+
i0.ɵɵelementEnd()()();
|
|
136
|
+
i0.ɵɵtemplate(21, ApplicationViewComponent_div_0_div_21_Template, 3, 1, "div", 16)(22, ApplicationViewComponent_div_0_div_22_Template, 10, 0, "div", 17)(23, ApplicationViewComponent_div_0_div_23_Template, 2, 0, "div", 18)(24, ApplicationViewComponent_div_0_div_24_Template, 2, 6, "div", 19);
|
|
137
|
+
i0.ɵɵelementStart(25, "mj-record-selector-dialog", 20);
|
|
138
|
+
i0.ɵɵlistener("DialogClosed", function ApplicationViewComponent_div_0_Template_mj_record_selector_dialog_DialogClosed_25_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnAppEntitySelectionDialogClosed($event)); });
|
|
139
|
+
i0.ɵɵelementEnd();
|
|
140
|
+
i0.ɵɵelementStart(26, "mj-user-view-properties-dialog", 21, 0);
|
|
141
|
+
i0.ɵɵlistener("dialogClosed", function ApplicationViewComponent_div_0_Template_mj_user_view_properties_dialog_dialogClosed_26_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.OnViewPropertiesDialogClose($event)); });
|
|
142
|
+
i0.ɵɵelementEnd();
|
|
143
|
+
i0.ɵɵelementStart(28, "mj-generic-dialog", 22);
|
|
144
|
+
i0.ɵɵlistener("DialogClosed", function ApplicationViewComponent_div_0_Template_mj_generic_dialog_DialogClosed_28_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.HandleLinkToSharedView($event)); });
|
|
145
|
+
i0.ɵɵtemplate(29, ApplicationViewComponent_div_0_mj_available_resources_29_Template, 2, 3, "mj-available-resources", 23);
|
|
146
|
+
i0.ɵɵelementEnd()();
|
|
147
|
+
} if (rf & 2) {
|
|
148
|
+
const ctx_r1 = i0.ɵɵnextContext();
|
|
149
|
+
i0.ɵɵadvance(10);
|
|
150
|
+
i0.ɵɵtextInterpolate(ctx_r1.app.Name);
|
|
151
|
+
i0.ɵɵadvance(3);
|
|
152
|
+
i0.ɵɵproperty("ngIf", ctx_r1.app.Icon && ctx_r1.app.Icon.length > 0);
|
|
153
|
+
i0.ɵɵadvance(3);
|
|
154
|
+
i0.ɵɵtextInterpolate(ctx_r1.app.Name);
|
|
155
|
+
i0.ɵɵadvance();
|
|
156
|
+
i0.ɵɵproperty("ngIf", ctx_r1.app.Description);
|
|
157
|
+
i0.ɵɵadvance(2);
|
|
158
|
+
i0.ɵɵproperty("title", "Configure Entities");
|
|
159
|
+
i0.ɵɵadvance(2);
|
|
160
|
+
i0.ɵɵproperty("ngIf", ctx_r1.SelectedAppEntities.length > 0);
|
|
161
|
+
i0.ɵɵadvance();
|
|
162
|
+
i0.ɵɵproperty("ngIf", ctx_r1.SelectedAppEntities.length === 0 && !ctx_r1.showLoader);
|
|
163
|
+
i0.ɵɵadvance();
|
|
164
|
+
i0.ɵɵproperty("ngIf", ctx_r1.showLoader);
|
|
165
|
+
i0.ɵɵadvance();
|
|
166
|
+
i0.ɵɵproperty("ngIf", ctx_r1.SelectedAppEntities.length > 0 && !ctx_r1.showLoader);
|
|
167
|
+
i0.ɵɵadvance();
|
|
168
|
+
i0.ɵɵproperty("AvailableRecords", ctx_r1.AllAppEntities)("SelectedRecords", ctx_r1.SelectedAppEntities)("UnselectedRecords", ctx_r1.UnselectedAppEntities)("DialogVisible", ctx_r1.AppEntitySelectionDialogVisible);
|
|
169
|
+
i0.ɵɵadvance();
|
|
170
|
+
i0.ɵɵproperty("ShowPropertiesButton", false);
|
|
171
|
+
i0.ɵɵadvance(2);
|
|
172
|
+
i0.ɵɵproperty("DialogVisible", ctx_r1.LinkToSharedViewDialogVisible);
|
|
173
|
+
i0.ɵɵadvance();
|
|
174
|
+
i0.ɵɵproperty("ngIf", ctx_r1.LinkToSharedViewDialogVisible);
|
|
175
|
+
} }
|
|
176
|
+
export class ApplicationViewComponent extends BaseBrowserComponent {
|
|
177
|
+
router;
|
|
178
|
+
route;
|
|
179
|
+
location;
|
|
180
|
+
sharedService;
|
|
181
|
+
cdr;
|
|
182
|
+
entityRowRef;
|
|
183
|
+
viewPropertiesDialog;
|
|
184
|
+
availableResourcesComponent;
|
|
185
|
+
categoryEntityID;
|
|
186
|
+
currentlySelectedAppEntity;
|
|
187
|
+
ResourceItemFilter = "";
|
|
188
|
+
AppEntitySelectionDialogVisible = false;
|
|
189
|
+
AllAppEntities = [];
|
|
190
|
+
SelectedAppEntities = [];
|
|
191
|
+
UnselectedAppEntities = [];
|
|
192
|
+
app;
|
|
193
|
+
userApp;
|
|
194
|
+
currentUser;
|
|
195
|
+
FilterOutCurrentUserViews;
|
|
196
|
+
NewItemOptions = [
|
|
197
|
+
{
|
|
198
|
+
Text: 'New View',
|
|
199
|
+
Description: 'Create a new User View',
|
|
200
|
+
Icon: 'folder',
|
|
201
|
+
Action: () => {
|
|
202
|
+
this.createNewView();
|
|
203
|
+
}
|
|
204
|
+
},
|
|
205
|
+
{
|
|
206
|
+
Text: 'New Record',
|
|
207
|
+
Description: `Create a new record for the currently selected entity`,
|
|
208
|
+
Icon: 'plus',
|
|
209
|
+
Action: () => {
|
|
210
|
+
this.createNewRecord();
|
|
211
|
+
}
|
|
212
|
+
}
|
|
213
|
+
];
|
|
214
|
+
ViewResourceTypeID;
|
|
215
|
+
constructor(router, route, location, sharedService, cdr) {
|
|
216
|
+
super();
|
|
217
|
+
this.router = router;
|
|
218
|
+
this.route = route;
|
|
219
|
+
this.location = location;
|
|
220
|
+
this.sharedService = sharedService;
|
|
221
|
+
this.cdr = cdr;
|
|
222
|
+
this.categoryEntityName = "User View Categories";
|
|
223
|
+
this.itemEntityName = "User Views";
|
|
224
|
+
}
|
|
225
|
+
async ngOnInit() {
|
|
226
|
+
const md = new Metadata();
|
|
227
|
+
this.currentUser = md.CurrentUser;
|
|
228
|
+
this.ViewResourceTypeID = this.sharedService.ResourceTypeByName('User Views')?.ID || '';
|
|
229
|
+
this.route.paramMap.subscribe(async (params) => {
|
|
230
|
+
const appName = params.get('appName');
|
|
231
|
+
const entityName = params.get('entityName');
|
|
232
|
+
const folderID = params.get('folderID');
|
|
233
|
+
this.showLoader = true;
|
|
234
|
+
if (folderID) {
|
|
235
|
+
this.selectedFolderID = folderID;
|
|
236
|
+
}
|
|
237
|
+
if (appName && appName !== this.app?.Name) {
|
|
238
|
+
const md = new Metadata();
|
|
239
|
+
const rv = new RunView();
|
|
240
|
+
const appNameToLower = appName.toLowerCase();
|
|
241
|
+
this.app = md.Applications.find(a => a.Name.toLowerCase() === appNameToLower);
|
|
242
|
+
// if we get here and we have a blank app, problem
|
|
243
|
+
if (!this.app) {
|
|
244
|
+
throw new Error(`Application ${appName} not found`);
|
|
245
|
+
}
|
|
246
|
+
// next up we need to find the UserApplication record based on the app and the current user
|
|
247
|
+
const userAppResult = await rv.RunView({
|
|
248
|
+
EntityName: "User Applications",
|
|
249
|
+
ExtraFilter: `UserID='${md.CurrentUser.ID}' AND ApplicationID='${this.app.ID}'`,
|
|
250
|
+
ResultType: 'entity_object'
|
|
251
|
+
});
|
|
252
|
+
if (!userAppResult || userAppResult.Success === false || userAppResult.Results.length === 0)
|
|
253
|
+
throw new Error('User Application Record for current user and selected application not found');
|
|
254
|
+
this.userApp = userAppResult.Results[0];
|
|
255
|
+
const matches = this.app.ApplicationEntities
|
|
256
|
+
.map(ae => md.Entities.find(e => e.ID === ae.EntityID))
|
|
257
|
+
.filter(e => e) // filter out null entries
|
|
258
|
+
.sort((a, b) => {
|
|
259
|
+
if (!a || !b) {
|
|
260
|
+
return 0;
|
|
261
|
+
}
|
|
262
|
+
return a.Name.localeCompare(b.Name);
|
|
263
|
+
}); // sort by name
|
|
264
|
+
// store the entire list of POSSIBLE app entities in this list
|
|
265
|
+
this.AllAppEntities = matches; // we filter out null above so this cast is safe;
|
|
266
|
+
const userAppEntities = await rv.RunView({
|
|
267
|
+
EntityName: 'User Application Entities',
|
|
268
|
+
ResultType: 'entity_object',
|
|
269
|
+
ExtraFilter: `UserApplicationID = '${this.userApp.ID}'`,
|
|
270
|
+
OrderBy: 'Sequence, Entity'
|
|
271
|
+
});
|
|
272
|
+
if (userAppEntities && userAppEntities.Success) {
|
|
273
|
+
this.SelectedAppEntities = userAppEntities.Results.map(uae => this.AllAppEntities.find(ae => uae.EntityID === ae.ID)).filter(val => val); // now we have our selected app entities and they're sorted properly
|
|
274
|
+
this.UnselectedAppEntities = this.AllAppEntities.filter(e => !this.SelectedAppEntities.some(sa => sa.ID === e.ID));
|
|
275
|
+
// special case - if we have NO user app entities and the application has entities that are marked as DefaultForNewUser=1 we will add them now
|
|
276
|
+
const defaultEntities = this.app.ApplicationEntities.filter(a => a.DefaultForNewUser);
|
|
277
|
+
if (this.SelectedAppEntities.length === 0 && defaultEntities.length > 0) {
|
|
278
|
+
// there are some entities that should default for a new user, so let's add them to the selected entities and remove from the Unselected
|
|
279
|
+
// app entities and then call the Save method that we use when the user dialog ends
|
|
280
|
+
this.SelectedAppEntities = defaultEntities.map(de => this.AllAppEntities.find(aae => de.EntityID === aae.ID)).filter(val => val);
|
|
281
|
+
// now we have the default entities in place for the app, remove them from the Unselected array
|
|
282
|
+
this.UnselectedAppEntities = this.UnselectedAppEntities.filter(e => !this.SelectedAppEntities.some(se => se.ID === e.ID));
|
|
283
|
+
// now save
|
|
284
|
+
await this.OnAppEntitySelectionDialogClosed(true);
|
|
285
|
+
}
|
|
286
|
+
}
|
|
287
|
+
}
|
|
288
|
+
// now down here we have either loaded the app above, or already had the current app loaded. Now we move on to set the current entity and load er up
|
|
289
|
+
if (this.app && this.SelectedAppEntities.length) {
|
|
290
|
+
if (entityName) {
|
|
291
|
+
// sometimes the entity name contains a ? and values after it, look for that and only grab stuff to left of ?
|
|
292
|
+
const entityNameParts = entityName.split('?');
|
|
293
|
+
const entityNameToLower = entityNameParts[0].toLowerCase().trim();
|
|
294
|
+
const selectedAppEntity = this.SelectedAppEntities.find(e => e.Name.toLocaleLowerCase() === entityNameToLower);
|
|
295
|
+
if (selectedAppEntity) {
|
|
296
|
+
await this.loadEntityAndFolders(selectedAppEntity);
|
|
297
|
+
}
|
|
298
|
+
else
|
|
299
|
+
await this.loadEntityAndFolders(this.SelectedAppEntities[0]);
|
|
300
|
+
}
|
|
301
|
+
else {
|
|
302
|
+
await this.loadEntityAndFolders(this.SelectedAppEntities[0]);
|
|
303
|
+
}
|
|
304
|
+
}
|
|
305
|
+
this.showLoader = false;
|
|
306
|
+
});
|
|
307
|
+
}
|
|
308
|
+
IsEntitySelected(entity) {
|
|
309
|
+
if (this.currentlySelectedAppEntity?.ID === entity.ID)
|
|
310
|
+
return true;
|
|
311
|
+
else
|
|
312
|
+
return false;
|
|
313
|
+
}
|
|
314
|
+
ShowAppEntitySelectionDialog() {
|
|
315
|
+
this.AppEntitySelectionDialogVisible = true;
|
|
316
|
+
}
|
|
317
|
+
async OnAppEntitySelectionDialogClosed(save) {
|
|
318
|
+
this.AppEntitySelectionDialogVisible = false;
|
|
319
|
+
// now we need to process the changes if the user hit save
|
|
320
|
+
if (save) {
|
|
321
|
+
// we need to basically make sure the User Application Entities entity for this user maps to the set of selected Entities within the application, in the order selected as well
|
|
322
|
+
const rv = new RunView();
|
|
323
|
+
const md = new Metadata();
|
|
324
|
+
const userAppEntities = await rv.RunView({
|
|
325
|
+
EntityName: 'User Application Entities',
|
|
326
|
+
ResultType: 'entity_object',
|
|
327
|
+
ExtraFilter: `UserApplicationID = '${this.userApp.ID}'`,
|
|
328
|
+
OrderBy: 'Sequence'
|
|
329
|
+
});
|
|
330
|
+
// userAppEntities.results is the current DB state, we need to now compare it to the SelectedAppEntities array
|
|
331
|
+
// and if there are changes either update sequence values or delete records that aren't selected anymore.
|
|
332
|
+
const existingUserAppEntities = userAppEntities.Results;
|
|
333
|
+
const userAppEntitiesToSave = [];
|
|
334
|
+
const userAppEntitiesToDelete = [];
|
|
335
|
+
// first we need to update the sequence values for the selected applications
|
|
336
|
+
for (let index = 0; index < this.SelectedAppEntities.length; index++) {
|
|
337
|
+
const e = this.SelectedAppEntities[index];
|
|
338
|
+
const existing = existingUserAppEntities.find(uae => uae.EntityID === e.ID);
|
|
339
|
+
if (existing) {
|
|
340
|
+
if (existing.Sequence !== index) {
|
|
341
|
+
existing.Sequence = index;
|
|
342
|
+
userAppEntitiesToSave.push(existing);
|
|
343
|
+
}
|
|
344
|
+
}
|
|
345
|
+
else {
|
|
346
|
+
// this is a new app entity that the user has selected
|
|
347
|
+
const newApp = await md.GetEntityObject("User Application Entities");
|
|
348
|
+
newApp.UserApplicationID = this.userApp.ID;
|
|
349
|
+
newApp.Sequence = index;
|
|
350
|
+
newApp.EntityID = e.ID;
|
|
351
|
+
userAppEntitiesToSave.push(newApp);
|
|
352
|
+
}
|
|
353
|
+
}
|
|
354
|
+
// now we need to add the records that aren't selected anymore to a delete array
|
|
355
|
+
for (let index = 0; index < existingUserAppEntities.length; index++) {
|
|
356
|
+
const existing = existingUserAppEntities[index];
|
|
357
|
+
if (!this.SelectedAppEntities.some(sa => sa.ID === existing.EntityID)) {
|
|
358
|
+
userAppEntitiesToDelete.push(existing);
|
|
359
|
+
}
|
|
360
|
+
}
|
|
361
|
+
// finally, we need to submit a single transaction so we have one server round trip to commit all this good stuff
|
|
362
|
+
const tg = await md.CreateTransactionGroup();
|
|
363
|
+
for (const toSave of userAppEntitiesToSave) {
|
|
364
|
+
toSave.TransactionGroup = tg;
|
|
365
|
+
await toSave.Save();
|
|
366
|
+
}
|
|
367
|
+
for (const d of userAppEntitiesToDelete) {
|
|
368
|
+
d.TransactionGroup = tg;
|
|
369
|
+
await d.Delete();
|
|
370
|
+
}
|
|
371
|
+
if (!await tg.Submit()) {
|
|
372
|
+
// the data doesn't need to be updated when we are succesful because we're all bound to the same data which is cool
|
|
373
|
+
// but in this case we need to notify the user it failed
|
|
374
|
+
this.sharedService.CreateSimpleNotification('There was an error saving your entity selections. Please try again later or notify a system administrator.', "error", 3500);
|
|
375
|
+
}
|
|
376
|
+
}
|
|
377
|
+
}
|
|
378
|
+
onAppEntityButtonClicked(e) {
|
|
379
|
+
if (e.ID === this.currentlySelectedAppEntity?.ID)
|
|
380
|
+
return;
|
|
381
|
+
this.selectedFolderID = null;
|
|
382
|
+
this.currentlySelectedAppEntity = e;
|
|
383
|
+
this.navigateToCurrentPage();
|
|
384
|
+
}
|
|
385
|
+
async loadEntityAndFolders(entity) {
|
|
386
|
+
if (!entity) {
|
|
387
|
+
this.currentlySelectedAppEntity = undefined; // make sure our current selection is wiped out here
|
|
388
|
+
return;
|
|
389
|
+
}
|
|
390
|
+
this.showLoader = true;
|
|
391
|
+
this.currentlySelectedAppEntity = entity;
|
|
392
|
+
this.categoryEntityID = entity.ID;
|
|
393
|
+
this.ResourceItemFilter = `EntityID='${entity.ID}'`;
|
|
394
|
+
this.FilterOutCurrentUserViews = `UserID <> '${this.currentUser.ID}' AND EntityID = '${entity.ID}'`;
|
|
395
|
+
if (this.selectedFolderID) {
|
|
396
|
+
let viewResult = await super.RunView(this.categoryEntityName, `ID='${this.selectedFolderID}'`);
|
|
397
|
+
if (viewResult.length > 0) {
|
|
398
|
+
this.pageTitle = viewResult[0].Name;
|
|
399
|
+
}
|
|
400
|
+
}
|
|
401
|
+
else {
|
|
402
|
+
this.pageTitle = this.currentlySelectedAppEntity.Name;
|
|
403
|
+
}
|
|
404
|
+
const md = new Metadata();
|
|
405
|
+
const parentFolderIDFilter = this.selectedFolderID ? `ParentID='${this.selectedFolderID}'` : 'ParentID IS NULL';
|
|
406
|
+
const categoryFilter = `UserID='${md.CurrentUser.ID}' AND EntityID='${this.currentlySelectedAppEntity.ID}' AND ` + parentFolderIDFilter;
|
|
407
|
+
const categoryIDFilter = this.selectedFolderID ? `CategoryID='${this.selectedFolderID}'` : 'CategoryID IS NULL';
|
|
408
|
+
const userViewFilter = `UserID = '${md.CurrentUser.ID}' AND EntityID='${this.currentlySelectedAppEntity.ID}' AND ` + categoryIDFilter;
|
|
409
|
+
await super.LoadData({
|
|
410
|
+
sortItemsAfterLoad: true,
|
|
411
|
+
categoryItemFilter: categoryFilter,
|
|
412
|
+
entityItemFilter: userViewFilter,
|
|
413
|
+
linkItemFilter: `EntityID='${this.currentlySelectedAppEntity.ID}'`,
|
|
414
|
+
showLoader: true
|
|
415
|
+
});
|
|
416
|
+
this.showLoader = false;
|
|
417
|
+
this.cdr.detectChanges(); // tell Angular to detect changes as we just change the current entity so that affects some UI elements visualy like which button shows as selected
|
|
418
|
+
}
|
|
419
|
+
onItemClick(item) {
|
|
420
|
+
if (!item) {
|
|
421
|
+
return;
|
|
422
|
+
}
|
|
423
|
+
if (item.Type === ItemType.Resource) {
|
|
424
|
+
this.router.navigate(['resource', 'view', item.Data.ID], { queryParams: { viewMode: this.viewMode } });
|
|
425
|
+
}
|
|
426
|
+
else if (item.Type === ItemType.Folder) {
|
|
427
|
+
this.selectedFolderID = item.Data.ID;
|
|
428
|
+
this.navigateToCurrentPage();
|
|
429
|
+
}
|
|
430
|
+
}
|
|
431
|
+
entityItemClick(info) {
|
|
432
|
+
if (info) {
|
|
433
|
+
const paramsArray = ['entity', info.Entity];
|
|
434
|
+
this.router.navigate(paramsArray, { queryParams: { viewMode: this.viewMode } });
|
|
435
|
+
}
|
|
436
|
+
}
|
|
437
|
+
favoriteItemClick(fav) {
|
|
438
|
+
if (fav) {
|
|
439
|
+
if (fav.Entity === 'User Views') {
|
|
440
|
+
// opening a view, different route
|
|
441
|
+
this.router.navigate(['resource', 'view', fav.RecordID], { queryParams: { viewMode: this.viewMode } });
|
|
442
|
+
}
|
|
443
|
+
else {
|
|
444
|
+
this.router.navigate(['resource', 'record', fav.RecordID], { queryParams: { Entity: fav.Entity, viewMode: this.viewMode } });
|
|
445
|
+
}
|
|
446
|
+
}
|
|
447
|
+
}
|
|
448
|
+
navigateToCurrentPage() {
|
|
449
|
+
if (!this.app) {
|
|
450
|
+
throw new Error('Application Not Loaded');
|
|
451
|
+
}
|
|
452
|
+
//we're capable of loading the data associated with the selected ApplicationEntityInfo object
|
|
453
|
+
//without a page refresh, but we'd need additonal logic to handle routing, e.g. back
|
|
454
|
+
//button in the browser taking you to the last selected entity.
|
|
455
|
+
//so its easier if we instead navigate to this page with an updated url and leverage angular's router
|
|
456
|
+
let folderID = this.selectedFolderID;
|
|
457
|
+
let url = ["/app", this.app.Name];
|
|
458
|
+
let appEntityName = this.currentlySelectedAppEntity?.Name || null;
|
|
459
|
+
if (appEntityName) {
|
|
460
|
+
url.push(`${appEntityName}`);
|
|
461
|
+
if (folderID) {
|
|
462
|
+
url.push(`${folderID}`);
|
|
463
|
+
}
|
|
464
|
+
}
|
|
465
|
+
this.router.navigate(url, { queryParams: { viewMode: this.viewMode } });
|
|
466
|
+
}
|
|
467
|
+
onViewModeChange(viewMode) {
|
|
468
|
+
this.viewMode = viewMode;
|
|
469
|
+
}
|
|
470
|
+
LinkToSharedViewDialogVisible = false;
|
|
471
|
+
createItemClickedEvent(event) {
|
|
472
|
+
switch (event.Text.trim().toLowerCase()) {
|
|
473
|
+
case 'link to shared view':
|
|
474
|
+
this.LinkToSharedViewDialogVisible = true;
|
|
475
|
+
break;
|
|
476
|
+
default:
|
|
477
|
+
LogError('Unknown dropdown option clicked');
|
|
478
|
+
break;
|
|
479
|
+
}
|
|
480
|
+
}
|
|
481
|
+
async HandleLinkToSharedView(okClicked) {
|
|
482
|
+
this.LinkToSharedViewDialogVisible = false;
|
|
483
|
+
if (okClicked) {
|
|
484
|
+
const resources = this.availableResourcesComponent.SelectedResources;
|
|
485
|
+
const md = new Metadata();
|
|
486
|
+
let success = true;
|
|
487
|
+
for (const r of resources) {
|
|
488
|
+
const newResourceLink = await md.GetEntityObject('Resource Links');
|
|
489
|
+
newResourceLink.ResourceRecordID = r.ResourceRecordID;
|
|
490
|
+
newResourceLink.ResourceTypeID = r.ResourceTypeID;
|
|
491
|
+
newResourceLink.UserID = this.currentUser.ID;
|
|
492
|
+
newResourceLink.FolderID = this.selectedFolderID;
|
|
493
|
+
if (!await newResourceLink.Save()) {
|
|
494
|
+
LogError('Error saving new resource link: ' + newResourceLink.LatestResult.Message);
|
|
495
|
+
success = false;
|
|
496
|
+
}
|
|
497
|
+
else {
|
|
498
|
+
await this.loadEntityAndFolders(this.currentlySelectedAppEntity); // refresh the view
|
|
499
|
+
}
|
|
500
|
+
}
|
|
501
|
+
if (!success) {
|
|
502
|
+
this.sharedService.CreateSimpleNotification('There was an error linking to the shared view(s). Please try again later or notify a system administrator.', 'error', 3500);
|
|
503
|
+
}
|
|
504
|
+
}
|
|
505
|
+
}
|
|
506
|
+
createNewView() {
|
|
507
|
+
if (this.viewPropertiesDialog && this.currentlySelectedAppEntity) {
|
|
508
|
+
this.viewPropertiesDialog.CategoryID = this.selectedFolderID; // pass along a folder if we have one, if null, that's fine it saves to "root" which is the null CategoryID
|
|
509
|
+
this.viewPropertiesDialog.CreateView(this.currentlySelectedAppEntity.Name);
|
|
510
|
+
}
|
|
511
|
+
else {
|
|
512
|
+
LogError("View Properties Dialog not found");
|
|
513
|
+
}
|
|
514
|
+
}
|
|
515
|
+
async editView(event) {
|
|
516
|
+
event.Cancel = true;
|
|
517
|
+
if (this.viewPropertiesDialog) {
|
|
518
|
+
let data = event.Item.Data;
|
|
519
|
+
this.viewPropertiesDialog.Open(data.ID);
|
|
520
|
+
}
|
|
521
|
+
else {
|
|
522
|
+
LogError("View Properties Dialog not found");
|
|
523
|
+
}
|
|
524
|
+
}
|
|
525
|
+
async OnViewPropertiesDialogClose(args) {
|
|
526
|
+
//user view properties dialog handles navigating to the newly created views
|
|
527
|
+
//so we only need to worry about saves to existing views
|
|
528
|
+
if (args && args.Saved && this.currentlySelectedAppEntity) {
|
|
529
|
+
args.Cancel = true;
|
|
530
|
+
await this.loadEntityAndFolders(this.currentlySelectedAppEntity);
|
|
531
|
+
}
|
|
532
|
+
}
|
|
533
|
+
async navigateToParentFolder() {
|
|
534
|
+
if (this.selectedFolderID) {
|
|
535
|
+
const rv = new RunView();
|
|
536
|
+
const parentResult = await rv.RunView({
|
|
537
|
+
EntityName: "User View Categories",
|
|
538
|
+
ExtraFilter: `ID='${this.selectedFolderID}'`,
|
|
539
|
+
});
|
|
540
|
+
if (parentResult && parentResult.Success && parentResult.Results.length > 0) {
|
|
541
|
+
this.selectedFolderID = parentResult.Results[0].ParentID;
|
|
542
|
+
this.navigateToCurrentPage();
|
|
543
|
+
}
|
|
544
|
+
}
|
|
545
|
+
}
|
|
546
|
+
async GoToApps(event) {
|
|
547
|
+
event.preventDefault();
|
|
548
|
+
this.router.navigate(['data']);
|
|
549
|
+
}
|
|
550
|
+
async GoHome(event) {
|
|
551
|
+
event.preventDefault();
|
|
552
|
+
// tell the router to go to /home
|
|
553
|
+
this.router.navigate(['home']);
|
|
554
|
+
}
|
|
555
|
+
createNewRecord() {
|
|
556
|
+
if (!this.currentlySelectedAppEntity) {
|
|
557
|
+
LogError("Unable to create new record: No Entity selected");
|
|
558
|
+
return;
|
|
559
|
+
}
|
|
560
|
+
const md = new Metadata();
|
|
561
|
+
const entityInfo = md.EntityByName(this.currentlySelectedAppEntity.Name);
|
|
562
|
+
if (!entityInfo.AllowCreateAPI) {
|
|
563
|
+
LogError(`Unable to create new record: ${entityInfo.Name} does not allow creation`);
|
|
564
|
+
return;
|
|
565
|
+
}
|
|
566
|
+
const permissions = entityInfo.GetUserPermisions(md.CurrentUser);
|
|
567
|
+
if (!permissions.CanCreate) {
|
|
568
|
+
LogError(`Unable to create new record: Current User ${md.CurrentUser.Name} does not have permission to create records for ${entityInfo.Name}`);
|
|
569
|
+
return;
|
|
570
|
+
}
|
|
571
|
+
// route to a resource/record with a blank string for the 3rd segment which is normally the pkey value
|
|
572
|
+
// here we don't provide the pkey value so the record component will know to create a new record
|
|
573
|
+
this.router.navigate(['resource', 'record', '' /*add this 3rd param that's blank so the route validates*/], { queryParams: {
|
|
574
|
+
Entity: entityInfo.Name,
|
|
575
|
+
NewRecordValues: null
|
|
576
|
+
}
|
|
577
|
+
});
|
|
578
|
+
}
|
|
579
|
+
static ɵfac = function ApplicationViewComponent_Factory(t) { return new (t || ApplicationViewComponent)(i0.ɵɵdirectiveInject(i1.Router), i0.ɵɵdirectiveInject(i1.ActivatedRoute), i0.ɵɵdirectiveInject(i2.Location), i0.ɵɵdirectiveInject(i3.SharedService), i0.ɵɵdirectiveInject(i0.ChangeDetectorRef)); };
|
|
580
|
+
static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: ApplicationViewComponent, selectors: [["mj-application-view"]], viewQuery: function ApplicationViewComponent_Query(rf, ctx) { if (rf & 1) {
|
|
581
|
+
i0.ɵɵviewQuery(_c0, 5);
|
|
582
|
+
i0.ɵɵviewQuery(_c1, 5);
|
|
583
|
+
i0.ɵɵviewQuery(_c2, 5);
|
|
584
|
+
} if (rf & 2) {
|
|
585
|
+
let _t;
|
|
586
|
+
i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.entityRowRef = _t.first);
|
|
587
|
+
i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.viewPropertiesDialog = _t.first);
|
|
588
|
+
i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.availableResourcesComponent = _t.first);
|
|
589
|
+
} }, inputs: { categoryEntityID: "categoryEntityID" }, features: [i0.ɵɵInheritDefinitionFeature], decls: 1, vars: 1, consts: [["userViewDialog", ""], ["availableResourcesComponent", ""], ["class", "mj-page-container", 4, "ngIf"], [1, "mj-page-container"], [1, "mj-breadcrumb"], [1, "mj-breadcrumb-item", 3, "click"], [1, "fas", "fa-home"], [1, "fas", "fa-chevron-right", "mj-breadcrumb-separator"], [1, "mj-breadcrumb-current"], [1, "mj-header"], [1, "mj-header-title"], ["class", "mj-header-icon", 4, "ngIf"], ["class", "mj-header-subtitle", 4, "ngIf"], [1, "mj-header-actions"], ["kendoButton", "", "fillMode", "flat", "rounded", "full", "size", "large", "themeColor", "primary", 3, "click", "title"], [1, "fas", "fa-cog"], ["class", "mj-entity-selection", 4, "ngIf"], ["class", "mj-empty-state", 4, "ngIf"], ["class", "mj-loading mj-loading-overlay", 4, "ngIf"], ["class", "mj-main-content", 4, "ngIf"], ["EntityName", "Entities", "DisplayField", "Name", "DisplayIconField", "Icon", 3, "DialogClosed", "AvailableRecords", "SelectedRecords", "UnselectedRecords", "DialogVisible"], [3, "dialogClosed", "ShowPropertiesButton"], ["DialogTitle", "Available Resources", 3, "DialogClosed", "DialogVisible"], ["ExtraColumns", "UserName, Description", "SelectionMode", "Multiple", 3, "User", "ResourceTypeID", "ResourceExtraFilter", 4, "ngIf"], [1, "mj-header-icon"], [3, "ngClass"], [1, "mj-header-subtitle"], [1, "fas", "fa-info-circle"], [1, "mj-entity-selection"], [1, "mj-entity-buttons"], ["class", "mj-entity-btn", 3, "mj-entity-btn-active", "title", "click", 4, "ngFor", "ngForOf"], [1, "mj-entity-btn", 3, "click", "title"], ["class", "mj-entity-btn-icon", 3, "ngClass", 4, "ngIf"], [1, "mj-entity-btn-icon", 3, "ngClass"], [1, "mj-empty-state"], [1, "fas", "fa-database", "mj-empty-icon"], ["kendoButton", "", "themeColor", "primary", "rounded", "medium", "size", "large", 3, "click"], [1, "button-content"], [1, "mj-loading", "mj-loading-overlay"], ["text", "Loading application...", "size", "large"], [1, "mj-main-content"], ["ResourceTypeName", "User Views", "DisplayMode", "Tile", 3, "ResourceSelected", "NavigateToParentEvent", "EditItemEvent", "EnableCategories", "CategoryEntityID", "CurrentCategoryID", "Title", "ItemFilter", "NewItemOptions"], ["ExtraColumns", "UserName, Description", "SelectionMode", "Multiple", 3, "User", "ResourceTypeID", "ResourceExtraFilter"]], template: function ApplicationViewComponent_Template(rf, ctx) { if (rf & 1) {
|
|
590
|
+
i0.ɵɵtemplate(0, ApplicationViewComponent_div_0_Template, 30, 16, "div", 2);
|
|
591
|
+
} if (rf & 2) {
|
|
592
|
+
i0.ɵɵproperty("ngIf", ctx.app);
|
|
593
|
+
} }, dependencies: [i2.NgClass, i2.NgForOf, i2.NgIf, i4.ButtonComponent, i5.UserViewPropertiesDialogComponent, i6.RecordSelectorDialogComponent, i7.AvailableResourcesComponent, i8.GenericDialogComponent, i9.LoadingComponent, i10.ResourceBrowserComponent], styles: ["[_nghost-%COMP%] {\n display: block;\n}\n\n\n\n.mj-entity-selection[_ngcontent-%COMP%] {\n background: linear-gradient(135deg, var(--gray-600) 0%, #f8f9fa 100%);\n border-radius: var(--border-radius);\n padding: 20px;\n margin-bottom: 24px;\n box-shadow: \n 0 2px 8px rgba(0, 0, 0, 0.08),\n inset 0 1px 0 rgba(255, 255, 255, 0.9);\n position: relative;\n overflow: hidden;\n \n \n\n &::before {\n content: '';\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n background-image: \n repeating-linear-gradient(\n 45deg,\n transparent,\n transparent 10px,\n rgba(255, 255, 255, 0.05) 10px,\n rgba(255, 255, 255, 0.05) 20px\n );\n pointer-events: none;\n }\n}\n\n.mj-entity-buttons[_ngcontent-%COMP%] {\n display: flex;\n flex-wrap: wrap;\n gap: 12px;\n position: relative;\n z-index: 1;\n}\n\n\n\n.mj-entity-btn[_ngcontent-%COMP%] {\n display: inline-flex;\n align-items: center;\n gap: 8px;\n padding: 12px 20px;\n background: var(--white-color);\n border: 2px solid var(--gray-700);\n border-radius: 50px;\n font-size: 14px;\n font-weight: 500;\n color: var(--navy);\n cursor: pointer;\n transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);\n position: relative;\n overflow: hidden;\n white-space: nowrap;\n \n \n\n &::before {\n content: '';\n position: absolute;\n top: 0;\n left: -100%;\n width: 100%;\n height: 100%;\n background: linear-gradient(\n 90deg,\n transparent,\n rgba(0, 118, 182, 0.1),\n transparent\n );\n transition: left 0.6s ease;\n }\n \n &:hover {\n transform: translateY(-2px);\n border-color: var(--mj-blue);\n box-shadow: \n 0 6px 20px rgba(0, 118, 182, 0.15),\n 0 2px 8px rgba(0, 0, 0, 0.1);\n \n &::before {\n left: 100%;\n }\n \n .mj-entity-btn-icon {\n transform: rotate(10deg) scale(1.1);\n color: var(--mj-blue);\n }\n }\n \n &:active {\n transform: translateY(0);\n box-shadow: \n 0 2px 8px rgba(0, 118, 182, 0.15),\n inset 0 1px 2px rgba(0, 0, 0, 0.1);\n }\n}\n\n\n\n.mj-entity-btn-active[_ngcontent-%COMP%] {\n background: linear-gradient(135deg, var(--mj-blue) 0%, #005a9e 100%);\n color: var(--white-color);\n border-color: var(--mj-blue);\n font-weight: 600;\n box-shadow: \n 0 4px 16px rgba(0, 118, 182, 0.3),\n inset 0 1px 0 rgba(255, 255, 255, 0.2);\n \n &::after {\n content: '';\n position: absolute;\n bottom: -2px;\n left: 10%;\n right: 10%;\n height: 3px;\n background: var(--light-blue);\n border-radius: 3px 3px 0 0;\n box-shadow: 0 0 10px var(--light-blue);\n }\n \n &:hover {\n background: linear-gradient(135deg, #0084d1 0%, var(--mj-blue) 100%);\n transform: translateY(-2px) scale(1.02);\n box-shadow: \n 0 8px 24px rgba(0, 118, 182, 0.4),\n inset 0 1px 0 rgba(255, 255, 255, 0.3);\n }\n \n .mj-entity-btn-icon {\n color: var(--white-color);\n filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.2));\n }\n}\n\n\n\n.mj-entity-btn-icon[_ngcontent-%COMP%] {\n font-size: 16px;\n transition: all 0.3s ease;\n color: var(--mj-blue);\n}\n\n\n\n.button-content[_ngcontent-%COMP%] {\n display: inline-flex;\n align-items: center;\n gap: 8px;\n}\n\n\n\n.mj-main-content[_ngcontent-%COMP%] {\n animation: fadeInUp 0.4s ease-out;\n}\n\n\n\n.mj-version-info[_ngcontent-%COMP%] {\n position: fixed;\n bottom: 2rem;\n right: 2rem;\n background: linear-gradient(135deg, var(--navy) 0%, #0a2a4d 100%);\n color: var(--white-color);\n padding: 0.75rem 1.25rem;\n border-radius: 50px;\n font-size: 0.85rem;\n font-weight: 500;\n box-shadow: \n 0 4px 16px rgba(9, 35, 64, 0.3),\n inset 0 1px 0 rgba(255, 255, 255, 0.1);\n z-index: 1000;\n display: flex;\n align-items: center;\n gap: 0.5rem;\n transition: all var(--transition-time);\n backdrop-filter: blur(10px);\n border: 1px solid rgba(255, 255, 255, 0.1);\n \n &:hover {\n background: linear-gradient(135deg, var(--mj-blue) 0%, #005a9e 100%);\n transform: translateY(-4px) scale(1.05);\n box-shadow: \n 0 8px 32px rgba(0, 118, 182, 0.4),\n inset 0 1px 0 rgba(255, 255, 255, 0.2);\n }\n \n i {\n font-size: 0.75rem;\n }\n}\n\n\n\n@media (max-width: 768px) {\n .mj-entity-selection[_ngcontent-%COMP%] {\n padding: 16px;\n margin-bottom: 20px;\n }\n \n .mj-entity-buttons[_ngcontent-%COMP%] {\n gap: 8px;\n }\n \n .mj-entity-btn[_ngcontent-%COMP%] {\n padding: 10px 16px;\n font-size: 13px;\n \n .mj-entity-btn-icon {\n font-size: 14px;\n }\n }\n \n .mj-header[_ngcontent-%COMP%] {\n .mj-header-icon {\n width: 48px;\n height: 48px;\n \n span {\n font-size: 24px;\n }\n }\n \n h1 {\n font-size: 2rem;\n }\n }\n \n .mj-empty-state[_ngcontent-%COMP%] {\n padding: 60px 30px;\n margin: 20px auto;\n \n .mj-empty-icon {\n font-size: 4rem;\n }\n \n h3 {\n font-size: 1.5rem;\n }\n \n p {\n font-size: 1rem;\n }\n }\n \n .mj-version-info[_ngcontent-%COMP%] {\n bottom: 1rem;\n right: 1rem;\n font-size: 0.8rem;\n padding: 0.6rem 1rem;\n }\n}\n\n@media (max-width: 480px) {\n .mj-entity-buttons[_ngcontent-%COMP%] {\n flex-direction: column;\n width: 100%;\n }\n \n .mj-entity-btn[_ngcontent-%COMP%] {\n width: 100%;\n justify-content: center;\n }\n \n .mj-header[_ngcontent-%COMP%] {\n h1 {\n font-size: 1.5rem;\n }\n }\n}\n\n\n\n.mj-entity-btn[_ngcontent-%COMP%]:focus-visible, \n.mj-btn-icon-only[_ngcontent-%COMP%]:focus-visible {\n outline: 2px solid var(--mj-blue);\n outline-offset: 2px;\n}\n\n\n\n@media (prefers-contrast: high) {\n .mj-entity-btn[_ngcontent-%COMP%], \n .mj-btn-icon-only[_ngcontent-%COMP%] {\n border-width: 2px !important;\n }\n \n .mj-entity-btn-active[_ngcontent-%COMP%] {\n border-width: 3px !important;\n }\n}\n\n\n\n@media (prefers-reduced-motion: reduce) {\n *[_ngcontent-%COMP%], \n *[_ngcontent-%COMP%]::before, \n *[_ngcontent-%COMP%]::after {\n animation-duration: 0.01ms !important;\n transition-duration: 0.01ms !important;\n }\n \n .mj-entity-btn[_ngcontent-%COMP%]:hover, \n .mj-btn-icon-only[_ngcontent-%COMP%]:hover {\n transform: none !important;\n }\n}\n\n\n\n@media (prefers-color-scheme: dark) {\n \n\n}"] });
|
|
594
|
+
}
|
|
595
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(ApplicationViewComponent, [{
|
|
596
|
+
type: Component,
|
|
597
|
+
args: [{ selector: 'mj-application-view', template: "<!-- Enhanced Application View Component -->\n<div class=\"mj-page-container\" *ngIf=\"this.app\">\n <!-- Enhanced Breadcrumb Navigation -->\n <nav class=\"mj-breadcrumb\">\n <span class=\"mj-breadcrumb-item\" (click)=\"GoHome($event)\">\n <i class=\"fas fa-home\"></i>\n Home\n </span>\n <i class=\"fas fa-chevron-right mj-breadcrumb-separator\"></i>\n <span class=\"mj-breadcrumb-item\" (click)=\"GoToApps($event)\">Applications</span>\n <i class=\"fas fa-chevron-right mj-breadcrumb-separator\"></i>\n <span class=\"mj-breadcrumb-current\">{{this.app.Name}}</span>\n </nav>\n\n <!-- Enhanced Header Section -->\n <div class=\"mj-header\"> \n <div class=\"mj-header-title\">\n <div class=\"mj-header-icon\" *ngIf=\"this.app.Icon && this.app.Icon.length > 0\">\n <span [ngClass]=\"this.app.Icon\"></span>\n </div>\n <div>\n <h1>{{this.app.Name}}</h1>\n <div class=\"mj-header-subtitle\" *ngIf=\"this.app.Description\">\n <i class=\"fas fa-info-circle\"></i>\n {{this.app.Description}}\n </div>\n </div>\n </div>\n <div class=\"mj-header-actions\">\n <button kendoButton\n fillMode=\"flat\"\n rounded=\"full\"\n size=\"large\"\n themeColor=\"primary\"\n [title]=\"'Configure Entities'\"\n (click)=\"ShowAppEntitySelectionDialog()\">\n <i class=\"fas fa-cog\"></i>\n </button>\n </div>\n </div>\n\n <!-- Enhanced Entity Selection Bar -->\n <div class=\"mj-entity-selection\" *ngIf=\"SelectedAppEntities.length > 0\">\n <div class=\"mj-entity-buttons\">\n <button\n *ngFor=\"let item of SelectedAppEntities\"\n class=\"mj-entity-btn\"\n [class.mj-entity-btn-active]=\"IsEntitySelected(item)\"\n (click)=\"onAppEntityButtonClicked(item)\"\n [title]=\"item.Description || item.Name\"\n >\n <i *ngIf=\"item.Icon && item.Icon.length > 0\" \n [ngClass]=\"item.Icon\" \n class=\"mj-entity-btn-icon\"></i>\n <span>{{item.Name}}</span>\n </button>\n </div>\n </div>\n\n <!-- Enhanced Empty State -->\n <div class=\"mj-empty-state\" *ngIf=\"SelectedAppEntities.length === 0 && !showLoader\">\n <i class=\"fas fa-database mj-empty-icon\"></i>\n <h3>No Entities Selected</h3>\n <p>Configure which entities you'd like to work with in this application</p>\n <button kendoButton\n themeColor=\"primary\"\n rounded=\"medium\"\n size=\"large\"\n (click)=\"ShowAppEntitySelectionDialog()\">\n <span class=\"button-content\">\n <i class=\"fas fa-cog\"></i>\n Configure Entities\n </span>\n </button>\n </div>\n\n <!-- Enhanced Loading State -->\n <div class=\"mj-loading mj-loading-overlay\" *ngIf=\"showLoader\">\n <mj-loading text=\"Loading application...\" size=\"large\"></mj-loading>\n </div>\n\n <!-- Main Content Area -->\n <div class=\"mj-main-content\" *ngIf=\"SelectedAppEntities.length > 0 && !showLoader\">\n <mj-resource-browser\n ResourceTypeName=\"User Views\"\n [EnableCategories]=\"true\"\n [CategoryEntityID]=\"currentlySelectedAppEntity?.ID\"\n [CurrentCategoryID]=\"selectedFolderID\"\n [Title]=\"currentlySelectedAppEntity?.Name\"\n [ItemFilter]=\"ResourceItemFilter\"\n DisplayMode=\"Tile\"\n [NewItemOptions]=\"NewItemOptions\"\n (ResourceSelected)=\"onItemClick($event)\"\n (NavigateToParentEvent)=\"navigateToParentFolder()\"\n (EditItemEvent)=\"editView($event)\"\n />\n </div>\n\n <!-- Dialogs -->\n <mj-record-selector-dialog \n EntityName=\"Entities\"\n [AvailableRecords]=\"AllAppEntities\" \n [SelectedRecords]=\"SelectedAppEntities\" \n [UnselectedRecords]=\"UnselectedAppEntities\"\n [DialogVisible]=\"AppEntitySelectionDialogVisible\"\n DisplayField=\"Name\"\n DisplayIconField=\"Icon\"\n (DialogClosed)=\"OnAppEntitySelectionDialogClosed($event)\"\n >\n </mj-record-selector-dialog>\n\n <mj-user-view-properties-dialog \n #userViewDialog \n [ShowPropertiesButton]=\"false\"\n (dialogClosed)=\"OnViewPropertiesDialogClose($event)\">\n </mj-user-view-properties-dialog>\n\n <mj-generic-dialog\n DialogTitle=\"Available Resources\"\n (DialogClosed)=\"HandleLinkToSharedView($event)\"\n [DialogVisible]=\"LinkToSharedViewDialogVisible\"\n >\n <mj-available-resources\n *ngIf=\"LinkToSharedViewDialogVisible\" \n #availableResourcesComponent\n [User]=\"currentUser\"\n [ResourceTypeID]=\"ViewResourceTypeID\"\n [ResourceExtraFilter]=\"FilterOutCurrentUserViews\"\n ExtraColumns=\"UserName, Description\"\n SelectionMode=\"Multiple\"\n >\n </mj-available-resources>\n </mj-generic-dialog> \n</div>\n", styles: [":host {\n display: block;\n}\n\n/* Entity Selection Bar */\n.mj-entity-selection {\n background: linear-gradient(135deg, var(--gray-600) 0%, #f8f9fa 100%);\n border-radius: var(--border-radius);\n padding: 20px;\n margin-bottom: 24px;\n box-shadow: \n 0 2px 8px rgba(0, 0, 0, 0.08),\n inset 0 1px 0 rgba(255, 255, 255, 0.9);\n position: relative;\n overflow: hidden;\n \n /* Subtle pattern overlay */\n &::before {\n content: '';\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n background-image: \n repeating-linear-gradient(\n 45deg,\n transparent,\n transparent 10px,\n rgba(255, 255, 255, 0.05) 10px,\n rgba(255, 255, 255, 0.05) 20px\n );\n pointer-events: none;\n }\n}\n\n.mj-entity-buttons {\n display: flex;\n flex-wrap: wrap;\n gap: 12px;\n position: relative;\n z-index: 1;\n}\n\n/* Entity Selection Buttons - Modern pill design */\n.mj-entity-btn {\n display: inline-flex;\n align-items: center;\n gap: 8px;\n padding: 12px 20px;\n background: var(--white-color);\n border: 2px solid var(--gray-700);\n border-radius: 50px;\n font-size: 14px;\n font-weight: 500;\n color: var(--navy);\n cursor: pointer;\n transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);\n position: relative;\n overflow: hidden;\n white-space: nowrap;\n \n /* Shine effect on hover */\n &::before {\n content: '';\n position: absolute;\n top: 0;\n left: -100%;\n width: 100%;\n height: 100%;\n background: linear-gradient(\n 90deg,\n transparent,\n rgba(0, 118, 182, 0.1),\n transparent\n );\n transition: left 0.6s ease;\n }\n \n &:hover {\n transform: translateY(-2px);\n border-color: var(--mj-blue);\n box-shadow: \n 0 6px 20px rgba(0, 118, 182, 0.15),\n 0 2px 8px rgba(0, 0, 0, 0.1);\n \n &::before {\n left: 100%;\n }\n \n .mj-entity-btn-icon {\n transform: rotate(10deg) scale(1.1);\n color: var(--mj-blue);\n }\n }\n \n &:active {\n transform: translateY(0);\n box-shadow: \n 0 2px 8px rgba(0, 118, 182, 0.15),\n inset 0 1px 2px rgba(0, 0, 0, 0.1);\n }\n}\n\n/* Active Entity Button */\n.mj-entity-btn-active {\n background: linear-gradient(135deg, var(--mj-blue) 0%, #005a9e 100%);\n color: var(--white-color);\n border-color: var(--mj-blue);\n font-weight: 600;\n box-shadow: \n 0 4px 16px rgba(0, 118, 182, 0.3),\n inset 0 1px 0 rgba(255, 255, 255, 0.2);\n \n &::after {\n content: '';\n position: absolute;\n bottom: -2px;\n left: 10%;\n right: 10%;\n height: 3px;\n background: var(--light-blue);\n border-radius: 3px 3px 0 0;\n box-shadow: 0 0 10px var(--light-blue);\n }\n \n &:hover {\n background: linear-gradient(135deg, #0084d1 0%, var(--mj-blue) 100%);\n transform: translateY(-2px) scale(1.02);\n box-shadow: \n 0 8px 24px rgba(0, 118, 182, 0.4),\n inset 0 1px 0 rgba(255, 255, 255, 0.3);\n }\n \n .mj-entity-btn-icon {\n color: var(--white-color);\n filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.2));\n }\n}\n\n/* Entity Button Icon */\n.mj-entity-btn-icon {\n font-size: 16px;\n transition: all 0.3s ease;\n color: var(--mj-blue);\n}\n\n/* Button content wrapper */\n.button-content {\n display: inline-flex;\n align-items: center;\n gap: 8px;\n}\n\n/* Main Content Wrapper */\n.mj-main-content {\n animation: fadeInUp 0.4s ease-out;\n}\n\n/* Version Info Badge */\n.mj-version-info {\n position: fixed;\n bottom: 2rem;\n right: 2rem;\n background: linear-gradient(135deg, var(--navy) 0%, #0a2a4d 100%);\n color: var(--white-color);\n padding: 0.75rem 1.25rem;\n border-radius: 50px;\n font-size: 0.85rem;\n font-weight: 500;\n box-shadow: \n 0 4px 16px rgba(9, 35, 64, 0.3),\n inset 0 1px 0 rgba(255, 255, 255, 0.1);\n z-index: 1000;\n display: flex;\n align-items: center;\n gap: 0.5rem;\n transition: all var(--transition-time);\n backdrop-filter: blur(10px);\n border: 1px solid rgba(255, 255, 255, 0.1);\n \n &:hover {\n background: linear-gradient(135deg, var(--mj-blue) 0%, #005a9e 100%);\n transform: translateY(-4px) scale(1.05);\n box-shadow: \n 0 8px 32px rgba(0, 118, 182, 0.4),\n inset 0 1px 0 rgba(255, 255, 255, 0.2);\n }\n \n i {\n font-size: 0.75rem;\n }\n}\n\n/* Responsive Design */\n@media (max-width: 768px) {\n .mj-entity-selection {\n padding: 16px;\n margin-bottom: 20px;\n }\n \n .mj-entity-buttons {\n gap: 8px;\n }\n \n .mj-entity-btn {\n padding: 10px 16px;\n font-size: 13px;\n \n .mj-entity-btn-icon {\n font-size: 14px;\n }\n }\n \n .mj-header {\n .mj-header-icon {\n width: 48px;\n height: 48px;\n \n span {\n font-size: 24px;\n }\n }\n \n h1 {\n font-size: 2rem;\n }\n }\n \n .mj-empty-state {\n padding: 60px 30px;\n margin: 20px auto;\n \n .mj-empty-icon {\n font-size: 4rem;\n }\n \n h3 {\n font-size: 1.5rem;\n }\n \n p {\n font-size: 1rem;\n }\n }\n \n .mj-version-info {\n bottom: 1rem;\n right: 1rem;\n font-size: 0.8rem;\n padding: 0.6rem 1rem;\n }\n}\n\n@media (max-width: 480px) {\n .mj-entity-buttons {\n flex-direction: column;\n width: 100%;\n }\n \n .mj-entity-btn {\n width: 100%;\n justify-content: center;\n }\n \n .mj-header {\n h1 {\n font-size: 1.5rem;\n }\n }\n}\n\n/* Accessibility Enhancements */\n.mj-entity-btn:focus-visible,\n.mj-btn-icon-only:focus-visible {\n outline: 2px solid var(--mj-blue);\n outline-offset: 2px;\n}\n\n/* High Contrast Mode */\n@media (prefers-contrast: high) {\n .mj-entity-btn,\n .mj-btn-icon-only {\n border-width: 2px !important;\n }\n \n .mj-entity-btn-active {\n border-width: 3px !important;\n }\n}\n\n/* Reduced Motion */\n@media (prefers-reduced-motion: reduce) {\n *,\n *::before,\n *::after {\n animation-duration: 0.01ms !important;\n transition-duration: 0.01ms !important;\n }\n \n .mj-entity-btn:hover,\n .mj-btn-icon-only:hover {\n transform: none !important;\n }\n}\n\n/* Dark Mode Support (if needed in future) */\n@media (prefers-color-scheme: dark) {\n /* Dark mode overrides can be added here */\n}\n"] }]
|
|
598
|
+
}], () => [{ type: i1.Router }, { type: i1.ActivatedRoute }, { type: i2.Location }, { type: i3.SharedService }, { type: i0.ChangeDetectorRef }], { entityRowRef: [{
|
|
599
|
+
type: ViewChild,
|
|
600
|
+
args: ['entityRow']
|
|
601
|
+
}], viewPropertiesDialog: [{
|
|
602
|
+
type: ViewChild,
|
|
603
|
+
args: ['userViewDialog']
|
|
604
|
+
}], availableResourcesComponent: [{
|
|
605
|
+
type: ViewChild,
|
|
606
|
+
args: ['availableResourcesComponent']
|
|
607
|
+
}], categoryEntityID: [{
|
|
608
|
+
type: Input
|
|
609
|
+
}] }); })();
|
|
610
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(ApplicationViewComponent, { className: "ApplicationViewComponent" }); })();
|
|
611
|
+
//# sourceMappingURL=application-view.component.js.map
|