@fluxhub/fluxhub-lib 11.0.119 → 11.0.121
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/bundles/fluxhub-fluxhub-lib.umd.js +204 -365
- package/bundles/fluxhub-fluxhub-lib.umd.js.map +1 -1
- package/bundles/fluxhub-fluxhub-lib.umd.min.js +1 -1
- package/bundles/fluxhub-fluxhub-lib.umd.min.js.map +1 -1
- package/esm2015/lib/controls/fhautocomplete.js +2 -2
- package/esm2015/lib/controls/fhcombobox.js +2 -3
- package/esm2015/lib/controls/fhgridn.js +200 -362
- package/esm2015/lib/controls/fhnumeric.js +2 -2
- package/esm2015/lib/controls/fhtextinput.js +2 -2
- package/fesm2015/fluxhub-fluxhub-lib.js +203 -366
- package/fesm2015/fluxhub-fluxhub-lib.js.map +1 -1
- package/fluxhub-fluxhub-lib.metadata.json +1 -1
- package/lib/controls/fhgridn.d.ts +17 -2
- package/package.json +1 -1
|
@@ -8240,7 +8240,7 @@
|
|
|
8240
8240
|
{ type: i0.Component, args: [{
|
|
8241
8241
|
selector: "FHComboBox",
|
|
8242
8242
|
providers: [CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$7],
|
|
8243
|
-
template: "\n <div style=\"min-height:45px\" *ngIf=\"enabled && !hidden && !is_loaded && myData?.length==0\"><mat-spinner diameter=\"25\" ></mat-spinner></div>\n <mat-form-field\n [hidden]=\"!enabled || hidden || (!is_loaded && myData.length==0)\" [class.fh_field]=\"enabled\"\n appearance=\"outline\"\n floatLabel=\"always\"\n ><mat-label>{{ label|translate }}</mat-label>\n <mat-select\n #cmb\n [(ngModel)]=\"selval\"\n (selectionChange)=\"sc()\"\n [required]=\"required\"\n [matTooltip]=\"tooltip\"\n >\n <mat-option value=\"-1\" *ngIf=\"show_empty\">{{ sel_label }}</mat-option>\n <mat-option value=\"{{ app.valore }}\" *ngFor=\"let app of myData\">{{\n app.descrizione_valore | translate\n }}</mat-option>\n </mat-select>\n
|
|
8243
|
+
template: "\n <div style=\"min-height:45px\" *ngIf=\"enabled && !hidden && !is_loaded && myData?.length==0\"><mat-spinner diameter=\"25\" ></mat-spinner></div>\n <mat-form-field\n [hidden]=\"!enabled || hidden || (!is_loaded && myData.length==0)\" [class.fh_field]=\"enabled\"\n appearance=\"outline\"\n floatLabel=\"always\"\n ><mat-label>{{ label|translate }}</mat-label>\n <mat-select\n #cmb\n [(ngModel)]=\"selval\"\n (selectionChange)=\"sc()\"\n [required]=\"required\"\n [matTooltip]=\"tooltip\"\n >\n <mat-option value=\"-1\" *ngIf=\"show_empty\">{{ sel_label }}</mat-option>\n <mat-option value=\"{{ app.valore }}\" *ngFor=\"let app of myData\">{{\n app.descrizione_valore | translate\n }}</mat-option>\n </mat-select>\n </mat-form-field>\n <div *ngIf=\"error && !(!enabled || hidden || (!is_loaded && myData.length==0))\" class=\"field-error\">{{error}}</div>\n <mat-form-field\n [hidden]=\"enabled || hidden\" [class.fh_field_dis]=\"!enabled\"\n appearance=\"outline\"\n floatLabel=\"always\"\n ><mat-label>{{ label }}</mat-label>\n <input\n type=\"text\"\n #el1\n matInput\n [disabled]=\"true\"\n [(ngModel)]=\"dis_value\"\n [matTooltip]=\"tooltip\"\n />\n </mat-form-field>\n ",
|
|
8244
8244
|
styles: [""]
|
|
8245
8245
|
},] }
|
|
8246
8246
|
];
|
|
@@ -8655,7 +8655,7 @@
|
|
|
8655
8655
|
{ type: i0.Component, args: [{
|
|
8656
8656
|
selector: "FHAutoComplete",
|
|
8657
8657
|
providers: [CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$6],
|
|
8658
|
-
template: "\n <div style=\"min-height:45px\" *ngIf=\"enabled && !hidden && !is_loaded && myData?.length==0\"><mat-spinner diameter=\"25\" ></mat-spinner></div>\n <mat-form-field\n [hidden]=\"!enabled || hidden || (!is_loaded && myData.length==0)\" [class.fh_field]=\"enabled\"\n appearance=\"outline\"\n floatLabel=\"always\"\n ><mat-label>{{ label }}</mat-label>\n <input\n matInput\n [disabled]=\"!enabled || hidden\"\n [matAutocomplete]=\"auto\"\n [required]=\"required\"\n #trigger=\"matAutocompleteTrigger\"\n (keyup)=\"onChange_up($event)\"\n [(ngModel)]=\"sItem\"\n (focus)=\"fi_search();onChange_up($event)\"\n (focusout)=\"fo_search($event)\"\n #searchp\n />\n
|
|
8658
|
+
template: "\n <div style=\"min-height:45px\" *ngIf=\"enabled && !hidden && !is_loaded && myData?.length==0\"><mat-spinner diameter=\"25\" ></mat-spinner></div>\n <mat-form-field\n [hidden]=\"!enabled || hidden || (!is_loaded && myData.length==0)\" [class.fh_field]=\"enabled\"\n appearance=\"outline\"\n floatLabel=\"always\"\n ><mat-label>{{ label }}</mat-label>\n <input\n matInput\n [disabled]=\"!enabled || hidden\"\n [matAutocomplete]=\"auto\"\n [required]=\"required\"\n #trigger=\"matAutocompleteTrigger\"\n (keyup)=\"onChange_up($event)\"\n [(ngModel)]=\"sItem\"\n (focus)=\"fi_search();onChange_up($event)\"\n (focusout)=\"fo_search($event)\"\n #searchp\n />\n </mat-form-field>\n <div *ngIf=\"error && !(!enabled || hidden || (!is_loaded && myData.length==0))\" class=\"field-error\">{{error}}</div>\n <mat-autocomplete\n #auto=\"matAutocomplete\"\n (optionSelected)=\"selectedSearchItem($event)\"\n [autoActiveFirstOption]=\"open_on_load\"\n >\n <mat-option\n *ngFor=\"let objx of searchItemsFiltered\"\n [value]=\"objx.descrizione_valore\"\n >\n {{ objx.descrizione_valore }}\n </mat-option>\n </mat-autocomplete>\n\n <div class=\"ui negative message\" *ngIf=\"errorMsg != ''\">\n <i class=\"close icon\"></i>\n <div class=\"header\">\n {{ errorMsg }}\n </div>\n </div>\n <mat-form-field\n [hidden]=\"enabled || hidden\" [class.fh_field_dis]=\"!enabled\"\n\n appearance=\"outline\"\n floatLabel=\"always\"\n ><mat-label>{{ label }}</mat-label>\n <input type=\"text\" #el1 matInput [disabled]=\"true\" [required]=\"required\" [(ngModel)]=\"sItem\" />\n </mat-form-field>\n ",
|
|
8659
8659
|
styles: [""]
|
|
8660
8660
|
},] }
|
|
8661
8661
|
];
|
|
@@ -9365,7 +9365,7 @@
|
|
|
9365
9365
|
{ type: i0.Component, args: [{
|
|
9366
9366
|
selector: "FHTextInput",
|
|
9367
9367
|
providers: [CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$4],
|
|
9368
|
-
template: "\n <mat-form-field [hidden]=\"hidden\" appearance=\"outline\" floatLabel=\"always\" [class.fh_field]=\"enabled\" [class.fh_field_dis]=\"!enabled\"\n ><mat-label>{{ label }}</mat-label>\n <input\n matInput\n [email]=\"email\"\n type=\"text\"\n [(ngModel)]=\"text_v\"\n #el\n [disabled]=\"!enabled\"\n [required]=\"required\"\n (focusout)=\"onFu()\"\n (focusin)=\"onFi()\"\n (ngModelChange)=\"modelch()\"\n [autocomplete]=\"autocomplete\"\n [maxlength]=\"maxlength\"\n [type]=\"type\"\n />\n <mat-hint [hidden]=\"hint==''\">{{hint}}</mat-hint>\n </mat-form-field>\n <div *ngIf=\"error\" class=\"field-error\">{{error}}</div>\n ",
|
|
9368
|
+
template: "\n <mat-form-field [hidden]=\"hidden\" appearance=\"outline\" floatLabel=\"always\" [class.fh_field]=\"enabled\" [class.fh_field_dis]=\"!enabled\"\n ><mat-label>{{ label }}</mat-label>\n <input\n matInput\n [email]=\"email\"\n type=\"text\"\n [(ngModel)]=\"text_v\"\n #el\n [disabled]=\"!enabled\"\n [required]=\"required\"\n (focusout)=\"onFu()\"\n (focusin)=\"onFi()\"\n (ngModelChange)=\"modelch()\"\n [autocomplete]=\"autocomplete\"\n [maxlength]=\"maxlength\"\n [type]=\"type\"\n />\n <mat-hint [hidden]=\"hint==''\">{{hint}}</mat-hint>\n </mat-form-field>\n <div *ngIf=\"error && !hidden\" class=\"field-error\">{{error}}</div>\n ",
|
|
9369
9369
|
styles: [""]
|
|
9370
9370
|
},] }
|
|
9371
9371
|
];
|
|
@@ -10538,7 +10538,7 @@
|
|
|
10538
10538
|
{ type: i0.Component, args: [{
|
|
10539
10539
|
selector: "FHNumericField",
|
|
10540
10540
|
providers: [CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR_NUMERIC],
|
|
10541
|
-
template: "\n <mat-form-field [hidden]=\"hidden\" appearance=\"outline\" floatLabel=\"always\" [class.fh_field]=\"enabled\" [class.fh_field_dis]=\"!enabled\"\n ><mat-label>{{ label }}</mat-label>\n <input\n type=\"text\"\n [style.text-align]=\"text_align\"\n [style.background-color]=\"getStyle_BkColor()\"\n [style.color]=\"getStyle_Color()\"\n #el\n matInput\n [required]=\"required\"\n [disabled]=\"!enabled\"\n [(ngModel)]=\"formattedAmount\"\n (ngModelChange)=\"modelch()\"\n formnovalidate\n (blur)=\"chg();focus_out.emit(value)\"\n (click)=\"click_select_allf($event)\"\n (focus)=\"removeCurrencyPipeFormat($event); select_allf($event)\"\n (keydown)=\"keyDownFunctioncl($event)\"\n />\n <mat-hint [hidden]=\"hint==''\">{{hint}}</mat-hint>\n
|
|
10541
|
+
template: "\n <mat-form-field [hidden]=\"hidden\" appearance=\"outline\" floatLabel=\"always\" [class.fh_field]=\"enabled\" [class.fh_field_dis]=\"!enabled\"\n ><mat-label>{{ label }}</mat-label>\n <input\n type=\"text\"\n [style.text-align]=\"text_align\"\n [style.background-color]=\"getStyle_BkColor()\"\n [style.color]=\"getStyle_Color()\"\n #el\n matInput\n [required]=\"required\"\n [disabled]=\"!enabled\"\n [(ngModel)]=\"formattedAmount\"\n (ngModelChange)=\"modelch()\"\n formnovalidate\n (blur)=\"chg();focus_out.emit(value)\"\n (click)=\"click_select_allf($event)\"\n (focus)=\"removeCurrencyPipeFormat($event); select_allf($event)\"\n (keydown)=\"keyDownFunctioncl($event)\"\n />\n <mat-hint [hidden]=\"hint==''\">{{hint}}</mat-hint>\n </mat-form-field>\n <div *ngIf=\"error && !hidden\" class=\"field-error\">{{error}}</div>\n ",
|
|
10542
10542
|
styles: ["\n\n "]
|
|
10543
10543
|
},] }
|
|
10544
10544
|
];
|
|
@@ -17407,6 +17407,9 @@
|
|
|
17407
17407
|
this.clipboard = clipboard;
|
|
17408
17408
|
this.width_max = '100%';
|
|
17409
17409
|
this.browser = 'nd';
|
|
17410
|
+
this.pagination = false;
|
|
17411
|
+
this.paginationPageSize = 10;
|
|
17412
|
+
this.paginationAutoPageSize = false;
|
|
17410
17413
|
this.tooltipShowDelay = 2000;
|
|
17411
17414
|
this.elimina_label = 'ELIMINA';
|
|
17412
17415
|
this.export_field_aggiuntivi = '';
|
|
@@ -17415,6 +17418,7 @@
|
|
|
17415
17418
|
this.columnDefs = [];
|
|
17416
17419
|
this.num_per_pag = 35;
|
|
17417
17420
|
this.grid_key = 'PRO_H';
|
|
17421
|
+
this.service = 'dogridn';
|
|
17418
17422
|
this.enabled = true;
|
|
17419
17423
|
this.show_link = false;
|
|
17420
17424
|
this.show_help_bar = false;
|
|
@@ -17425,6 +17429,7 @@
|
|
|
17425
17429
|
this.enabled_pag = true;
|
|
17426
17430
|
this.show_help = true;
|
|
17427
17431
|
this.show_num_elem = true;
|
|
17432
|
+
this.private_pref = false;
|
|
17428
17433
|
this.system_dest = 1;
|
|
17429
17434
|
this.header_h = 35;
|
|
17430
17435
|
this.selection_mode = 'multiple';
|
|
@@ -17439,6 +17444,9 @@
|
|
|
17439
17444
|
this.label_elementi = ' Elementi';
|
|
17440
17445
|
this.trova_label = 'TROVA';
|
|
17441
17446
|
this.mantieni_impostazioni = 'Mantieni Imp.';
|
|
17447
|
+
this.row_height = 25;
|
|
17448
|
+
this.master_detail = false;
|
|
17449
|
+
this.detail_cell_renderer = null;
|
|
17442
17450
|
this.curr_filter = '';
|
|
17443
17451
|
this.show_buttons = true;
|
|
17444
17452
|
this.fill_end = new i0.EventEmitter();
|
|
@@ -17450,6 +17458,7 @@
|
|
|
17450
17458
|
this.custom_export = false;
|
|
17451
17459
|
this.toolbar_type = 'NONE';
|
|
17452
17460
|
this.toolbar_custom_commands = [];
|
|
17461
|
+
this.exec_params = [];
|
|
17453
17462
|
this.command = new i0.EventEmitter();
|
|
17454
17463
|
this.b_ensure = false;
|
|
17455
17464
|
this.gf = null;
|
|
@@ -17713,6 +17722,7 @@
|
|
|
17713
17722
|
this.dataSource = {
|
|
17714
17723
|
//rowCount: ???, - not setting the row count, infinite paging will be used
|
|
17715
17724
|
getRows: function (params) {
|
|
17725
|
+
// console.log('!!!!params ',params);
|
|
17716
17726
|
// this code should contact the server for rows. however for the purposes of the demo,
|
|
17717
17727
|
// the data is generated locally, a timer is used to give the experience of
|
|
17718
17728
|
// an asynchronous call
|
|
@@ -17720,147 +17730,48 @@
|
|
|
17720
17730
|
//console.log( params.filterModel);// + ' params.filterModel ' +params.filterModel);
|
|
17721
17731
|
_this.m_appService.start();
|
|
17722
17732
|
var p = { kd: _this.tbl_name };
|
|
17723
|
-
|
|
17724
|
-
|
|
17725
|
-
|
|
17726
|
-
// console.log(params);
|
|
17727
|
-
p.num_per_pag = params.endRow - params.startRow;
|
|
17728
|
-
// this.gridOptions.paginationPageSize = this.num_per_pag;
|
|
17729
|
-
// this.gridOptions.cacheBlockSize = this.num_per_pag;
|
|
17730
|
-
// console.log(this.gridOptions.cacheBlockSize );
|
|
17731
|
-
// console.log(this.gridOptions.paginationPageSize );
|
|
17732
|
-
p.curr_page = Math.round(params.startRow / p.num_per_pag);
|
|
17733
|
+
p.num_per_pag = params.request.endRow - params.request.startRow;
|
|
17734
|
+
p.fix_flt = (_this.fix_flt || '');
|
|
17735
|
+
p.curr_page = Math.round(params.request.startRow / p.num_per_pag);
|
|
17733
17736
|
if (p.curr_page == null)
|
|
17734
17737
|
p.curr_page = 0;
|
|
17735
17738
|
if (p.num_per_pag == null)
|
|
17736
17739
|
p.num_per_pag = 100;
|
|
17737
17740
|
p.system_dest = _this.system_dest;
|
|
17741
|
+
p.exec_params = (_this.exec_params || []);
|
|
17738
17742
|
p.p = JSON.stringify({
|
|
17739
|
-
sort_model: params.sortModel,
|
|
17740
|
-
filter_model: params.filterModel,
|
|
17743
|
+
sort_model: params.request.sortModel,
|
|
17744
|
+
filter_model: params.request.filterModel,
|
|
17741
17745
|
free_search: _this.ric_libera,
|
|
17746
|
+
fix_flt: (_this.fix_flt || '')
|
|
17742
17747
|
});
|
|
17743
|
-
|
|
17744
|
-
|
|
17745
|
-
if (params.sortModel != null)
|
|
17746
|
-
if (params.sortModel.length > 0) {
|
|
17747
|
-
p.sort_field = "";
|
|
17748
|
-
for (var i: number = 0; i < params.sortModel.length; i++) {
|
|
17749
|
-
if (p.sort_field != "") p.sort_field = p.sort_field + ",";
|
|
17750
|
-
if (params.sortModel[i].colId == "autori")
|
|
17751
|
-
p.sort_field =
|
|
17752
|
-
p.sort_field +
|
|
17753
|
-
"case when CHARINDEX('" +
|
|
17754
|
-
this.m_appService.user +
|
|
17755
|
-
"',autori)>0 then 1 else 0 end" +
|
|
17756
|
-
" " +
|
|
17757
|
-
params.sortModel[i].sort;
|
|
17758
|
-
else
|
|
17759
|
-
p.sort_field =
|
|
17760
|
-
p.sort_field +
|
|
17761
|
-
params.sortModel[i].colId +
|
|
17762
|
-
" " +
|
|
17763
|
-
params.sortModel[i].sort;
|
|
17764
|
-
}
|
|
17765
|
-
}
|
|
17766
|
-
|
|
17767
|
-
|
|
17768
|
-
|
|
17769
|
-
|
|
17770
|
-
if (this.filters != null) p.filter = this.filters;
|
|
17771
|
-
|
|
17772
|
-
if (this.fix_flt != "") {
|
|
17773
|
-
if (p.filter != "") p.filter = p.filter + " and ";
|
|
17774
|
-
p.filter = p.filter + " (" + this.fix_flt + " )";
|
|
17775
|
-
}
|
|
17776
|
-
|
|
17777
|
-
if (this.fix_flt_temp != "") {
|
|
17778
|
-
if (p.filter != "") p.filter = p.filter + " and ";
|
|
17779
|
-
p.filter = p.filter + " (" + this.fix_flt_temp + " )";
|
|
17780
|
-
}
|
|
17781
|
-
|
|
17782
|
-
// console.log('Filter model');
|
|
17783
|
-
//console.log(params.filterModel);
|
|
17784
|
-
|
|
17785
|
-
if (params.filterModel != null) {
|
|
17786
|
-
// console.log('Filtri');
|
|
17787
|
-
|
|
17788
|
-
for (let key in params.filterModel) {
|
|
17789
|
-
// console.log(key);
|
|
17790
|
-
// if (p.hasOwnProperty(key)) {
|
|
17791
|
-
// console.log( params.filterModel[key]);
|
|
17792
|
-
let obj_filtro_test = params.filterModel[key];
|
|
17793
|
-
console.log(params.filterModel[key], key);
|
|
17794
|
-
if (obj_filtro_test.operator == null) {
|
|
17795
|
-
if (p.filter == "")
|
|
17796
|
-
p.filter += this.calcola_filtro(
|
|
17797
|
-
params.filterModel[key],
|
|
17798
|
-
"",
|
|
17799
|
-
key,
|
|
17800
|
-
false
|
|
17801
|
-
);
|
|
17802
|
-
else
|
|
17803
|
-
p.filter += this.calcola_filtro(
|
|
17804
|
-
params.filterModel[key],
|
|
17805
|
-
"",
|
|
17806
|
-
key,
|
|
17807
|
-
true
|
|
17808
|
-
);
|
|
17809
|
-
} else {
|
|
17810
|
-
if (p.filter != "") p.filter += " and ";
|
|
17811
|
-
p.filter += " (";
|
|
17812
|
-
p.filter += this.calcola_filtro(
|
|
17813
|
-
params.filterModel[key].condition1,
|
|
17814
|
-
"",
|
|
17815
|
-
key,
|
|
17816
|
-
false
|
|
17817
|
-
);
|
|
17818
|
-
|
|
17819
|
-
p.filter += " " + obj_filtro_test.operator + " ";
|
|
17820
|
-
p.filter += this.calcola_filtro(
|
|
17821
|
-
params.filterModel[key].condition2,
|
|
17822
|
-
"",
|
|
17823
|
-
key,
|
|
17824
|
-
false
|
|
17825
|
-
);
|
|
17826
|
-
|
|
17827
|
-
p.filter += ")";
|
|
17828
|
-
}
|
|
17829
|
-
// }
|
|
17830
|
-
}
|
|
17831
|
-
}
|
|
17832
|
-
|
|
17833
|
-
(data) => {
|
|
17834
|
-
//p.num_per_pag=5000;
|
|
17835
|
-
// console.log(this._gridservice);
|
|
17836
|
-
this.str_curr_q_p = "";
|
|
17837
|
-
if (p.filter != "") this.str_curr_q_p = "where " + p.filter;
|
|
17838
|
-
if (p.sort_field != "")
|
|
17839
|
-
this.str_curr_q_p = this.str_curr_q_p + " order by " + p.sort_field;
|
|
17840
|
-
this.curr_filter = p.filter;*/
|
|
17841
|
-
//console.log('params.filterModel ',params.filterModel, JSON.stringify(params.filterModel));
|
|
17842
|
-
if ((params.filterModel == null ||
|
|
17843
|
-
JSON.stringify(params.filterModel) == '{}') &&
|
|
17748
|
+
if ((params.request.filterModel == null ||
|
|
17749
|
+
JSON.stringify(params.request.filterModel) == '{}') &&
|
|
17844
17750
|
(_this.ric_libera == null || _this.ric_libera == ''))
|
|
17845
17751
|
_this.show_pulisci_filtri = false;
|
|
17846
17752
|
else
|
|
17847
17753
|
_this.show_pulisci_filtri = true;
|
|
17848
|
-
|
|
17849
|
-
|
|
17754
|
+
_this.p_fi = {
|
|
17755
|
+
kd: p.kd,
|
|
17756
|
+
system_dest: p.system_dest, exec_params: (_this.exec_params || []),
|
|
17757
|
+
p: p.p,
|
|
17758
|
+
fix_flt: (_this.fix_flt || '')
|
|
17759
|
+
};
|
|
17850
17760
|
_this._gridservice
|
|
17851
|
-
.doQuery(p, true, _this.m_appService.API_ENDPOINT +
|
|
17761
|
+
.doQuery(p, true, _this.m_appService.API_ENDPOINT + _this.service)
|
|
17852
17762
|
.subscribe(function (data) {
|
|
17853
17763
|
var ok_op = false;
|
|
17854
17764
|
if (data != null)
|
|
17855
17765
|
if (data.result_msg == 'OK') {
|
|
17856
17766
|
ok_op = true;
|
|
17857
|
-
//
|
|
17767
|
+
// console.log(data.result_data, data.count);
|
|
17858
17768
|
params.successCallback(data.result_data, data.count);
|
|
17859
17769
|
_this.b_init = true;
|
|
17860
17770
|
_this.myData = data.result_data.slice();
|
|
17861
17771
|
_this.num_r = data.count;
|
|
17862
17772
|
_this.m_appService.complete();
|
|
17863
17773
|
_this.fill_end.emit();
|
|
17774
|
+
_this.check_width();
|
|
17864
17775
|
// console.log("end");
|
|
17865
17776
|
// console.log(localStorage.getItem(this.grid_key+'_POS'));
|
|
17866
17777
|
localStorage.setItem(_this.grid_key + '_POS1', JSON.stringify(p));
|
|
@@ -17884,7 +17795,8 @@
|
|
|
17884
17795
|
var b_mantieni_ck = false;
|
|
17885
17796
|
if (_this.toggle_mantieni != null)
|
|
17886
17797
|
b_mantieni_ck = _this.toggle_mantieni.checked;
|
|
17887
|
-
if (_this.no_pref && !_this.b_init1
|
|
17798
|
+
if (_this.no_pref && !_this.b_init1 &&
|
|
17799
|
+
_this.autosize_at_ini) {
|
|
17888
17800
|
_this.autoSizeAll();
|
|
17889
17801
|
}
|
|
17890
17802
|
_this.b_init1 = true;
|
|
@@ -17952,102 +17864,7 @@
|
|
|
17952
17864
|
icon: '<img src="assets/icons/square-o/xlsx.svg"/>',
|
|
17953
17865
|
},
|
|
17954
17866
|
]; };
|
|
17955
|
-
this.gridOptions = {
|
|
17956
|
-
debug: false,
|
|
17957
|
-
headerHeight: this.header_h,
|
|
17958
|
-
enableRangeSelection: true,
|
|
17959
|
-
defaultColDef: { resizable: true, sortable: true, floatingFilter: true },
|
|
17960
|
-
allowContextMenuWithControlKey: true,
|
|
17961
|
-
rowModelType: 'infinite',
|
|
17962
|
-
localeText: {
|
|
17963
|
-
// for filter panel
|
|
17964
|
-
page: 'pagina',
|
|
17965
|
-
more: 'altre',
|
|
17966
|
-
to: 'a',
|
|
17967
|
-
of: 'di',
|
|
17968
|
-
next: 'prossima',
|
|
17969
|
-
last: 'ultima',
|
|
17970
|
-
first: 'prima',
|
|
17971
|
-
previous: 'precedente',
|
|
17972
|
-
loadingOoo: 'Caricamento...',
|
|
17973
|
-
// for set filter
|
|
17974
|
-
selectAll: 'Seleziona Tutto',
|
|
17975
|
-
searchOoo: 'Trova...',
|
|
17976
|
-
blanks: 'Vuoto',
|
|
17977
|
-
// for number filter and text filter
|
|
17978
|
-
filterOoo: 'Filtro...',
|
|
17979
|
-
applyFilter: 'Applica Filtro...',
|
|
17980
|
-
// for number filter
|
|
17981
|
-
equals: 'Uguale',
|
|
17982
|
-
notEqual: 'Diverso',
|
|
17983
|
-
lessThan: 'Minore o Uguale',
|
|
17984
|
-
greaterThan: 'Maggiore o Uguale',
|
|
17985
|
-
// for text filter
|
|
17986
|
-
notContains: 'Non Contiene',
|
|
17987
|
-
contains: 'Contiene',
|
|
17988
|
-
startsWith: 'Inizia Con',
|
|
17989
|
-
endsWith: 'Finisce Con',
|
|
17990
|
-
// the header of the default group column
|
|
17991
|
-
group: 'Gruppo',
|
|
17992
|
-
// tool panel
|
|
17993
|
-
columns: 'Colonne',
|
|
17994
|
-
rowGroupColumns: 'Colonne Pivot',
|
|
17995
|
-
rowGroupColumnsEmptyMessage: 'trascina le colonne per raggrupparle',
|
|
17996
|
-
valueColumns: 'Colonne Valore',
|
|
17997
|
-
pivotMode: 'Modalità Pivot',
|
|
17998
|
-
groups: 'Gruppi',
|
|
17999
|
-
values: 'Valori',
|
|
18000
|
-
pivots: 'Pivots',
|
|
18001
|
-
valueColumnsEmptyMessage: 'trascina le colonne per aggreare',
|
|
18002
|
-
pivotColumnsEmptyMessage: 'trascina le colonne per pivot',
|
|
18003
|
-
// other
|
|
18004
|
-
noRowsToShow: 'nessun dato',
|
|
18005
|
-
// enterprise menu
|
|
18006
|
-
pinColumn: 'Sposta Colonna',
|
|
18007
|
-
valueAggregation: 'Aggregazione',
|
|
18008
|
-
autosizeThiscolumn: 'Autosize colonna',
|
|
18009
|
-
autosizeAllColumns: 'Autosize tutte le colonne',
|
|
18010
|
-
groupBy: 'Raggruppa per',
|
|
18011
|
-
ungroupBy: 'Spacca per',
|
|
18012
|
-
resetColumns: 'Resetta queste colonna',
|
|
18013
|
-
expandAll: 'Espandi',
|
|
18014
|
-
collapseAll: 'Chiudi',
|
|
18015
|
-
toolPanel: 'Impostazioni',
|
|
18016
|
-
// enterprise menu pinning
|
|
18017
|
-
pinLeft: 'Sposta <<',
|
|
18018
|
-
pinRight: 'Sposta >>',
|
|
18019
|
-
noPin: 'Sposta <>',
|
|
18020
|
-
// enterprise menu aggregation and status panel
|
|
18021
|
-
sum: 'Somma',
|
|
18022
|
-
min: 'Minimo',
|
|
18023
|
-
max: 'Massimo',
|
|
18024
|
-
none: 'Nessuno',
|
|
18025
|
-
count: 'Numero',
|
|
18026
|
-
average: 'Media',
|
|
18027
|
-
// standard menu
|
|
18028
|
-
copy: 'Copia',
|
|
18029
|
-
ctrlC: 'ctrl n C',
|
|
18030
|
-
paste: 'Incolla',
|
|
18031
|
-
ctrlV: 'ctrl n C',
|
|
18032
|
-
},
|
|
18033
|
-
getRowNodeId: function (item) {
|
|
18034
|
-
// console.log(item);
|
|
18035
|
-
if (item.ID != null)
|
|
18036
|
-
return String(item.ID);
|
|
18037
|
-
if (item.id != null)
|
|
18038
|
-
return String(item.id);
|
|
18039
|
-
if (item.uiid != null)
|
|
18040
|
-
return item.uiid;
|
|
18041
|
-
if (item.codice != null)
|
|
18042
|
-
return item.codice;
|
|
18043
|
-
if (item.id_doc != null)
|
|
18044
|
-
return item.id_doc;
|
|
18045
|
-
if (item.notesid != null)
|
|
18046
|
-
return item.notesid;
|
|
18047
|
-
if (item.ord != null)
|
|
18048
|
-
return item.ord;
|
|
18049
|
-
},
|
|
18050
|
-
};
|
|
17867
|
+
this.gridOptions = {};
|
|
18051
17868
|
this.last_copy = '';
|
|
18052
17869
|
this.showGrid = true;
|
|
18053
17870
|
this.rowData = [];
|
|
@@ -18056,6 +17873,7 @@
|
|
|
18056
17873
|
this.b_init1 = false;
|
|
18057
17874
|
this.errorMsg = '';
|
|
18058
17875
|
this.innerWidth = 750;
|
|
17876
|
+
this.init_opt = false;
|
|
18059
17877
|
this.show_pulisci_filtri = false;
|
|
18060
17878
|
this.uiid_stampa = '';
|
|
18061
17879
|
this.xxopx = 0;
|
|
@@ -18092,6 +17910,20 @@
|
|
|
18092
17910
|
return 'other';
|
|
18093
17911
|
}
|
|
18094
17912
|
};
|
|
17913
|
+
FHGridComponentN.prototype.check_width = function () {
|
|
17914
|
+
var _this = this;
|
|
17915
|
+
if (!this.autosize_at_ini)
|
|
17916
|
+
return;
|
|
17917
|
+
setTimeout(function () {
|
|
17918
|
+
//get columns size
|
|
17919
|
+
var go = _this.gridOptions.columnApi;
|
|
17920
|
+
if (go.getColumnState()[0].width < 24) {
|
|
17921
|
+
setTimeout(function () {
|
|
17922
|
+
_this.autoSizeAll();
|
|
17923
|
+
}, 1000);
|
|
17924
|
+
}
|
|
17925
|
+
}, 100);
|
|
17926
|
+
};
|
|
18095
17927
|
FHGridComponentN.prototype.docmd = function (o) {
|
|
18096
17928
|
this.command.emit(o);
|
|
18097
17929
|
};
|
|
@@ -18136,7 +17968,6 @@
|
|
|
18136
17968
|
if (this.curr_config == '-1')
|
|
18137
17969
|
return;
|
|
18138
17970
|
localStorage.removeItem(this.grid_key + '_COLS');
|
|
18139
|
-
// localStorage.removeItem(this.grid_key + "_SORT");
|
|
18140
17971
|
localStorage.removeItem(this.grid_key + '_FILTER');
|
|
18141
17972
|
localStorage.removeItem(this.grid_key + '_CFG_DEFAULT');
|
|
18142
17973
|
localStorage.removeItem(this.grid_key + '_FILTER_UP');
|
|
@@ -18425,7 +18256,7 @@
|
|
|
18425
18256
|
this.gridOptions.api.setHeaderHeight(this.header_h);
|
|
18426
18257
|
this.gridOptions.suppressCopyRowsToClipboard = true;
|
|
18427
18258
|
this.gridOptions.sendToClipboard = function (v) {
|
|
18428
|
-
console.log('v ', v);
|
|
18259
|
+
// console.log('v ', v);
|
|
18429
18260
|
if (_this.enable_copy)
|
|
18430
18261
|
_this.gridApi.copySelectedRangeToClipboard();
|
|
18431
18262
|
{
|
|
@@ -18449,6 +18280,107 @@
|
|
|
18449
18280
|
};
|
|
18450
18281
|
FHGridComponentN.prototype.ngAfterViewInit = function () {
|
|
18451
18282
|
var _this = this;
|
|
18283
|
+
this.gridOptions = {
|
|
18284
|
+
debug: false,
|
|
18285
|
+
pagination: this.pagination,
|
|
18286
|
+
paginationPageSize: this.paginationPageSize,
|
|
18287
|
+
headerHeight: this.header_h,
|
|
18288
|
+
paginationAutoPageSize: this.paginationAutoPageSize,
|
|
18289
|
+
rowHeight: this.row_height,
|
|
18290
|
+
enableRangeSelection: true,
|
|
18291
|
+
defaultColDef: { resizable: true, sortable: true, floatingFilter: true },
|
|
18292
|
+
allowContextMenuWithControlKey: true,
|
|
18293
|
+
rowModelType: 'serverSide',
|
|
18294
|
+
localeText: {
|
|
18295
|
+
// for filter panel
|
|
18296
|
+
page: 'pagina',
|
|
18297
|
+
more: 'altre',
|
|
18298
|
+
to: 'a',
|
|
18299
|
+
of: 'di',
|
|
18300
|
+
next: 'prossima',
|
|
18301
|
+
last: 'ultima',
|
|
18302
|
+
first: 'prima',
|
|
18303
|
+
previous: 'precedente',
|
|
18304
|
+
loadingOoo: 'Caricamento...',
|
|
18305
|
+
// for set filter
|
|
18306
|
+
selectAll: 'Seleziona Tutto',
|
|
18307
|
+
searchOoo: 'Trova...',
|
|
18308
|
+
blanks: 'Vuoto',
|
|
18309
|
+
// for number filter and text filter
|
|
18310
|
+
filterOoo: 'Filtro...',
|
|
18311
|
+
applyFilter: 'Applica Filtro...',
|
|
18312
|
+
// for number filter
|
|
18313
|
+
equals: 'Uguale',
|
|
18314
|
+
notEqual: 'Diverso',
|
|
18315
|
+
lessThan: 'Minore o Uguale',
|
|
18316
|
+
greaterThan: 'Maggiore o Uguale',
|
|
18317
|
+
// for text filter
|
|
18318
|
+
notContains: 'Non Contiene',
|
|
18319
|
+
contains: 'Contiene',
|
|
18320
|
+
startsWith: 'Inizia Con',
|
|
18321
|
+
endsWith: 'Finisce Con',
|
|
18322
|
+
// the header of the default group column
|
|
18323
|
+
group: 'Gruppo',
|
|
18324
|
+
// tool panel
|
|
18325
|
+
columns: 'Colonne',
|
|
18326
|
+
rowGroupColumns: 'Colonne Pivot',
|
|
18327
|
+
rowGroupColumnsEmptyMessage: 'trascina le colonne per raggrupparle',
|
|
18328
|
+
valueColumns: 'Colonne Valore',
|
|
18329
|
+
pivotMode: 'Modalità Pivot',
|
|
18330
|
+
groups: 'Gruppi',
|
|
18331
|
+
values: 'Valori',
|
|
18332
|
+
pivots: 'Pivots',
|
|
18333
|
+
valueColumnsEmptyMessage: 'trascina le colonne per aggreare',
|
|
18334
|
+
pivotColumnsEmptyMessage: 'trascina le colonne per pivot',
|
|
18335
|
+
// other
|
|
18336
|
+
noRowsToShow: 'nessun dato',
|
|
18337
|
+
// enterprise menu
|
|
18338
|
+
pinColumn: 'Sposta Colonna',
|
|
18339
|
+
valueAggregation: 'Aggregazione',
|
|
18340
|
+
autosizeThiscolumn: 'Autosize colonna',
|
|
18341
|
+
autosizeAllColumns: 'Autosize tutte le colonne',
|
|
18342
|
+
groupBy: 'Raggruppa per',
|
|
18343
|
+
ungroupBy: 'Spacca per',
|
|
18344
|
+
resetColumns: 'Resetta queste colonna',
|
|
18345
|
+
expandAll: 'Espandi',
|
|
18346
|
+
collapseAll: 'Chiudi',
|
|
18347
|
+
toolPanel: 'Impostazioni',
|
|
18348
|
+
// enterprise menu pinning
|
|
18349
|
+
pinLeft: 'Sposta <<',
|
|
18350
|
+
pinRight: 'Sposta >>',
|
|
18351
|
+
noPin: 'Sposta <>',
|
|
18352
|
+
// enterprise menu aggregation and status panel
|
|
18353
|
+
sum: 'Somma',
|
|
18354
|
+
min: 'Minimo',
|
|
18355
|
+
max: 'Massimo',
|
|
18356
|
+
none: 'Nessuno',
|
|
18357
|
+
count: 'Numero',
|
|
18358
|
+
average: 'Media',
|
|
18359
|
+
// standard menu
|
|
18360
|
+
copy: 'Copia',
|
|
18361
|
+
ctrlC: 'ctrl n C',
|
|
18362
|
+
paste: 'Incolla',
|
|
18363
|
+
ctrlV: 'ctrl n C',
|
|
18364
|
+
},
|
|
18365
|
+
getRowNodeId: function (item) {
|
|
18366
|
+
// console.log(item);
|
|
18367
|
+
if (item.ID != null)
|
|
18368
|
+
return String(item.ID);
|
|
18369
|
+
if (item.id != null)
|
|
18370
|
+
return String(item.id);
|
|
18371
|
+
if (item.uiid != null)
|
|
18372
|
+
return item.uiid;
|
|
18373
|
+
if (item.codice != null)
|
|
18374
|
+
return item.codice;
|
|
18375
|
+
if (item.id_doc != null)
|
|
18376
|
+
return item.id_doc;
|
|
18377
|
+
if (item.notesid != null)
|
|
18378
|
+
return item.notesid;
|
|
18379
|
+
if (item.ord != null)
|
|
18380
|
+
return item.ord;
|
|
18381
|
+
},
|
|
18382
|
+
};
|
|
18383
|
+
this.init_opt = true;
|
|
18452
18384
|
if (this.grid_key == 'PRO_H')
|
|
18453
18385
|
this.no_pref = true;
|
|
18454
18386
|
setTimeout(function () {
|
|
@@ -18464,7 +18396,7 @@
|
|
|
18464
18396
|
FHGridComponentN.prototype.okr = function (event) {
|
|
18465
18397
|
//console.log(event.column.colDef.field);
|
|
18466
18398
|
event.data.nome_colonna = event.column.colDef.field;
|
|
18467
|
-
this.cell_edited.emit(event);
|
|
18399
|
+
this.cell_edited.emit(event.data);
|
|
18468
18400
|
};
|
|
18469
18401
|
FHGridComponentN.prototype.help_window = function () {
|
|
18470
18402
|
var dialogRef = this.m_dialog.open(win_grid_help, { disableClose: true });
|
|
@@ -18494,6 +18426,7 @@
|
|
|
18494
18426
|
};
|
|
18495
18427
|
FHGridComponentN.prototype.autoSizeAll = function () {
|
|
18496
18428
|
var _this = this;
|
|
18429
|
+
// console.log("🚀 ~ file: fhgridn.ts:1121 ~ FHGridComponentN ~ autoSizeAll ~ autoSizeAll:")
|
|
18497
18430
|
if (this.gridOptions == null)
|
|
18498
18431
|
return;
|
|
18499
18432
|
if (this.gridOptions.columnApi == null)
|
|
@@ -18513,6 +18446,7 @@
|
|
|
18513
18446
|
this.save_cfg();
|
|
18514
18447
|
};
|
|
18515
18448
|
FHGridComponentN.prototype.fitSizeAll = function () {
|
|
18449
|
+
// console.log("🚀 ~ file: fhgridn.ts:1142 ~ FHGridComponentN ~ fitSizeAll ~ fitSizeAll:")
|
|
18516
18450
|
// console.log("fitSizeAll");
|
|
18517
18451
|
if (this.gridOptions.api)
|
|
18518
18452
|
this.gridOptions.api.sizeColumnsToFit();
|
|
@@ -18584,7 +18518,7 @@
|
|
|
18584
18518
|
if (this.gridOptions.api)
|
|
18585
18519
|
this.gridOptions.api.setFilterModel(null);
|
|
18586
18520
|
var filtrtm = {}; /*
|
|
18587
|
-
this.columnDefs.map((v)=>{
|
|
18521
|
+
this.columnDefs.map((v:any)=>{
|
|
18588
18522
|
if(v.filter=='agSetColumnFilter'){
|
|
18589
18523
|
filtrtm[v.field]={type:'set',values:[]}
|
|
18590
18524
|
}
|
|
@@ -18592,141 +18526,6 @@
|
|
|
18592
18526
|
if (this.gridOptions.api)
|
|
18593
18527
|
this.gridOptions.api.setFilterModel(filtrtm);
|
|
18594
18528
|
};
|
|
18595
|
-
/*
|
|
18596
|
-
public export_excel(format: string = "xlsx") {
|
|
18597
|
-
if(this.custom_export){
|
|
18598
|
-
this.command.emit({ cmd: "export_excel",v:format });
|
|
18599
|
-
return;}
|
|
18600
|
-
if (this.num_r > 20000) {
|
|
18601
|
-
this._toast.error("Massimo 20000 elementi esportabili");
|
|
18602
|
-
return;
|
|
18603
|
-
}
|
|
18604
|
-
format = "." + format;
|
|
18605
|
-
|
|
18606
|
-
this.uiid_stampa = this.uti_s.newGuid();
|
|
18607
|
-
this.xxopx = 0;
|
|
18608
|
-
let q: string = "";
|
|
18609
|
-
this.dialogRef_W = this.m_dialog.open(fh_win_wait, {
|
|
18610
|
-
disableClose: true,
|
|
18611
|
-
});
|
|
18612
|
-
setTimeout(() => {
|
|
18613
|
-
this.dialogRef_W.componentInstance.label = "EXPORT IN CORSO";
|
|
18614
|
-
});
|
|
18615
|
-
let cmds: Array<any> = [];
|
|
18616
|
-
|
|
18617
|
-
let str_fields = "";
|
|
18618
|
-
let p_col = this.gridOptions.columnApi.getAllDisplayedColumns();
|
|
18619
|
-
|
|
18620
|
-
for (let j = 0; j < p_col.length; j++) {
|
|
18621
|
-
if (str_fields != "") str_fields += ",";
|
|
18622
|
-
if (p_col[j].getColDef().headerName == null)
|
|
18623
|
-
str_fields += "[" + p_col[j].getColDef().field + "]";
|
|
18624
|
-
else if (p_col[j].getColDef().headerName == "")
|
|
18625
|
-
str_fields += "[" + p_col[j].getColDef().field + "]";
|
|
18626
|
-
else
|
|
18627
|
-
str_fields +=
|
|
18628
|
-
"[" +
|
|
18629
|
-
p_col[j].getColDef().field +
|
|
18630
|
-
"] [" +
|
|
18631
|
-
p_col[j].getColDef().headerName.split('[').join('').split(']').join('') +
|
|
18632
|
-
"]";
|
|
18633
|
-
}
|
|
18634
|
-
if (this.fields.indexOf("DISTINCT") != -1)
|
|
18635
|
-
str_fields = "DISTINCT " + str_fields;
|
|
18636
|
-
cmds.push(
|
|
18637
|
-
this.officeService.operation(
|
|
18638
|
-
"GB_XLS_APRI",
|
|
18639
|
-
"tpl_report.xlsx",
|
|
18640
|
-
"" + this.uiid_stampa + ".xlsx",
|
|
18641
|
-
this.xxopx++
|
|
18642
|
-
)
|
|
18643
|
-
);
|
|
18644
|
-
let opx:string='GB_CREA_TABELLA_FROM_DB';
|
|
18645
|
-
if(this.system_dest==2)opx='GB_CREA_TABELLA_FROM_DB1';
|
|
18646
|
-
if(this.export_field_aggiuntivi=='')
|
|
18647
|
-
cmds.push(
|
|
18648
|
-
this.officeService.operation(
|
|
18649
|
-
opx,
|
|
18650
|
-
"select " +
|
|
18651
|
-
str_fields+
|
|
18652
|
-
" from " +
|
|
18653
|
-
this.tbl_name +
|
|
18654
|
-
" " +
|
|
18655
|
-
this.str_curr_q_p,
|
|
18656
|
-
"3",
|
|
18657
|
-
this.xxopx++
|
|
18658
|
-
)
|
|
18659
|
-
);
|
|
18660
|
-
else
|
|
18661
|
-
cmds.push(
|
|
18662
|
-
this.officeService.operation(
|
|
18663
|
-
opx,
|
|
18664
|
-
"select " +
|
|
18665
|
-
str_fields +','+this.export_field_aggiuntivi+
|
|
18666
|
-
" from " +
|
|
18667
|
-
this.tbl_name +
|
|
18668
|
-
" " +
|
|
18669
|
-
this.str_curr_q_p,
|
|
18670
|
-
"3",
|
|
18671
|
-
this.xxopx++
|
|
18672
|
-
)
|
|
18673
|
-
);
|
|
18674
|
-
cmds.push(
|
|
18675
|
-
this.officeService.operation(
|
|
18676
|
-
"GB_XLS_SAVE",
|
|
18677
|
-
this.m_appService.LOCAL_PATH +
|
|
18678
|
-
"grid_reports\\" +
|
|
18679
|
-
this.uiid_stampa +
|
|
18680
|
-
"_" +
|
|
18681
|
-
this.m_appService.user +
|
|
18682
|
-
format,
|
|
18683
|
-
"",
|
|
18684
|
-
this.xxopx++
|
|
18685
|
-
)
|
|
18686
|
-
);
|
|
18687
|
-
|
|
18688
|
-
this.officeService
|
|
18689
|
-
.runCommands(this.uiid_stampa, cmds, this.dialogRef_W,false)
|
|
18690
|
-
.subscribe((data) => {
|
|
18691
|
-
this.check_end(format);
|
|
18692
|
-
});
|
|
18693
|
-
}
|
|
18694
|
-
check_end(format:any){
|
|
18695
|
-
|
|
18696
|
-
|
|
18697
|
-
let p: FSInput = new FSInput();
|
|
18698
|
-
p.p1 =
|
|
18699
|
-
this.m_appService.LOCAL_PATH +
|
|
18700
|
-
"grid_reports\\" +
|
|
18701
|
-
this.uiid_stampa +
|
|
18702
|
-
"_" +
|
|
18703
|
-
this.m_appService.user +
|
|
18704
|
-
format;
|
|
18705
|
-
p.command = "check_file";
|
|
18706
|
-
this._fileService.doQuery(p).subscribe((data) => {
|
|
18707
|
-
if (data != null)
|
|
18708
|
-
if (data.msg == "N") {
|
|
18709
|
-
setTimeout(() => {
|
|
18710
|
-
this.check_end(format);
|
|
18711
|
-
},5000);
|
|
18712
|
-
} else {
|
|
18713
|
-
setTimeout(() => {
|
|
18714
|
-
this.dialogRef_W.componentInstance.update_progess(100);
|
|
18715
|
-
});
|
|
18716
|
-
window.open(
|
|
18717
|
-
this.m_appService.COMPANY_SITE_ROOT +
|
|
18718
|
-
"/grid_reports/" +
|
|
18719
|
-
this.uiid_stampa +
|
|
18720
|
-
"_" +
|
|
18721
|
-
this.m_appService.user +
|
|
18722
|
-
format
|
|
18723
|
-
);
|
|
18724
|
-
}
|
|
18725
|
-
});
|
|
18726
|
-
|
|
18727
|
-
}
|
|
18728
|
-
|
|
18729
|
-
*/
|
|
18730
18529
|
FHGridComponentN.prototype.print = function () {
|
|
18731
18530
|
if (this.custom_export)
|
|
18732
18531
|
this.command.emit({ cmd: 'print_pdf' });
|
|
@@ -18865,6 +18664,7 @@
|
|
|
18865
18664
|
FHGridComponentN.prototype.res_columns = function (forza) {
|
|
18866
18665
|
var _this = this;
|
|
18867
18666
|
if (forza === void 0) { forza = false; }
|
|
18667
|
+
console.log("🚀 ~ file: fhgridn.ts:1370 ~ FHGridComponentN ~ res_columns ~ res_columns:", forza);
|
|
18868
18668
|
if (this.columnDefs == null) {
|
|
18869
18669
|
setTimeout(function () {
|
|
18870
18670
|
_this.res_columns(forza);
|
|
@@ -18887,9 +18687,11 @@
|
|
|
18887
18687
|
return;
|
|
18888
18688
|
}
|
|
18889
18689
|
if (localStorage.getItem(this.grid_key + '_COLS') != null &&
|
|
18890
|
-
(b_mantieni_ck || forza))
|
|
18690
|
+
(b_mantieni_ck || forza)) {
|
|
18691
|
+
// console.log('qqqqq1111');
|
|
18891
18692
|
if (localStorage.getItem(this.grid_key + '_COLS') != '') {
|
|
18892
18693
|
b_rip = true;
|
|
18694
|
+
// console.log('qqqqq2222');
|
|
18893
18695
|
try {
|
|
18894
18696
|
var a = JSON.parse((localStorage.getItem(this.grid_key + '_COLS') || '[]'));
|
|
18895
18697
|
var annulla = true;
|
|
@@ -18897,16 +18699,24 @@
|
|
|
18897
18699
|
if (!a[i].hide)
|
|
18898
18700
|
annulla = false;
|
|
18899
18701
|
}
|
|
18702
|
+
// console.log('qqqqq3333 ',annulla);
|
|
18900
18703
|
if (annulla)
|
|
18901
18704
|
localStorage.getItem(this.grid_key + '_COLS');
|
|
18902
|
-
else
|
|
18903
|
-
|
|
18904
|
-
|
|
18705
|
+
else {
|
|
18706
|
+
// console.log('qqqqq4444');
|
|
18707
|
+
if (localStorage.getItem(this.grid_key + '_COLS'))
|
|
18708
|
+
if (this.gridOptions.columnApi) {
|
|
18709
|
+
// console.log('qqqqq5555',JSON.parse(localStorage.getItem(this.grid_key + '_COLS')||'{}'));
|
|
18710
|
+
var colState = { state: JSON.parse(localStorage.getItem(this.grid_key + '_COLS') || '{}') };
|
|
18711
|
+
this.gridOptions.columnApi.applyColumnState(colState);
|
|
18712
|
+
}
|
|
18713
|
+
}
|
|
18905
18714
|
}
|
|
18906
18715
|
catch (eer) {
|
|
18907
18716
|
console.log(eer);
|
|
18908
18717
|
}
|
|
18909
18718
|
}
|
|
18719
|
+
}
|
|
18910
18720
|
/* try {
|
|
18911
18721
|
this.gridOptions.api.setSortModel(null);
|
|
18912
18722
|
} catch (eer) {
|
|
@@ -18962,7 +18772,7 @@
|
|
|
18962
18772
|
_this.ref_dt();
|
|
18963
18773
|
}, 500);
|
|
18964
18774
|
else
|
|
18965
|
-
this.gridOptions.api.
|
|
18775
|
+
this.gridOptions.api.setServerSideDatasource(this.dataSource);
|
|
18966
18776
|
}
|
|
18967
18777
|
};
|
|
18968
18778
|
FHGridComponentN.prototype.updateRow = function () {
|
|
@@ -18972,12 +18782,19 @@
|
|
|
18972
18782
|
// console.log('onModelUpdated');
|
|
18973
18783
|
// this.calculateRowCount();
|
|
18974
18784
|
};
|
|
18785
|
+
FHGridComponentN.prototype.doSearch = function (s) {
|
|
18786
|
+
this.ric_libera = s;
|
|
18787
|
+
this.free_search();
|
|
18788
|
+
};
|
|
18975
18789
|
FHGridComponentN.prototype.onReady = function (event) {
|
|
18976
18790
|
// console.log(this.header_h);
|
|
18977
18791
|
this.gridApi = event.api;
|
|
18978
18792
|
this.setHeaderHeight(this.header_h);
|
|
18979
18793
|
if (this.gf != null && this.show_buttons && !this.pref_hidden) {
|
|
18980
|
-
this.
|
|
18794
|
+
if (!this.private_pref)
|
|
18795
|
+
this.gf.sql = 'SELECT_CFG_GRID';
|
|
18796
|
+
else
|
|
18797
|
+
this.gf.sql = 'SELECT_CFG_GRID_BY_USER';
|
|
18981
18798
|
this.gf.types = ['string'];
|
|
18982
18799
|
this.gf.values = [this.grid_key];
|
|
18983
18800
|
this.gf.fillCombo();
|
|
@@ -19094,7 +18911,7 @@
|
|
|
19094
18911
|
}
|
|
19095
18912
|
});
|
|
19096
18913
|
if (ss_r != '') {
|
|
19097
|
-
console.log('ADDO '), ss_r;
|
|
18914
|
+
// console.log('ADDO '), ss_r;
|
|
19098
18915
|
if (ss != '')
|
|
19099
18916
|
ss += ' and ';
|
|
19100
18917
|
ss += '(' + ss_r + ')';
|
|
@@ -19108,6 +18925,8 @@
|
|
|
19108
18925
|
this.doFill_Temp(ss, true);
|
|
19109
18926
|
};
|
|
19110
18927
|
FHGridComponentN.prototype.onCellClicked = function (event) {
|
|
18928
|
+
if (!this.b_init)
|
|
18929
|
+
return;
|
|
19111
18930
|
// console.log(event.rowIndex + ' ' + event.colDef.field);
|
|
19112
18931
|
this.cell_clicked.emit(event);
|
|
19113
18932
|
// console.log(this.myModalNormal);
|
|
@@ -19126,7 +18945,7 @@
|
|
|
19126
18945
|
FHGridComponentN.prototype.onCellFocused = function (event) {
|
|
19127
18946
|
//console.log('onCellFocused: (' + event.rowIndex + ',' + event.colIndex + ')');
|
|
19128
18947
|
};
|
|
19129
|
-
FHGridComponentN.prototype.onSelectionChanged = function () {
|
|
18948
|
+
FHGridComponentN.prototype.onSelectionChanged = function (event) {
|
|
19130
18949
|
// console.log('selectionChanged');
|
|
19131
18950
|
};
|
|
19132
18951
|
FHGridComponentN.prototype.onBeforeFilterChanged = function () {
|
|
@@ -19134,6 +18953,8 @@
|
|
|
19134
18953
|
};
|
|
19135
18954
|
FHGridComponentN.prototype.oncolumnEverythingChanged = function (event) {
|
|
19136
18955
|
// console.log('oncolumnEverythingChanged');
|
|
18956
|
+
if (!this.b_init)
|
|
18957
|
+
return;
|
|
19137
18958
|
if (this.b_init) {
|
|
19138
18959
|
// console.log('salvo f: '+JSON.stringify(this.gridOptions.columnApi.getColumnState()));
|
|
19139
18960
|
if (this.gridOptions.columnApi)
|
|
@@ -19142,6 +18963,8 @@
|
|
|
19142
18963
|
};
|
|
19143
18964
|
FHGridComponentN.prototype.onFilterModified = function () {
|
|
19144
18965
|
var _this = this;
|
|
18966
|
+
if (!this.b_init)
|
|
18967
|
+
return;
|
|
19145
18968
|
if (this.no_pref)
|
|
19146
18969
|
return;
|
|
19147
18970
|
setTimeout(function () {
|
|
@@ -19176,6 +18999,8 @@
|
|
|
19176
18999
|
// console.log('onVirtualRowRemoved: ' + event.rowIndex);
|
|
19177
19000
|
};
|
|
19178
19001
|
FHGridComponentN.prototype.onRowClicked = function ($event) {
|
|
19002
|
+
if (!this.b_init)
|
|
19003
|
+
return;
|
|
19179
19004
|
//console.log('onRowClicked: ' );
|
|
19180
19005
|
var selectedInGrid;
|
|
19181
19006
|
if (this.gridOptions.api)
|
|
@@ -19200,6 +19025,8 @@
|
|
|
19200
19025
|
}
|
|
19201
19026
|
};
|
|
19202
19027
|
FHGridComponentN.prototype.onRowDClicked = function ($event) {
|
|
19028
|
+
if (!this.b_init)
|
|
19029
|
+
return;
|
|
19203
19030
|
//console.log('onRowClicked: ' );
|
|
19204
19031
|
//console.log(event);
|
|
19205
19032
|
this.dclicked.emit($event.data);
|
|
@@ -19216,6 +19043,8 @@
|
|
|
19216
19043
|
// here we use one generic event to handle all the column type events.
|
|
19217
19044
|
// the method just prints the event name
|
|
19218
19045
|
FHGridComponentN.prototype.onColumnEvent = function ($event) {
|
|
19046
|
+
if (!this.b_init)
|
|
19047
|
+
return;
|
|
19219
19048
|
this.columndclicked.emit($event);
|
|
19220
19049
|
// console.log('onColumnEvent: ' + $event);
|
|
19221
19050
|
// localStorage.setItem(this.grid_key+'_COLUMN',JSON.stringify(this.gridOptions.api.getColumnDef()));
|
|
@@ -19276,6 +19105,9 @@
|
|
|
19276
19105
|
{ type: clipboard.Clipboard }
|
|
19277
19106
|
]; };
|
|
19278
19107
|
FHGridComponentN.propDecorators = {
|
|
19108
|
+
pagination: [{ type: i0.Input }],
|
|
19109
|
+
paginationPageSize: [{ type: i0.Input }],
|
|
19110
|
+
paginationAutoPageSize: [{ type: i0.Input }],
|
|
19279
19111
|
tooltipShowDelay: [{ type: i0.Input }],
|
|
19280
19112
|
elimina_label: [{ type: i0.Input }],
|
|
19281
19113
|
export_field_aggiuntivi: [{ type: i0.Input }],
|
|
@@ -19284,6 +19116,7 @@
|
|
|
19284
19116
|
columnDefs: [{ type: i0.Input }],
|
|
19285
19117
|
num_per_pag: [{ type: i0.Input }],
|
|
19286
19118
|
grid_key: [{ type: i0.Input }],
|
|
19119
|
+
service: [{ type: i0.Input }],
|
|
19287
19120
|
enabled: [{ type: i0.Input }],
|
|
19288
19121
|
show_link: [{ type: i0.Input }],
|
|
19289
19122
|
show_help_bar: [{ type: i0.Input }],
|
|
@@ -19294,6 +19127,8 @@
|
|
|
19294
19127
|
enabled_pag: [{ type: i0.Input }],
|
|
19295
19128
|
show_help: [{ type: i0.Input }],
|
|
19296
19129
|
show_num_elem: [{ type: i0.Input }],
|
|
19130
|
+
private_pref: [{ type: i0.Input }],
|
|
19131
|
+
icons: [{ type: i0.Input }],
|
|
19297
19132
|
system_dest: [{ type: i0.Input }],
|
|
19298
19133
|
header_h: [{ type: i0.Input }],
|
|
19299
19134
|
selection_mode: [{ type: i0.Input }],
|
|
@@ -19308,6 +19143,9 @@
|
|
|
19308
19143
|
label_elementi: [{ type: i0.Input }],
|
|
19309
19144
|
trova_label: [{ type: i0.Input }],
|
|
19310
19145
|
mantieni_impostazioni: [{ type: i0.Input }],
|
|
19146
|
+
row_height: [{ type: i0.Input }],
|
|
19147
|
+
master_detail: [{ type: i0.Input }],
|
|
19148
|
+
detail_cell_renderer: [{ type: i0.Input }],
|
|
19311
19149
|
show_buttons: [{ type: i0.Input }],
|
|
19312
19150
|
fill_end: [{ type: i0.Output }],
|
|
19313
19151
|
cell_edited: [{ type: i0.Output }],
|
|
@@ -19319,6 +19157,7 @@
|
|
|
19319
19157
|
toolbar_type: [{ type: i0.Input }],
|
|
19320
19158
|
toolbar_wkfapp: [{ type: i0.Input }],
|
|
19321
19159
|
toolbar_custom_commands: [{ type: i0.Input }],
|
|
19160
|
+
exec_params: [{ type: i0.Input }],
|
|
19322
19161
|
command: [{ type: i0.Output }],
|
|
19323
19162
|
gf: [{ type: i0.ViewChild, args: ['gf',] }],
|
|
19324
19163
|
toggle_mantieni: [{ type: i0.ViewChild, args: ['toggle_mantieni',] }],
|