wuic-framework-lib 1.0.11 → 1.0.19

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.
Files changed (16) hide show
  1. package/fesm2022/{wuic-framework-lib-chart-list.component-vuzmQW9F.mjs → wuic-framework-lib-chart-list.component-C0OYuZoM.mjs} +8 -8
  2. package/fesm2022/{wuic-framework-lib-code-editor.component-BjbIkm4g.mjs → wuic-framework-lib-code-editor.component-B8OQ3Z0k.mjs} +258 -258
  3. package/fesm2022/{wuic-framework-lib-designer.component-BM3elB-a.mjs → wuic-framework-lib-designer.component-DsWgWtFj.mjs} +99 -105
  4. package/fesm2022/{wuic-framework-lib-first-run-wizard.component-5tcl67dK.mjs → wuic-framework-lib-first-run-wizard.component-wR_LrvPK.mjs} +244 -38
  5. package/fesm2022/{wuic-framework-lib-framework-docs.component-BGcJ7k1X.mjs → wuic-framework-lib-framework-docs.component-eyzu9tdV.mjs} +31 -15
  6. package/fesm2022/{wuic-framework-lib-pivot-builder.component-ChNyMAfi.mjs → wuic-framework-lib-pivot-builder.component-BFdZW5Ch.mjs} +215 -88
  7. package/fesm2022/{wuic-framework-lib-prompt-dialog-fallback-host.component-DFLR_EmK.mjs → wuic-framework-lib-prompt-dialog-fallback-host.component-B583WbYe.mjs} +2 -2
  8. package/fesm2022/{wuic-framework-lib-report-designer.component-B_SC7VkW.mjs → wuic-framework-lib-report-designer.component-HJUpslLX.mjs} +12 -12
  9. package/fesm2022/{wuic-framework-lib-report-viewer.component-BTK-p8xF.mjs → wuic-framework-lib-report-viewer.component-El32zpzi.mjs} +81 -11
  10. package/fesm2022/{wuic-framework-lib-scheduler-list.component-CIoGVf4O.mjs → wuic-framework-lib-scheduler-list.component-E8s_e533.mjs} +16 -16
  11. package/fesm2022/{wuic-framework-lib-spreadsheet-list-sf.component-DQ5OxO4j.mjs → wuic-framework-lib-spreadsheet-list-sf.component-CDn0qi_C.mjs} +19 -5
  12. package/fesm2022/{wuic-framework-lib-workflow-designer.component-BHLT4MER.mjs → wuic-framework-lib-workflow-designer.component-hL7oKqYO.mjs} +2 -2
  13. package/fesm2022/{wuic-framework-lib-wuic-framework-lib-DDokY6wY.mjs → wuic-framework-lib-wuic-framework-lib-ABS_G7lO.mjs} +2149 -1089
  14. package/fesm2022/wuic-framework-lib.mjs +1 -1
  15. package/package.json +1 -1
  16. package/types/wuic-framework-lib.d.ts +308 -24
@@ -2,7 +2,7 @@ import * as i0 from '@angular/core';
2
2
  import { EventEmitter, Output, Input, Component } from '@angular/core';
3
3
  import * as i2 from 'primeng/dialog';
4
4
  import { DialogModule } from 'primeng/dialog';
5
- import { d as ParametricDialogComponent } from './wuic-framework-lib-wuic-framework-lib-DDokY6wY.mjs';
5
+ import { d as ParametricDialogComponent } from './wuic-framework-lib-wuic-framework-lib-ABS_G7lO.mjs';
6
6
 
7
7
  class PromptDialogFallbackHostComponent {
8
8
  datasource;
@@ -96,4 +96,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.8", ngImpor
96
96
  }] } });
97
97
 
98
98
  export { PromptDialogFallbackHostComponent };
99
- //# sourceMappingURL=wuic-framework-lib-prompt-dialog-fallback-host.component-DFLR_EmK.mjs.map
99
+ //# sourceMappingURL=wuic-framework-lib-prompt-dialog-fallback-host.component-B583WbYe.mjs.map
@@ -1,6 +1,6 @@
1
1
  import * as i0 from '@angular/core';
2
2
  import { ViewChild, Component } from '@angular/core';
3
- import { W as WtoolboxService, M as MetadataProviderService } from './wuic-framework-lib-wuic-framework-lib-DDokY6wY.mjs';
3
+ import { W as WtoolboxService, M as MetadataProviderService } from './wuic-framework-lib-wuic-framework-lib-ABS_G7lO.mjs';
4
4
  import * as i3 from 'stimulsoft-designer-angular';
