@esfaenza/es-table 11.2.22-beta7 → 11.2.22-beta8
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/esfaenza-es-table.umd.js +39 -42
- package/bundles/esfaenza-es-table.umd.js.map +1 -1
- package/bundles/esfaenza-es-table.umd.min.js +1 -1
- package/bundles/esfaenza-es-table.umd.min.js.map +1 -1
- package/esm2015/lib/components/es-table/es_table.component.js +6 -14
- package/esm2015/lib/core/handlers/classes/ColumnMetadataHandler.js +7 -6
- package/esm2015/lib/core/handlers/classes/DynamicModeHandler.js +2 -1
- package/esm2015/lib/core/handlers/classes/ExportHandler.js +3 -1
- package/esm2015/lib/core/handlers/classes/HierarchyModeHandler.js +3 -1
- package/esm2015/lib/core/handlers/classes/ItemsHandler.js +5 -4
- package/esm2015/lib/core/handlers/classes/ReportModeHandler.js +4 -1
- package/esm2015/lib/core/handlers/classes/RowGroupingHandler.js +4 -3
- package/esm2015/lib/core/handlers/classes/SelectionHandler.js +7 -9
- package/esm2015/lib/core/handlers/classes/UtilitiesHandler.js +11 -12
- package/esm2015/lib/domain/internals/classes/ThElement.js +2 -0
- package/esm2015/lib/domain/internals/index.js +2 -1
- package/fesm2015/esfaenza-es-table.js +41 -42
- package/fesm2015/esfaenza-es-table.js.map +1 -1
- package/lib/components/es-table/es_table.component.d.ts +7 -37
- package/lib/core/handlers/classes/ColumnMetadataHandler.d.ts +6 -5
- package/lib/core/handlers/classes/DynamicModeHandler.d.ts +1 -0
- package/lib/core/handlers/classes/ExportHandler.d.ts +2 -0
- package/lib/core/handlers/classes/HierarchyModeHandler.d.ts +2 -0
- package/lib/core/handlers/classes/ItemsHandler.d.ts +4 -4
- package/lib/core/handlers/classes/ReportModeHandler.d.ts +2 -0
- package/lib/core/handlers/classes/RowGroupingHandler.d.ts +3 -3
- package/lib/core/handlers/classes/SelectionHandler.d.ts +6 -10
- package/lib/core/handlers/classes/UtilitiesHandler.d.ts +5 -4
- package/lib/domain/internals/classes/ThElement.d.ts +13 -0
- package/lib/domain/internals/index.d.ts +1 -0
- package/package.json +1 -1
|
@@ -1122,6 +1122,7 @@
|
|
|
1122
1122
|
// Modelli
|
|
1123
1123
|
/** Classe che gestisce tutte le informaizoni relative alle colonne: visibilità, posizione, stato di pin/unpin, ecc ecc... */
|
|
1124
1124
|
var ColumnMetadataHandler = /** @class */ (function () {
|
|
1125
|
+
/** @ignore Costruttore*/
|
|
1125
1126
|
function ColumnMetadataHandler(est, utilities, utiExts, prefService, rgH) {
|
|
1126
1127
|
this.est = est;
|
|
1127
1128
|
this.utilities = utilities;
|
|
@@ -1130,11 +1131,11 @@
|
|
|
1130
1131
|
this.rgH = rgH;
|
|
1131
1132
|
}
|
|
1132
1133
|
/**
|
|
1133
|
-
|
|
1134
|
-
|
|
1135
|
-
|
|
1136
|
-
|
|
1137
|
-
|
|
1134
|
+
* Metodo che gestisce il cambio di Ordinamento di una colonna
|
|
1135
|
+
*
|
|
1136
|
+
* @param {string} id ID della colonna il cui oridnamento è cambiato
|
|
1137
|
+
* @param {'DESC' | 'ASC'} order Nuovo ordine selezionato per la colonna
|
|
1138
|
+
*/
|
|
1138
1139
|
ColumnMetadataHandler.prototype.handleTHOrderChange = function (id, order) {
|
|
1139
1140
|
var orders = this.est.viewMode ? this.est.View.orders : this.est.arrayOrders;
|
|
1140
1141
|
var orderToAdd = true;
|
|
@@ -1802,6 +1803,7 @@
|
|
|
1802
1803
|
// Dominio
|
|
1803
1804
|
/** Classe contenente le gestioni particolari della modalità dinamica dell'es-table */
|
|
1804
1805
|
var DynamicModeHandler = /** @class */ (function () {
|
|
1806
|
+
/** @ignore Costruttore*/
|
|
1805
1807
|
function DynamicModeHandler(est) {
|
|
1806
1808
|
this.est = est;
|
|
1807
1809
|
}
|
|
@@ -1862,7 +1864,9 @@
|
|
|
1862
1864
|
return DynamicModeHandler;
|
|
1863
1865
|
}());
|
|
1864
1866
|
|
|
1867
|
+
/** Classe contenente la gestione delle importazioni */
|
|
1865
1868
|
var ExportHandler = /** @class */ (function () {
|
|
1869
|
+
/** @ignore Costruttore*/
|
|
1866
1870
|
function ExportHandler(est, expExts, msgExts) {
|
|
1867
1871
|
this.est = est;
|
|
1868
1872
|
this.expExts = expExts;
|
|
@@ -1906,7 +1910,9 @@
|
|
|
1906
1910
|
return ExportHandler;
|
|
1907
1911
|
}());
|
|
1908
1912
|
|
|
1913
|
+
/** Classe contenente la gestione della modalità gerarchica */
|
|
1909
1914
|
var HierarchyModeHandler = /** @class */ (function () {
|
|
1915
|
+
/** @ignore Costruttore*/
|
|
1910
1916
|
function HierarchyModeHandler(est) {
|
|
1911
1917
|
this.est = est;
|
|
1912
1918
|
}
|
|
@@ -2041,7 +2047,10 @@
|
|
|
2041
2047
|
return HierarchyModeHandler;
|
|
2042
2048
|
}());
|
|
2043
2049
|
|
|
2050
|
+
// Modelli
|
|
2051
|
+
/** Classe che si occupa della gestione del recupero degli oggetti, paginazione e tutto ciò in cui gli elementi caricati vengono manipolati direttamente */
|
|
2044
2052
|
var ItemsHandler = /** @class */ (function () {
|
|
2053
|
+
/** @ignore Costruttore */
|
|
2045
2054
|
function ItemsHandler(est, utilities) {
|
|
2046
2055
|
this.est = est;
|
|
2047
2056
|
this.utilities = utilities;
|
|
@@ -2155,9 +2164,7 @@
|
|
|
2155
2164
|
}
|
|
2156
2165
|
return arrayBy100;
|
|
2157
2166
|
};
|
|
2158
|
-
/**
|
|
2159
|
-
* Se in modalità array applica gli ordinamenti ASC-DESC delle colonne
|
|
2160
|
-
*/
|
|
2167
|
+
/** Se in modalità array applica gli ordinamenti ASC-DESC delle colonne */
|
|
2161
2168
|
ItemsHandler.prototype.arrayModeReviewOrderings = function () {
|
|
2162
2169
|
var _this = this;
|
|
2163
2170
|
if (this.est.arrayOrders.length > 0)
|
|
@@ -2166,7 +2173,10 @@
|
|
|
2166
2173
|
return ItemsHandler;
|
|
2167
2174
|
}());
|
|
2168
2175
|
|
|
2176
|
+
// Modelli
|
|
2177
|
+
/** Classe che gestisce la modalità Report dell'es-table utilizzata nel Metering */
|
|
2169
2178
|
var ReportModeHandler = /** @class */ (function () {
|
|
2179
|
+
/** @ignore Costruttore */
|
|
2170
2180
|
function ReportModeHandler(est, utilities) {
|
|
2171
2181
|
this.est = est;
|
|
2172
2182
|
this.utilities = utilities;
|
|
@@ -2234,7 +2244,9 @@
|
|
|
2234
2244
|
return ReportModeHandler;
|
|
2235
2245
|
}());
|
|
2236
2246
|
|
|
2247
|
+
/** Classe che gestisce la modalità Row Grouping dell'es-table */
|
|
2237
2248
|
var RowGroupingHandler = /** @class */ (function () {
|
|
2249
|
+
/** @ignore Costruttore */
|
|
2238
2250
|
function RowGroupingHandler(est, utilities, dateExts) {
|
|
2239
2251
|
this.est = est;
|
|
2240
2252
|
this.utilities = utilities;
|
|
@@ -2714,8 +2726,6 @@
|
|
|
2714
2726
|
* @param {string} fromat Formato su cui formattare il valore. Può essere ad esempio "small", "long" "verylong" per le date o F{0-9} per i numeri decimali
|
|
2715
2727
|
*
|
|
2716
2728
|
* @returns {string} Valore dell'aggregazione formattato come si deve
|
|
2717
|
-
*
|
|
2718
|
-
* @todo ROWGROUPING
|
|
2719
2729
|
*/
|
|
2720
2730
|
RowGroupingHandler.prototype.formatAggregationValue = function (value, format) {
|
|
2721
2731
|
if (!format)
|
|
@@ -2738,10 +2748,11 @@
|
|
|
2738
2748
|
return RowGroupingHandler;
|
|
2739
2749
|
}());
|
|
2740
2750
|
|
|
2751
|
+
/** Classe che gestisce le selezioni degli oggetti */
|
|
2741
2752
|
var SelectionHandler = /** @class */ (function () {
|
|
2742
|
-
|
|
2753
|
+
/** @ignore Costruttore */
|
|
2754
|
+
function SelectionHandler(est, rgHandler) {
|
|
2743
2755
|
this.est = est;
|
|
2744
|
-
this.utilities = utilities;
|
|
2745
2756
|
this.rgHandler = rgHandler;
|
|
2746
2757
|
/** Cache di selezione Hash - Oggetto per la variabile **items** dell'itemSelector. Facilita le operazioni di lookup via hash*/
|
|
2747
2758
|
this.itemsCache = new Map();
|
|
@@ -3027,9 +3038,7 @@
|
|
|
3027
3038
|
}
|
|
3028
3039
|
}
|
|
3029
3040
|
};
|
|
3030
|
-
/**
|
|
3031
|
-
* Helper per evitare di riscrivere ogni santa volta array.splice(array.indexof(item), 1);
|
|
3032
|
-
*/
|
|
3041
|
+
/** Helper per evitare di riscrivere ogni santa volta array.splice(array.indexof(item), 1); */
|
|
3033
3042
|
SelectionHandler.prototype.removeItem = function (item, triptic) {
|
|
3034
3043
|
var index = triptic.index_cache.get(item._hash);
|
|
3035
3044
|
if (index != null) {
|
|
@@ -3039,9 +3048,7 @@
|
|
|
3039
3048
|
}
|
|
3040
3049
|
return !!index;
|
|
3041
3050
|
};
|
|
3042
|
-
/**
|
|
3043
|
-
* Helper per evitare di riscrivere ogni santa volta array.push(item); e la gestione della
|
|
3044
|
-
*/
|
|
3051
|
+
/** Helper per evitare di riscrivere ogni santa volta array.push(item); e la gestione della */
|
|
3045
3052
|
SelectionHandler.prototype.addItem = function (item, triptic) {
|
|
3046
3053
|
if (triptic.index_cache.get(item._hash) == null) {
|
|
3047
3054
|
var i = triptic.array.push(item) - 1;
|
|
@@ -3306,12 +3313,16 @@
|
|
|
3306
3313
|
return SelectionHandler;
|
|
3307
3314
|
}());
|
|
3308
3315
|
|
|
3316
|
+
// Angular
|
|
3317
|
+
/** Classe di utilità per le cose comuni */
|
|
3309
3318
|
var UtilitiesHandler = /** @class */ (function () {
|
|
3319
|
+
/** @ignore Costruttore */
|
|
3310
3320
|
function UtilitiesHandler(hashExts) {
|
|
3311
3321
|
this.hashExts = hashExts;
|
|
3312
3322
|
}
|
|
3313
3323
|
/**
|
|
3314
|
-
* Data una lista di oggetti effettua dei raggruppamenti in base alla proprietà **field**,
|
|
3324
|
+
* Data una lista di oggetti effettua dei raggruppamenti in base alla proprietà **field**,
|
|
3325
|
+
* restituendo un oggetto del tipo { Gruppo1: oggetti[], Gruppo2: oggetti[], ecc... }
|
|
3315
3326
|
*
|
|
3316
3327
|
* @param {any[]} array Lista degli oggetti da raggruppare
|
|
3317
3328
|
* @param {string} field Campo su cui effettuare i raggruppamenti
|
|
@@ -3346,9 +3357,7 @@
|
|
|
3346
3357
|
}
|
|
3347
3358
|
}
|
|
3348
3359
|
};
|
|
3349
|
-
/**
|
|
3350
|
-
* Helper per spostare un oggetto di un array da un indice all'altro, in place
|
|
3351
|
-
*/
|
|
3360
|
+
/** Helper per spostare un oggetto di un array da un indice all'altro, in place */
|
|
3352
3361
|
UtilitiesHandler.prototype.arrayMove = function (array, oldI, newI) {
|
|
3353
3362
|
if (newI > array.length - 1 || oldI > array.length - 1 || newI < 0 || oldI < 0)
|
|
3354
3363
|
throw "Gli indici passati non fanno riferimento a una posizione dell'array. Length: " + array.length + " Old:" + oldI + " New: " + newI;
|
|
@@ -3360,18 +3369,14 @@
|
|
|
3360
3369
|
* @param {any} td Cella da valutare
|
|
3361
3370
|
* @returns {boolean} Restituisce **true** se il **td** è di tipo **EsTd**, **false** se è di tipo **EsTdDirective**
|
|
3362
3371
|
*/
|
|
3363
|
-
UtilitiesHandler.prototype.isEsTd = function (td) {
|
|
3364
|
-
return !td._directive;
|
|
3365
|
-
};
|
|
3372
|
+
UtilitiesHandler.prototype.isEsTd = function (td) { return !td._directive; };
|
|
3366
3373
|
/**
|
|
3367
3374
|
* Helper che identifica se il th attuale è di tipo **EsTh**. In caso contrario è da considerarsi **EsThDirective**
|
|
3368
3375
|
*
|
|
3369
3376
|
* @param {any} td Header da valutare
|
|
3370
3377
|
* @returns {boolean} Restituisce **true** se il **th** è di tipo **EsTh**, **false** se è di tipo **EsThDirective**
|
|
3371
3378
|
*/
|
|
3372
|
-
UtilitiesHandler.prototype.isEsTh = function (th) {
|
|
3373
|
-
return !th._directive;
|
|
3374
|
-
};
|
|
3379
|
+
UtilitiesHandler.prototype.isEsTh = function (th) { return !th._directive; };
|
|
3375
3380
|
/**
|
|
3376
3381
|
* Date le informazioni di paginazione ottiene l'array dei pulsanti
|
|
3377
3382
|
*
|
|
@@ -3469,7 +3474,7 @@
|
|
|
3469
3474
|
}());
|
|
3470
3475
|
UtilitiesHandler.ɵprov = i0__namespace.ɵɵdefineInjectable({ factory: function UtilitiesHandler_Factory() { return new UtilitiesHandler(i0__namespace.ɵɵinject(i1__namespace.HashingService)); }, token: UtilitiesHandler, providedIn: "root" });
|
|
3471
3476
|
UtilitiesHandler.decorators = [
|
|
3472
|
-
{ type: i0.Injectable, args: [{ providedIn: 'root'
|
|
3477
|
+
{ type: i0.Injectable, args: [{ providedIn: 'root' },] }
|
|
3473
3478
|
];
|
|
3474
3479
|
UtilitiesHandler.ctorParameters = function () { return [
|
|
3475
3480
|
{ type: i1.HashingService }
|
|
@@ -3798,7 +3803,7 @@
|
|
|
3798
3803
|
this.hierarchyMode_H = new HierarchyModeHandler(this);
|
|
3799
3804
|
this.items_H = new ItemsHandler(this, this.utilities_H);
|
|
3800
3805
|
this.reportMode_H = new ReportModeHandler(this, this.utilities_H);
|
|
3801
|
-
this.selection_H = new SelectionHandler(this, this.
|
|
3806
|
+
this.selection_H = new SelectionHandler(this, this.rowGrouping_H);
|
|
3802
3807
|
if (ngControl)
|
|
3803
3808
|
ngControl.valueAccessor = this;
|
|
3804
3809
|
// Assegnazione per tutti gli Input di default
|
|
@@ -4089,9 +4094,7 @@
|
|
|
4089
4094
|
setTimeout(function () { _this.internalPostBoundSource(); });
|
|
4090
4095
|
}
|
|
4091
4096
|
};
|
|
4092
|
-
/**
|
|
4093
|
-
* Per poter distinguere le chiamate a questo metodo: Dopo il setTimeout se uso gli EsTd/EsTh vecchi, senza il setTimeout se uso le nuove direttive
|
|
4094
|
-
*/
|
|
4097
|
+
/** Per poter distinguere le chiamate a questo metodo: Dopo il setTimeout se uso gli EsTd/EsTh vecchi, senza il setTimeout se uso le nuove direttive */
|
|
4095
4098
|
EsTableComponent.prototype.internalPostBoundSource = function () {
|
|
4096
4099
|
var View = this.View;
|
|
4097
4100
|
var ths = this.EsThs && this.EsThs.length > 0 ? this.EsThs.toArray() : this.EsThsDirective && this.EsThsDirective.length > 0 ? this.EsThsDirective.toArray() : [];
|
|
@@ -4170,9 +4173,7 @@
|
|
|
4170
4173
|
}
|
|
4171
4174
|
this.rowGrouping_H.handleNewDataOnRowGrouping(view, groupingKeys);
|
|
4172
4175
|
};
|
|
4173
|
-
/**
|
|
4174
|
-
* Metodo richiamato solo quando **TMPRowTDs** e **TMPRowTHs** sono completamente generati ed aggiustati. Serve per collegarli alle variabili usate lato binding HTML
|
|
4175
|
-
*/
|
|
4176
|
+
/** Metodo richiamato solo quando **TMPRowTDs** e **TMPRowTHs** sono completamente generati ed aggiustati. Serve per collegarli alle variabili usate lato binding HTML */
|
|
4176
4177
|
EsTableComponent.prototype.MoveTemporaryVariablesToRealOnes = function () {
|
|
4177
4178
|
this.RowTDs = this.TMPRowTDs;
|
|
4178
4179
|
this.RowTHs = this.TMPRowTHs;
|
|
@@ -4539,16 +4540,12 @@
|
|
|
4539
4540
|
else
|
|
4540
4541
|
this.emitSearchRequest(true);
|
|
4541
4542
|
};
|
|
4542
|
-
/**
|
|
4543
|
-
* Evento richiamato sul cambio della paginazione. Verrà richiamato l'evento **emitSearchRequest** con la vista del separatore
|
|
4544
|
-
*/
|
|
4543
|
+
/** Evento richiamato sul cambio della paginazione. Verrà richiamato l'evento **emitSearchRequest** con la vista del separatore */
|
|
4545
4544
|
EsTableComponent.prototype.onGroupItemsPerPageChanged = function (pager, newIpp) {
|
|
4546
4545
|
pager.view.itemsperpageoverride = newIpp;
|
|
4547
4546
|
this.emitSearchRequest(true, pager.view);
|
|
4548
4547
|
};
|
|
4549
|
-
/**
|
|
4550
|
-
* Metodo che gestisce la modifica del tempo specificato per l'aggiornamento automatico
|
|
4551
|
-
*/
|
|
4548
|
+
/** Metodo che gestisce la modifica del tempo specificato per l'aggiornamento automatico */
|
|
4552
4549
|
EsTableComponent.prototype.autoUpdateChanged = function () {
|
|
4553
4550
|
var _this = this;
|
|
4554
4551
|
if (!/^[1-9]\d*$/.test(this.seconds))
|