@eqproject/eqp-dynamic-module 2.4.11 → 2.4.13

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.
@@ -1,7 +1,7 @@
1
1
  import * as i2$2 from '@angular/common';
2
2
  import { CommonModule } from '@angular/common';
3
3
  import * as i0 from '@angular/core';
4
- import { Injectable, EventEmitter, Component, Input, ViewChild, Output, ViewChildren, NgModule, Inject } from '@angular/core';
4
+ import { Injectable, EventEmitter, Component, Input, ViewChild, Output, ViewChildren, HostListener, NgModule, Inject } from '@angular/core';
5
5
  import * as i5 from '@angular/forms';
6
6
  import { Validators, UntypedFormControl, FormsModule, ReactiveFormsModule } from '@angular/forms';
7
7
  import Swal from 'sweetalert2';
@@ -51,6 +51,7 @@ import { MatNativeDateModule } from '@angular/material/core';
51
51
  import * as i5$3 from '@angular/material/select';
52
52
  import { MatSelectModule } from '@angular/material/select';
53
53
  import * as i2$5 from '@angular/platform-browser';
54
+ import * as ss from 'simple-statistics';
54
55
  import * as i2$6 from '@canvasjs/angular-stockcharts';
55
56
  import { CanvasJSAngularStockChartsModule, CanvasJSChart, CanvasJSStockChart } from '@canvasjs/angular-stockcharts';
56
57
  import * as i8 from '@angular/material/autocomplete';
@@ -3132,10 +3133,10 @@ class ImageFieldTemplateComponent {
3132
3133
  }
3133
3134
  }
3134
3135
  ImageFieldTemplateComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ImageFieldTemplateComponent, deps: [{ token: i1$2.MatDialog }, { token: UtilityHelperService }], target: i0.ɵɵFactoryTarget.Component });
