gamma-app-controller 2.0.1 → 2.0.3

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.
@@ -4323,10 +4323,10 @@ class UserAccessComponent {
4323
4323
  }
4324
4324
  }
4325
4325
  UserAccessComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: UserAccessComponent, deps: [{ token: CommonService }], target: i0.ɵɵFactoryTarget.Component });
4326
- UserAccessComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: UserAccessComponent, selector: "app-user-access", inputs: { userOptionContainer: "userOptionContainer" }, outputs: { userOptionContainerChange: "userOptionContainerChange" }, ngImport: i0, template: "<div class=\"p-4 w-full\">\n <div class=\"m-3 p-4 bg-white border border-gray-200 rounded-lg shadow-md dark:bg-gray-800 dark:border-gray-700\">\n\n <h6 class=\"mb-2 text-lg tracking-tight text-gray-900 dark:text-white border-b pb-3 flex items-center\">\n User Information\n <div class=\"ml-auto\">\n <div class=\"{{ commonService?.btn_primary_md }}\" (click)=\"addNewUser()\">\n Add Permission Entity\n </div>\n </div>\n </h6>\n\n <div class=\"w-full m-2\">\n <ng-container *ngFor=\"let item of userOptionContainer; let i = index\">\n <div class=\"flex flex-row\">\n\n <!-- Accessible User Type -->\n <div class=\"mx-2 w-1/4\">\n <div class=\"text-md p-2 capitalize\">Entity Type</div>\n <dx-select-box [items]=\"menuType\" [(ngModel)]=\"item.entityName\" (onValueChanged)=\"emitChanges()\">\n </dx-select-box>\n </div>\n\n <!-- User -->\n <div class=\"mx-2 w-1/4\">\n <div class=\"text-md p-2 capitalize\">Entity Value</div>\n <dx-tag-box [(ngModel)]=\"item.entityValues\" [acceptCustomValue]=\"true\" (onValueChanged)=\"emitChanges()\">\n </dx-tag-box>\n </div>\n\n <!-- Delete -->\n <div class=\"mx-2\">\n <div class=\"text-md p-2 capitalize\"></div>\n <div class=\"mt-4\">\n <div class=\"{{ commonService?.btn_danger_md }}\" (click)=\"deleteUser(i)\">\n Delete\n </div>\n </div>\n </div>\n\n </div>\n </ng-container>\n </div>\n </div>\n</div>", dependencies: [{ kind: "directive", type: i4$2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i8.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i8.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i6$1.DxSelectBoxComponent, selector: "dx-select-box", inputs: ["acceptCustomValue", "accessKey", "activeStateEnabled", "buttons", "dataSource", "deferRendering", "disabled", "displayExpr", "displayValue", "dropDownButtonTemplate", "dropDownOptions", "elementAttr", "fieldTemplate", "focusStateEnabled", "grouped", "groupTemplate", "height", "hint", "hoverStateEnabled", "inputAttr", "isValid", "items", "itemTemplate", "label", "labelMode", "maxLength", "minSearchLength", "name", "noDataText", "opened", "openOnFieldClick", "placeholder", "readOnly", "rtlEnabled", "searchEnabled", "searchExpr", "searchMode", "searchTimeout", "selectedItem", "showClearButton", "showDataBeforeSearch", "showDropDownButton", "showSelectionControls", "spellcheck", "stylingMode", "tabIndex", "text", "useItemTextAsTitle", "validationError", "validationErrors", "validationMessageMode", "validationStatus", "value", "valueChangeEvent", "valueExpr", "visible", "width", "wrapItemText"], outputs: ["onChange", "onClosed", "onContentReady", "onCopy", "onCustomItemCreating", "onCut", "onDisposing", "onEnterKey", "onFocusIn", "onFocusOut", "onInitialized", "onInput", "onItemClick", "onKeyDown", "onKeyUp", "onOpened", "onOptionChanged", "onPaste", "onSelectionChanged", "onValueChanged", "acceptCustomValueChange", "accessKeyChange", "activeStateEnabledChange", "buttonsChange", "dataSourceChange", "deferRenderingChange", "disabledChange", "displayExprChange", "displayValueChange", "dropDownButtonTemplateChange", "dropDownOptionsChange", "elementAttrChange", "fieldTemplateChange", "focusStateEnabledChange", "groupedChange", "groupTemplateChange", "heightChange", "hintChange", "hoverStateEnabledChange", "inputAttrChange", "isValidChange", "itemsChange", "itemTemplateChange", "labelChange", "labelModeChange", "maxLengthChange", "minSearchLengthChange", "nameChange", "noDataTextChange", "openedChange", "openOnFieldClickChange", "placeholderChange", "readOnlyChange", "rtlEnabledChange", "searchEnabledChange", "searchExprChange", "searchModeChange", "searchTimeoutChange", "selectedItemChange", "showClearButtonChange", "showDataBeforeSearchChange", "showDropDownButtonChange", "showSelectionControlsChange", "spellcheckChange", "stylingModeChange", "tabIndexChange", "textChange", "useItemTextAsTitleChange", "validationErrorChange", "validationErrorsChange", "validationMessageModeChange", "validationStatusChange", "valueChange", "valueChangeEventChange", "valueExprChange", "visibleChange", "widthChange", "wrapItemTextChange", "onBlur"] }, { kind: "component", type: i8$1.DxTagBoxComponent, selector: "dx-tag-box", inputs: ["acceptCustomValue", "accessKey", "activeStateEnabled", "applyValueMode", "buttons", "dataSource", "deferRendering", "disabled", "displayExpr", "dropDownButtonTemplate", "dropDownOptions", "elementAttr", "fieldTemplate", "focusStateEnabled", "grouped", "groupTemplate", "height", "hideSelectedItems", "hint", "hoverStateEnabled", "inputAttr", "isValid", "items", "itemTemplate", "label", "labelMode", "maxDisplayedTags", "maxFilterQueryLength", "maxLength", "minSearchLength", "multiline", "name", "noDataText", "opened", "openOnFieldClick", "placeholder", "readOnly", "rtlEnabled", "searchEnabled", "searchExpr", "searchMode", "searchTimeout", "selectAllMode", "selectAllText", "selectedItems", "showClearButton", "showDataBeforeSearch", "showDropDownButton", "showMultiTagOnly", "showSelectionControls", "stylingMode", "tabIndex", "tagTemplate", "text", "useItemTextAsTitle", "validationError", "validationErrors", "validationMessageMode", "validationStatus", "value", "valueExpr", "visible", "width", "wrapItemText"], outputs: ["onChange", "onClosed", "onContentReady", "onCustomItemCreating", "onDisposing", "onEnterKey", "onFocusIn", "onFocusOut", "onInitialized", "onInput", "onItemClick", "onKeyDown", "onKeyUp", "onMultiTagPreparing", "onOpened", "onOptionChanged", "onSelectAllValueChanged", "onSelectionChanged", "onValueChanged", "acceptCustomValueChange", "accessKeyChange", "activeStateEnabledChange", "applyValueModeChange", "buttonsChange", "dataSourceChange", "deferRenderingChange", "disabledChange", "displayExprChange", "dropDownButtonTemplateChange", "dropDownOptionsChange", "elementAttrChange", "fieldTemplateChange", "focusStateEnabledChange", "groupedChange", "groupTemplateChange", "heightChange", "hideSelectedItemsChange", "hintChange", "hoverStateEnabledChange", "inputAttrChange", "isValidChange", "itemsChange", "itemTemplateChange", "labelChange", "labelModeChange", "maxDisplayedTagsChange", "maxFilterQueryLengthChange", "maxLengthChange", "minSearchLengthChange", "multilineChange", "nameChange", "noDataTextChange", "openedChange", "openOnFieldClickChange", "placeholderChange", "readOnlyChange", "rtlEnabledChange", "searchEnabledChange", "searchExprChange", "searchModeChange", "searchTimeoutChange", "selectAllModeChange", "selectAllTextChange", "selectedItemsChange", "showClearButtonChange", "showDataBeforeSearchChange", "showDropDownButtonChange", "showMultiTagOnlyChange", "showSelectionControlsChange", "stylingModeChange", "tabIndexChange", "tagTemplateChange", "textChange", "useItemTextAsTitleChange", "validationErrorChange", "validationErrorsChange", "validationMessageModeChange", "validationStatusChange", "valueChange", "valueExprChange", "visibleChange", "widthChange", "wrapItemTextChange", "onBlur"] }] });
4326
+ UserAccessComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: UserAccessComponent, selector: "app-user-access", inputs: { userOptionContainer: "userOptionContainer" }, outputs: { userOptionContainerChange: "userOptionContainerChange" }, ngImport: i0, template: "<div class=\"p-4 w-full\">\n <div class=\"m-3 p-4 bg-white border border-gray-200 rounded-lg shadow-md dark:bg-gray-800 dark:border-gray-700\">\n\n <h6 class=\"mb-2 text-lg tracking-tight text-gray-900 dark:text-white border-b pb-3 flex items-center\">\n Manage Permissions\n <div class=\"ml-auto\">\n <div class=\"{{ commonService?.btn_primary_md }}\" (click)=\"addNewUser()\">\n Add Permission Entity\n </div>\n </div>\n </h6>\n\n <div class=\"w-full m-2\">\n <ng-container *ngFor=\"let item of userOptionContainer; let i = index\">\n <div class=\"flex flex-row\">\n\n <!-- Accessible User Type -->\n <div class=\"mx-2 w-1/4\">\n <div class=\"text-md p-2 capitalize\">Entity Type</div>\n <dx-select-box [items]=\"menuType\" [(ngModel)]=\"item.entityName\" (onValueChanged)=\"emitChanges()\">\n </dx-select-box>\n </div>\n\n <!-- User -->\n <div class=\"mx-2 w-1/4\">\n <div class=\"text-md p-2 capitalize\">Entity Value</div>\n <dx-tag-box [(ngModel)]=\"item.entityValues\" [acceptCustomValue]=\"true\" (onValueChanged)=\"emitChanges()\">\n </dx-tag-box>\n </div>\n\n <!-- Delete -->\n <div class=\"mx-2\">\n <div class=\"text-md p-2 capitalize\"></div>\n <div class=\"mt-4\">\n <div class=\"{{ commonService?.btn_danger_md }}\" (click)=\"deleteUser(i)\">\n Delete\n </div>\n </div>\n </div>\n\n </div>\n </ng-container>\n </div>\n </div>\n</div>", dependencies: [{ kind: "directive", type: i4$2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i8.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i8.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i6$1.DxSelectBoxComponent, selector: "dx-select-box", inputs: ["acceptCustomValue", "accessKey", "activeStateEnabled", "buttons", "dataSource", "deferRendering", "disabled", "displayExpr", "displayValue", "dropDownButtonTemplate", "dropDownOptions", "elementAttr", "fieldTemplate", "focusStateEnabled", "grouped", "groupTemplate", "height", "hint", "hoverStateEnabled", "inputAttr", "isValid", "items", "itemTemplate", "label", "labelMode", "maxLength", "minSearchLength", "name", "noDataText", "opened", "openOnFieldClick", "placeholder", "readOnly", "rtlEnabled", "searchEnabled", "searchExpr", "searchMode", "searchTimeout", "selectedItem", "showClearButton", "showDataBeforeSearch", "showDropDownButton", "showSelectionControls", "spellcheck", "stylingMode", "tabIndex", "text", "useItemTextAsTitle", "validationError", "validationErrors", "validationMessageMode", "validationStatus", "value", "valueChangeEvent", "valueExpr", "visible", "width", "wrapItemText"], outputs: ["onChange", "onClosed", "onContentReady", "onCopy", "onCustomItemCreating", "onCut", "onDisposing", "onEnterKey", "onFocusIn", "onFocusOut", "onInitialized", "onInput", "onItemClick", "onKeyDown", "onKeyUp", "onOpened", "onOptionChanged", "onPaste", "onSelectionChanged", "onValueChanged", "acceptCustomValueChange", "accessKeyChange", "activeStateEnabledChange", "buttonsChange", "dataSourceChange", "deferRenderingChange", "disabledChange", "displayExprChange", "displayValueChange", "dropDownButtonTemplateChange", "dropDownOptionsChange", "elementAttrChange", "fieldTemplateChange", "focusStateEnabledChange", "groupedChange", "groupTemplateChange", "heightChange", "hintChange", "hoverStateEnabledChange", "inputAttrChange", "isValidChange", "itemsChange", "itemTemplateChange", "labelChange", "labelModeChange", "maxLengthChange", "minSearchLengthChange", "nameChange", "noDataTextChange", "openedChange", "openOnFieldClickChange", "placeholderChange", "readOnlyChange", "rtlEnabledChange", "searchEnabledChange", "searchExprChange", "searchModeChange", "searchTimeoutChange", "selectedItemChange", "showClearButtonChange", "showDataBeforeSearchChange", "showDropDownButtonChange", "showSelectionControlsChange", "spellcheckChange", "stylingModeChange", "tabIndexChange", "textChange", "useItemTextAsTitleChange", "validationErrorChange", "validationErrorsChange", "validationMessageModeChange", "validationStatusChange", "valueChange", "valueChangeEventChange", "valueExprChange", "visibleChange", "widthChange", "wrapItemTextChange", "onBlur"] }, { kind: "component", type: i8$1.DxTagBoxComponent, selector: "dx-tag-box", inputs: ["acceptCustomValue", "accessKey", "activeStateEnabled", "applyValueMode", "buttons", "dataSource", "deferRendering", "disabled", "displayExpr", "dropDownButtonTemplate", "dropDownOptions", "elementAttr", "fieldTemplate", "focusStateEnabled", "grouped", "groupTemplate", "height", "hideSelectedItems", "hint", "hoverStateEnabled", "inputAttr", "isValid", "items", "itemTemplate", "label", "labelMode", "maxDisplayedTags", "maxFilterQueryLength", "maxLength", "minSearchLength", "multiline", "name", "noDataText", "opened", "openOnFieldClick", "placeholder", "readOnly", "rtlEnabled", "searchEnabled", "searchExpr", "searchMode", "searchTimeout", "selectAllMode", "selectAllText", "selectedItems", "showClearButton", "showDataBeforeSearch", "showDropDownButton", "showMultiTagOnly", "showSelectionControls", "stylingMode", "tabIndex", "tagTemplate", "text", "useItemTextAsTitle", "validationError", "validationErrors", "validationMessageMode", "validationStatus", "value", "valueExpr", "visible", "width", "wrapItemText"], outputs: ["onChange", "onClosed", "onContentReady", "onCustomItemCreating", "onDisposing", "onEnterKey", "onFocusIn", "onFocusOut", "onInitialized", "onInput", "onItemClick", "onKeyDown", "onKeyUp", "onMultiTagPreparing", "onOpened", "onOptionChanged", "onSelectAllValueChanged", "onSelectionChanged", "onValueChanged", "acceptCustomValueChange", "accessKeyChange", "activeStateEnabledChange", "applyValueModeChange", "buttonsChange", "dataSourceChange", "deferRenderingChange", "disabledChange", "displayExprChange", "dropDownButtonTemplateChange", "dropDownOptionsChange", "elementAttrChange", "fieldTemplateChange", "focusStateEnabledChange", "groupedChange", "groupTemplateChange", "heightChange", "hideSelectedItemsChange", "hintChange", "hoverStateEnabledChange", "inputAttrChange", "isValidChange", "itemsChange", "itemTemplateChange", "labelChange", "labelModeChange", "maxDisplayedTagsChange", "maxFilterQueryLengthChange", "maxLengthChange", "minSearchLengthChange", "multilineChange", "nameChange", "noDataTextChange", "openedChange", "openOnFieldClickChange", "placeholderChange", "readOnlyChange", "rtlEnabledChange", "searchEnabledChange", "searchExprChange", "searchModeChange", "searchTimeoutChange", "selectAllModeChange", "selectAllTextChange", "selectedItemsChange", "showClearButtonChange", "showDataBeforeSearchChange", "showDropDownButtonChange", "showMultiTagOnlyChange", "showSelectionControlsChange", "stylingModeChange", "tabIndexChange", "tagTemplateChange", "textChange", "useItemTextAsTitleChange", "validationErrorChange", "validationErrorsChange", "validationMessageModeChange", "validationStatusChange", "valueChange", "valueExprChange", "visibleChange", "widthChange", "wrapItemTextChange", "onBlur"] }] });
4327
4327
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: UserAccessComponent, decorators: [{
4328
4328
  type: Component,
4329
- args: [{ selector: 'app-user-access', template: "<div class=\"p-4 w-full\">\n <div class=\"m-3 p-4 bg-white border border-gray-200 rounded-lg shadow-md dark:bg-gray-800 dark:border-gray-700\">\n\n <h6 class=\"mb-2 text-lg tracking-tight text-gray-900 dark:text-white border-b pb-3 flex items-center\">\n User Information\n <div class=\"ml-auto\">\n <div class=\"{{ commonService?.btn_primary_md }}\" (click)=\"addNewUser()\">\n Add Permission Entity\n </div>\n </div>\n </h6>\n\n <div class=\"w-full m-2\">\n <ng-container *ngFor=\"let item of userOptionContainer; let i = index\">\n <div class=\"flex flex-row\">\n\n <!-- Accessible User Type -->\n <div class=\"mx-2 w-1/4\">\n <div class=\"text-md p-2 capitalize\">Entity Type</div>\n <dx-select-box [items]=\"menuType\" [(ngModel)]=\"item.entityName\" (onValueChanged)=\"emitChanges()\">\n </dx-select-box>\n </div>\n\n <!-- User -->\n <div class=\"mx-2 w-1/4\">\n <div class=\"text-md p-2 capitalize\">Entity Value</div>\n <dx-tag-box [(ngModel)]=\"item.entityValues\" [acceptCustomValue]=\"true\" (onValueChanged)=\"emitChanges()\">\n </dx-tag-box>\n </div>\n\n <!-- Delete -->\n <div class=\"mx-2\">\n <div class=\"text-md p-2 capitalize\"></div>\n <div class=\"mt-4\">\n <div class=\"{{ commonService?.btn_danger_md }}\" (click)=\"deleteUser(i)\">\n Delete\n </div>\n </div>\n </div>\n\n </div>\n </ng-container>\n </div>\n </div>\n</div>" }]
4329
+ args: [{ selector: 'app-user-access', template: "<div class=\"p-4 w-full\">\n <div class=\"m-3 p-4 bg-white border border-gray-200 rounded-lg shadow-md dark:bg-gray-800 dark:border-gray-700\">\n\n <h6 class=\"mb-2 text-lg tracking-tight text-gray-900 dark:text-white border-b pb-3 flex items-center\">\n Manage Permissions\n <div class=\"ml-auto\">\n <div class=\"{{ commonService?.btn_primary_md }}\" (click)=\"addNewUser()\">\n Add Permission Entity\n </div>\n </div>\n </h6>\n\n <div class=\"w-full m-2\">\n <ng-container *ngFor=\"let item of userOptionContainer; let i = index\">\n <div class=\"flex flex-row\">\n\n <!-- Accessible User Type -->\n <div class=\"mx-2 w-1/4\">\n <div class=\"text-md p-2 capitalize\">Entity Type</div>\n <dx-select-box [items]=\"menuType\" [(ngModel)]=\"item.entityName\" (onValueChanged)=\"emitChanges()\">\n </dx-select-box>\n </div>\n\n <!-- User -->\n <div class=\"mx-2 w-1/4\">\n <div class=\"text-md p-2 capitalize\">Entity Value</div>\n <dx-tag-box [(ngModel)]=\"item.entityValues\" [acceptCustomValue]=\"true\" (onValueChanged)=\"emitChanges()\">\n </dx-tag-box>\n </div>\n\n <!-- Delete -->\n <div class=\"mx-2\">\n <div class=\"text-md p-2 capitalize\"></div>\n <div class=\"mt-4\">\n <div class=\"{{ commonService?.btn_danger_md }}\" (click)=\"deleteUser(i)\">\n Delete\n </div>\n </div>\n </div>\n\n </div>\n </ng-container>\n </div>\n </div>\n</div>" }]
4330
4330
  }], ctorParameters: function () { return [{ type: CommonService }]; }, propDecorators: { userOptionContainer: [{
4331
4331
  type: Input
4332
4332
  }], userOptionContainerChange: [{
@@ -8122,11 +8122,10 @@ class BreadCrumbsComponent {
8122
8122
  return;
8123
8123
  }
8124
8124
  else {
8125
- let relativePath = 'rakpiBrowser';
8126
- this.getKpiName(value, relativePath);
8127
- setTimeout(() => {
8128
- this.loadBreadCrumbs();
8129
- }, 500);
8125
+ debugger;
8126
+ this.kpiListData = value;
8127
+ this.getBreadCrumbsData(value);
8128
+ this.loadBreadCrumbs();
8130
8129
  this.isBreadCrumbs = true;
8131
8130
  }
8132
8131
  }
@@ -8163,75 +8162,72 @@ class BreadCrumbsComponent {
8163
8162
  let structures = {};
8164
8163
  data.forEach(result => {
8165
8164
  const item = {};
8166
- item["relativePath"] = result.relativePath;
8167
- item["name"] = result["name"];
8168
- item["pageId"] = result["pageId"];
8169
- item["tid"] = result["tid"].trim();
8170
- if (result["nodes"] !== undefined) {
8171
- item["nodes"] = this.getBreadCrumbsData(result["nodes"]);
8172
- }
8165
+ item["name"] = result["kpiName"];
8166
+ item["pageId"] = result.tagType == 'child' ? result["pageId"] : null;
8167
+ item["tid"] = result.tagType == 'child' ? result["childTid"].trim() : result["parentTid"].trim();
8173
8168
  this.kpi_names[result["pageId"]] = item["tid"];
8174
- structures[result["tid"]] = item;
8175
- this.kpi_structures[result["tid"]] = item;
8169
+ structures[result["childTid"]] = item;
8170
+ this.kpi_structures[result["childTid"]] = item;
8176
8171
  });
8177
8172
  return structures;
8178
8173
  }
8179
8174
  loadBreadCrumbs() {
8180
- let kpiRoot = this.kpiBrowserName ? "fmskpi" : "rakpi";
8181
- let kpiContainer;
8182
- if (this.kpiListData.length > 0 || this.kpiListData != undefined) {
8183
- kpiContainer = this.getBreadCrumbsData(this.kpiListData);
8184
- }
8185
- else {
8186
- kpiContainer = this.getBreadCrumbsData(this.commonService.allKpibrowserDetailContainer);
8187
- }
8188
- const kpiId = this.activatedRoute.snapshot.queryParams['pageId'];
8189
- const kpiTid = this.kpi_names[kpiId];
8175
+ debugger;
8176
+ const pageId = this.activatedRoute.snapshot.queryParams['pageId'];
8177
+ const kpiTid = this.kpi_names[pageId];
8190
8178
  const props = this.kpi_structures[kpiTid];
8191
- const propsList = props["relativePath"] + "/" + props["name"];
8179
+ const propsList = this.buildKpiPath(this.kpiListData, props["tid"]);
8192
8180
  this.breadcrumbList = propsList.split("/");
8193
8181
  if (this.location.path() !== "") {
8194
8182
  let link = {};
8195
8183
  this.breadcrumbLinksList = [];
8184
+ this.breadcrumbLinksList.unshift({
8185
+ name: "RA KPI Browser",
8186
+ url: "/apps/raKpi/rakpiBrowser",
8187
+ kpiName: "RA KPI Browser"
8188
+ });
8196
8189
  for (let i = 0; i < this.breadcrumbList.length; i++) {
8197
- if (i == 0) {
8198
- if (!this.kpiBrowserName) {
8199
- link = {
8200
- name: this.breadcrumbList[i],
8201
- url: "/apps/raKpi/rakpiBrowser",
8202
- kpiName: "RA KPI Browser",
8203
- };
8190
+ let returnId = "";
8191
+ for (let j = 0; j <= i; j++) {
8192
+ if (j != 0) {
8193
+ returnId += "/";
8204
8194
  }
8205
- else {
8206
- link = {
8207
- name: this.breadcrumbList[i],
8208
- url: "/apps/fmsKpi",
8209
- kpiName: "FMS KPI Browser",
8210
- };
8211
- }
8212
- }
8213
- else {
8214
- let returnId = "";
8215
- for (let j = 0; j <= i; j++) {
8216
- if (j != 0) {
8217
- returnId += "/";
8218
- }
8219
- returnId += this.breadcrumbList[j];
8220
- }
8221
- link = {
8222
- name: this.breadcrumbList[i],
8223
- url: this.breadcrumbLinksList[i - 1]["url"],
8224
- id: this.breadcrumbList[i],
8225
- kpiName: this.breadcrumbList[i],
8226
- returnId: returnId,
8227
- };
8228
- this.commonService.global_kpi_name = this.breadcrumbList[i];
8229
- }
8195
+ returnId += this.breadcrumbList[j];
8196
+ }
8197
+ link = {
8198
+ name: this.breadcrumbList[i],
8199
+ url: this.breadcrumbLinksList[i]["url"],
8200
+ id: this.breadcrumbList[i],
8201
+ kpiName: this.breadcrumbList[i],
8202
+ returnId: returnId,
8203
+ };
8204
+ this.commonService.global_kpi_name = this.breadcrumbList[i];
8230
8205
  this.breadcrumbLinksList.push(link);
8231
8206
  }
8232
8207
  this.count = this.breadcrumbList.length;
8233
8208
  }
8234
8209
  }
8210
+ buildKpiPath(kpiListData, startTid) {
8211
+ const path = [];
8212
+ const tidArray = this.buildTidArray(startTid);
8213
+ tidArray.forEach((tid, index) => {
8214
+ const kpi = kpiListData.find(kpi => index === 0
8215
+ ? kpi.parentTid === tid
8216
+ : kpi.childTid === tid);
8217
+ if (kpi) {
8218
+ path.push(kpi.kpiName);
8219
+ }
8220
+ });
8221
+ return path.join(" / ");
8222
+ }
8223
+ buildTidArray(startTid) {
8224
+ const parts = startTid.split(".");
8225
+ const result = [];
8226
+ for (let i = 0; i < parts.length; i++) {
8227
+ result.push(parts.slice(0, i + 1).join("."));
8228
+ }
8229
+ return result;
8230
+ }
8235
8231
  }
8236
8232
  BreadCrumbsComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: BreadCrumbsComponent, deps: [{ token: i4$2.Location }, { token: i2.Router }, { token: i1.HttpClient }, { token: i2.ActivatedRoute }, { token: CommonService }], target: i0.ɵɵFactoryTarget.Component });
