@tsi-developpement/tsi-shared-ui 1.11.1 → 1.11.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm2022/lib/end-points/reporting-endpoints.mjs +3 -1
- package/esm2022/lib/models/reporting/report-template-response.mjs +1 -1
- package/esm2022/lib/services/reporting/reporting.service.mjs +4 -1
- package/esm2022/lib/tsi-components/manage-reporting/add-report-popup/add-report-popup.component.mjs +15 -3
- package/esm2022/lib/tsi-components/manage-reporting/manage-reporting.component.mjs +55 -3
- package/fesm2022/tsi-developpement-tsi-shared-ui.mjs +73 -4
- package/fesm2022/tsi-developpement-tsi-shared-ui.mjs.map +1 -1
- package/lib/end-points/reporting-endpoints.d.ts +2 -0
- package/lib/models/reporting/report-template-response.d.ts +1 -0
- package/lib/services/reporting/reporting.service.d.ts +1 -0
- package/lib/tsi-components/manage-reporting/add-report-popup/add-report-popup.component.d.ts +3 -0
- package/lib/tsi-components/manage-reporting/manage-reporting.component.d.ts +1 -0
- package/package.json +1 -1
|
@@ -502,6 +502,7 @@ const ReportingSegments = {
|
|
|
502
502
|
deleteDefaultReportTemplateFile: 'delete-default-report-template-file',
|
|
503
503
|
dashboardModule: 'dashboardmodule',
|
|
504
504
|
toggleSeedOnStartup: 'toggle-seed-on-startup',
|
|
505
|
+
duplicateReport: 'duplicate',
|
|
505
506
|
};
|
|
506
507
|
const ReportingEndpoints = {
|
|
507
508
|
addToBuiltInTemplate: (reportUid) => `${Segment.base}/${ReportingSegments.reporting}/${ReportingSegments.addReportToBuiltIn}/${reportUid}`,
|
|
@@ -528,6 +529,7 @@ const ReportingEndpoints = {
|
|
|
528
529
|
getReportDescriminator: (entityName, propertyName, propertyValue) => `${Segment.base}/${ReportingSegments.reporting}/${ReportingSegments.getReportDescriminator}/${entityName}/${propertyName}/${propertyValue}`,
|
|
529
530
|
getReportTemplateByModuleCode: (moduleCode) => `${Segment.reportingServiceBase}/api/${ReportingSegments.dashboardModule}/${moduleCode}`,
|
|
530
531
|
toggleSeedOnStartup: (formName, templateName) => `${Segment.base}/${ReportingSegments.reporting}/${ReportingSegments.toggleSeedOnStartup}/${formName}/${templateName}`,
|
|
532
|
+
duplicateReport: (uid) => `${Segment.reportingServiceBase}/api/${ReportingSegments.report}/${ReportingSegments.duplicateReport}/${uid}`,
|
|
531
533
|
};
|
|
532
534
|
|
|
533
535
|
const IdentityPlatformSegments = {
|
|
@@ -4504,6 +4506,9 @@ class ReportingService {
|
|
|
4504
4506
|
toggleSeedOnStartup(formName, templateName) {
|
|
4505
4507
|
return this.httpClient.post(ReportingEndpoints.toggleSeedOnStartup(formName, templateName), {});
|
|
4506
4508
|
}
|
|
4509
|
+
duplicateReport(uid, newName) {
|
|
4510
|
+
return this.httpClient.post(ReportingEndpoints.duplicateReport(uid), { newName });
|
|
4511
|
+
}
|
|
4507
4512
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: ReportingService, deps: [{ token: i1.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
4508
4513
|
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: ReportingService, providedIn: 'root' }); }
|
|
4509
4514
|
}
|
|
@@ -19022,6 +19027,12 @@ class AddReportPopupComponent extends TsiFormComponentBaseComponent {
|
|
|
19022
19027
|
&& !this.config.data?.fromEndpoint?.includes("getallpaged")
|
|
19023
19028
|
&& this.config.data?.fromEndpoint != undefined;
|
|
19024
19029
|
}
|
|
19030
|
+
get lockAllButName() {
|
|
19031
|
+
return this.mode === this.modes.duplicate;
|
|
19032
|
+
}
|
|
19033
|
+
get lockAllButDisplay() {
|
|
19034
|
+
return this.mode === this.modes.edit && this.isReadOnlySource;
|
|
19035
|
+
}
|
|
19025
19036
|
constructor(ref, reportingService, config, notificationService, dashboardModuleService, _confirm, _httpClient, _router) {
|
|
19026
19037
|
super(ref, config);
|
|
19027
19038
|
this.ref = ref;
|
|
@@ -19040,6 +19051,7 @@ class AddReportPopupComponent extends TsiFormComponentBaseComponent {
|
|
|
19040
19051
|
this.isGetByIdRequest = false;
|
|
19041
19052
|
this.modes = Modes;
|
|
19042
19053
|
this.isEditionPersonnalise = false;
|
|
19054
|
+
this.isReadOnlySource = false;
|
|
19043
19055
|
this.administrationEndpoints = AdministrationEndpoints;
|
|
19044
19056
|
this.selectedEndpoints = [];
|
|
19045
19057
|
this.endpointsOptions = [];
|
|
@@ -19074,6 +19086,7 @@ class AddReportPopupComponent extends TsiFormComponentBaseComponent {
|
|
|
19074
19086
|
this.report.formName = this.config.data.value.formName;
|
|
19075
19087
|
this.report.reportNameAbrege = this.config.data.value.shortName;
|
|
19076
19088
|
this.report.display = this.config.data.value.display;
|
|
19089
|
+
this.isReadOnlySource = this.config.data.value.isReadOnly === true;
|
|
19077
19090
|
if (this.enableMultiSelectEndpoints) {
|
|
19078
19091
|
this.endpointsOptions = this.report.endPointKey
|
|
19079
19092
|
? this.report.endPointKey.split(';').map(x => ({ label: x, value: x }))
|
|
@@ -19159,6 +19172,10 @@ class AddReportPopupComponent extends TsiFormComponentBaseComponent {
|
|
|
19159
19172
|
this.notificationService.warn("shared_reporting_report_endpoint_required");
|
|
19160
19173
|
return;
|
|
19161
19174
|
}
|
|
19175
|
+
if (this.mode === this.modes.duplicate || this.lockAllButDisplay) {
|
|
19176
|
+
this.hide(this.report);
|
|
19177
|
+
return;
|
|
19178
|
+
}
|
|
19162
19179
|
this._confirm
|
|
19163
19180
|
.confirm(this.l('shared_reporting_report_confirmRedirection'), undefined, (result) => {
|
|
19164
19181
|
if (result) {
|
|
@@ -19188,11 +19205,11 @@ class AddReportPopupComponent extends TsiFormComponentBaseComponent {
|
|
|
19188
19205
|
});
|
|
19189
19206
|
}
|
|
19190
19207
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: AddReportPopupComponent, deps: [{ token: i1$3.DynamicDialogRef }, { token: ReportingService }, { token: i1$3.DynamicDialogConfig }, { token: TsiNotificationService }, { token: DashboardModuleService }, { token: TsiConfirmationService }, { token: i1.HttpClient }, { token: i7$1.Router }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
19191
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.12", type: AddReportPopupComponent, selector: "app-add-report-popup", providers: [...appProviders], usesInheritance: true, ngImport: i0, template: "<tsi-form class=\"form-horizontal\" autocomplete=\"off\" (onSubmit)=\"save()\">\r\n <h4>\r\n <Tsi-Label [labelValue]=\"'Nouveau Rapport'\"></Tsi-Label>\r\n </h4>\r\n <p-panel header=\"Informations\">\r\n <div class=\"grid \">\r\n <!-- Type -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_type\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-9\">\r\n <Tsi-Search-Combo [disabled]=\"this.mode !== modes.create\" id-field=\"key\" label-field=\"value\"\r\n [(bind)]=\"report.reportType\" [datasource]=\"dataSource\">\r\n </Tsi-Search-Combo>\r\n </div>\r\n <!-- Nom du rapport -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_reportName\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-9\">\r\n <Tsi-Text-Box [inputName]=\"'reportName'\" [(inputField)]=\"report.reportName\"></Tsi-Text-Box>\r\n </div>\r\n <!-- Nom abr\u00E9g\u00E9 -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_reportNameAbrege\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-3\">\r\n <Tsi-Text-Box [inputName]=\"'reportNameAbrege'\" [(inputField)]=\"report.reportNameAbrege\"></Tsi-Text-Box>\r\n </div>\r\n <div class=\"flex col-6\">\r\n <!-- Ordre de tri -->\r\n <div class=\"flex gap-4 w-6\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_triOrdre\"></Tsi-Label>\r\n <Tsi-Integer [inputName]=\"'triOrdre'\" [(inputField)]=\"report.triOrdre\"></Tsi-Integer>\r\n </div>\r\n <!-- Afficher dashboard -->\r\n <div class=\"flex gap-4 w-6\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_display\"></Tsi-Label>\r\n <Tsi-CheckBox [inputName]=\"'display'\" [(inputField)]=\"report.display\"></Tsi-CheckBox>\r\n </div>\r\n </div>\r\n <!-- Module -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_Module\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-9\">\r\n <Tsi-Search-Combo id-field=\"code\" label-field=\"libelle\" [multiple]=\"false\" [(bind)]=\"report.module\"\r\n [datasource]=\"modules\" [isFiltered]=\"false\">\r\n </Tsi-Search-Combo>\r\n </div>\r\n <!-- Deuxi\u00E9me Impress -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_imppress\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-5\">\r\n <Tsi-Text-Box [disabled]=\"true\" [inputName]=\"'imppress'\" [(inputField)]=\"report.impress\"></Tsi-Text-Box>\r\n </div>\r\n <!-- Edition unique -->\r\n <div class=\"col-4 col-form-label flx\">\r\n <Tsi-CheckBox [inputName]=\"'EditionUnique'\" [(inputField)]=\"report.editionUnique\"></Tsi-CheckBox> \r\n <Tsi-Label labelValue=\"administration_edition_personnalise_EditionUnique\"></Tsi-Label>\r\n </div>\r\n <!-- Endpoint -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_endpoint\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-9\">\r\n <Tsi-Search-Combo *ngIf=\"!isReportForFiche && !enableMultiSelectEndpoints\" id-field=\"key\" label-field=\"value\"\r\n [disabled]=\"modes.edit === mode || isEditionPersonnalise === false\"\r\n (selectedLabelChange)=\"selectedEndpointChange($event)\" [(bind)]=\"report.endPointKey\"\r\n [elementSourceUrl]=\"administrationEndpoints.getApiAsKeyValuePair()\"\r\n [listSourceUrl]=\"administrationEndpoints.getAllApiAsKeyValuePair()\" [isFiltered]=\"true\">\r\n </Tsi-Search-Combo>\r\n\r\n <Tsi-Search-Combo *ngIf=\"customReportingMode && !enableMultiSelectEndpoints \" id-field=\"value\" label-field=\"value\"\r\n (selectedLabelChange)=\"selectedEndpointChange($event)\" [(bind)]=\"report.endPointKey\"\r\n [listSourceUrl]=\"administrationEndpoints.getAllApiAsKeyValuePairByBusinessClassName(this.reportBusinessClass)\"\r\n [isFiltered]=\"false\">\r\n </Tsi-Search-Combo>\r\n\r\n <Tsi-Search-Combo *ngIf=\"isReportForFiche\"\r\n id-field=\"value\"\r\n label-field=\"value\"\r\n [(bind)]=\"selectedEndpoints\"\r\n [listSourceUrl]=\"administrationEndpoints.getAllApiAsKeyValuePairByBusinessClassName(this.reportBusinessClass)\"\r\n [isFiltered]=\"false\"\r\n [multiple]=\"true\"\r\n (selectedLabelChange)=\"selectedEndpointChange($event)\">\r\n </Tsi-Search-Combo>\r\n\r\n <p-multiSelect *ngIf=\"!isReportForFiche && enableMultiSelectEndpoints\" [options]=\"endpointsOptions\" [(ngModel)]=\"selectedEndpoints\"\r\n selectedItemsLabel=\"{0} {{ 'endpoint_selected' | localize }}\" optionLabel=\"value\"\r\n optionValue=\"value\"\r\n [style]=\"{'min-width': '180px'}\" placeholder=\"{{ 'shared_reporting_choose_endpoints' | localize }}\"\r\n (onPanelShow)=\"handleOpen()\"\r\n [filter]=\"true\"\r\n (onFilter)=\"onFilter($event)\"\r\n display=\"chip\"\r\n class=\"rounded-multiselect\">\r\n <ng-template let-option pTemplate=\"item\">\r\n <div class=\"flex items-center gap-2\">\r\n <span>{{ option.value}}</span>\r\n </div>\r\n </ng-template>\r\n </p-multiSelect>\r\n </div>\r\n\r\n\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_formName\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-6\">\r\n <Tsi-Text-Box [disabled]=\"true\" [inputName]=\"'formName'\"\r\n [(inputField)]=\"report.formName\"></Tsi-Text-Box>\r\n </div>\r\n <!-- Param -->\r\n <div *ngIf=\"isGetByIdRequest\" class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_param\"></Tsi-Label>\r\n </div>\r\n <div *ngIf=\"isGetByIdRequest\" class=\"col-9\">\r\n <Tsi-Text-Box [inputName]=\"'param'\" [(inputField)]=\"report.param\"></Tsi-Text-Box>\r\n </div>\r\n </div>\r\n </p-panel>\r\n <br />\r\n <p-panel header=\"Configuration Pivot Grid\">\r\n <div class=\"grid \">\r\n <!-- Class or view -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label [labelValue]=\"'Class or view'\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-9\">\r\n <Tsi-Text-Box [inputName]=\"'dddd'\"></Tsi-Text-Box>\r\n </div>\r\n <!-- Query -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label [labelValue]=\"'Query'\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-9 col-form-label\">\r\n <Tsi-Text-Area [rows]=\"2\"></Tsi-Text-Area>\r\n </div>\r\n </div>\r\n </p-panel>\r\n\r\n <Tsi-Modal-Footer [cancelDisabled]=\"saving\" [saveDisabled]=\"saving\" (onCancelClick)=\"hide()\" \r\n [showSaveAndCloseButton]=\"false\"></Tsi-Modal-Footer>\r\n</tsi-form>", styles: [".flx{display:flex;justify-content:center;align-items:center}::ng-deep .rounded-multiselect .p-multiselect{border-radius:12px!important}::ng-deep .rounded-multiselect .p-multiselect-label{border-radius:12px!important}\n"], dependencies: [{ kind: "directive", type: i1$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i2$1.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "component", type: i11.MultiSelect, selector: "p-multiSelect", inputs: ["id", "ariaLabel", "style", "styleClass", "panelStyle", "panelStyleClass", "inputId", "disabled", "readonly", "group", "filter", "filterPlaceHolder", "filterLocale", "overlayVisible", "tabindex", "variant", "appendTo", "dataKey", "name", "ariaLabelledBy", "displaySelectedLabel", "maxSelectedLabels", "selectionLimit", "selectedItemsLabel", "showToggleAll", "emptyFilterMessage", "emptyMessage", "resetFilterOnHide", "dropdownIcon", "optionLabel", "optionValue", "optionDisabled", "optionGroupLabel", "optionGroupChildren", "showHeader", "filterBy", "scrollHeight", "lazy", "virtualScroll", "loading", "virtualScrollItemSize", "loadingIcon", "virtualScrollOptions", "overlayOptions", "ariaFilterLabel", "filterMatchMode", "tooltip", "tooltipPosition", "tooltipPositionStyle", "tooltipStyleClass", "autofocusFilter", "display", "autocomplete", "showClear", "autofocus", "autoZIndex", "baseZIndex", "showTransitionOptions", "hideTransitionOptions", "defaultLabel", "placeholder", "options", "filterValue", "itemSize", "selectAll", "focusOnHover", "filterFields", "selectOnFocus", "autoOptionFocus"], outputs: ["onChange", "onFilter", "onFocus", "onBlur", "onClick", "onClear", "onPanelShow", "onPanelHide", "onLazyLoad", "onRemove", "onSelectAllChange"] }, { kind: "component", type: i12.Panel, selector: "p-panel", inputs: ["toggleable", "header", "collapsed", "style", "styleClass", "iconPos", "expandIcon", "collapseIcon", "showHeader", "toggler", "transitionOptions"], outputs: ["collapsedChange", "onBeforeToggle", "onAfterToggle"] }, { kind: "component", type: TsiSearchComboComponent, selector: "Tsi-Search-Combo", inputs: ["elementSourceUrl", "listSourceUrl", "listSourceParams", "id-field", "label-field", "multiple", "sort", "showClear", "reloadDataSource", "isFiltered", "selectedLabel", "maxWidth", "businessClass", "searchDebounceTime", "comboType", "statusMetadata", "currentRowItem", "datasource", "bind", "maxSelectedLabels", "tooltipMaxDisplayedItems", "bindMode", "showSearchButton", "showAddButton", "showConsultButton", "showUpdateButton"], outputs: ["bindChange", "datasource-loaded", "init", "isLoaded", "selectedLabelChange", "onClick", "onSearchButtonClick", "selectionChange"] }, { kind: "component", type: TsiCheckboxComponent, selector: "Tsi-CheckBox", inputs: ["class", "isBinary", "checked", "tooltipText", "tooltipPosition"], outputs: ["inputFieldChange", "checkedChange"] }, { kind: "component", type: TsiIntegerComponent, selector: "Tsi-Integer", inputs: ["class", "minValue", "maxValue", "delayChangeTime"], outputs: ["newItemEvent", "inputFieldChange"] }, { kind: "component", type: TsiTextAreaComponent, selector: "Tsi-Text-Area", inputs: ["rows", "cols"], outputs: ["newItemEvent", "inputFieldChange"] }, { kind: "component", type: TsiTextBoxComponent, selector: "Tsi-Text-Box", inputs: ["textBoxType", "autocomplete"], outputs: ["newItemEvent", "inputFieldChange"] }, { kind: "component", type: TsiLabelComponent, selector: "Tsi-Label", inputs: ["labelValue", "styleClass", "infoText"] }, { kind: "component", type: TsiModalFooterComponent, selector: "Tsi-Modal-Footer", inputs: ["cancelDisabled", "saveDisabled", "cancelLabel", "saveLabel", "isConsult", "isDuplicate", "isOnlyCreate", "additionalButtonLabel", "additionalButtonIcon", "additionalButtonDisabled", "showAdditionalButton", "showSaveAndCloseButton", "mode"], outputs: ["onCancelClick", "onSaveClick", "onAdditionalButtonClick"] }, { kind: "component", type: TsiFormComponent, selector: "tsi-form", inputs: ["class", "autocomplete", "optionalEndpoints", "disabled", "isLoading", "modalSize", "showManageWorkflowButton", "formEndpoint", "formName", "isReportingToolbarDisabled", "isCreateOnly", "statusInputDisabled"], outputs: ["onSave", "openWorkflow", "onSubmit", "onSubmitFormWorkflowConfiguration", "formRefChange", "onStatusChange"] }, { kind: "pipe", type: LocalizePipe, name: "localize" }] }); }
|
|
19208
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.12", type: AddReportPopupComponent, selector: "app-add-report-popup", providers: [...appProviders], usesInheritance: true, ngImport: i0, template: "<tsi-form class=\"form-horizontal\" autocomplete=\"off\" (onSubmit)=\"save()\">\r\n <h4>\r\n <Tsi-Label [labelValue]=\"config.data?.title ?? 'Nouveau Rapport'\"></Tsi-Label>\r\n </h4>\r\n <p-panel header=\"Informations\">\r\n <div class=\"grid \">\r\n <!-- Type -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_type\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-9\">\r\n <Tsi-Search-Combo [disabled]=\"this.mode !== modes.create\" id-field=\"key\" label-field=\"value\"\r\n [(bind)]=\"report.reportType\" [datasource]=\"dataSource\">\r\n </Tsi-Search-Combo>\r\n </div>\r\n <!-- Nom du rapport -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_reportName\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-9\">\r\n <Tsi-Text-Box [disabled]=\"lockAllButDisplay\" [inputName]=\"'reportName'\" [(inputField)]=\"report.reportName\"></Tsi-Text-Box>\r\n </div>\r\n <!-- Nom abr\u00E9g\u00E9 -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_reportNameAbrege\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-3\">\r\n <Tsi-Text-Box [disabled]=\"lockAllButName || lockAllButDisplay\" [inputName]=\"'reportNameAbrege'\" [(inputField)]=\"report.reportNameAbrege\"></Tsi-Text-Box>\r\n </div>\r\n <div class=\"flex col-6\">\r\n <!-- Ordre de tri -->\r\n <div class=\"flex gap-4 w-6\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_triOrdre\"></Tsi-Label>\r\n <Tsi-Integer [disabled]=\"lockAllButName || lockAllButDisplay\" [inputName]=\"'triOrdre'\" [(inputField)]=\"report.triOrdre\"></Tsi-Integer>\r\n </div>\r\n <!-- Afficher dashboard -->\r\n <div class=\"flex gap-4 w-6\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_display\"></Tsi-Label>\r\n <Tsi-CheckBox [disabled]=\"lockAllButName\" [inputName]=\"'display'\" [(inputField)]=\"report.display\"></Tsi-CheckBox>\r\n </div>\r\n </div>\r\n <!-- Module -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_Module\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-9\">\r\n <Tsi-Search-Combo [disabled]=\"lockAllButName || lockAllButDisplay\" id-field=\"code\" label-field=\"libelle\" [multiple]=\"false\" [(bind)]=\"report.module\"\r\n [datasource]=\"modules\" [isFiltered]=\"false\">\r\n </Tsi-Search-Combo>\r\n </div>\r\n <!-- Deuxi\u00E9me Impress -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_imppress\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-5\">\r\n <Tsi-Text-Box [disabled]=\"true\" [inputName]=\"'imppress'\" [(inputField)]=\"report.impress\"></Tsi-Text-Box>\r\n </div>\r\n <!-- Edition unique -->\r\n <div class=\"col-4 col-form-label flx\">\r\n <Tsi-CheckBox [disabled]=\"lockAllButName || lockAllButDisplay\" [inputName]=\"'EditionUnique'\" [(inputField)]=\"report.editionUnique\"></Tsi-CheckBox> \r\n <Tsi-Label labelValue=\"administration_edition_personnalise_EditionUnique\"></Tsi-Label>\r\n </div>\r\n <!-- Endpoint -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_endpoint\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-9\">\r\n <Tsi-Search-Combo *ngIf=\"!isReportForFiche && !enableMultiSelectEndpoints\" id-field=\"key\" label-field=\"value\"\r\n [disabled]=\"modes.edit === mode || isEditionPersonnalise === false || lockAllButName || lockAllButDisplay\"\r\n (selectedLabelChange)=\"selectedEndpointChange($event)\" [(bind)]=\"report.endPointKey\"\r\n [elementSourceUrl]=\"administrationEndpoints.getApiAsKeyValuePair()\"\r\n [listSourceUrl]=\"administrationEndpoints.getAllApiAsKeyValuePair()\" [isFiltered]=\"true\">\r\n </Tsi-Search-Combo>\r\n\r\n <Tsi-Search-Combo *ngIf=\"customReportingMode && !enableMultiSelectEndpoints \" id-field=\"value\" label-field=\"value\"\r\n [disabled]=\"lockAllButName || lockAllButDisplay\"\r\n (selectedLabelChange)=\"selectedEndpointChange($event)\" [(bind)]=\"report.endPointKey\"\r\n [listSourceUrl]=\"administrationEndpoints.getAllApiAsKeyValuePairByBusinessClassName(this.reportBusinessClass)\"\r\n [isFiltered]=\"false\">\r\n </Tsi-Search-Combo>\r\n\r\n <Tsi-Search-Combo *ngIf=\"isReportForFiche\"\r\n id-field=\"value\"\r\n label-field=\"value\"\r\n [disabled]=\"lockAllButName || lockAllButDisplay\"\r\n [(bind)]=\"selectedEndpoints\"\r\n [listSourceUrl]=\"administrationEndpoints.getAllApiAsKeyValuePairByBusinessClassName(this.reportBusinessClass)\"\r\n [isFiltered]=\"false\"\r\n [multiple]=\"true\"\r\n (selectedLabelChange)=\"selectedEndpointChange($event)\">\r\n </Tsi-Search-Combo>\r\n\r\n <p-multiSelect *ngIf=\"!isReportForFiche && enableMultiSelectEndpoints\" [options]=\"endpointsOptions\" [(ngModel)]=\"selectedEndpoints\"\r\n [disabled]=\"lockAllButName || lockAllButDisplay\"\r\n selectedItemsLabel=\"{0} {{ 'endpoint_selected' | localize }}\" optionLabel=\"value\"\r\n optionValue=\"value\"\r\n [style]=\"{'min-width': '180px'}\" placeholder=\"{{ 'shared_reporting_choose_endpoints' | localize }}\"\r\n (onPanelShow)=\"handleOpen()\"\r\n [filter]=\"true\"\r\n (onFilter)=\"onFilter($event)\"\r\n display=\"chip\"\r\n class=\"rounded-multiselect\">\r\n <ng-template let-option pTemplate=\"item\">\r\n <div class=\"flex items-center gap-2\">\r\n <span>{{ option.value}}</span>\r\n </div>\r\n </ng-template>\r\n </p-multiSelect>\r\n </div>\r\n\r\n\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_formName\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-6\">\r\n <Tsi-Text-Box [disabled]=\"true\" [inputName]=\"'formName'\"\r\n [(inputField)]=\"report.formName\"></Tsi-Text-Box>\r\n </div>\r\n <!-- Param -->\r\n <div *ngIf=\"isGetByIdRequest\" class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_param\"></Tsi-Label>\r\n </div>\r\n <div *ngIf=\"isGetByIdRequest\" class=\"col-9\">\r\n <Tsi-Text-Box [disabled]=\"lockAllButName || lockAllButDisplay\" [inputName]=\"'param'\" [(inputField)]=\"report.param\"></Tsi-Text-Box>\r\n </div>\r\n </div>\r\n </p-panel>\r\n <br />\r\n <p-panel header=\"Configuration Pivot Grid\">\r\n <div class=\"grid \">\r\n <!-- Class or view -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label [labelValue]=\"'Class or view'\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-9\">\r\n <Tsi-Text-Box [inputName]=\"'dddd'\"></Tsi-Text-Box>\r\n </div>\r\n <!-- Query -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label [labelValue]=\"'Query'\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-9 col-form-label\">\r\n <Tsi-Text-Area [rows]=\"2\"></Tsi-Text-Area>\r\n </div>\r\n </div>\r\n </p-panel>\r\n\r\n <Tsi-Modal-Footer [cancelDisabled]=\"saving\" [saveDisabled]=\"saving\" (onCancelClick)=\"hide()\" \r\n [showSaveAndCloseButton]=\"false\"></Tsi-Modal-Footer>\r\n</tsi-form>", styles: [".flx{display:flex;justify-content:center;align-items:center}::ng-deep .rounded-multiselect .p-multiselect{border-radius:12px!important}::ng-deep .rounded-multiselect .p-multiselect-label{border-radius:12px!important}\n"], dependencies: [{ kind: "directive", type: i1$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i2$1.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "component", type: i11.MultiSelect, selector: "p-multiSelect", inputs: ["id", "ariaLabel", "style", "styleClass", "panelStyle", "panelStyleClass", "inputId", "disabled", "readonly", "group", "filter", "filterPlaceHolder", "filterLocale", "overlayVisible", "tabindex", "variant", "appendTo", "dataKey", "name", "ariaLabelledBy", "displaySelectedLabel", "maxSelectedLabels", "selectionLimit", "selectedItemsLabel", "showToggleAll", "emptyFilterMessage", "emptyMessage", "resetFilterOnHide", "dropdownIcon", "optionLabel", "optionValue", "optionDisabled", "optionGroupLabel", "optionGroupChildren", "showHeader", "filterBy", "scrollHeight", "lazy", "virtualScroll", "loading", "virtualScrollItemSize", "loadingIcon", "virtualScrollOptions", "overlayOptions", "ariaFilterLabel", "filterMatchMode", "tooltip", "tooltipPosition", "tooltipPositionStyle", "tooltipStyleClass", "autofocusFilter", "display", "autocomplete", "showClear", "autofocus", "autoZIndex", "baseZIndex", "showTransitionOptions", "hideTransitionOptions", "defaultLabel", "placeholder", "options", "filterValue", "itemSize", "selectAll", "focusOnHover", "filterFields", "selectOnFocus", "autoOptionFocus"], outputs: ["onChange", "onFilter", "onFocus", "onBlur", "onClick", "onClear", "onPanelShow", "onPanelHide", "onLazyLoad", "onRemove", "onSelectAllChange"] }, { kind: "component", type: i12.Panel, selector: "p-panel", inputs: ["toggleable", "header", "collapsed", "style", "styleClass", "iconPos", "expandIcon", "collapseIcon", "showHeader", "toggler", "transitionOptions"], outputs: ["collapsedChange", "onBeforeToggle", "onAfterToggle"] }, { kind: "component", type: TsiSearchComboComponent, selector: "Tsi-Search-Combo", inputs: ["elementSourceUrl", "listSourceUrl", "listSourceParams", "id-field", "label-field", "multiple", "sort", "showClear", "reloadDataSource", "isFiltered", "selectedLabel", "maxWidth", "businessClass", "searchDebounceTime", "comboType", "statusMetadata", "currentRowItem", "datasource", "bind", "maxSelectedLabels", "tooltipMaxDisplayedItems", "bindMode", "showSearchButton", "showAddButton", "showConsultButton", "showUpdateButton"], outputs: ["bindChange", "datasource-loaded", "init", "isLoaded", "selectedLabelChange", "onClick", "onSearchButtonClick", "selectionChange"] }, { kind: "component", type: TsiCheckboxComponent, selector: "Tsi-CheckBox", inputs: ["class", "isBinary", "checked", "tooltipText", "tooltipPosition"], outputs: ["inputFieldChange", "checkedChange"] }, { kind: "component", type: TsiIntegerComponent, selector: "Tsi-Integer", inputs: ["class", "minValue", "maxValue", "delayChangeTime"], outputs: ["newItemEvent", "inputFieldChange"] }, { kind: "component", type: TsiTextAreaComponent, selector: "Tsi-Text-Area", inputs: ["rows", "cols"], outputs: ["newItemEvent", "inputFieldChange"] }, { kind: "component", type: TsiTextBoxComponent, selector: "Tsi-Text-Box", inputs: ["textBoxType", "autocomplete"], outputs: ["newItemEvent", "inputFieldChange"] }, { kind: "component", type: TsiLabelComponent, selector: "Tsi-Label", inputs: ["labelValue", "styleClass", "infoText"] }, { kind: "component", type: TsiModalFooterComponent, selector: "Tsi-Modal-Footer", inputs: ["cancelDisabled", "saveDisabled", "cancelLabel", "saveLabel", "isConsult", "isDuplicate", "isOnlyCreate", "additionalButtonLabel", "additionalButtonIcon", "additionalButtonDisabled", "showAdditionalButton", "showSaveAndCloseButton", "mode"], outputs: ["onCancelClick", "onSaveClick", "onAdditionalButtonClick"] }, { kind: "component", type: TsiFormComponent, selector: "tsi-form", inputs: ["class", "autocomplete", "optionalEndpoints", "disabled", "isLoading", "modalSize", "showManageWorkflowButton", "formEndpoint", "formName", "isReportingToolbarDisabled", "isCreateOnly", "statusInputDisabled"], outputs: ["onSave", "openWorkflow", "onSubmit", "onSubmitFormWorkflowConfiguration", "formRefChange", "onStatusChange"] }, { kind: "pipe", type: LocalizePipe, name: "localize" }] }); }
|
|
19192
19209
|
}
|
|
19193
19210
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: AddReportPopupComponent, decorators: [{
|
|
19194
19211
|
type: Component,
|
|
19195
|
-
args: [{ selector: 'app-add-report-popup', providers: [...appProviders], template: "<tsi-form class=\"form-horizontal\" autocomplete=\"off\" (onSubmit)=\"save()\">\r\n <h4>\r\n <Tsi-Label [labelValue]=\"'Nouveau Rapport'\"></Tsi-Label>\r\n </h4>\r\n <p-panel header=\"Informations\">\r\n <div class=\"grid \">\r\n <!-- Type -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_type\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-9\">\r\n <Tsi-Search-Combo [disabled]=\"this.mode !== modes.create\" id-field=\"key\" label-field=\"value\"\r\n [(bind)]=\"report.reportType\" [datasource]=\"dataSource\">\r\n </Tsi-Search-Combo>\r\n </div>\r\n <!-- Nom du rapport -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_reportName\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-9\">\r\n <Tsi-Text-Box [inputName]=\"'reportName'\" [(inputField)]=\"report.reportName\"></Tsi-Text-Box>\r\n </div>\r\n <!-- Nom abr\u00E9g\u00E9 -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_reportNameAbrege\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-3\">\r\n <Tsi-Text-Box [inputName]=\"'reportNameAbrege'\" [(inputField)]=\"report.reportNameAbrege\"></Tsi-Text-Box>\r\n </div>\r\n <div class=\"flex col-6\">\r\n <!-- Ordre de tri -->\r\n <div class=\"flex gap-4 w-6\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_triOrdre\"></Tsi-Label>\r\n <Tsi-Integer [inputName]=\"'triOrdre'\" [(inputField)]=\"report.triOrdre\"></Tsi-Integer>\r\n </div>\r\n <!-- Afficher dashboard -->\r\n <div class=\"flex gap-4 w-6\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_display\"></Tsi-Label>\r\n <Tsi-CheckBox [inputName]=\"'display'\" [(inputField)]=\"report.display\"></Tsi-CheckBox>\r\n </div>\r\n </div>\r\n <!-- Module -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_Module\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-9\">\r\n <Tsi-Search-Combo id-field=\"code\" label-field=\"libelle\" [multiple]=\"false\" [(bind)]=\"report.module\"\r\n [datasource]=\"modules\" [isFiltered]=\"false\">\r\n </Tsi-Search-Combo>\r\n </div>\r\n <!-- Deuxi\u00E9me Impress -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_imppress\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-5\">\r\n <Tsi-Text-Box [disabled]=\"true\" [inputName]=\"'imppress'\" [(inputField)]=\"report.impress\"></Tsi-Text-Box>\r\n </div>\r\n <!-- Edition unique -->\r\n <div class=\"col-4 col-form-label flx\">\r\n <Tsi-CheckBox [inputName]=\"'EditionUnique'\" [(inputField)]=\"report.editionUnique\"></Tsi-CheckBox> \r\n <Tsi-Label labelValue=\"administration_edition_personnalise_EditionUnique\"></Tsi-Label>\r\n </div>\r\n <!-- Endpoint -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_endpoint\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-9\">\r\n <Tsi-Search-Combo *ngIf=\"!isReportForFiche && !enableMultiSelectEndpoints\" id-field=\"key\" label-field=\"value\"\r\n [disabled]=\"modes.edit === mode || isEditionPersonnalise === false\"\r\n (selectedLabelChange)=\"selectedEndpointChange($event)\" [(bind)]=\"report.endPointKey\"\r\n [elementSourceUrl]=\"administrationEndpoints.getApiAsKeyValuePair()\"\r\n [listSourceUrl]=\"administrationEndpoints.getAllApiAsKeyValuePair()\" [isFiltered]=\"true\">\r\n </Tsi-Search-Combo>\r\n\r\n <Tsi-Search-Combo *ngIf=\"customReportingMode && !enableMultiSelectEndpoints \" id-field=\"value\" label-field=\"value\"\r\n (selectedLabelChange)=\"selectedEndpointChange($event)\" [(bind)]=\"report.endPointKey\"\r\n [listSourceUrl]=\"administrationEndpoints.getAllApiAsKeyValuePairByBusinessClassName(this.reportBusinessClass)\"\r\n [isFiltered]=\"false\">\r\n </Tsi-Search-Combo>\r\n\r\n <Tsi-Search-Combo *ngIf=\"isReportForFiche\"\r\n id-field=\"value\"\r\n label-field=\"value\"\r\n [(bind)]=\"selectedEndpoints\"\r\n [listSourceUrl]=\"administrationEndpoints.getAllApiAsKeyValuePairByBusinessClassName(this.reportBusinessClass)\"\r\n [isFiltered]=\"false\"\r\n [multiple]=\"true\"\r\n (selectedLabelChange)=\"selectedEndpointChange($event)\">\r\n </Tsi-Search-Combo>\r\n\r\n <p-multiSelect *ngIf=\"!isReportForFiche && enableMultiSelectEndpoints\" [options]=\"endpointsOptions\" [(ngModel)]=\"selectedEndpoints\"\r\n selectedItemsLabel=\"{0} {{ 'endpoint_selected' | localize }}\" optionLabel=\"value\"\r\n optionValue=\"value\"\r\n [style]=\"{'min-width': '180px'}\" placeholder=\"{{ 'shared_reporting_choose_endpoints' | localize }}\"\r\n (onPanelShow)=\"handleOpen()\"\r\n [filter]=\"true\"\r\n (onFilter)=\"onFilter($event)\"\r\n display=\"chip\"\r\n class=\"rounded-multiselect\">\r\n <ng-template let-option pTemplate=\"item\">\r\n <div class=\"flex items-center gap-2\">\r\n <span>{{ option.value}}</span>\r\n </div>\r\n </ng-template>\r\n </p-multiSelect>\r\n </div>\r\n\r\n\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_formName\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-6\">\r\n <Tsi-Text-Box [disabled]=\"true\" [inputName]=\"'formName'\"\r\n [(inputField)]=\"report.formName\"></Tsi-Text-Box>\r\n </div>\r\n <!-- Param -->\r\n <div *ngIf=\"isGetByIdRequest\" class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_param\"></Tsi-Label>\r\n </div>\r\n <div *ngIf=\"isGetByIdRequest\" class=\"col-9\">\r\n <Tsi-Text-Box [inputName]=\"'param'\" [(inputField)]=\"report.param\"></Tsi-Text-Box>\r\n </div>\r\n </div>\r\n </p-panel>\r\n <br />\r\n <p-panel header=\"Configuration Pivot Grid\">\r\n <div class=\"grid \">\r\n <!-- Class or view -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label [labelValue]=\"'Class or view'\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-9\">\r\n <Tsi-Text-Box [inputName]=\"'dddd'\"></Tsi-Text-Box>\r\n </div>\r\n <!-- Query -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label [labelValue]=\"'Query'\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-9 col-form-label\">\r\n <Tsi-Text-Area [rows]=\"2\"></Tsi-Text-Area>\r\n </div>\r\n </div>\r\n </p-panel>\r\n\r\n <Tsi-Modal-Footer [cancelDisabled]=\"saving\" [saveDisabled]=\"saving\" (onCancelClick)=\"hide()\" \r\n [showSaveAndCloseButton]=\"false\"></Tsi-Modal-Footer>\r\n</tsi-form>", styles: [".flx{display:flex;justify-content:center;align-items:center}::ng-deep .rounded-multiselect .p-multiselect{border-radius:12px!important}::ng-deep .rounded-multiselect .p-multiselect-label{border-radius:12px!important}\n"] }]
|
|
19212
|
+
args: [{ selector: 'app-add-report-popup', providers: [...appProviders], template: "<tsi-form class=\"form-horizontal\" autocomplete=\"off\" (onSubmit)=\"save()\">\r\n <h4>\r\n <Tsi-Label [labelValue]=\"config.data?.title ?? 'Nouveau Rapport'\"></Tsi-Label>\r\n </h4>\r\n <p-panel header=\"Informations\">\r\n <div class=\"grid \">\r\n <!-- Type -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_type\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-9\">\r\n <Tsi-Search-Combo [disabled]=\"this.mode !== modes.create\" id-field=\"key\" label-field=\"value\"\r\n [(bind)]=\"report.reportType\" [datasource]=\"dataSource\">\r\n </Tsi-Search-Combo>\r\n </div>\r\n <!-- Nom du rapport -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_reportName\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-9\">\r\n <Tsi-Text-Box [disabled]=\"lockAllButDisplay\" [inputName]=\"'reportName'\" [(inputField)]=\"report.reportName\"></Tsi-Text-Box>\r\n </div>\r\n <!-- Nom abr\u00E9g\u00E9 -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_reportNameAbrege\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-3\">\r\n <Tsi-Text-Box [disabled]=\"lockAllButName || lockAllButDisplay\" [inputName]=\"'reportNameAbrege'\" [(inputField)]=\"report.reportNameAbrege\"></Tsi-Text-Box>\r\n </div>\r\n <div class=\"flex col-6\">\r\n <!-- Ordre de tri -->\r\n <div class=\"flex gap-4 w-6\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_triOrdre\"></Tsi-Label>\r\n <Tsi-Integer [disabled]=\"lockAllButName || lockAllButDisplay\" [inputName]=\"'triOrdre'\" [(inputField)]=\"report.triOrdre\"></Tsi-Integer>\r\n </div>\r\n <!-- Afficher dashboard -->\r\n <div class=\"flex gap-4 w-6\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_display\"></Tsi-Label>\r\n <Tsi-CheckBox [disabled]=\"lockAllButName\" [inputName]=\"'display'\" [(inputField)]=\"report.display\"></Tsi-CheckBox>\r\n </div>\r\n </div>\r\n <!-- Module -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_Module\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-9\">\r\n <Tsi-Search-Combo [disabled]=\"lockAllButName || lockAllButDisplay\" id-field=\"code\" label-field=\"libelle\" [multiple]=\"false\" [(bind)]=\"report.module\"\r\n [datasource]=\"modules\" [isFiltered]=\"false\">\r\n </Tsi-Search-Combo>\r\n </div>\r\n <!-- Deuxi\u00E9me Impress -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_imppress\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-5\">\r\n <Tsi-Text-Box [disabled]=\"true\" [inputName]=\"'imppress'\" [(inputField)]=\"report.impress\"></Tsi-Text-Box>\r\n </div>\r\n <!-- Edition unique -->\r\n <div class=\"col-4 col-form-label flx\">\r\n <Tsi-CheckBox [disabled]=\"lockAllButName || lockAllButDisplay\" [inputName]=\"'EditionUnique'\" [(inputField)]=\"report.editionUnique\"></Tsi-CheckBox> \r\n <Tsi-Label labelValue=\"administration_edition_personnalise_EditionUnique\"></Tsi-Label>\r\n </div>\r\n <!-- Endpoint -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_endpoint\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-9\">\r\n <Tsi-Search-Combo *ngIf=\"!isReportForFiche && !enableMultiSelectEndpoints\" id-field=\"key\" label-field=\"value\"\r\n [disabled]=\"modes.edit === mode || isEditionPersonnalise === false || lockAllButName || lockAllButDisplay\"\r\n (selectedLabelChange)=\"selectedEndpointChange($event)\" [(bind)]=\"report.endPointKey\"\r\n [elementSourceUrl]=\"administrationEndpoints.getApiAsKeyValuePair()\"\r\n [listSourceUrl]=\"administrationEndpoints.getAllApiAsKeyValuePair()\" [isFiltered]=\"true\">\r\n </Tsi-Search-Combo>\r\n\r\n <Tsi-Search-Combo *ngIf=\"customReportingMode && !enableMultiSelectEndpoints \" id-field=\"value\" label-field=\"value\"\r\n [disabled]=\"lockAllButName || lockAllButDisplay\"\r\n (selectedLabelChange)=\"selectedEndpointChange($event)\" [(bind)]=\"report.endPointKey\"\r\n [listSourceUrl]=\"administrationEndpoints.getAllApiAsKeyValuePairByBusinessClassName(this.reportBusinessClass)\"\r\n [isFiltered]=\"false\">\r\n </Tsi-Search-Combo>\r\n\r\n <Tsi-Search-Combo *ngIf=\"isReportForFiche\"\r\n id-field=\"value\"\r\n label-field=\"value\"\r\n [disabled]=\"lockAllButName || lockAllButDisplay\"\r\n [(bind)]=\"selectedEndpoints\"\r\n [listSourceUrl]=\"administrationEndpoints.getAllApiAsKeyValuePairByBusinessClassName(this.reportBusinessClass)\"\r\n [isFiltered]=\"false\"\r\n [multiple]=\"true\"\r\n (selectedLabelChange)=\"selectedEndpointChange($event)\">\r\n </Tsi-Search-Combo>\r\n\r\n <p-multiSelect *ngIf=\"!isReportForFiche && enableMultiSelectEndpoints\" [options]=\"endpointsOptions\" [(ngModel)]=\"selectedEndpoints\"\r\n [disabled]=\"lockAllButName || lockAllButDisplay\"\r\n selectedItemsLabel=\"{0} {{ 'endpoint_selected' | localize }}\" optionLabel=\"value\"\r\n optionValue=\"value\"\r\n [style]=\"{'min-width': '180px'}\" placeholder=\"{{ 'shared_reporting_choose_endpoints' | localize }}\"\r\n (onPanelShow)=\"handleOpen()\"\r\n [filter]=\"true\"\r\n (onFilter)=\"onFilter($event)\"\r\n display=\"chip\"\r\n class=\"rounded-multiselect\">\r\n <ng-template let-option pTemplate=\"item\">\r\n <div class=\"flex items-center gap-2\">\r\n <span>{{ option.value}}</span>\r\n </div>\r\n </ng-template>\r\n </p-multiSelect>\r\n </div>\r\n\r\n\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_formName\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-6\">\r\n <Tsi-Text-Box [disabled]=\"true\" [inputName]=\"'formName'\"\r\n [(inputField)]=\"report.formName\"></Tsi-Text-Box>\r\n </div>\r\n <!-- Param -->\r\n <div *ngIf=\"isGetByIdRequest\" class=\"col-3 col-form-label\">\r\n <Tsi-Label labelValue=\"administration_edition_personnalise_param\"></Tsi-Label>\r\n </div>\r\n <div *ngIf=\"isGetByIdRequest\" class=\"col-9\">\r\n <Tsi-Text-Box [disabled]=\"lockAllButName || lockAllButDisplay\" [inputName]=\"'param'\" [(inputField)]=\"report.param\"></Tsi-Text-Box>\r\n </div>\r\n </div>\r\n </p-panel>\r\n <br />\r\n <p-panel header=\"Configuration Pivot Grid\">\r\n <div class=\"grid \">\r\n <!-- Class or view -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label [labelValue]=\"'Class or view'\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-9\">\r\n <Tsi-Text-Box [inputName]=\"'dddd'\"></Tsi-Text-Box>\r\n </div>\r\n <!-- Query -->\r\n <div class=\"col-3 col-form-label\">\r\n <Tsi-Label [labelValue]=\"'Query'\"></Tsi-Label>\r\n </div>\r\n <div class=\"col-9 col-form-label\">\r\n <Tsi-Text-Area [rows]=\"2\"></Tsi-Text-Area>\r\n </div>\r\n </div>\r\n </p-panel>\r\n\r\n <Tsi-Modal-Footer [cancelDisabled]=\"saving\" [saveDisabled]=\"saving\" (onCancelClick)=\"hide()\" \r\n [showSaveAndCloseButton]=\"false\"></Tsi-Modal-Footer>\r\n</tsi-form>", styles: [".flx{display:flex;justify-content:center;align-items:center}::ng-deep .rounded-multiselect .p-multiselect{border-radius:12px!important}::ng-deep .rounded-multiselect .p-multiselect-label{border-radius:12px!important}\n"] }]
|
|
19196
19213
|
}], ctorParameters: () => [{ type: i1$3.DynamicDialogRef }, { type: ReportingService }, { type: i1$3.DynamicDialogConfig }, { type: TsiNotificationService }, { type: DashboardModuleService }, { type: TsiConfirmationService }, { type: i1.HttpClient }, { type: i7$1.Router }] });
|
|
19197
19214
|
|
|
19198
19215
|
class ManageReportingComponent extends TsiFormComponentBaseComponent {
|
|
@@ -19319,6 +19336,14 @@ class ManageReportingComponent extends TsiFormComponentBaseComponent {
|
|
|
19319
19336
|
styleClass: 'p-button-text p-button-danger',
|
|
19320
19337
|
toolTipText: 'shared_reporting_delete_report',
|
|
19321
19338
|
},
|
|
19339
|
+
{
|
|
19340
|
+
header: '',
|
|
19341
|
+
field: 'duplicate',
|
|
19342
|
+
isButton: true,
|
|
19343
|
+
buttonIcon: 'pi pi-clone',
|
|
19344
|
+
styleClass: 'p-button-text',
|
|
19345
|
+
toolTipText: 'shared_actions_duplicate',
|
|
19346
|
+
},
|
|
19322
19347
|
{
|
|
19323
19348
|
header: '',
|
|
19324
19349
|
field: 'Add_To_BuiltIn_Templates',
|
|
@@ -19512,6 +19537,10 @@ class ManageReportingComponent extends TsiFormComponentBaseComponent {
|
|
|
19512
19537
|
this._importToReport(event.key);
|
|
19513
19538
|
break;
|
|
19514
19539
|
}
|
|
19540
|
+
case 'duplicate': {
|
|
19541
|
+
this._duplicateReport(event.key);
|
|
19542
|
+
break;
|
|
19543
|
+
}
|
|
19515
19544
|
case 'Add_From_BuiltIn_Templates': {
|
|
19516
19545
|
console.log('Add_From_BuiltIn_Templates');
|
|
19517
19546
|
this._addFromBuiltInTemplates(event.key);
|
|
@@ -19703,6 +19732,7 @@ class ManageReportingComponent extends TsiFormComponentBaseComponent {
|
|
|
19703
19732
|
this.reports = items.map((r) => {
|
|
19704
19733
|
return {
|
|
19705
19734
|
...r,
|
|
19735
|
+
color: r.isReadOnly ? '#fff3cd' : undefined,
|
|
19706
19736
|
reportTypeName: ManageReportingComponent.reportTypeLabels[r.reportType] ||
|
|
19707
19737
|
'Unknown',
|
|
19708
19738
|
};
|
|
@@ -19837,7 +19867,7 @@ class ManageReportingComponent extends TsiFormComponentBaseComponent {
|
|
|
19837
19867
|
width: ModalSizeEnum.Large.width,
|
|
19838
19868
|
height: ModalSizeEnum.Large.height,
|
|
19839
19869
|
data: {
|
|
19840
|
-
value: value,
|
|
19870
|
+
value: { ...value, isReadOnly: report?.isReadOnly },
|
|
19841
19871
|
mode: Modes.edit,
|
|
19842
19872
|
isEditionPersonnalise: this.isEditionPersonnalise,
|
|
19843
19873
|
fromEndpoint: this.otherFormEndpoint
|
|
@@ -19869,7 +19899,7 @@ class ManageReportingComponent extends TsiFormComponentBaseComponent {
|
|
|
19869
19899
|
let reportToTemplateId = value.uid;
|
|
19870
19900
|
let urlDesigner;
|
|
19871
19901
|
let tenantUid = this.identityManagerService.parseMyAuthToken()?.tenantUid;
|
|
19872
|
-
let canredirect = localStorage.getItem('canRedirect');
|
|
19902
|
+
let canredirect = !report?.isReadOnly && localStorage.getItem('canRedirect');
|
|
19873
19903
|
if (value.reportType === TsiReportType.List) {
|
|
19874
19904
|
urlDesigner = `${Segment.reportingServiceBase}/report-designer-edit/${reportToTemplateId}?${queryParamNamesConst.tenantUid}=${tenantUid}`;
|
|
19875
19905
|
}
|
|
@@ -19910,6 +19940,45 @@ class ManageReportingComponent extends TsiFormComponentBaseComponent {
|
|
|
19910
19940
|
}
|
|
19911
19941
|
});
|
|
19912
19942
|
}
|
|
19943
|
+
_duplicateReport(uid) {
|
|
19944
|
+
let report = this.reports.find((r) => r.uid === uid);
|
|
19945
|
+
if (report === undefined || report === null) {
|
|
19946
|
+
this.notificationService.error(this.errorMessageKey);
|
|
19947
|
+
return;
|
|
19948
|
+
}
|
|
19949
|
+
report.name = `${report.name} - Dupliquer`;
|
|
19950
|
+
let config = {
|
|
19951
|
+
maximizable: true,
|
|
19952
|
+
width: ModalSizeEnum.Large.width,
|
|
19953
|
+
height: ModalSizeEnum.Large.height,
|
|
19954
|
+
data: {
|
|
19955
|
+
mode: Modes.duplicate,
|
|
19956
|
+
value: report,
|
|
19957
|
+
title: `Dupliquer "${report.name}"`,
|
|
19958
|
+
isEditionPersonnalise: this.isEditionPersonnalise,
|
|
19959
|
+
fromEndpoint: this.otherFormEndpoint ?? report?.restEndpoint,
|
|
19960
|
+
reportBusinessClass: this.businessClass,
|
|
19961
|
+
},
|
|
19962
|
+
};
|
|
19963
|
+
this._dialogRef = this._tsiModalService.open(AddReportPopupComponent, config);
|
|
19964
|
+
this._dialogRef.onClose.subscribe((val) => {
|
|
19965
|
+
if (val === null || val === undefined)
|
|
19966
|
+
return;
|
|
19967
|
+
this.isloading = true;
|
|
19968
|
+
this.reportingService.duplicateReport(uid, val.reportName).subscribe({
|
|
19969
|
+
next: async () => {
|
|
19970
|
+
await this._refreshReports();
|
|
19971
|
+
this.notificationService.success('shared_reporting_report_duplicated_successfully');
|
|
19972
|
+
this.isloading = false;
|
|
19973
|
+
},
|
|
19974
|
+
error: () => {
|
|
19975
|
+
this.isloading = false;
|
|
19976
|
+
this.notificationService.error(this.errorMessageKey);
|
|
19977
|
+
},
|
|
19978
|
+
});
|
|
19979
|
+
this._closeModal(val);
|
|
19980
|
+
});
|
|
19981
|
+
}
|
|
19913
19982
|
_setDefaultReport(id) {
|
|
19914
19983
|
this.confirmationService.confirm('shared_reporting_confirm_set_default_report_file', undefined, (result) => {
|
|
19915
19984
|
if (result && id != null && id != undefined) {
|