5
5
  import { StimulsoftDesignerModule, StimulsoftDesignerComponent } from 'stimulsoft-designer-angular';
6
6
  import * as i1 from '@angular/router';
@@ -80,7 +80,7 @@ class ReportDesignerComponent {
80
80
  * Gestisce la logica di `fix` con il flusso specifico definito dalla sua implementazione.
81
81
  */
82
82
  fix() {
83
- var designer = this.designer;
83
+ let designer = this.designer;
84
84
  debugger;
85
85
  }
86
86
  /**
@@ -92,7 +92,7 @@ class ReportDesignerComponent {
92
92
  * already polls for readiness, but we guard the initial access too.
93
93
  */
94
94
  ngAfterViewInit() {
95
- var self = this;
95
+ let self = this;
96
96
  this.designerBootstrapInterval = setInterval(() => {
97
97
  if (!this.designer) {
98
98
  return; // @defer block hasn't rendered yet
@@ -107,8 +107,8 @@ class ReportDesignerComponent {
107
107
  clearInterval(this.designerBootstrapInterval);
108
108
  this.designerBootstrapInterval = undefined;
109
109
  }
110
- var tr = this.designer.designerEl.nativeElement.getElementsByClassName("stiChildWorkPanel stiWorkPanelScrollContainer")[0].getElementsByTagName("table")[0].getElementsByTagName("tr")[0];
111
- var saveBtn = tr.children[0];
110
+ let tr = this.designer.designerEl.nativeElement.getElementsByClassName("stiChildWorkPanel stiWorkPanelScrollContainer")[0].getElementsByTagName("table")[0].getElementsByTagName("tr")[0];
111
+ let saveBtn = tr.children[0];
112
112
  saveBtn.addEventListener("click", () => {
113
113
  if (this.reportCacheInvalidationTimer) {
114
114
  clearTimeout(this.reportCacheInvalidationTimer);
@@ -118,7 +118,7 @@ class ReportDesignerComponent {
118
118
  this.metaSrv.invalidateReportListCache(this.route);
119
119
  }, 400);
120
120
  });
121
- var cloned = saveBtn.cloneNode(true);
121
+ let cloned = saveBtn.cloneNode(true);
122
122
  cloned.id = "saveAsBtn";
123
123
  saveBtn.parentElement.prepend(cloned);
124
124
  cloned.getElementsByTagName("table")[0].getElementsByTagName("tr")[2].getElementsByTagName("td")[0].innerText = "Save As";
@@ -130,15 +130,15 @@ class ReportDesignerComponent {
130
130
  //ask name -> save copy of current
131
131
  //change requestUrl and reload
132
132
  };
133
- var td = document.createElement("td");
133
+ let td = document.createElement("td");
134
134
  td.className = "stiDesignerClearAllStyles";
135
- var div = document.createElement("div");
135
+ let div = document.createElement("div");
136
136
  div.className = "stiDesignerGroupBlock";
137
- var div2 = document.createElement("div");
137
+ let div2 = document.createElement("div");
138
138
  div2.className = "stiDesignerGroupBlockContainer";
139
- var formElement = document.createElement("select");
139
+ let formElement = document.createElement("select");
140
140
  formElement.className = "stiDesignerTextBox stiDesignerTextBoxDefault";
141
- var optionElement = document.createElement("option");
141
+ let optionElement = document.createElement("option");
142
142
  optionElement.value = "foo";
143
143
  optionElement.text = "foo";
144
144
  optionElement.selected = true;
@@ -191,4 +191,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.8", ngImpor
191
191
  }] } });
192
192
 
193
193
  export { ReportDesignerComponent };
194
- //# sourceMappingURL=wuic-framework-lib-report-designer.component-B_SC7VkW.mjs.map
194
+ //# sourceMappingURL=wuic-framework-lib-report-designer.component-HJUpslLX.mjs.map
@@ -2,14 +2,18 @@ import * as i0 from '@angular/core';
2
2
  import { ViewChild, Component } from '@angular/core';
3
3
  import * as i1 from '@angular/router';
4
4
  import { NavigationEnd } from '@angular/router';
5
- import * as i2 from 'stimulsoft-viewer-angular';
5
+ import { CommonModule } from '@angular/common';
6
+ import * as i3 from 'stimulsoft-viewer-angular';
6
7
  import { StimulsoftViewerModule, StimulsoftViewerComponent } from 'stimulsoft-viewer-angular';