8237
8233
  BreadCrumbsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: BreadCrumbsComponent, selector: "gamma-bread-crumbs", inputs: { kpi_data_container: "kpi_data_container" }, ngImport: i0, template: "<nav class=\"flex mt-1\" aria-label=\"Breadcrumb\" *ngIf=\"isBreadCrumbs\">\n <ol class=\"inline-flex items-center space-x-1 md:space-x-3\">\n <li class=\"inline-flex items-center cursor-pointer\" *ngFor=\"let breadcrumbLabel of breadcrumbLinksList;\">\n <a [routerLink]=\"breadcrumbLabel.url\" [queryParams]=\"{returnId: breadcrumbLabel.returnId }\"\n class=\"inline-flex items-center text-sm font-medium text-gray-700 hover:text-gray-900 dark:text-gray-400 dark:hover:text-white\">\n <svg class=\"w-6 h-6 text-gray-400\" fill=\"currentColor\" viewBox=\"0 0 20 20\"\n xmlns=\"http://www.w3.org/2000/svg\">\n <path fill-rule=\"evenodd\"\n d=\"M7.293 14.707a1 1 0 010-1.414L10.586 10 7.293 6.707a1 1 0 011.414-1.414l4 4a1 1 0 010 1.414l-4 4a1 1 0 01-1.414 0z\"\n clip-rule=\"evenodd\"></path>\n </svg>\n {{breadcrumbLabel.kpiName}}\n </a>\n </li>\n </ol>\n</nav>", styles: [".breadcrumb{padding:0!important;margin-bottom:0!important;font-weight:400;font-size:12px}\n"], dependencies: [{ kind: "directive", type: i4$2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i4$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.RouterLinkWithHref, selector: "a[routerLink],area[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "preserveFragment", "skipLocationChange", "replaceUrl", "state", "relativeTo", "routerLink"] }] });
@@ -13275,25 +13271,25 @@ class ApplicationCreateMenuComponent {
13275
13271
  ngOnInit() {
13276
13272
  let menuId = this.activatedRoute.snapshot.queryParams['menuId'];
13277
13273
  let contentType = this.activatedRoute.snapshot.queryParams['contentType'];
13278
- if (contentType == "edit") {
13274
+ if (menuId && contentType == "edit") {
13279
13275
  this.service.getAppMenuConfigById(menuId).subscribe({
13280
13276
  next: (data) => {
13281
13277
  this.menuObject = data;
13282
13278
  this.selectedQueryParamStr = (data['queryParams'] && data['queryParams']['pageId']) ? data['queryParams']['pageId'] : "";
13283
13279
  this.userOptionContainer = (data['permissions'] && data['permissions'].length !== 0) ? data['permissions'] : [];
13284
13280
  this.isContentType = true;
13281
+ this.getParentMenuList();
13285
13282
  }, error: (err) => {
13286
13283
  }
13287
13284
  });
13288
13285
  }
13289
- this.getParentMenuList();
13290
13286
  }
13291
13287
  getParentMenuList() {
13292
13288
  this.paparentMenuDatasource = [];
13293
13289
  this.service.listAppMenuConfigs().subscribe({
13294
13290
  next: (data) => {
13295
13291
  data.forEach(element => {
13296
- if (element.type == "collapsable") {
13292
+ if (element.type == "collapsable" || element.menuType == "parent") {
13297
13293
  let obj = {};
13298
13294
  obj = {
13299
13295
  parentMenuTid: element.parentMenuTid,
@@ -13304,6 +13300,7 @@ class ApplicationCreateMenuComponent {
13304
13300
  this.paparentMenuDatasource.push(obj);
13305
13301
  }
13306
13302
  });
13303
+ debugger;
13307
13304
  if (this.menuObject.menuId !== "" && this.menuObject.menuType == "parent") {
13308
13305
  const menu_object = this.paparentMenuDatasource.filter(menu => menu.menuId == this.menuObject.menuId);
13309
13306
  this.defaultSelectedParent = menu_object[0].menuId;
@@ -18017,6 +18014,14 @@ class KpiWithSingleLayoutService {
18017
18014
  return response;
18018
18015
  }), catchError(this.handleError));
18019
18016
  }
18017
+ listKpiEntryConfigs() {
18018
+ const apiUrl = this.environment.appUrl + this.environment.apiVersion + this.environment.packageBasePath + '/listKpiEntryConfigs?caller=app';
18019
+ return this.http
18020
+ .get(apiUrl, { withCredentials: true })
18021
+ .pipe(map((response) => {
18022
+ return response;
18023
+ }), catchError(this.handleError));
18024
+ }
18020
18025
  }
18021
18026
  KpiWithSingleLayoutService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: KpiWithSingleLayoutService, deps: [{ token: i1.HttpClient }, { token: APP_ENVIRONMENT }], target: i0.ɵɵFactoryTarget.Injectable });
18022
18027
  KpiWithSingleLayoutService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: KpiWithSingleLayoutService, providedIn: "root" });
@@ -18529,6 +18534,37 @@ class PermissionHelper {
18529
18534
  }
18530
18535
  return false;
18531
18536
  }
18537
+ buildMenuTree(userName, kpiData) {
18538
+ let filteredMenus = kpiData;
18539
+ const menuMap = new Map();
18540
+ const menuTree = [];
18541
+ filteredMenus.forEach(menu => {
18542
+ if (!this.getPermissionEntity(menu.permissions))
18543
+ return;
18544
+ menuMap.set(menu.childTid || menu.parentTid, {
18545
+ id: menu.kpiId,
18546
+ title: menu.kpiName,
18547
+ icon: menu.icon,
18548
+ type: menu.kpiType,
18549
+ tagType: menu.tagType,
18550
+ visibility: menu.visibility,
18551
+ ...(menu.link && { link: menu.link.replace(/^\/+/, '') }),
18552
+ children: []
18553
+ });
18554
+ });
18555
+ filteredMenus.forEach(kpi => {
18556
+ if (kpi.parentTid && kpi.childTid) {
18557
+ const parent = menuMap.get(kpi.parentTid);
18558
+ if (parent) {
18559
+ parent.children.push(menuMap.get(kpi.childTid));
18560
+ }
18561
+ }
18562
+ else {
18563
+ menuTree.push(menuMap.get(kpi.parentTid));
18564
+ }
18565
+ });
18566
+ return menuTree;
18567
+ }
18532
18568
  }
18533
18569
  PermissionHelper.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: PermissionHelper, deps: [{ token: APP_SECURITY_PRINCIPAL }], target: i0.ɵɵFactoryTarget.Injectable });
18534
18570
  PermissionHelper.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: PermissionHelper, providedIn: 'root' });
@@ -18766,10 +18802,10 @@ class KpiWithDataSetTestComponent {
18766
18802
  this.isDefaultFilterParams = false;
18767
18803
  }
18768
18804
  ngOnInit() {
18769
- this.service.getlistKpiBrowser().subscribe({
18770
- next: ((data) => {
18771
- this.kpi_breadcrumbs_container = data;
18772
- })
18805
+ this.service.listKpiEntryConfigs().subscribe((data) => {
18806
+ this.kpi_breadcrumbs_container = data;
18807
+ }, err => {
18808
+ this.toastr.error('Unexpected Server Exception. Please contact System Admin.', 'KPI Config');
18773
18809
  });
18774
18810
  this.loadingModal = true;
18775
18811
  this.pageId = this.activatedRoute.snapshot.queryParams['pageId'];