3135
- ImageFieldTemplateComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: ImageFieldTemplateComponent, selector: "image-field-template", inputs: { endPointConfiguration: "endPointConfiguration", record: "record", field: "field", inConfig: "inConfig" }, outputs: { recordChange: "recordChange", imageDraw: "imageDraw" }, viewQueries: [{ propertyName: "dialogImageDrawing", first: true, predicate: ["dialogImageDrawing"], descendants: true, static: true }], usesOnChanges: true, ngImport: i0, template: "<div class=\"row imageContainer\" style=\"width: {{imageWidth}}px;\">\r\n <div class=\"row\">\r\n <div class=\"col-12\">{{field.Description}}</div>\r\n <div class=\"col-12\"><img *ngIf=\"field.DynAttachment\"\r\n src=\"data:{{field.DynAttachment.FileContentType}};base64,{{FileDataBase64}}\"\r\n [height]=\"field.DynAttachment.ResizedImageHeightPx != null ? field.DynAttachment.ResizedImageHeightPx : 128\"\r\n class=\"singleImage\"></div>\r\n <div class=\"col-12 drawButton\">\r\n <button class=\"btn btn-primary btn-w100\" (click)=\"openDraw()\">Disegna</button>\r\n </div>\r\n <div class=\"col-12 flex justify-content-around buttonkey\" *ngIf=\"field.DynAttachment.ButtonKey != null && field.DynAttachment.ButtonKey != ''\">\r\n <div>Etichetta</div><div>{{field.DynAttachment.ButtonKey}}</div>\r\n </div>\r\n <div class=\"col-12 flex justify-content-around buttonvalue\" *ngIf=\"field.DynAttachment.ButtonValue != null && field.DynAttachment.ButtonValue != ''\"> \r\n <div>Valore</div><div>{{field.DynAttachment.ButtonValue}}</div>\r\n </div>\r\n </div> \r\n</div>\r\n\r\n<!-- DIALOG PER DISEGNARE SUL NUOVO ALLEGATO CARICATO -->\r\n<ng-template #dialogImageDrawing>\r\n <div class=\"padder\">\r\n <div\r\n class=\"row\">\r\n <div class=\"col-sm-12 col-md-12\">\r\n <tmw-image-drawer\r\n *ngIf=\"drawingLoaded\"\r\n [src]=\"'data:'+ field.DynAttachment.FileContentType + ';base64,'+ FileBase64\" [inConfig]=\"inConfig\"\r\n [showCancelButton]=\"false\" [enableLoadAnotherImage]=\"false\" [enableRemoveImage]=\"false\" [width]=\"field.DynAttachment.ImageWidthPx\"\r\n [height]=\"field.DynAttachment.ImageHeightPx\" [i18n]=\"i18n\" [showCancelButton]=\"true\" (save)=\"saveDraw($event)\" (loadOriginal)=\"loadOriginal()\" (closeDialog)=\"closeImageDrowingDialog()\">\r\n </tmw-image-drawer>\r\n </div>\r\n </div>\r\n </div>\r\n</ng-template>", styles: ["::ng-deep image-drawing>button{background-color:var(--primary)!important;color:#fff!important}.imageContainer .singleImage{margin-top:5px;display:block}.drawButton{margin:5px 0}.buttonkey{border-top:1px solid black;padding-top:10px}\n"], dependencies: [{ kind: "directive", type: i2$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: TmwImageDrawerComponent, selector: "tmw-image-drawer", inputs: ["src", "width", "height", "forceSizeCanvas", "forceSizeExport", "enableRemoveImage", "enableLoadAnotherImage", "enableTooltip", "showCancelButton", "inConfig", "i18n", "locale", "loadingTemplate", "errorTemplate", "outputMimeType", "outputQuality", "borderCss", "drawingSizes", "colors"], outputs: ["closeDialog", "save", "loadOriginal"] }] });
3136
+ ImageFieldTemplateComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: ImageFieldTemplateComponent, selector: "image-field-template", inputs: { endPointConfiguration: "endPointConfiguration", record: "record", field: "field", inConfig: "inConfig" }, outputs: { recordChange: "recordChange", imageDraw: "imageDraw" }, viewQueries: [{ propertyName: "dialogImageDrawing", first: true, predicate: ["dialogImageDrawing"], descendants: true, static: true }], usesOnChanges: true, ngImport: i0, template: "\r\n<div class=\"row imageContainer\" style=\"width: {{imageWidth}}px;\">\r\n <div class=\"row\">\r\n <div class=\"col-12\">{{field.Description}}</div>\r\n <div class=\"col-12\">\r\n <img *ngIf=\"field.DynAttachment\"\r\n src=\"data:{{field.DynAttachment.FileContentType}};base64,{{FileDataBase64}}\"\r\n [height]=\"field.DynAttachment.ResizedImageHeightPx != null ? field.DynAttachment.ResizedImageHeightPx : 128\"\r\n class=\"singleImage\">\r\n </div>\r\n <div *ngIf=\"field.EnableDrawing\" class=\"col-12 drawButton\">\r\n <button class=\"btn btn-primary btn-w100\" (click)=\"openDraw()\">Disegna</button>\r\n </div>\r\n <div *ngIf=\"field.DynAttachment.ButtonKey != null && field.DynAttachment.ButtonKey != ''\" class=\"col-12 flex justify-content-around buttonkey\">\r\n <div>Etichetta</div><div>{{field.DynAttachment.ButtonKey}}</div>\r\n </div>\r\n <div *ngIf=\"field.DynAttachment.ButtonValue != null && field.DynAttachment.ButtonValue != ''\" class=\"col-12 flex justify-content-around buttonvalue\"> \r\n <div>Valore</div><div>{{field.DynAttachment.ButtonValue}}</div>\r\n </div>\r\n </div> \r\n</div>\r\n\r\n<!-- DIALOG PER DISEGNARE SUL NUOVO ALLEGATO CARICATO -->\r\n<ng-template #dialogImageDrawing>\r\n <div class=\"padder\">\r\n <div class=\"row\">\r\n <div class=\"col-sm-12 col-md-12\">\r\n <tmw-image-drawer *ngIf=\"drawingLoaded\"\r\n [src]=\"'data:'+ field.DynAttachment.FileContentType + ';base64,'+ FileBase64\" \r\n [inConfig]=\"inConfig\"\r\n [showCancelButton]=\"false\" \r\n [enableLoadAnotherImage]=\"false\" \r\n [enableRemoveImage]=\"false\" \r\n [width]=\"field.DynAttachment.ImageWidthPx\"\r\n [height]=\"field.DynAttachment.ImageHeightPx\" \r\n [i18n]=\"i18n\" \r\n [showCancelButton]=\"true\" \r\n (save)=\"saveDraw($event)\" \r\n (loadOriginal)=\"loadOriginal()\" \r\n (closeDialog)=\"closeImageDrowingDialog()\"\r\n >\r\n </tmw-image-drawer>\r\n </div>\r\n </div>\r\n </div>\r\n</ng-template>", styles: ["::ng-deep image-drawing>button{background-color:var(--primary)!important;color:#fff!important}.imageContainer .singleImage{margin-top:5px;display:block}.drawButton{margin:5px 0}.buttonkey{border-top:1px solid black;padding-top:10px}\n"], dependencies: [{ kind: "directive", type: i2$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: TmwImageDrawerComponent, selector: "tmw-image-drawer", inputs: ["src", "width", "height", "forceSizeCanvas", "forceSizeExport", "enableRemoveImage", "enableLoadAnotherImage", "enableTooltip", "showCancelButton", "inConfig", "i18n", "locale", "loadingTemplate", "errorTemplate", "outputMimeType", "outputQuality", "borderCss", "drawingSizes", "colors"], outputs: ["closeDialog", "save", "loadOriginal"] }] });
3136
3137
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ImageFieldTemplateComponent, decorators: [{
3137
3138
  type: Component,
3138
- args: [{ selector: 'image-field-template', template: "<div class=\"row imageContainer\" style=\"width: {{imageWidth}}px;\">\r\n <div class=\"row\">\r\n <div class=\"col-12\">{{field.Description}}</div>\r\n <div class=\"col-12\"><img *ngIf=\"field.DynAttachment\"\r\n src=\"data:{{field.DynAttachment.FileContentType}};base64,{{FileDataBase64}}\"\r\n [height]=\"field.DynAttachment.ResizedImageHeightPx != null ? field.DynAttachment.ResizedImageHeightPx : 128\"\r\n class=\"singleImage\"></div>\r\n <div class=\"col-12 drawButton\">\r\n <button class=\"btn btn-primary btn-w100\" (click)=\"openDraw()\">Disegna</button>\r\n </div>\r\n <div class=\"col-12 flex justify-content-around buttonkey\" *ngIf=\"field.DynAttachment.ButtonKey != null && field.DynAttachment.ButtonKey != ''\">\r\n <div>Etichetta</div><div>{{field.DynAttachment.ButtonKey}}</div>\r\n </div>\r\n <div class=\"col-12 flex justify-content-around buttonvalue\" *ngIf=\"field.DynAttachment.ButtonValue != null && field.DynAttachment.ButtonValue != ''\"> \r\n <div>Valore</div><div>{{field.DynAttachment.ButtonValue}}</div>\r\n </div>\r\n </div> \r\n</div>\r\n\r\n<!-- DIALOG PER DISEGNARE SUL NUOVO ALLEGATO CARICATO -->\r\n<ng-template #dialogImageDrawing>\r\n <div class=\"padder\">\r\n <div\r\n class=\"row\">\r\n <div class=\"col-sm-12 col-md-12\">\r\n <tmw-image-drawer\r\n *ngIf=\"drawingLoaded\"\r\n [src]=\"'data:'+ field.DynAttachment.FileContentType + ';base64,'+ FileBase64\" [inConfig]=\"inConfig\"\r\n [showCancelButton]=\"false\" [enableLoadAnotherImage]=\"false\" [enableRemoveImage]=\"false\" [width]=\"field.DynAttachment.ImageWidthPx\"\r\n [height]=\"field.DynAttachment.ImageHeightPx\" [i18n]=\"i18n\" [showCancelButton]=\"true\" (save)=\"saveDraw($event)\" (loadOriginal)=\"loadOriginal()\" (closeDialog)=\"closeImageDrowingDialog()\">\r\n </tmw-image-drawer>\r\n </div>\r\n </div>\r\n </div>\r\n</ng-template>", styles: ["::ng-deep image-drawing>button{background-color:var(--primary)!important;color:#fff!important}.imageContainer .singleImage{margin-top:5px;display:block}.drawButton{margin:5px 0}.buttonkey{border-top:1px solid black;padding-top:10px}\n"] }]
3139
+ args: [{ selector: 'image-field-template', template: "\r\n<div class=\"row imageContainer\" style=\"width: {{imageWidth}}px;\">\r\n <div class=\"row\">\r\n <div class=\"col-12\">{{field.Description}}</div>\r\n <div class=\"col-12\">\r\n <img *ngIf=\"field.DynAttachment\"\r\n src=\"data:{{field.DynAttachment.FileContentType}};base64,{{FileDataBase64}}\"\r\n [height]=\"field.DynAttachment.ResizedImageHeightPx != null ? field.DynAttachment.ResizedImageHeightPx : 128\"\r\n class=\"singleImage\">\r\n </div>\r\n <div *ngIf=\"field.EnableDrawing\" class=\"col-12 drawButton\">\r\n <button class=\"btn btn-primary btn-w100\" (click)=\"openDraw()\">Disegna</button>\r\n </div>\r\n <div *ngIf=\"field.DynAttachment.ButtonKey != null && field.DynAttachment.ButtonKey != ''\" class=\"col-12 flex justify-content-around buttonkey\">\r\n <div>Etichetta</div><div>{{field.DynAttachment.ButtonKey}}</div>\r\n </div>\r\n <div *ngIf=\"field.DynAttachment.ButtonValue != null && field.DynAttachment.ButtonValue != ''\" class=\"col-12 flex justify-content-around buttonvalue\"> \r\n <div>Valore</div><div>{{field.DynAttachment.ButtonValue}}</div>\r\n </div>\r\n </div> \r\n</div>\r\n\r\n<!-- DIALOG PER DISEGNARE SUL NUOVO ALLEGATO CARICATO -->\r\n<ng-template #dialogImageDrawing>\r\n <div class=\"padder\">\r\n <div class=\"row\">\r\n <div class=\"col-sm-12 col-md-12\">\r\n <tmw-image-drawer *ngIf=\"drawingLoaded\"\r\n [src]=\"'data:'+ field.DynAttachment.FileContentType + ';base64,'+ FileBase64\" \r\n [inConfig]=\"inConfig\"\r\n [showCancelButton]=\"false\" \r\n [enableLoadAnotherImage]=\"false\" \r\n [enableRemoveImage]=\"false\" \r\n [width]=\"field.DynAttachment.ImageWidthPx\"\r\n [height]=\"field.DynAttachment.ImageHeightPx\" \r\n [i18n]=\"i18n\" \r\n [showCancelButton]=\"true\" \r\n (save)=\"saveDraw($event)\" \r\n (loadOriginal)=\"loadOriginal()\" \r\n (closeDialog)=\"closeImageDrowingDialog()\"\r\n >\r\n </tmw-image-drawer>\r\n </div>\r\n </div>\r\n </div>\r\n</ng-template>", styles: ["::ng-deep image-drawing>button{background-color:var(--primary)!important;color:#fff!important}.imageContainer .singleImage{margin-top:5px;display:block}.drawButton{margin:5px 0}.buttonkey{border-top:1px solid black;padding-top:10px}\n"] }]
3139
3140
  }], ctorParameters: function () { return [{ type: i1$2.MatDialog }, { type: UtilityHelperService }]; }, propDecorators: { endPointConfiguration: [{
3140
3141
  type: Input
3141
3142
  }], record: [{
@@ -3181,7 +3182,8 @@ class ImageFieldSelectorTemplateComponent {
3181
3182
  this.recordChange = new EventEmitter();
3182
3183
  }
3183
3184
  ngOnInit() {
3184
- console.log("RECORD ngOnInit()", this.record[this.field.Name], this.field);
3185
+ GlobalService.debugLog("ImageFieldSelectorTemplateComponent - RECORD ngOnInit() - record", this.record[this.field.Name]);
3186
+ GlobalService.debugLog("ImageFieldSelectorTemplateComponent - RECORD ngOnInit() - field", this.field);
3185
3187
  this.initStyles();
3186
3188
  this.initializeAttachments();
3187
3189
  }
@@ -4770,10 +4772,15 @@ class Coords {
4770
4772
  }
4771
4773
 
4772
4774
  class GraphComponent {
4775
+ onResize() {
4776
+ this.loaded = false;
4777
+ this.loadGraph(Math.floor(window.innerWidth / 2));
4778
+ }
4773
4779
  constructor(datePipe) {
4774
4780
  this.datePipe = datePipe;
4775
4781
  this.data = new Array();
4776
4782
  this.title = "";
4783
+ this.trendColor = '#EB0102';
4777
4784
  this.loaded = false;
4778
4785
  this.counter = 0;
4779
4786
  }
@@ -4781,48 +4788,92 @@ class GraphComponent {
4781
4788
  var self = this;
4782
4789
  // Aggiustamento e scrittura dati
4783
4790
  if (this.data.length > 0) {
4784
- var lastvalue = this.data[0];
4785
- var firstvalue = this.data[this.data.length - 1];
4786
- var stockChartMinimum = new Date(firstvalue.x);
4787
- var stockChartMaximum = new Date(lastvalue.x);
4788
- var stockChartTitleText = this.title;
4789
- var stockChartdataPoints = this.data;
4790
- this.stockChartOptions = {
4791
- theme: 'light2',
4792
- animationEnabled: true,
4793
- width: 1000,
4794
- height: 500,
4795
- creditText: "",
4796
- creditHref: "",
4797
- title: {
4798
- text: stockChartTitleText
4799
- },
4800
- charts: [{
4801
- axisX: {
4802
- labelFormatter: this.labelFormatterFunction,
4791
+ this.loadGraph(Math.floor(window.innerWidth / 2));
4792
+ }
4793
+ }
4794
+ loadGraph(width) {
4795
+ var lastvalue = this.data[0];
4796
+ var firstvalue = this.data[this.data.length - 1];
4797
+ var stockChartMinimum = new Date(firstvalue.x);
4798
+ var stockChartMaximum = new Date(lastvalue.x);
4799
+ var stockChartTitleText = this.title;
4800
+ var stockChartdataPoints = this.data;
4801
+ this.linearRegression = new Array();
4802
+ this.trend = "";
4803
+ stockChartdataPoints.reverse();
4804
+ if (stockChartdataPoints.length > 2) {
4805
+ let x = [];
4806
+ for (let i = 0; i < stockChartdataPoints.length; i++) {
4807
+ x.push([i, stockChartdataPoints[i].y]);
4808
+ }
4809
+ let parameters = ss.linearRegression(x);
4810
+ this.m = parameters.m;
4811
+ this.q = parameters.b;
4812
+ if (this.m > 0) {
4813
+ this.trend += " ↗";
4814
+ }
4815
+ else if (this.m < 0) {
4816
+ this.trend += " ↘";
4817
+ }
4818
+ // console.log(x);
4819
+ // console.log(stockChartdataPoints);
4820
+ for (let i = 0; i < stockChartdataPoints.length; i++) {
4821
+ this.linearRegression.push({ x: stockChartdataPoints[i].x,
4822
+ y: this.m * i + this.q,
4823
+ label: stockChartdataPoints[i].label,
4824
+ name: stockChartdataPoints[i].name
4825
+ });
4826
+ }
4827
+ //this.linearRegression.reverse();
4828
+ // console.log(this.linearRegression);
4829
+ // console.log(this.m);
4830
+ // console.log(this.q);
4831
+ }
4832
+ this.stockChartOptions = {
4833
+ theme: 'light2',
4834
+ animationEnabled: true,
4835
+ width: width,
4836
+ height: 500,
4837
+ creditText: "",
4838
+ creditHref: "",
4839
+ title: {
4840
+ text: stockChartTitleText
4841
+ },
4842
+ charts: [{
4843
+ axisX: {
4844
+ labelFormatter: this.labelFormatterFunction,
4845
+ },
4846
+ data: [{
4847
+ type: "spline",
4848
+ dataPoints: stockChartdataPoints
4803
4849
  },
4804
- data: [{
4805
- type: "line",
4806
- dataPoints: stockChartdataPoints
4807
- }],
4808
- culture: "it"
4809
- }],
4810
- rangeSelector: {
4811
- enabled: false
4812
- },
4813
- navigator: {
4814
- slider: {
4815
- minimum: stockChartMinimum,
4816
- maximum: stockChartMaximum
4817
- }
4818
- },
4819
- options: {
4820
- responsive: true,
4821
- maintainAspectRatio: false
4850
+ {
4851
+ //toolTipContent: null,
4852
+ type: 'line',
4853
+ color: this.trendColor,
4854
+ showInLegend: true,
4855
+ legendMarkerType: "none",
4856
+ markerType: "none",
4857
+ legendText: "Trend" + this.trend,
4858
+ dataPoints: this.linearRegression
4859
+ }],
4860
+ culture: "it"
4861
+ }],
4862
+ rangeSelector: {
4863
+ enabled: false
4864
+ },
4865
+ navigator: {
4866
+ slider: {
4867
+ minimum: stockChartMinimum,
4868
+ maximum: stockChartMaximum
4822
4869
  }
4823
- };
4824
- this.loaded = true;
4825
- }
4870
+ },
4871
+ options: {
4872
+ responsive: true,
4873
+ maintainAspectRatio: false
4874
+ }
4875
+ };
4876
+ this.loaded = true;
4826
4877
  }
4827
4878
  labelFormatterFunction(e) {
4828
4879
  let label = "";
@@ -4874,11 +4925,14 @@ class GraphComponent {
4874
4925
  }
4875
4926
  }
4876
4927
  GraphComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: GraphComponent, deps: [{ token: i2$2.DatePipe }], target: i0.ɵɵFactoryTarget.Component });
4877
- GraphComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: GraphComponent, selector: "graph", inputs: { data: "data", title: "title" }, ngImport: i0, template: "<canvasjs-stockchart *ngIf=\"loaded\" [options]=\"stockChartOptions\"></canvasjs-stockchart>\r\n<div class=\"error\" *ngIf=\"!loaded\"><b>{{title}}:</b> Nessun dato trovato nell'intervallo specificato!</div>", styles: [""], dependencies: [{ kind: "directive", type: i2$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i2$6.CanvasJSStockChart, selector: "canvasjs-stockchart", inputs: ["options", "styles"], outputs: ["stockChartInstance"] }] });
4928
+ GraphComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: GraphComponent, selector: "graph", inputs: { data: "data", title: "title" }, host: { listeners: { "window:resize": "onResize($event)" } }, ngImport: i0, template: "<canvasjs-stockchart *ngIf=\"loaded\" [options]=\"stockChartOptions\"></canvasjs-stockchart>\r\n<div class=\"error\" *ngIf=\"!loaded\"><b>{{title}}:</b> Nessun dato trovato nell'intervallo specificato!</div>", styles: [""], dependencies: [{ kind: "directive", type: i2$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i2$6.CanvasJSStockChart, selector: "canvasjs-stockchart", inputs: ["options", "styles"], outputs: ["stockChartInstance"] }] });
4878
4929
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: GraphComponent, decorators: [{
4879
4930
  type: Component,
4880
4931
  args: [{ selector: 'graph', template: "<canvasjs-stockchart *ngIf=\"loaded\" [options]=\"stockChartOptions\"></canvasjs-stockchart>\r\n<div class=\"error\" *ngIf=\"!loaded\"><b>{{title}}:</b> Nessun dato trovato nell'intervallo specificato!</div>" }]
4881
- }], ctorParameters: function () { return [{ type: i2$2.DatePipe }]; }, propDecorators: { data: [{
4932
+ }], ctorParameters: function () { return [{ type: i2$2.DatePipe }]; }, propDecorators: { onResize: [{
4933
+ type: HostListener,
4934
+ args: ['window:resize', ['$event']]
4935
+ }], data: [{
4882
4936
  type: Input,
4883
4937
  args: ["data"]
4884
4938
  }], title: [{
@@ -4929,6 +4983,7 @@ class GraphsComponent {
4929
4983
  this.form.Fields.filter(x => x.FieldType == FieldTypeEnum['Campo numerico']).forEach((field) => {
4930
4984
  var graphField = new GraphField();
4931
4985
  graphField.Name = field.Label;
4986
+ graphField.Description = field.Description;
4932
4987
  this.fields.push(graphField);
4933
4988
  });
4934
4989
  this.getRecordsByFormID();
@@ -5016,10 +5071,10 @@ class GraphsComponent {
5016
5071
  }
5017
5072
  }
5018
5073
  GraphsComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: GraphsComponent, deps: [{ token: UtilityHelperService }, { token: i2$2.DatePipe }], target: i0.ɵɵFactoryTarget.Component });
5019
- GraphsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: GraphsComponent, selector: "graphs", inputs: { configurations: "configurations", endPointConfiguration: "endPointConfiguration", userID: "userID", formID: "formID", form: "form" }, ngImport: i0, template: "<mat-card class=\"list-view-form-record\" *ngIf=\"loaded\">\r\n <mat-card-content>\r\n \r\n\r\n <div class=\"row\">\r\n <div class=\"col-sm-12 col-md-3 mt-2\">\r\n <eqp-datetimepicker class=\"date\" [placeholder]=\"'Periodo inizio'\"\r\n [(ngModelInput)]=\"minperiod\"\r\n [pickerMode]=\"pickerModeEnum.DATE\" [UTCDate]=\"true\" [showSeconds]=\"false\">\r\n </eqp-datetimepicker>\r\n </div>\r\n <div class=\"col-sm-12 col-md-3 mt-2\">\r\n <eqp-datetimepicker class=\"date\" [placeholder]=\"'Periodo fine'\"\r\n [(ngModelInput)]=\"maxperiod\"\r\n [pickerMode]=\"pickerModeEnum.DATE\" [UTCDate]=\"true\" [showSeconds]=\"false\">\r\n </eqp-datetimepicker>\r\n </div> \r\n <div class=\"col-sm-12 col-md-3 mt-2\">\r\n <eqp-select [arrayData]=\"fields\" [(ngModelInput)]=\"selectedFields\" [placeholder]=\"'Selezione dei campi'\"\r\n [arrayKeyProperty]=\"'Name'\" [arrayValueProperty]=\"'Name'\" [isMultiSelect]=\"true\">\r\n </eqp-select>\r\n </div> \r\n <div class=\"col-sm-12 col-md-3 mt-2\">\r\n <button\r\n [disabled]=\"selectedFields == null || selectedFields.length == 0\"\r\n class=\"btn btn-graph-generate button-next me-2\"\r\n mat-raised-button\r\n color=\"primary\"\r\n (click)=\"generateGraph()\"\r\n >\r\n Genera\r\n </button>\r\n </div> \r\n </div>\r\n <div class=\"generation_box\" *ngIf=\"generated\">\r\n <div class=\"row\">\r\n <div class=\"col-3\">\r\n <div class=\"generation_options\" *ngFor=\"let selectedField of selectedGeneratedFields\">\r\n <mat-checkbox class=\"mr-2\" [(ngModel)]=\"selectedField.Visible\">\r\n {{selectedField.Name}}\r\n </mat-checkbox>\r\n </div>\r\n </div>\r\n <div class=\"col-9\">\r\n <div class=\"generation_graph\" *ngFor=\"let selectedField of selectedGeneratedFields\">\r\n <div class=\"generation_divider\" [hidden]=\"!selectedField.Visible\">\r\n <graph [data]=\"selectedField.Coords\" [title]=\"selectedField.Name\"></graph>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n \r\n \r\n </mat-card-content>\r\n <mat-card-footer>\r\n </mat-card-footer>\r\n </mat-card>", styles: [".btn-graph-generate{height:56px;width:100%}.generation_box .generation_divider{margin-bottom:10px;padding-bottom:10px;border-bottom:2px solid black;width:100%;height:600px}.generation_box .generation_divider>*{width:100%;height:400px}\n"], dependencies: [{ kind: "component", type: i1.MatCheckbox, selector: "mat-checkbox", inputs: ["disableRipple", "color", "tabIndex"], exportAs: ["matCheckbox"] }, { kind: "component", type: i2$1.MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "component", type: i5$1.MatCard, selector: "mat-card", inputs: ["appearance"], exportAs: ["matCard"] }, { kind: "directive", type: i5$1.MatCardContent, selector: "mat-card-content" }, { kind: "directive", type: i5$1.MatCardFooter, selector: "mat-card-footer" }, { kind: "directive", type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i2$2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i7.EqpSelectComponent, selector: "eqp-select", inputs: ["placeholder", "enumData", "enumDataToExclude", "arrayData", "arrayKeyProperty", "arrayValueProperty", "ngModelOptions", "ngModelInput", "formGroupInput", "formControlNameInput", "isRequired", "isDisabled", "isMultiLanguage", "multilanguagePrefixKey", "isAlphabeticalOrderable", "suffixIcon", "prefixIcon", "isMultiSelect", "includeFullObject", "showCancelButton", "isSearchable", "searchText", "noResultSearchText", "data"], outputs: ["ngModelInputChange"] }, { kind: "component", type: i1$1.EqpDateTimePickerComponent, selector: "eqp-datetimepicker", inputs: ["placeholder", "ngModelInput", "UTCDate", "timeType", "pickerMode", "formControlNameInput", "formGroupInput", "isRequired", "minDate", "maxDate", "readonlyInput", "disabled", "showSpinners", "showSeconds", "disableMinute", "defaultTime", "stepHour", "stepMinute", "stepSecond", "color", "enableMeridian", "touchUi", "customDateFormat"], outputs: ["ngModelInputChange", "onDateChange"] }, { kind: "component", type: GraphComponent, selector: "graph", inputs: ["data", "title"] }] });
5074
+ GraphsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: GraphsComponent, selector: "graphs", inputs: { configurations: "configurations", endPointConfiguration: "endPointConfiguration", userID: "userID", formID: "formID", form: "form" }, ngImport: i0, template: "<mat-card class=\"list-view-form-record\" *ngIf=\"loaded\">\r\n <mat-card-content>\r\n \r\n\r\n <div class=\"row\">\r\n <div class=\"col-sm-12 col-md-3 mt-2\">\r\n <eqp-datetimepicker class=\"date\" [placeholder]=\"'Periodo inizio'\"\r\n [(ngModelInput)]=\"minperiod\"\r\n [pickerMode]=\"pickerModeEnum.DATE\" [UTCDate]=\"true\" [showSeconds]=\"false\">\r\n </eqp-datetimepicker>\r\n </div>\r\n <div class=\"col-sm-12 col-md-3 mt-2\">\r\n <eqp-datetimepicker class=\"date\" [placeholder]=\"'Periodo fine'\"\r\n [(ngModelInput)]=\"maxperiod\"\r\n [pickerMode]=\"pickerModeEnum.DATE\" [UTCDate]=\"true\" [showSeconds]=\"false\">\r\n </eqp-datetimepicker>\r\n </div> \r\n <div class=\"col-sm-12 col-md-3 mt-2\">\r\n <eqp-select [arrayData]=\"fields\" [(ngModelInput)]=\"selectedFields\" [placeholder]=\"'Selezione dei campi'\"\r\n [arrayKeyProperty]=\"'Description'\" [arrayValueProperty]=\"'Description'\" [isMultiSelect]=\"true\">\r\n </eqp-select>\r\n </div> \r\n <div class=\"col-sm-12 col-md-3 mt-2\">\r\n <button\r\n [disabled]=\"selectedFields == null || selectedFields.length == 0\"\r\n class=\"btn btn-graph-generate button-next me-2\"\r\n mat-raised-button\r\n color=\"primary\"\r\n (click)=\"generateGraph()\"\r\n >\r\n Genera\r\n </button>\r\n </div> \r\n </div>\r\n <div class=\"generation_box\" *ngIf=\"generated\">\r\n <div class=\"row\">\r\n <div class=\"col-3\">\r\n <div class=\"generation_options\" *ngFor=\"let selectedField of selectedGeneratedFields\">\r\n <mat-checkbox class=\"mr-2\" [(ngModel)]=\"selectedField.Visible\">\r\n {{selectedField.Description}}\r\n </mat-checkbox>\r\n </div>\r\n </div>\r\n <div class=\"col-9\">\r\n <div class=\"generation_graph\" *ngFor=\"let selectedField of selectedGeneratedFields\">\r\n <div class=\"generation_divider\" [hidden]=\"!selectedField.Visible\">\r\n <graph [data]=\"selectedField.Coords\" [title]=\"selectedField.Description\"></graph>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n \r\n \r\n </mat-card-content>\r\n <mat-card-footer>\r\n </mat-card-footer>\r\n </mat-card>", styles: [".btn-graph-generate{height:56px;width:100%}.generation_box .generation_divider{margin-bottom:10px;padding-bottom:10px;border-bottom:2px solid black;width:100%;height:600px}.generation_box .generation_divider>*{width:100%;height:400px}\n"], dependencies: [{ kind: "component", type: i1.MatCheckbox, selector: "mat-checkbox", inputs: ["disableRipple", "color", "tabIndex"], exportAs: ["matCheckbox"] }, { kind: "component", type: i2$1.MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "component", type: i5$1.MatCard, selector: "mat-card", inputs: ["appearance"], exportAs: ["matCard"] }, { kind: "directive", type: i5$1.MatCardContent, selector: "mat-card-content" }, { kind: "directive", type: i5$1.MatCardFooter, selector: "mat-card-footer" }, { kind: "directive", type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i2$2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i7.EqpSelectComponent, selector: "eqp-select", inputs: ["placeholder", "enumData", "enumDataToExclude", "arrayData", "arrayKeyProperty", "arrayValueProperty", "ngModelOptions", "ngModelInput", "formGroupInput", "formControlNameInput", "isRequired", "isDisabled", "isMultiLanguage", "multilanguagePrefixKey", "isAlphabeticalOrderable", "suffixIcon", "prefixIcon", "isMultiSelect", "includeFullObject", "showCancelButton", "isSearchable", "searchText", "noResultSearchText", "data"], outputs: ["ngModelInputChange"] }, { kind: "component", type: i1$1.EqpDateTimePickerComponent, selector: "eqp-datetimepicker", inputs: ["placeholder", "ngModelInput", "UTCDate", "timeType", "pickerMode", "formControlNameInput", "formGroupInput", "isRequired", "minDate", "maxDate", "readonlyInput", "disabled", "showSpinners", "showSeconds", "disableMinute", "defaultTime", "stepHour", "stepMinute", "stepSecond", "color", "enableMeridian", "touchUi", "customDateFormat"], outputs: ["ngModelInputChange", "onDateChange"] }, { kind: "component", type: GraphComponent, selector: "graph", inputs: ["data", "title"] }] });
5020
5075
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: GraphsComponent, decorators: [{
5021
5076
  type: Component,
5022
- args: [{ selector: 'graphs', template: "<mat-card class=\"list-view-form-record\" *ngIf=\"loaded\">\r\n <mat-card-content>\r\n \r\n\r\n <div class=\"row\">\r\n <div class=\"col-sm-12 col-md-3 mt-2\">\r\n <eqp-datetimepicker class=\"date\" [placeholder]=\"'Periodo inizio'\"\r\n [(ngModelInput)]=\"minperiod\"\r\n [pickerMode]=\"pickerModeEnum.DATE\" [UTCDate]=\"true\" [showSeconds]=\"false\">\r\n </eqp-datetimepicker>\r\n </div>\r\n <div class=\"col-sm-12 col-md-3 mt-2\">\r\n <eqp-datetimepicker class=\"date\" [placeholder]=\"'Periodo fine'\"\r\n [(ngModelInput)]=\"maxperiod\"\r\n [pickerMode]=\"pickerModeEnum.DATE\" [UTCDate]=\"true\" [showSeconds]=\"false\">\r\n </eqp-datetimepicker>\r\n </div> \r\n <div class=\"col-sm-12 col-md-3 mt-2\">\r\n <eqp-select [arrayData]=\"fields\" [(ngModelInput)]=\"selectedFields\" [placeholder]=\"'Selezione dei campi'\"\r\n [arrayKeyProperty]=\"'Name'\" [arrayValueProperty]=\"'Name'\" [isMultiSelect]=\"true\">\r\n </eqp-select>\r\n </div> \r\n <div class=\"col-sm-12 col-md-3 mt-2\">\r\n <button\r\n [disabled]=\"selectedFields == null || selectedFields.length == 0\"\r\n class=\"btn btn-graph-generate button-next me-2\"\r\n mat-raised-button\r\n color=\"primary\"\r\n (click)=\"generateGraph()\"\r\n >\r\n Genera\r\n </button>\r\n </div> \r\n </div>\r\n <div class=\"generation_box\" *ngIf=\"generated\">\r\n <div class=\"row\">\r\n <div class=\"col-3\">\r\n <div class=\"generation_options\" *ngFor=\"let selectedField of selectedGeneratedFields\">\r\n <mat-checkbox class=\"mr-2\" [(ngModel)]=\"selectedField.Visible\">\r\n {{selectedField.Name}}\r\n </mat-checkbox>\r\n </div>\r\n </div>\r\n <div class=\"col-9\">\r\n <div class=\"generation_graph\" *ngFor=\"let selectedField of selectedGeneratedFields\">\r\n <div class=\"generation_divider\" [hidden]=\"!selectedField.Visible\">\r\n <graph [data]=\"selectedField.Coords\" [title]=\"selectedField.Name\"></graph>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n \r\n \r\n </mat-card-content>\r\n <mat-card-footer>\r\n </mat-card-footer>\r\n </mat-card>", styles: [".btn-graph-generate{height:56px;width:100%}.generation_box .generation_divider{margin-bottom:10px;padding-bottom:10px;border-bottom:2px solid black;width:100%;height:600px}.generation_box .generation_divider>*{width:100%;height:400px}\n"] }]
5077
+ args: [{ selector: 'graphs', template: "<mat-card class=\"list-view-form-record\" *ngIf=\"loaded\">\r\n <mat-card-content>\r\n \r\n\r\n <div class=\"row\">\r\n <div class=\"col-sm-12 col-md-3 mt-2\">\r\n <eqp-datetimepicker class=\"date\" [placeholder]=\"'Periodo inizio'\"\r\n [(ngModelInput)]=\"minperiod\"\r\n [pickerMode]=\"pickerModeEnum.DATE\" [UTCDate]=\"true\" [showSeconds]=\"false\">\r\n </eqp-datetimepicker>\r\n </div>\r\n <div class=\"col-sm-12 col-md-3 mt-2\">\r\n <eqp-datetimepicker class=\"date\" [placeholder]=\"'Periodo fine'\"\r\n [(ngModelInput)]=\"maxperiod\"\r\n [pickerMode]=\"pickerModeEnum.DATE\" [UTCDate]=\"true\" [showSeconds]=\"false\">\r\n </eqp-datetimepicker>\r\n </div> \r\n <div class=\"col-sm-12 col-md-3 mt-2\">\r\n <eqp-select [arrayData]=\"fields\" [(ngModelInput)]=\"selectedFields\" [placeholder]=\"'Selezione dei campi'\"\r\n [arrayKeyProperty]=\"'Description'\" [arrayValueProperty]=\"'Description'\" [isMultiSelect]=\"true\">\r\n </eqp-select>\r\n </div> \r\n <div class=\"col-sm-12 col-md-3 mt-2\">\r\n <button\r\n [disabled]=\"selectedFields == null || selectedFields.length == 0\"\r\n class=\"btn btn-graph-generate button-next me-2\"\r\n mat-raised-button\r\n color=\"primary\"\r\n (click)=\"generateGraph()\"\r\n >\r\n Genera\r\n </button>\r\n </div> \r\n </div>\r\n <div class=\"generation_box\" *ngIf=\"generated\">\r\n <div class=\"row\">\r\n <div class=\"col-3\">\r\n <div class=\"generation_options\" *ngFor=\"let selectedField of selectedGeneratedFields\">\r\n <mat-checkbox class=\"mr-2\" [(ngModel)]=\"selectedField.Visible\">\r\n {{selectedField.Description}}\r\n </mat-checkbox>\r\n </div>\r\n </div>\r\n <div class=\"col-9\">\r\n <div class=\"generation_graph\" *ngFor=\"let selectedField of selectedGeneratedFields\">\r\n <div class=\"generation_divider\" [hidden]=\"!selectedField.Visible\">\r\n <graph [data]=\"selectedField.Coords\" [title]=\"selectedField.Description\"></graph>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n \r\n \r\n </mat-card-content>\r\n <mat-card-footer>\r\n </mat-card-footer>\r\n </mat-card>", styles: [".btn-graph-generate{height:56px;width:100%}.generation_box .generation_divider{margin-bottom:10px;padding-bottom:10px;border-bottom:2px solid black;width:100%;height:600px}.generation_box .generation_divider>*{width:100%;height:400px}\n"] }]
5023
5078
  }], ctorParameters: function () { return [{ type: UtilityHelperService }, { type: i2$2.DatePipe }]; }, propDecorators: { configurations: [{
5024
5079
  type: Input
5025
5080
  }], endPointConfiguration: [{
@@ -8520,6 +8575,7 @@ class AddFormFieldComponent {
8520
8575
  this.field.EnableDrawing = false;
8521
8576
  }
8522
8577
  this.fieldFormGroup.addControl("ResizedImagesHeightPx", new UntypedFormControl(this.field.ResizedImagesHeightPx, [Validators.required, Validators.max(4320)]));
8578
+ this.field.ResizedImagesHeightPx = this.field.ResizedImagesHeightPx != null ? this.field.ResizedImagesHeightPx : 128;
8523
8579
  this.fieldFormGroup.addControl("EnableDrawing", new UntypedFormControl(this.field.EnableDrawing));
8524
8580
  this.fieldTypeFormTemplate = this.imageFieldFormTemplate;
8525
8581
  break;
@@ -9882,7 +9938,7 @@ class EqpDynamicModuleConfiguratorComponent {
9882
9938
  {
9883
9939
  key: "Formula",
9884
9940
  display: "Calcolato",
9885
- value: (element) => element.Formula,
9941
+ value: (element) => element.Formula != null && element.Formula != '',
9886
9942
  type: TypeColumn.Boolean,
9887
9943
  booleanValues: {
9888
9944
  true: '<i class="fa fa-check success-color"></i>',
@@ -9892,41 +9948,40 @@ class EqpDynamicModuleConfiguratorComponent {
9892
9948
  },
9893
9949
  {
9894
9950
  key: "InListView",
9895
- display: "Compilazione Visibile",
9951
+ display: "Visibile in Compilazione",
9896
9952
  value: (element) => element.InListView,
9897
9953
  type: TypeColumn.Boolean,
9898
9954
  booleanValues: {
9899
9955
  true: '<i class="fa fa-check success-color"></i>',
9900
9956
  false: '<i class="fa fa-close error-color"></i>',
9901
9957
  },
9902
- styles: { flex: "0 0 5rem", cellAlignment: CellAlignmentEnum.CENTER },
9958
+ styles: { flex: "0 0 7rem", cellAlignment: CellAlignmentEnum.CENTER },
9903
9959
  },
9904
9960
  {
9905
9961
  key: "Invisibility",
9906
- display: "Compilazione Invisibilità",
9907
- value: (element) => element.Invisibility,
9908
- type: TypeColumn.Enum,
9909
- enumModel: FieldInvisibilityEnum,
9962
+ display: "Occupa spazio?",
9963
+ value: (element) => element.InListView || element.Invisibility == FieldInvisibilityEnum["NASCOSTO CON AREA VISIBILE"],
9964
+ type: TypeColumn.Boolean,
9910
9965
  booleanValues: {
9911
9966
  true: '<i class="fa fa-check success-color"></i>',
9912
9967
  false: '<i class="fa fa-close error-color"></i>',
9913
9968
  },
9914
- styles: { flex: "0 0 5rem", cellAlignment: CellAlignmentEnum.CENTER },
9969
+ styles: { flex: "0 0 7rem", cellAlignment: CellAlignmentEnum.CENTER },
9915
9970
  },
9916
9971
  {
9917
9972
  key: "VisibleIf",
9918
- display: "Calcolo Visibile",
9973
+ display: "Visibilità condizionata",
9919
9974
  value: (element) => element.VisibleIf != null && element.VisibleIf != "",
9920
9975
  type: TypeColumn.Boolean,
9921
9976
  booleanValues: {
9922
9977
  true: '<i class="fa fa-check success-color"></i>',
9923
9978
  false: '<i class="fa fa-close error-color"></i>',
9924
9979
  },
9925
- styles: { flex: "0 0 5rem", cellAlignment: CellAlignmentEnum.CENTER },
9980
+ styles: { flex: "0 0 7rem", cellAlignment: CellAlignmentEnum.CENTER },
9926
9981
  },
9927
9982
  {
9928
9983
  key: "AnswerStyle.InListView",
9929
- display: "Risposta Visibile",
9984
+ display: "Visibile nella risposta",
9930
9985
  value: (element) => !element.AnswerStyle || element.AnswerStyle && element.AnswerStyle.InListView,
9931
9986
  type: TypeColumn.Boolean,
9932
9987
  booleanValues: {