@fluxhub/fluxhub-lib 22.0.8 → 22.0.9
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.
|
@@ -10475,6 +10475,18 @@ class FHGridComponent {
|
|
|
10475
10475
|
toolbar_custom_commands = [];
|
|
10476
10476
|
exec_params = [];
|
|
10477
10477
|
command = new EventEmitter();
|
|
10478
|
+
/** Ultima riga cliccata salvata in localStorage; null se manca o non e' JSON valido (es. 'undefined' scritto dalle versioni precedenti). */
|
|
10479
|
+
read_last_row() {
|
|
10480
|
+
const raw = localStorage.getItem(this.grid_customer_preference_key + '_LAST_ROW');
|
|
10481
|
+
if (raw == null || raw === 'undefined')
|
|
10482
|
+
return null;
|
|
10483
|
+
try {
|
|
10484
|
+
return JSON.parse(raw);
|
|
10485
|
+
}
|
|
10486
|
+
catch {
|
|
10487
|
+
return null;
|
|
10488
|
+
}
|
|
10489
|
+
}
|
|
10478
10490
|
check_width() {
|
|
10479
10491
|
if (!this.autosize_at_ini)
|
|
10480
10492
|
return;
|
|
@@ -10846,7 +10858,7 @@ class FHGridComponent {
|
|
|
10846
10858
|
node.setSelected(true);
|
|
10847
10859
|
localStorage.removeItem(this.grid_customer_preference_key + '_POS2');
|
|
10848
10860
|
if (localStorage.getItem(this.grid_customer_preference_key + '_LAST_ROW') != null)
|
|
10849
|
-
this.sRow =
|
|
10861
|
+
this.sRow = this.read_last_row();
|
|
10850
10862
|
else
|
|
10851
10863
|
this.sRow = null;
|
|
10852
10864
|
localStorage.removeItem(this.grid_customer_preference_key + '_LAST_ROW');
|
|
@@ -11860,7 +11872,11 @@ class FHGridComponent {
|
|
|
11860
11872
|
// this.m_appService.getState().grid_obj[this.grid_customer_preference_key+'_NODE']=this.gridApi.getSelectedRows[0];
|
|
11861
11873
|
}
|
|
11862
11874
|
this.sRow = $event.data;
|
|
11863
|
-
|
|
11875
|
+
// riga senza dati (gruppo, riga di caricamento): niente LAST_ROW, altrimenti si salva la stringa 'undefined'
|
|
11876
|
+
if (this.sRow != null)
|
|
11877
|
+
localStorage.setItem(this.grid_customer_preference_key + '_LAST_ROW', JSON.stringify(this.sRow));
|
|
11878
|
+
else
|
|
11879
|
+
localStorage.removeItem(this.grid_customer_preference_key + '_LAST_ROW');
|
|
11864
11880
|
this.clicked.emit($event.data);
|
|
11865
11881
|
var iOS = /iPad|iPhone|iPod/.test(navigator.userAgent);
|
|
11866
11882
|
if (iOS) {
|