7
- import { W as WtoolboxService } from './wuic-framework-lib-wuic-framework-lib-DDokY6wY.mjs';
8
+ import { W as WtoolboxService } from './wuic-framework-lib-wuic-framework-lib-ABS_G7lO.mjs';
8
9
  import { e as ensureWuicStimulsoftLicenseRegistered } from './wuic-framework-lib-stimulsoft-license.service-BIyxB4pO.mjs';
10
+ import { firstValueFrom } from 'rxjs';
11
+ import * as i1$1 from '@angular/common/http';
9
12
 
10
13
  class ReportViewerComponent {
11
14
  router;
12
15
  aRoute;
16
+ http;
13
17
  /**
14
18
  * Registra la chiave Stimulsoft prima di lasciare istanziare il viewer.
15
19
  * E' fire-and-forget perche' il viewer puo' iniziare a renderizzare anche
@@ -22,6 +26,11 @@ class ReportViewerComponent {
22
26
  */
23
27
  ngOnInit() {
24
28
  void ensureWuicStimulsoftLicenseRegistered();
29
+ // Trigger iniziale: il subscribe a `router.events` nel constructor cattura
30
+ // SOLO le NavigationEnd successive — su deep-link / reload con la route
31
+ // gia' attiva, la NavigationEnd e' gia' stata emessa prima che la
32
+ // subscription esistesse. Forziamo il preflight qui.
33
+ this.updateRequestUrl();
25
34
  }
26
35
  /**
27
36
  * Riferimento a elementi o componenti figli usato dalla logica UI per viewer.
@@ -57,14 +66,27 @@ class ReportViewerComponent {
57
66
  */
58
67
  routerEventsSubscription;
59
68
  diagnosticPrefix = '[WUIC][ReportViewer]';
69
+ /**
70
+ * Gate `*ngIf` del template: se `false` lo Stimulsoft viewer NON viene
71
+ * montato. Settato a `false` quando il preflight `CheckReport` fallisce
72
+ * (404 con `errors.report.not_found` o altro errore tipizzato), cosi'
73
+ * evitiamo che la libreria Stimulsoft riceva la response error envelope
74
+ * e crashi su `Cannot read properties of null (reading 'reportFileName')`.
75
+ * La dialog localizzata e' gia' mostrata dal `WuicErrorInterceptor` →
76
+ * `GlobalHandler` standard pipeline.
77
+ */
78
+ canRenderViewer = false;
79
+ /** Token incrementale per evitare race su preflight concorrenti. */
80
+ preflightSeq = 0;
60
81
  /**
61
82
  * function Object() { [native code] }
62
83
  * @param router Informazioni di routing usate per comporre o risolvere la navigazione.
63
84
  * @param aRoute Informazioni di routing usate per comporre o risolvere la navigazione.
64
85
  */
65
- constructor(router, aRoute) {
86
+ constructor(router, aRoute, http) {
66
87
  this.router = router;
67
88
  this.aRoute = aRoute;
89
+ this.http = http;
68
90
  this.action = 'InitViewer';
69
91
  this.baseRequestUrl = WtoolboxService.appSettings.api_url + 'ReportViewer/{action}';
70
92
  this.requestUrl = WtoolboxService.appSettings.api_url + 'ReportViewer/{action}';
@@ -106,11 +128,59 @@ class ReportViewerComponent {
106
128
  if (filters) {
107
129
  queryParts.push('filters=' + encodeURIComponent(filters));
108
130
  }
109
- this.requestUrl = this.baseRequestUrl + '?' + queryParts.join('&');
110
- this.logDiag('updateRequestUrl', {
131
+ const computedUrl = this.baseRequestUrl + '?' + queryParts.join('&');
132
+ this.logDiag('updateRequestUrl:start', {
111
133
  route: this.route,
112
- requestUrl: this.requestUrl
134
+ reportName,
135
+ requestUrl: computedUrl
113
136
  });
137
+ // Preflight: chiama `/api/ReportViewer/CheckReport` (vedi commento in
138
+ // ReportViewerController.CheckReport per il razionale completo). Il
139
+ // viewer Stimulsoft NON va montato se il file non esiste, perche'
140
+ // la sua callback di parse della response e' sincrona e non passa
141
+ // attraverso la nostra pipeline interceptor → GlobalHandler.
142
+ // Sequenziamo via `preflightSeq` per evitare che un preflight piu'
143
+ // vecchio (es. utente ha gia' navigato a un report diverso) sovrascriva
144
+ // lo stato del piu' recente.
145
+ const seq = ++this.preflightSeq;
146
+ this.canRenderViewer = false;
147
+ this.requestUrl = '';
148
+ void this.runPreflight(this.route || '', reportName || 'Report.mrt', seq, computedUrl);
149
+ }
150
+ /**
151
+ * Esegue il GET preflight a `CheckReport`. Su 200 → monta il viewer.
152
+ * Su 4xx/5xx → l'envelope tipizzato e' gia' stato dispatchato a
153
+ * GlobalHandler dal WuicErrorInterceptor, qui ci limitiamo a non
154
+ * inizializzare lo Stimulsoft viewer.
155
+ */
156
+ async runPreflight(route, reportName, seq, computedUrl) {
157
+ const checkUrl = WtoolboxService.appSettings.api_url
158
+ + 'ReportViewer/CheckReport'
159
+ + '?route=' + encodeURIComponent(route)
160
+ + '&reportName=' + encodeURIComponent(reportName);
161
+ try {
162
+ await firstValueFrom(this.http.get(checkUrl));
163
+ // Race-guard: scarta se nel mentre e' partito un preflight piu' nuovo.
164
+ if (seq !== this.preflightSeq) {
165
+ this.logDiag('preflight:stale-success', { seq, current: this.preflightSeq });
166
+ return;
167
+ }
168
+ this.requestUrl = computedUrl;
169
+ this.canRenderViewer = true;
170
+ this.logDiag('preflight:ok', { route, reportName });
171
+ }
172
+ catch (err) {
173
+ if (seq !== this.preflightSeq) {
174
+ this.logDiag('preflight:stale-error', { seq, current: this.preflightSeq });
175
+ return;
176
+ }
177
+ // Niente notify manuale: l'interceptor (`wuicErrorInterceptor`) ha
178
+ // gia' dispatchato l'envelope tipizzato a GlobalHandler.handleErrorStatic
179
+ // → dialog localizzata mostrata. Qui solo lockdown del viewer.
180
+ this.canRenderViewer = false;
181
+ this.requestUrl = '';
182
+ this.logDiag('preflight:ko', { route, reportName, err });
183
+ }
114
184
  }
115
185
  /**
116
186
  * Costruisce una struttura di output a partire dal contesto corrente normalizzando e trasformando collezioni di record.
@@ -394,16 +464,16 @@ class ReportViewerComponent {
394
464
  ngOnDestroy() {
395
465
  this.routerEventsSubscription?.unsubscribe();
396
466
  }
397
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.8", ngImport: i0, type: ReportViewerComponent, deps: [{ token: i1.Router }, { token: i1.ActivatedRoute }], target: i0.ɵɵFactoryTarget.Component });
398
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.8", type: ReportViewerComponent, isStandalone: true, selector: "wuic-report-viewer", viewQueries: [{ propertyName: "viewer", first: true, predicate: StimulsoftViewerComponent, descendants: true }], ngImport: i0, template: "@defer (on immediate) {\n <stimulsoft-viewer-angular [requestUrl]=\"requestUrl\" [action]=\"action\" [width]=\"'100%'\"\n [height]=\"'calc(100% - 10px)'\" [properties]=\"viewerProperties\" (loaded)=\"onViewerLoaded()\" (export)=\"onExportEvent($event)\"\n (print)=\"onPrintEvent($event)\" (error)=\"onViewerError($event)\"></stimulsoft-viewer-angular>\n} @placeholder {\n <div class=\"stimulsoft-loading-placeholder\">\n <i class=\"pi pi-spin pi-spinner\"></i>\n <span>Caricamento Report Viewer\u2026</span>\n <small>Il SDK Stimulsoft \u00E8 in download (~15 MB). Operazione una tantum.</small>\n </div>\n} @loading (minimum 300ms) {\n <div class=\"stimulsoft-loading-placeholder\">\n <i class=\"pi pi-spin pi-spinner\"></i>\n <span>Rendering report\u2026</span>\n </div>\n} @error {\n <div class=\"stimulsoft-error-placeholder\">\n <i class=\"pi pi-exclamation-triangle\"></i>\n <span>Errore nel caricamento del Report Viewer. Verifica connessione e ricarica la pagina.</span>\n </div>\n}\n", styles: [":host{display:block;width:100%;height:100%;flex:1 1 auto;min-height:0}:host ::ng-deep stimulsoft-viewer-angular{display:block;width:100%;height:100%}:host ::ng-deep .stiJsViewerForm,:host ::ng-deep .stiJsViewerDisabledPanel{display:none!important}.stimulsoft-loading-placeholder,.stimulsoft-error-placeholder{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:12px;width:100%;height:100%;min-height:400px;color:#64748b;font-size:1rem;background:#f8fafc;border:1px dashed #cbd5e1;border-radius:8px}.stimulsoft-loading-placeholder .pi-spinner{font-size:2rem;color:#6366f1}.stimulsoft-loading-placeholder small{font-size:.8rem;color:#94a3b8;max-width:400px;text-align:center}.stimulsoft-error-placeholder{color:#b91c1c;background:#fef2f2;border-color:#fecaca}.stimulsoft-error-placeholder .pi-exclamation-triangle{font-size:2rem}\n"], dependencies: [{ kind: "ngmodule", type: StimulsoftViewerModule }], deferBlockDependencies: [() => [i2.StimulsoftViewerComponent]] });
467
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.8", ngImport: i0, type: ReportViewerComponent, deps: [{ token: i1.Router }, { token: i1.ActivatedRoute }, { token: i1$1.HttpClient }], target: i0.ɵɵFactoryTarget.Component });
468
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.8", type: ReportViewerComponent, isStandalone: true, selector: "wuic-report-viewer", viewQueries: [{ propertyName: "viewer", first: true, predicate: StimulsoftViewerComponent, descendants: true }], ngImport: i0, template: "@defer (on immediate) {\n @if (canRenderViewer) {\n <stimulsoft-viewer-angular [requestUrl]=\"requestUrl\" [action]=\"action\" [width]=\"'100%'\"\n [height]=\"'calc(100% - 10px)'\" [properties]=\"viewerProperties\" (loaded)=\"onViewerLoaded()\" (export)=\"onExportEvent($event)\"\n (print)=\"onPrintEvent($event)\" (error)=\"onViewerError($event)\"></stimulsoft-viewer-angular>\n } @else {\n <!-- Preflight in corso o fallito. Se fallito, la dialog localizzata e'\n gia' stata mostrata da WuicErrorInterceptor \u2192 GlobalHandler. -->\n <div class=\"stimulsoft-loading-placeholder\">\n <i class=\"pi pi-spin pi-spinner\"></i>\n <span>Verifica disponibilit\u00E0 report\u2026</span>\n </div>\n }\n} @placeholder {\n <div class=\"stimulsoft-loading-placeholder\">\n <i class=\"pi pi-spin pi-spinner\"></i>\n <span>Caricamento Report Viewer\u2026</span>\n <small>Il SDK Stimulsoft \u00E8 in download (~15 MB). Operazione una tantum.</small>\n </div>\n} @loading (minimum 300ms) {\n <div class=\"stimulsoft-loading-placeholder\">\n <i class=\"pi pi-spin pi-spinner\"></i>\n <span>Rendering report\u2026</span>\n </div>\n} @error {\n <div class=\"stimulsoft-error-placeholder\">\n <i class=\"pi pi-exclamation-triangle\"></i>\n <span>Errore nel caricamento del Report Viewer. Verifica connessione e ricarica la pagina.</span>\n </div>\n}\n", styles: [":host{display:block;width:100%;height:100%;flex:1 1 auto;min-height:0}:host ::ng-deep stimulsoft-viewer-angular{display:block;width:100%;height:100%}:host ::ng-deep .stiJsViewerForm,:host ::ng-deep .stiJsViewerDisabledPanel{display:none!important}.stimulsoft-loading-placeholder,.stimulsoft-error-placeholder{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:12px;width:100%;height:100%;min-height:400px;color:#64748b;font-size:1rem;background:#f8fafc;border:1px dashed #cbd5e1;border-radius:8px}.stimulsoft-loading-placeholder .pi-spinner{font-size:2rem;color:#6366f1}.stimulsoft-loading-placeholder small{font-size:.8rem;color:#94a3b8;max-width:400px;text-align:center}.stimulsoft-error-placeholder{color:#b91c1c;background:#fef2f2;border-color:#fecaca}.stimulsoft-error-placeholder .pi-exclamation-triangle{font-size:2rem}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: StimulsoftViewerModule }], deferBlockDependencies: [() => [i3.StimulsoftViewerComponent]] });
399
469
  }
400
470
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.8", ngImport: i0, type: ReportViewerComponent, decorators: [{
401
471
  type: Component,
402
- args: [{ selector: 'wuic-report-viewer', imports: [StimulsoftViewerModule], template: "@defer (on immediate) {\n <stimulsoft-viewer-angular [requestUrl]=\"requestUrl\" [action]=\"action\" [width]=\"'100%'\"\n [height]=\"'calc(100% - 10px)'\" [properties]=\"viewerProperties\" (loaded)=\"onViewerLoaded()\" (export)=\"onExportEvent($event)\"\n (print)=\"onPrintEvent($event)\" (error)=\"onViewerError($event)\"></stimulsoft-viewer-angular>\n} @placeholder {\n <div class=\"stimulsoft-loading-placeholder\">\n <i class=\"pi pi-spin pi-spinner\"></i>\n <span>Caricamento Report Viewer\u2026</span>\n <small>Il SDK Stimulsoft \u00E8 in download (~15 MB). Operazione una tantum.</small>\n </div>\n} @loading (minimum 300ms) {\n <div class=\"stimulsoft-loading-placeholder\">\n <i class=\"pi pi-spin pi-spinner\"></i>\n <span>Rendering report\u2026</span>\n </div>\n} @error {\n <div class=\"stimulsoft-error-placeholder\">\n <i class=\"pi pi-exclamation-triangle\"></i>\n <span>Errore nel caricamento del Report Viewer. Verifica connessione e ricarica la pagina.</span>\n </div>\n}\n", styles: [":host{display:block;width:100%;height:100%;flex:1 1 auto;min-height:0}:host ::ng-deep stimulsoft-viewer-angular{display:block;width:100%;height:100%}:host ::ng-deep .stiJsViewerForm,:host ::ng-deep .stiJsViewerDisabledPanel{display:none!important}.stimulsoft-loading-placeholder,.stimulsoft-error-placeholder{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:12px;width:100%;height:100%;min-height:400px;color:#64748b;font-size:1rem;background:#f8fafc;border:1px dashed #cbd5e1;border-radius:8px}.stimulsoft-loading-placeholder .pi-spinner{font-size:2rem;color:#6366f1}.stimulsoft-loading-placeholder small{font-size:.8rem;color:#94a3b8;max-width:400px;text-align:center}.stimulsoft-error-placeholder{color:#b91c1c;background:#fef2f2;border-color:#fecaca}.stimulsoft-error-placeholder .pi-exclamation-triangle{font-size:2rem}\n"] }]
403
- }], ctorParameters: () => [{ type: i1.Router }, { type: i1.ActivatedRoute }], propDecorators: { viewer: [{
472
+ args: [{ selector: 'wuic-report-viewer', imports: [CommonModule, StimulsoftViewerModule], template: "@defer (on immediate) {\n @if (canRenderViewer) {\n <stimulsoft-viewer-angular [requestUrl]=\"requestUrl\" [action]=\"action\" [width]=\"'100%'\"\n [height]=\"'calc(100% - 10px)'\" [properties]=\"viewerProperties\" (loaded)=\"onViewerLoaded()\" (export)=\"onExportEvent($event)\"\n (print)=\"onPrintEvent($event)\" (error)=\"onViewerError($event)\"></stimulsoft-viewer-angular>\n } @else {\n <!-- Preflight in corso o fallito. Se fallito, la dialog localizzata e'\n gia' stata mostrata da WuicErrorInterceptor \u2192 GlobalHandler. -->\n <div class=\"stimulsoft-loading-placeholder\">\n <i class=\"pi pi-spin pi-spinner\"></i>\n <span>Verifica disponibilit\u00E0 report\u2026</span>\n </div>\n }\n} @placeholder {\n <div class=\"stimulsoft-loading-placeholder\">\n <i class=\"pi pi-spin pi-spinner\"></i>\n <span>Caricamento Report Viewer\u2026</span>\n <small>Il SDK Stimulsoft \u00E8 in download (~15 MB). Operazione una tantum.</small>\n </div>\n} @loading (minimum 300ms) {\n <div class=\"stimulsoft-loading-placeholder\">\n <i class=\"pi pi-spin pi-spinner\"></i>\n <span>Rendering report\u2026</span>\n </div>\n} @error {\n <div class=\"stimulsoft-error-placeholder\">\n <i class=\"pi pi-exclamation-triangle\"></i>\n <span>Errore nel caricamento del Report Viewer. Verifica connessione e ricarica la pagina.</span>\n </div>\n}\n", styles: [":host{display:block;width:100%;height:100%;flex:1 1 auto;min-height:0}:host ::ng-deep stimulsoft-viewer-angular{display:block;width:100%;height:100%}:host ::ng-deep .stiJsViewerForm,:host ::ng-deep .stiJsViewerDisabledPanel{display:none!important}.stimulsoft-loading-placeholder,.stimulsoft-error-placeholder{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:12px;width:100%;height:100%;min-height:400px;color:#64748b;font-size:1rem;background:#f8fafc;border:1px dashed #cbd5e1;border-radius:8px}.stimulsoft-loading-placeholder .pi-spinner{font-size:2rem;color:#6366f1}.stimulsoft-loading-placeholder small{font-size:.8rem;color:#94a3b8;max-width:400px;text-align:center}.stimulsoft-error-placeholder{color:#b91c1c;background:#fef2f2;border-color:#fecaca}.stimulsoft-error-placeholder .pi-exclamation-triangle{font-size:2rem}\n"] }]
473
+ }], ctorParameters: () => [{ type: i1.Router }, { type: i1.ActivatedRoute }, { type: i1$1.HttpClient }], propDecorators: { viewer: [{
404
474
  type: ViewChild,
405
475
  args: [StimulsoftViewerComponent]
406
476
  }] } });
407
477
 
408
478
  export { ReportViewerComponent };
409
- //# sourceMappingURL=wuic-framework-lib-report-viewer.component-BTK-p8xF.mjs.map
479
+ //# sourceMappingURL=wuic-framework-lib-report-viewer.component-El32zpzi.mjs.map
@@ -8,7 +8,7 @@ import interactionPlugin from '@fullcalendar/interaction';
8
8
  import timeGridPlugin from '@fullcalendar/timegrid';
9
9
  import * as i1 from '@angular/platform-browser';
10
10
  import { Title } from '@angular/platform-browser';
11
- import { o as FilterInfo, p as FilterItem, W as WtoolboxService, d as ParametricDialogComponent, M as MetadataProviderService, D as DynamicGenericTemplateComponent, T as TranslationManagerService } from './wuic-framework-lib-wuic-framework-lib-DDokY6wY.mjs';
11
+ import { o as FilterInfo, q as FilterItem, W as WtoolboxService, d as ParametricDialogComponent, M as MetadataProviderService, D as DynamicGenericTemplateComponent, T as TranslationManagerService } from './wuic-framework-lib-wuic-framework-lib-ABS_G7lO.mjs';
12
12
  import { BehaviorSubject } from 'rxjs';
13
13
 
14
14
  // https://fullcalendar.io/docs/initialize-globals#premium-bundle -
@@ -161,8 +161,8 @@ class SchedulerListComponent {
161
161
  * Completa inizializzazione dopo il rendering della view e collega riferimenti UI.
162
162
  */
163
163
  ngAfterViewInit() {
164
- var self = this;
165
- var calOpts = {
164
+ let self = this;
165
+ let calOpts = {
166
166
  initialView: 'dayGridMonth',
167
167
  plugins: [dayGridPlugin, timeGridPlugin, interactionPlugin],
168
168
  headerToolbar: {
@@ -191,12 +191,12 @@ class SchedulerListComponent {
191
191
  dateClick: function (info) {
192
192
  self.onSchedulerDateClick.emit(info);
193
193
  if (self.datasource && self.datasource.value && self.datasource.value.metaInfo && self.datasource.value.metaInfo.tableMetadata.md_insertable) {
194
- var header = self.trslSrv.instant('insert') + ' ' + self.metaInfo.tableMetadata.md_display_string;
195
- var defaulted = self.datasource.value.addNewRecord();
194
+ let header = self.trslSrv.instant('insert') + ' ' + self.metaInfo.tableMetadata.md_display_string;
195
+ let defaulted = self.datasource.value.addNewRecord();
196
196
  const fromCol = self.getColumnMetadata(self.fromField);
197
197
  const toCol = self.getColumnMetadata(self.toField);
198
198
  defaulted[self.fromField].next(self.serializeDateForColumn(info.date, fromCol));
199
- var toDate = new Date(info.date);
199
+ let toDate = new Date(info.date);
200
200
  const toType = String(toCol?.mc_ui_column_type || '').trim().toLowerCase();
201
201
  // For all-day date fields we persist inclusive end date.
202
202
  if (toType !== 'date') {
@@ -290,7 +290,7 @@ class SchedulerListComponent {
290
290
  this.fetchInfoSub = this.datasource.value.fetchInfo$.subscribe((info) => {
291
291
  if (info) {
292
292
  this.metaInfo = info.metaInfo;
293
- var schedOptions = info.metaInfo.tableMetadata.extraProps?.archetypes?.scheduler;
293
+ let schedOptions = info.metaInfo.tableMetadata.extraProps?.archetypes?.scheduler;
294
294
  this.calendarOptions.editable = info.metaInfo.tableMetadata.md_editable;
295
295
  if (schedOptions) {
296
296
  this.fromField = schedOptions.fromField;
@@ -311,10 +311,10 @@ class SchedulerListComponent {
311
311
  }
312
312
  }
313
313
  else {
314
- var dateFields = this.metaInfo.columnMetadata.filter(c => c.mc_ui_column_type == 'date' || c.mc_ui_column_type == 'datetime');
314
+ let dateFields = this.metaInfo.columnMetadata.filter(c => c.mc_ui_column_type == 'date' || c.mc_ui_column_type == 'datetime');
315
315
  if (dateFields.length >= 2) {
316
- var fromCandidates = dateFields.filter(c => c.mc_nome_colonna.toLowerCase().includes('from'));
317
- var toCandidates = dateFields.filter(c => c.mc_nome_colonna.toLowerCase().includes('to'));
316
+ let fromCandidates = dateFields.filter(c => c.mc_nome_colonna.toLowerCase().includes('from'));
317
+ let toCandidates = dateFields.filter(c => c.mc_nome_colonna.toLowerCase().includes('to'));
318
318
  if (fromCandidates.length > 0 && toCandidates.length > 0) {
319
319
  this.fromField = fromCandidates[0].mc_nome_colonna;
320
320
  this.toField = toCandidates[0].mc_nome_colonna;
@@ -329,7 +329,7 @@ class SchedulerListComponent {
329
329
  }
330
330
  this.titleField = this.metaInfo.columnMetadata.find(c => c.mc_ui_column_type == 'text' || c.mc_ui_column_type == 'txt_area')?.mc_nome_colonna;
331
331
  }
332
- var title = this.metaInfo.tableMetadata.md_display_string;
332
+ let title = this.metaInfo.tableMetadata.md_display_string;
333
333
  this.titleService.setTitle(title);
334
334
  const template = this.itemTemplateString || MetadataProviderService.widgetDefinition.schedulerEventTemplate;
335
335
  const component = DynamicGenericTemplateComponent.getComponentFromTemplate(template || '', 'md_props_bag.archetypes.scheduler.itemTemplate', String(this.metaInfo?.tableMetadata?.md_route_name || ''));
@@ -367,8 +367,8 @@ class SchedulerListComponent {
367
367
  return WtoolboxService.wrapArchetypeLifecycleSync('scheduler', 'parseData', () => this._parseDataInternal(data), { route: this.metaInfo?.tableMetadata?.md_route_name }, { fallback: [] });
368
368
  }
369
369
  _parseDataInternal(data) {
370
- var startcol = this.metaInfo.columnMetadata.find(c => c.mc_nome_colonna == this.fromField);
371
- var endcol = this.metaInfo.columnMetadata.find(c => c.mc_nome_colonna == this.toField);
370
+ let startcol = this.metaInfo.columnMetadata.find(c => c.mc_nome_colonna == this.fromField);
371
+ let endcol = this.metaInfo.columnMetadata.find(c => c.mc_nome_colonna == this.toField);
372
372
  const allDay = String(startcol?.mc_ui_column_type || '').trim().toLowerCase() === 'date';
373
373
  return data.filter(x => x[this.fromField] && x[this.toField]).map((x) => {
374
374
  const startDate = this.parseDate(x[this.fromField], startcol);
@@ -433,7 +433,7 @@ class SchedulerListComponent {
433
433
  // this.datasource.value.resultInfo.current = instance;
434
434
  const originalRecord = JSON.parse(JSON.stringify(arg?.event?.extendedProps || {}));
435
435
  this.datasource.value.setCurrent(originalRecord);
436
- var instance = this.datasource.value.resultInfo.current;
436
+ let instance = this.datasource.value.resultInfo.current;
437
437
  const startDate = arg?.event?.start ?? null;
438
438
  const endDate = arg?.event?.end ?? startDate;
439
439
  const sameField = String(this.fromField || '').trim().toLowerCase() === String(this.toField || '').trim().toLowerCase();
@@ -453,7 +453,7 @@ class SchedulerListComponent {
453
453
  instance[this.toField]?.next?.(this.serializeDateForColumn(endToPersist, toCol));
454
454
  }
455
455
  }
456
- var res = await this.datasource.value.syncData(instance, originalRecord);
456
+ let res = await this.datasource.value.syncData(instance, originalRecord);
457
457
  if (!res) {
458
458
  arg?.revert?.();
459
459
  return;
@@ -591,4 +591,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.8", ngImpor
591
591
  }] } });
592
592
 
593
593
  export { SchedulerListComponent };
594
- //# sourceMappingURL=wuic-framework-lib-scheduler-list.component-CIoGVf4O.mjs.map
594
+ //# sourceMappingURL=wuic-framework-lib-scheduler-list.component-E8s_e533.mjs.map