@esfaenza/es-table 11.2.37-beta2 → 11.2.40
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 +501 -510
- 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/esfaenza-es-table.d.ts +1 -1
- package/esfaenza-es-table.metadata.json +1 -1
- package/esm2015/esfaenza-es-table.js +2 -2
- package/esm2015/lib/components/es-table/es_table.component.js +27 -13
- package/esm2015/lib/core/handlers/ColumnMetadataHandler.js +669 -0
- package/esm2015/lib/core/handlers/DynamicModeHandler.js +63 -0
- package/esm2015/lib/core/handlers/ExportHandler.js +106 -0
- package/esm2015/lib/core/handlers/HierarchyModeHandler.js +136 -0
- package/esm2015/lib/core/handlers/ItemsHandler.js +112 -0
- package/esm2015/lib/core/handlers/ReportModeHandler.js +70 -0
- package/esm2015/lib/core/handlers/RowGroupingHandler.js +481 -0
- package/esm2015/lib/core/handlers/SelectionHandler.js +526 -0
- package/esm2015/lib/core/handlers/UtilitiesHandler.js +155 -0
- package/esm2015/lib/directives/es_th.directive.js +4 -1
- package/esm2015/lib/domain/configuration/EsTableDefaultable.js +1 -1
- package/esm2015/lib/domain/externals/CornerMenuOption.js +4 -0
- package/esm2015/lib/domain/externals/EsTableColumnsDefinition.js +31 -0
- package/esm2015/lib/domain/externals/EsTableOperationDefinition.js +22 -0
- package/esm2015/lib/domain/externals/appsearch/AppOrdering.js +16 -0
- package/esm2015/lib/domain/externals/appsearch/AppSearch.js +35 -0
- package/esm2015/lib/domain/externals/appsearch/GenericItem.js +11 -0
- package/esm2015/lib/domain/externals/appsearch/Group.js +17 -0
- package/esm2015/lib/domain/externals/appsearch/GroupAggregation.js +16 -0
- package/esm2015/lib/domain/externals/appsearch/GroupFilter.js +14 -0
- package/esm2015/lib/domain/externals/appsearch/GroupOrAggregation.js +16 -0
- package/esm2015/lib/domain/externals/appsearch/ItemsSelection.js +23 -0
- package/esm2015/lib/domain/externals/report/ReportColumn.js +4 -0
- package/esm2015/lib/domain/externals/report/ReportDefinition.js +4 -0
- package/esm2015/lib/domain/externals/report/ReportOrder.js +4 -0
- package/esm2015/lib/domain/externals/report/ReportParam.js +4 -0
- package/esm2015/lib/domain/externals/report/ReportResult.js +4 -0
- package/esm2015/lib/domain/externals/report/ReportRow.js +4 -0
- package/esm2015/lib/domain/internals/CacheTriptic.js +16 -0
- package/esm2015/lib/domain/internals/EsTableColumn.js +27 -0
- package/esm2015/lib/domain/internals/GroupPager.js +22 -0
- package/esm2015/lib/domain/internals/GroupRouteFragment.js +17 -0
- package/esm2015/lib/domain/internals/TdElement.js +2 -0
- package/esm2015/lib/domain/internals/ThAggregation.js +16 -0
- package/esm2015/lib/domain/internals/ThElement.js +2 -0
- package/esm2015/public-api.js +18 -5
- package/fesm2015/esfaenza-es-table.js +451 -461
- package/fesm2015/esfaenza-es-table.js.map +1 -1
- package/lib/components/es-table/es_table.component.d.ts +25 -5
- package/lib/core/handlers/{classes/ColumnMetadataHandler.d.ts → ColumnMetadataHandler.d.ts} +9 -7
- package/lib/core/handlers/{classes/DynamicModeHandler.d.ts → DynamicModeHandler.d.ts} +2 -2
- package/lib/core/handlers/{classes/ExportHandler.d.ts → ExportHandler.d.ts} +1 -1
- package/lib/core/handlers/{classes/HierarchyModeHandler.d.ts → HierarchyModeHandler.d.ts} +1 -1
- package/lib/core/handlers/{classes/ItemsHandler.d.ts → ItemsHandler.d.ts} +1 -1
- package/lib/core/handlers/{classes/ReportModeHandler.d.ts → ReportModeHandler.d.ts} +2 -2
- package/lib/core/handlers/{classes/RowGroupingHandler.d.ts → RowGroupingHandler.d.ts} +8 -3
- package/lib/core/handlers/{classes/SelectionHandler.d.ts → SelectionHandler.d.ts} +3 -3
- package/lib/core/handlers/{classes/UtilitiesHandler.d.ts → UtilitiesHandler.d.ts} +0 -0
- package/lib/directives/es_th.directive.d.ts +3 -1
- package/lib/domain/configuration/EsTableDefaultable.d.ts +1 -0
- package/lib/domain/externals/{classes/CornerMenuOption.d.ts → CornerMenuOption.d.ts} +0 -0
- package/lib/domain/externals/{classes/EsTableColumnsDefinition.d.ts → EsTableColumnsDefinition.d.ts} +0 -0
- package/lib/domain/externals/{classes/EsTableOperationDefinition.d.ts → EsTableOperationDefinition.d.ts} +0 -0
- package/lib/domain/externals/{classes/appsearch → appsearch}/AppOrdering.d.ts +0 -0
- package/lib/domain/externals/{classes/appsearch → appsearch}/AppSearch.d.ts +0 -0
- package/lib/domain/externals/{classes/appsearch → appsearch}/GenericItem.d.ts +0 -0
- package/lib/domain/externals/{classes/appsearch → appsearch}/Group.d.ts +0 -0
- package/lib/domain/externals/{classes/appsearch → appsearch}/GroupAggregation.d.ts +0 -0
- package/lib/domain/externals/{classes/appsearch → appsearch}/GroupFilter.d.ts +0 -0
- package/lib/domain/externals/{classes/appsearch → appsearch}/GroupOrAggregation.d.ts +0 -0
- package/lib/domain/externals/{classes/appsearch → appsearch}/ItemsSelection.d.ts +1 -1
- package/lib/domain/externals/{classes/report → report}/ReportColumn.d.ts +0 -0
- package/lib/domain/externals/{classes/report → report}/ReportDefinition.d.ts +3 -1
- package/lib/domain/externals/{classes/report → report}/ReportOrder.d.ts +0 -0
- package/lib/domain/externals/{classes/report → report}/ReportParam.d.ts +0 -0
- package/lib/domain/externals/{classes/report → report}/ReportResult.d.ts +2 -1
- package/lib/domain/externals/{classes/report → report}/ReportRow.d.ts +0 -0
- package/lib/domain/internals/{classes/CacheTriptic.d.ts → CacheTriptic.d.ts} +0 -0
- package/lib/domain/internals/{classes/EsTableColumn.d.ts → EsTableColumn.d.ts} +2 -1
- package/lib/domain/internals/{classes/GroupPager.d.ts → GroupPager.d.ts} +4 -1
- package/lib/domain/internals/{classes/GroupRouteFragment.d.ts → GroupRouteFragment.d.ts} +0 -0
- package/lib/domain/internals/{classes/TdElement.d.ts → TdElement.d.ts} +17 -1
- package/lib/domain/internals/{classes/ThAggregation.d.ts → ThAggregation.d.ts} +0 -0
- package/lib/domain/internals/{classes/ThElement.d.ts → ThElement.d.ts} +0 -0
- package/package.json +1 -1
- package/public-api.d.ts +17 -1
- package/esm2015/lib/core/handlers/classes/ColumnMetadataHandler.js +0 -667
- package/esm2015/lib/core/handlers/classes/DynamicModeHandler.js +0 -64
- package/esm2015/lib/core/handlers/classes/ExportHandler.js +0 -106
- package/esm2015/lib/core/handlers/classes/HierarchyModeHandler.js +0 -136
- package/esm2015/lib/core/handlers/classes/ItemsHandler.js +0 -112
- package/esm2015/lib/core/handlers/classes/ReportModeHandler.js +0 -70
- package/esm2015/lib/core/handlers/classes/RowGroupingHandler.js +0 -473
- package/esm2015/lib/core/handlers/classes/SelectionHandler.js +0 -527
- package/esm2015/lib/core/handlers/classes/UtilitiesHandler.js +0 -155
- package/esm2015/lib/core/handlers/index.js +0 -10
- package/esm2015/lib/domain/externals/classes/CornerMenuOption.js +0 -4
- package/esm2015/lib/domain/externals/classes/EsTableColumnsDefinition.js +0 -31
- package/esm2015/lib/domain/externals/classes/EsTableOperationDefinition.js +0 -22
- package/esm2015/lib/domain/externals/classes/appsearch/AppOrdering.js +0 -16
- package/esm2015/lib/domain/externals/classes/appsearch/AppSearch.js +0 -35
- package/esm2015/lib/domain/externals/classes/appsearch/GenericItem.js +0 -11
- package/esm2015/lib/domain/externals/classes/appsearch/Group.js +0 -17
- package/esm2015/lib/domain/externals/classes/appsearch/GroupAggregation.js +0 -16
- package/esm2015/lib/domain/externals/classes/appsearch/GroupFilter.js +0 -14
- package/esm2015/lib/domain/externals/classes/appsearch/GroupOrAggregation.js +0 -16
- package/esm2015/lib/domain/externals/classes/appsearch/ItemsSelection.js +0 -23
- package/esm2015/lib/domain/externals/classes/report/ReportColumn.js +0 -4
- package/esm2015/lib/domain/externals/classes/report/ReportDefinition.js +0 -4
- package/esm2015/lib/domain/externals/classes/report/ReportOrder.js +0 -4
- package/esm2015/lib/domain/externals/classes/report/ReportParam.js +0 -4
- package/esm2015/lib/domain/externals/classes/report/ReportResult.js +0 -4
- package/esm2015/lib/domain/externals/classes/report/ReportRow.js +0 -4
- package/esm2015/lib/domain/externals/index.js +0 -18
- package/esm2015/lib/domain/index.js +0 -3
- package/esm2015/lib/domain/internals/classes/CacheTriptic.js +0 -16
- package/esm2015/lib/domain/internals/classes/EsTableColumn.js +0 -26
- package/esm2015/lib/domain/internals/classes/GroupPager.js +0 -21
- package/esm2015/lib/domain/internals/classes/GroupRouteFragment.js +0 -17
- package/esm2015/lib/domain/internals/classes/TdElement.js +0 -2
- package/esm2015/lib/domain/internals/classes/ThAggregation.js +0 -16
- package/esm2015/lib/domain/internals/classes/ThElement.js +0 -2
- package/esm2015/lib/domain/internals/index.js +0 -8
- package/lib/core/handlers/index.d.ts +0 -9
- package/lib/domain/externals/index.d.ts +0 -17
- package/lib/domain/index.d.ts +0 -2
- package/lib/domain/internals/index.d.ts +0 -7
|
@@ -17,22 +17,6 @@ import { BsDropdownModule } from 'ngx-bootstrap/dropdown';
|
|
|
17
17
|
import { CsvModule } from '@ctrl/ngx-csv';
|
|
18
18
|
import { ContextMenuModule } from '@esfaenza/ngx-contextmenu';
|
|
19
19
|
|
|
20
|
-
/**
|
|
21
|
-
* Classe che identifica un ordinamento di una colonna
|
|
22
|
-
*/
|
|
23
|
-
class AppOrdering {
|
|
24
|
-
/**
|
|
25
|
-
* Costruttore
|
|
26
|
-
*
|
|
27
|
-
* @param {string} id ID della colonna a cui si vogliono applicare ordinamenti, deve combaciare all'id messo nella dichiarazione dell'ES-TD/TH
|
|
28
|
-
* @param {'DESC' | 'ASC' } order Ordinamento da applicare alla colonna, Discendente/Ascendente, default 'null' per indicare assenza di ordine
|
|
29
|
-
*/
|
|
30
|
-
constructor(id, order) {
|
|
31
|
-
this.id = id;
|
|
32
|
-
this.order = order;
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
|
|
36
20
|
/**
|
|
37
21
|
* Classe che identifica una ricerca paginata in tutte le sue sfumature (di grigio)
|
|
38
22
|
*/
|
|
@@ -68,98 +52,10 @@ class AppSearch {
|
|
|
68
52
|
}
|
|
69
53
|
}
|
|
70
54
|
|
|
71
|
-
/** Classe che identifica una colonna. Utilizzata in modalità "Colonne dinamiche" */
|
|
72
|
-
class EsTableColumnsDefinition {
|
|
73
|
-
/**
|
|
74
|
-
* Costruttore
|
|
75
|
-
*
|
|
76
|
-
* @param {string} description Descrizione della colonna
|
|
77
|
-
* @param {string} propertyName Nome della proprietà del modello in cui sono contenuti i dati da visualizzare per questa colonna
|
|
78
|
-
* @param {string} routePath Route di navigazione. Es. "['/pages/mod/mod_detail', { 'idItem': '{0}', 'idItem2' : '{1}' }]"
|
|
79
|
-
* @param {string[]} routeParameterProperties Proprietà da bindare a **routePath** per generare la route completa.
|
|
80
|
-
* L'indice scritto in **routePath** è l'indice di accesso a questo array. Es. ["iditem", "iditem2"]
|
|
81
|
-
* @param {'ASC' | 'DESC' } dataOrder Ordinamento dei dati presentati in questa colonna
|
|
82
|
-
* @param {number} columnOrder Ordinamento di questa colonna
|
|
83
|
-
* @param {boolean} visible Visibilità o meno della colonna
|
|
84
|
-
* @param {string} clss Classe da applicare sia ai TD che ai TH relativi a questa colonna
|
|
85
|
-
* @param {boolean} orderable Indica se la colonna è ordinabile o no (nel senso ASC / DESC / NONE)
|
|
86
|
-
* @param {boolean} headerWraps Indica se il testo dell'header dev'essere wrappato all'interno del th. Di default no.
|
|
87
|
-
*/
|
|
88
|
-
constructor(description, propertyName, routePath = null, routeParameterProperties = null, dataOrder = null, columnOrder = null, visible = true, clss = null, orderable = true, headerWraps = false) {
|
|
89
|
-
this.description = description;
|
|
90
|
-
this.propertyName = propertyName;
|
|
91
|
-
this.routePath = routePath;
|
|
92
|
-
this.routeParameterProperties = routeParameterProperties;
|
|
93
|
-
this.dataOrder = dataOrder;
|
|
94
|
-
this.columnOrder = columnOrder;
|
|
95
|
-
this.visible = visible;
|
|
96
|
-
this.clss = clss;
|
|
97
|
-
this.orderable = orderable;
|
|
98
|
-
this.headerWraps = headerWraps;
|
|
99
|
-
}
|
|
100
|
-
}
|
|
101
|
-
|
|
102
|
-
/** Classe che definisce un oggetto generico come lista di proprietà-valore */
|
|
103
|
-
class GenericItem {
|
|
104
|
-
/** @ignore */
|
|
105
|
-
constructor() {
|
|
106
|
-
this._selected = false;
|
|
107
|
-
this._rowClass = null;
|
|
108
|
-
this._hash = null;
|
|
109
|
-
this.properties = {};
|
|
110
|
-
}
|
|
111
|
-
}
|
|
112
|
-
|
|
113
|
-
/** Indica un'opzione cliccabile nel Corner Menù della tabella (il menù richiamabile dai 3 pallini verticli in alto a destra) */
|
|
114
|
-
class CornerMenuOption {
|
|
115
|
-
}
|
|
116
|
-
|
|
117
55
|
/** Definizione generica di un report che può o no disporre di paginazione/export e la cui richiesta è basata su uno o più parametri */
|
|
118
56
|
class ReportDefinition {
|
|
119
57
|
}
|
|
120
58
|
|
|
121
|
-
/** Classe che identifica una direttiva di ordinamento per un report */
|
|
122
|
-
class ReportOrder {
|
|
123
|
-
}
|
|
124
|
-
|
|
125
|
-
/** Classe che rappresenta una colonna di un report */
|
|
126
|
-
class ReportColumn {
|
|
127
|
-
}
|
|
128
|
-
|
|
129
|
-
/** Classe che rappresenta una lista di oggetti generati da un report */
|
|
130
|
-
class ReportResult {
|
|
131
|
-
}
|
|
132
|
-
|
|
133
|
-
/** Classe che rappresenta i valori delle proprietà di un oggetto Report */
|
|
134
|
-
class ReportRow {
|
|
135
|
-
}
|
|
136
|
-
|
|
137
|
-
/** Classe che identifica un parametro generico per un report */
|
|
138
|
-
class ReportParam {
|
|
139
|
-
}
|
|
140
|
-
|
|
141
|
-
/** Indica operazioni dinamiche generiche che possono essere effettuate per riga. Appaiono come colonne extra sul lato sinistro della tabella */
|
|
142
|
-
class EsTableOperationDefinition {
|
|
143
|
-
/**
|
|
144
|
-
* Costruttore
|
|
145
|
-
*
|
|
146
|
-
* @param {string} id Codice dell'operazione
|
|
147
|
-
* @param {string} title Titolo dell'operazione, da presentare all'utente su hover della cella
|
|
148
|
-
* @param {string} iconClass Classe che fornisca un iconcina Es. "fa fa-remove"
|
|
149
|
-
* @param {string} text Eventuale testo presentato nella cella, genericamente va in alternativa a **iconClass**
|
|
150
|
-
* @param {string} conditionField Indica il campo dell'oggetto sottostante su cui verificare la visibilità o meno di questa icona
|
|
151
|
-
* @param {string} conditionValue Indica il valore che la proprietà **conditionField** dell'oggetto sottostante deve assumere affinché questa opzione si veda
|
|
152
|
-
*/
|
|
153
|
-
constructor(id, title, iconClass, text, conditionField, conditionValue) {
|
|
154
|
-
this.id = id;
|
|
155
|
-
this.title = title;
|
|
156
|
-
this.iconClass = iconClass;
|
|
157
|
-
this.text = text;
|
|
158
|
-
this.conditionField = conditionField;
|
|
159
|
-
this.conditionValue = conditionValue;
|
|
160
|
-
}
|
|
161
|
-
}
|
|
162
|
-
|
|
163
59
|
/** Identifica una selezione applicabile agli oggetti presentati in una tabella */
|
|
164
60
|
class ItemsSelection {
|
|
165
61
|
/**
|
|
@@ -183,39 +79,6 @@ class ItemsSelection {
|
|
|
183
79
|
}
|
|
184
80
|
}
|
|
185
81
|
|
|
186
|
-
/** Classe che rappresenta un Gruppo con le proprie aggregazioni */
|
|
187
|
-
class Group {
|
|
188
|
-
/**
|
|
189
|
-
* Costruttore
|
|
190
|
-
*
|
|
191
|
-
* @param {string} column ID della colonna raggruppata
|
|
192
|
-
* @param {number} count Numero di elementi raggruppati sotto questa colonna
|
|
193
|
-
* @param {string} value Valore del Gruppo
|
|
194
|
-
*/
|
|
195
|
-
constructor(column, count, value) {
|
|
196
|
-
this.column = column;
|
|
197
|
-
this.count = count;
|
|
198
|
-
this.value = value;
|
|
199
|
-
this.aggregations = [];
|
|
200
|
-
}
|
|
201
|
-
}
|
|
202
|
-
|
|
203
|
-
/** Classe che rappresenta un'aggregazione */
|
|
204
|
-
class GroupAggregation {
|
|
205
|
-
/**
|
|
206
|
-
* Costruttore
|
|
207
|
-
*
|
|
208
|
-
* @param {string} column ID della colonna aggregata
|
|
209
|
-
* @param {'min' | 'max' | 'sum' } aggregation Aggregazione da effettuare su questa colonna
|
|
210
|
-
* @param {string} value Valore dell'aggregazione
|
|
211
|
-
*/
|
|
212
|
-
constructor(column, aggregation, value) {
|
|
213
|
-
this.column = column;
|
|
214
|
-
this.aggregation = aggregation;
|
|
215
|
-
this.value = value;
|
|
216
|
-
}
|
|
217
|
-
}
|
|
218
|
-
|
|
219
82
|
/** Classe che rappresenta un filtro su un gruppo */
|
|
220
83
|
class GroupFilter {
|
|
221
84
|
/**
|
|
@@ -230,116 +93,8 @@ class GroupFilter {
|
|
|
230
93
|
}
|
|
231
94
|
}
|
|
232
95
|
|
|
233
|
-
/**
|
|
234
|
-
class
|
|
235
|
-
/**
|
|
236
|
-
* Costruttore
|
|
237
|
-
*
|
|
238
|
-
* @param {string} column Colonna su cui è presente o un gruppo o un'aggregazione
|
|
239
|
-
* @param {'min' | 'max' | 'sum' } aggregation Aggregazione presente sulla **column**. Se questo campo è nullo significa che è un gruppo.
|
|
240
|
-
* @param {'string' | 'date' | 'number'} datatype Tipo di dati contenuto nella colonna **column** se non c'è alcuna aggregazione è inutile, pertanto non sarà valorizzato
|
|
241
|
-
*/
|
|
242
|
-
constructor(column, aggregation, datatype) {
|
|
243
|
-
this.column = column;
|
|
244
|
-
this.aggregation = aggregation;
|
|
245
|
-
this.datatype = datatype;
|
|
246
|
-
}
|
|
247
|
-
}
|
|
248
|
-
|
|
249
|
-
/** Rappresenta un trittico formato da un array e due cache relative a tale array per un accesso estremamente veloce per tutte le operazioni del caso */
|
|
250
|
-
class CacheTriptic {
|
|
251
|
-
/**
|
|
252
|
-
* Costruttore
|
|
253
|
-
*
|
|
254
|
-
* @param {Map<string, any>} cache Cache Chiave-Oggetto
|
|
255
|
-
* @param {Map<string, number>} index_cache Cache Indice-Oggetto
|
|
256
|
-
* @param {any[]} array Array contenente gli oggetti
|
|
257
|
-
*/
|
|
258
|
-
constructor(cache, index_cache, array) {
|
|
259
|
-
this.cache = cache;
|
|
260
|
-
this.index_cache = index_cache;
|
|
261
|
-
this.array = array;
|
|
262
|
-
}
|
|
263
|
-
}
|
|
264
|
-
|
|
265
|
-
/** Definizione di una colonna, utilizzato nella dialog che permette di modificare le posizioni e le visibilità */
|
|
266
|
-
class EsTableColumn {
|
|
267
|
-
/**
|
|
268
|
-
* Costruttore
|
|
269
|
-
*
|
|
270
|
-
* @param {string} id Id colonna
|
|
271
|
-
* @param {string} description Descrizione (Header)
|
|
272
|
-
* @param {boolean} visible Indica se di default mostrarla o meno
|
|
273
|
-
* @param {boolean} fixed Indica se è una colonna fixed
|
|
274
|
-
* @param {boolean} pinned Indica se è una colonna pinnata
|
|
275
|
-
* @param {number} pinnedWidth Indica la dimensione da assegnare a questa colonna quando è pinnata
|
|
276
|
-
* @param {TemplateRef<any>} template Indica il template da usare per mostrare il testo dell'Header
|
|
277
|
-
* @param {TemplateRef<any>[]} parentTemplates Indica la lista di template padri collegata a questo header
|
|
278
|
-
*/
|
|
279
|
-
constructor(id, description, visible, fixed, pinned, pinnedWidth, template, parentTemplates) {
|
|
280
|
-
this.id = id;
|
|
281
|
-
this.description = description;
|
|
282
|
-
this.visible = visible;
|
|
283
|
-
this.fixed = fixed;
|
|
284
|
-
this.pinned = pinned;
|
|
285
|
-
this.pinnedWidth = pinnedWidth;
|
|
286
|
-
this.template = template;
|
|
287
|
-
this.parentTemplates = parentTemplates;
|
|
288
|
-
}
|
|
289
|
-
}
|
|
290
|
-
|
|
291
|
-
/** Classe che rappresenta un separatore da inserire fra gli oggetti dell'es-table per le operazioni di paginazione dei raggruppamenti per riga */
|
|
292
|
-
class GroupPager {
|
|
293
|
-
/**
|
|
294
|
-
* Costruttore
|
|
295
|
-
*
|
|
296
|
-
* @param {number} groupLevel Livello del gruppo a cui questo separatore fa riferimento
|
|
297
|
-
* @param {string} parentKey Chiave del gruppo parent se esiste
|
|
298
|
-
* @param {AppSearch<any>} view Vista di ricerca collegata a questo elemento
|
|
299
|
-
* @param {'groups' | 'items'} searches Indica che cosa cerca questo separatore, se sottogruppi o oggetti
|
|
300
|
-
*/
|
|
301
|
-
constructor(_grouplevel, _thisRoute, _parent, view, searches) {
|
|
302
|
-
this._grouplevel = _grouplevel;
|
|
303
|
-
this._thisRoute = _thisRoute;
|
|
304
|
-
this._parent = _parent;
|
|
305
|
-
this.view = view;
|
|
306
|
-
this.searches = searches;
|
|
307
|
-
this._sep = true;
|
|
308
|
-
this.buttons = [];
|
|
309
|
-
}
|
|
310
|
-
}
|
|
311
|
-
|
|
312
|
-
/**
|
|
313
|
-
* Classe che rappresenta un singolo frammento di route di un elemento gruppo o non. Un array di questi indica tutte le colonne di gruppo con i loro valori
|
|
314
|
-
* per arrivare ad una ricerca su sottogruppi o elementi relativi
|
|
315
|
-
*/
|
|
316
|
-
class GroupRouteFragment {
|
|
317
|
-
/**
|
|
318
|
-
* Costruttore
|
|
319
|
-
*
|
|
320
|
-
* @param {string} column Colonna di raggruppamento
|
|
321
|
-
* @param {string} value Valore della colonna di raggruppamento
|
|
322
|
-
*/
|
|
323
|
-
constructor(column, value) {
|
|
324
|
-
this.column = column;
|
|
325
|
-
this.value = value;
|
|
326
|
-
}
|
|
327
|
-
}
|
|
328
|
-
|
|
329
|
-
/** Classe rappresentante una singola aggregazione effettuata su una colonna */
|
|
330
|
-
class ThAggregation {
|
|
331
|
-
/**
|
|
332
|
-
* Costruttore
|
|
333
|
-
*
|
|
334
|
-
* @param {'min' | 'max' | 'sum'} func Funzione di aggergazione, può essere **min**, **max** o **sum**
|
|
335
|
-
* @param {string} format Formato richiesto per il valore dell'aggregazione
|
|
336
|
-
* @param {string} match Match intero del pezzo di testo da cui si è estrapolata l'aggregazione, da rimpiazzare col valore calcolato
|
|
337
|
-
*/
|
|
338
|
-
constructor(func, format, match) {
|
|
339
|
-
this.func = func;
|
|
340
|
-
this.format = format;
|
|
341
|
-
this.match = match;
|
|
342
|
-
}
|
|
96
|
+
/** Raccolta di tutti gli Input dell'EsTable a cui può essere logicamente sensato assegnare default per progetto */
|
|
97
|
+
class EsTableDefaultable {
|
|
343
98
|
}
|
|
344
99
|
|
|
345
100
|
/** Direttiva per la dichiarazione snella di un EsTd da emettere per ogni elemento, data una colonna */
|
|
@@ -389,6 +144,8 @@ class EsThDirective {
|
|
|
389
144
|
this.th = "";
|
|
390
145
|
/** Indica se la colonna è pinnata o no */
|
|
391
146
|
this.thPinned = false;
|
|
147
|
+
/** Indica se la colonna è pinnabile o no */
|
|
148
|
+
this.thPinnable = true;
|
|
392
149
|
/** Indica le dimensioni che deve avere questa colonna quando viene pinnata, senza questo tutte le colonne mi collasserebbero l'una sull'altra */
|
|
393
150
|
this.thPinnedWidth = 150;
|
|
394
151
|
/** Indicazione sulla visibilità della colonna */
|
|
@@ -422,6 +179,7 @@ EsThDirective.ctorParameters = () => [
|
|
|
422
179
|
EsThDirective.propDecorators = {
|
|
423
180
|
th: [{ type: Input }],
|
|
424
181
|
thPinned: [{ type: Input }],
|
|
182
|
+
thPinnable: [{ type: Input }],
|
|
425
183
|
thPinnedWidth: [{ type: Input }],
|
|
426
184
|
thVisible: [{ type: Input }],
|
|
427
185
|
thFixed: [{ type: Input }],
|
|
@@ -445,44 +203,188 @@ const EST_DEBUG = new InjectionToken('EST_DEBUG');
|
|
|
445
203
|
/** Token che indica i default da assegnare agli Input */
|
|
446
204
|
const EST_DEFAULTS = new InjectionToken('EST_DEFAULTS');
|
|
447
205
|
|
|
448
|
-
/** Classe di localizzazione per il componente **EsTableComponent** */
|
|
449
|
-
class EsTableLoc extends LocalizationService {
|
|
450
|
-
/** @ignore */
|
|
451
|
-
constructor(LOC_LOCALE) {
|
|
452
|
-
super(LOC_LOCALE !== null && LOC_LOCALE !== void 0 ? LOC_LOCALE : 'it-IT');
|
|
453
|
-
super.set("en->it", "All the", ["Tutti gli"]);
|
|
454
|
-
super.set("en->it", "All", ["Tutto"]);
|
|
455
|
-
super.set("en->it", "Groups", ["Gruppi"]);
|
|
456
|
-
super.set("en->it", "Cannot export an empty dataset", ["Impossibile esportare un dataset vuoto"]);
|
|
457
|
-
super.set("en->it", "Performing Table bootstrap", ["Sto caricando la Tabella"]);
|
|
458
|
-
super.set("en->it", "Update every", ["Aggiorna ogni"]);
|
|
459
|
-
super.set("en->it", "second/s", ["secondo/i"]);
|
|
460
|
-
super.set("en->it", "Export View", ["Esporta Vista"]);
|
|
461
|
-
super.set("en->it", "Column Name", ["Nome Colonna"]);
|
|
462
|
-
super.set("en->it", "Columns Order", ["Ordine Colonne"]);
|
|
463
|
-
super.set("en->it", "Columns Visibility", ["Visibilità Colonne"]);
|
|
464
|
-
super.set("en->it", "There are no columns configured to be hidden/shown in this view", ["Non ci sono colonne configurate per essere visualizzate/nascoste in questa vista dati"]);
|
|
465
|
-
super.set("en->it", "Columns Visibility and Order", ["Visibilità e Ordine Colonne"]);
|
|
466
|
-
super.set("en->it", "Objects Selected", ["Oggetti Selezionati"]);
|
|
467
|
-
super.set("en->it", "Object Selected", ["Oggetto Selezionato"]);
|
|
468
|
-
super.set("en->it", "Select Everything", ["Seleziona Tutto"]);
|
|
469
|
-
super.set("en->it", "Reset Selection", ["Resetta Selezione"]);
|
|
470
|
-
super.set("en->it", "No operations available", ["Nessuna operazione disponibile"]);
|
|
471
|
-
super.set("en->it", "Paging options are not available for this report", ["Le opzioni di paginazione non sono disponibili per questo report"]);
|
|
206
|
+
/** Classe di localizzazione per il componente **EsTableComponent** */
|
|
207
|
+
class EsTableLoc extends LocalizationService {
|
|
208
|
+
/** @ignore */
|
|
209
|
+
constructor(LOC_LOCALE) {
|
|
210
|
+
super(LOC_LOCALE !== null && LOC_LOCALE !== void 0 ? LOC_LOCALE : 'it-IT');
|
|
211
|
+
super.set("en->it", "All the", ["Tutti gli"]);
|
|
212
|
+
super.set("en->it", "All", ["Tutto"]);
|
|
213
|
+
super.set("en->it", "Groups", ["Gruppi"]);
|
|
214
|
+
super.set("en->it", "Cannot export an empty dataset", ["Impossibile esportare un dataset vuoto"]);
|
|
215
|
+
super.set("en->it", "Performing Table bootstrap", ["Sto caricando la Tabella"]);
|
|
216
|
+
super.set("en->it", "Update every", ["Aggiorna ogni"]);
|
|
217
|
+
super.set("en->it", "second/s", ["secondo/i"]);
|
|
218
|
+
super.set("en->it", "Export View", ["Esporta Vista"]);
|
|
219
|
+
super.set("en->it", "Column Name", ["Nome Colonna"]);
|
|
220
|
+
super.set("en->it", "Columns Order", ["Ordine Colonne"]);
|
|
221
|
+
super.set("en->it", "Columns Visibility", ["Visibilità Colonne"]);
|
|
222
|
+
super.set("en->it", "There are no columns configured to be hidden/shown in this view", ["Non ci sono colonne configurate per essere visualizzate/nascoste in questa vista dati"]);
|
|
223
|
+
super.set("en->it", "Columns Visibility and Order", ["Visibilità e Ordine Colonne"]);
|
|
224
|
+
super.set("en->it", "Objects Selected", ["Oggetti Selezionati"]);
|
|
225
|
+
super.set("en->it", "Object Selected", ["Oggetto Selezionato"]);
|
|
226
|
+
super.set("en->it", "Select Everything", ["Seleziona Tutto"]);
|
|
227
|
+
super.set("en->it", "Reset Selection", ["Resetta Selezione"]);
|
|
228
|
+
super.set("en->it", "No operations available", ["Nessuna operazione disponibile"]);
|
|
229
|
+
super.set("en->it", "Paging options are not available for this report", ["Le opzioni di paginazione non sono disponibili per questo report"]);
|
|
230
|
+
}
|
|
231
|
+
}
|
|
232
|
+
EsTableLoc.decorators = [
|
|
233
|
+
{ type: Injectable }
|
|
234
|
+
];
|
|
235
|
+
EsTableLoc.ctorParameters = () => [
|
|
236
|
+
{ type: String, decorators: [{ type: Optional }, { type: Inject, args: [EST_LOCALE,] }] }
|
|
237
|
+
];
|
|
238
|
+
|
|
239
|
+
/** Classe contenente la gestione delle importazioni */
|
|
240
|
+
class ExportHandler {
|
|
241
|
+
/** @ignore Costruttore*/
|
|
242
|
+
constructor(est, expExts, msgExts, utiExts, dateExts) {
|
|
243
|
+
this.est = est;
|
|
244
|
+
this.expExts = expExts;
|
|
245
|
+
this.msgExts = msgExts;
|
|
246
|
+
this.utiExts = utiExts;
|
|
247
|
+
this.dateExts = dateExts;
|
|
248
|
+
}
|
|
249
|
+
/**
|
|
250
|
+
* Effettua l'esportazione dei dati
|
|
251
|
+
*
|
|
252
|
+
* @param {string} format Formato di esportazione. Letto solo in modalità Report della tabella
|
|
253
|
+
*/
|
|
254
|
+
tryExport(format) {
|
|
255
|
+
if (!this.est.ExportFunction)
|
|
256
|
+
return;
|
|
257
|
+
if (this.est.reportMode)
|
|
258
|
+
this.est.ExportFunction(format);
|
|
259
|
+
else
|
|
260
|
+
this.est.ExportFunction((data, cancel = false) => __awaiter(this, void 0, void 0, function* () {
|
|
261
|
+
if (cancel)
|
|
262
|
+
return;
|
|
263
|
+
if (data.length == 0) {
|
|
264
|
+
this.msgExts.simpleWarning(this.est.lc.loc("Cannot export an empty dataset"));
|
|
265
|
+
return;
|
|
266
|
+
}
|
|
267
|
+
this.setupExport(data);
|
|
268
|
+
if (format == "CSV") {
|
|
269
|
+
this.est.cdr.detectChanges();
|
|
270
|
+
setTimeout(() => { this.est.exportDownloader.nativeElement.click(); });
|
|
271
|
+
}
|
|
272
|
+
else if (format == "XLSX") {
|
|
273
|
+
if (this.ExcelJS != null) {
|
|
274
|
+
this.exportExcel();
|
|
275
|
+
return;
|
|
276
|
+
}
|
|
277
|
+
try {
|
|
278
|
+
this.ExcelJS = yield import('exceljs');
|
|
279
|
+
this.exportExcel();
|
|
280
|
+
}
|
|
281
|
+
catch (_a) {
|
|
282
|
+
throw "Impossibile caricare la libreria per l'esportazione in Excel";
|
|
283
|
+
}
|
|
284
|
+
}
|
|
285
|
+
else
|
|
286
|
+
throw "Formato di esportazione non riconosciuto";
|
|
287
|
+
}));
|
|
288
|
+
}
|
|
289
|
+
/** Effettua l'esportazione del file Excel basandosi sul modulo **ExcelJS**, sugli header **this.est.headers** e sui dati **this.est.data** */
|
|
290
|
+
exportExcel() {
|
|
291
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
292
|
+
let iFix = 1;
|
|
293
|
+
let workbook = new this.ExcelJS.Workbook();
|
|
294
|
+
workbook.creator = "Ema's big Es-Table";
|
|
295
|
+
workbook.created = new Date();
|
|
296
|
+
let sheet = workbook.addWorksheet('Data');
|
|
297
|
+
let header = sheet.getRow(1);
|
|
298
|
+
header.font = { bold: true };
|
|
299
|
+
this.est.headers = this.est.headers.sort((a, b) => a.order - b.order);
|
|
300
|
+
for (let i = 0; i < this.est.headers.length; i++) {
|
|
301
|
+
let h = this.est.headers[i];
|
|
302
|
+
header.getCell(i + iFix).value = h.label;
|
|
303
|
+
}
|
|
304
|
+
for (let i = 0; i < this.est.data.length; i++) {
|
|
305
|
+
let row = sheet.getRow(i + iFix + 1);
|
|
306
|
+
let item = this.est.data[i];
|
|
307
|
+
for (let i = 0; i < this.est.headers.length; i++) {
|
|
308
|
+
let h = this.est.headers[i];
|
|
309
|
+
let cell = row.getCell(i + 1);
|
|
310
|
+
let val = item[h.key];
|
|
311
|
+
if (val == null || val == undefined)
|
|
312
|
+
cell.value = "";
|
|
313
|
+
else {
|
|
314
|
+
switch (h.type) {
|
|
315
|
+
case 'date':
|
|
316
|
+
cell.value = this.dateExts.getDateConvertion(val).toDate();
|
|
317
|
+
case 'number':
|
|
318
|
+
cell.value = parseFloat(val.replace(',', '.'));
|
|
319
|
+
default:
|
|
320
|
+
cell.value = val;
|
|
321
|
+
}
|
|
322
|
+
}
|
|
323
|
+
}
|
|
324
|
+
}
|
|
325
|
+
let buffer = yield workbook.xlsx.writeBuffer();
|
|
326
|
+
let blob = new Blob([buffer], { type: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet;" });
|
|
327
|
+
let objectUrl = window.URL.createObjectURL(blob);
|
|
328
|
+
let fn = this.est.ExportFileName;
|
|
329
|
+
this.utiExts.fileDownload(objectUrl, fn.endsWith('.csv') ? fn.replace('.csv', '.xlsx') : fn.endsWith('.xlsx') ? fn : fn + ".xlsx");
|
|
330
|
+
});
|
|
331
|
+
}
|
|
332
|
+
/**
|
|
333
|
+
* Metodo che effettivamente genera gli header e i dati per l'esportazione con **ngx-csv**
|
|
334
|
+
*
|
|
335
|
+
* @param {any[]} items Oggetti da esportare
|
|
336
|
+
*/
|
|
337
|
+
setupExport(items) {
|
|
338
|
+
let drcd = this.est.DynamicRowColumnsDefinition;
|
|
339
|
+
this.est.headers = drcd && drcd.length > 0 ? this.expExts.setupForGenericExport(items, drcd.map(t => { return { label: t.description, key: t.propertyName, order: t.columnOrder, type: 'string' }; })) : this.expExts.setupForExport(items);
|
|
340
|
+
this.est.data = items;
|
|
341
|
+
}
|
|
342
|
+
}
|
|
343
|
+
|
|
344
|
+
/**
|
|
345
|
+
* Classe che identifica un ordinamento di una colonna
|
|
346
|
+
*/
|
|
347
|
+
class AppOrdering {
|
|
348
|
+
/**
|
|
349
|
+
* Costruttore
|
|
350
|
+
*
|
|
351
|
+
* @param {string} id ID della colonna a cui si vogliono applicare ordinamenti, deve combaciare all'id messo nella dichiarazione dell'ES-TD/TH
|
|
352
|
+
* @param {'DESC' | 'ASC' } order Ordinamento da applicare alla colonna, Discendente/Ascendente, default 'null' per indicare assenza di ordine
|
|
353
|
+
*/
|
|
354
|
+
constructor(id, order) {
|
|
355
|
+
this.id = id;
|
|
356
|
+
this.order = order;
|
|
472
357
|
}
|
|
473
|
-
}
|
|
474
|
-
EsTableLoc.decorators = [
|
|
475
|
-
{ type: Injectable }
|
|
476
|
-
];
|
|
477
|
-
EsTableLoc.ctorParameters = () => [
|
|
478
|
-
{ type: String, decorators: [{ type: Optional }, { type: Inject, args: [EST_LOCALE,] }] }
|
|
479
|
-
];
|
|
358
|
+
}
|
|
480
359
|
|
|
481
|
-
/**
|
|
482
|
-
class
|
|
360
|
+
/** Definizione di una colonna, utilizzato nella dialog che permette di modificare le posizioni e le visibilità */
|
|
361
|
+
class EsTableColumn {
|
|
362
|
+
/**
|
|
363
|
+
* Costruttore
|
|
364
|
+
*
|
|
365
|
+
* @param {string} id Id colonna
|
|
366
|
+
* @param {string} description Descrizione (Header)
|
|
367
|
+
* @param {boolean} visible Indica se di default mostrarla o meno
|
|
368
|
+
* @param {boolean} fixed Indica se è una colonna fixed
|
|
369
|
+
* @param {boolean} pinned Indica se è una colonna pinnata
|
|
370
|
+
* @param {number} pinnedWidth Indica la dimensione da assegnare a questa colonna quando è pinnata
|
|
371
|
+
* @param {TemplateRef<any>} template Indica il template da usare per mostrare il testo dell'Header
|
|
372
|
+
* @param {TemplateRef<any>[]} parentTemplates Indica la lista di template padri collegata a questo header
|
|
373
|
+
*/
|
|
374
|
+
constructor(id, description, visible, fixed, pinned, pinnable, pinnedWidth, template, parentTemplates) {
|
|
375
|
+
this.id = id;
|
|
376
|
+
this.description = description;
|
|
377
|
+
this.visible = visible;
|
|
378
|
+
this.fixed = fixed;
|
|
379
|
+
this.pinned = pinned;
|
|
380
|
+
this.pinnable = pinnable;
|
|
381
|
+
this.pinnedWidth = pinnedWidth;
|
|
382
|
+
this.template = template;
|
|
383
|
+
this.parentTemplates = parentTemplates;
|
|
384
|
+
}
|
|
483
385
|
}
|
|
484
386
|
|
|
485
|
-
//
|
|
387
|
+
// Angular
|
|
486
388
|
/** Classe che gestisce tutte le informaizoni relative alle colonne: visibilità, posizione, stato di pin/unpin, ecc ecc... */
|
|
487
389
|
class ColumnMetadataHandler {
|
|
488
390
|
/** @ignore Costruttore*/
|
|
@@ -564,7 +466,7 @@ class ColumnMetadataHandler {
|
|
|
564
466
|
// Di default la visibilità è quella impostata nel componente
|
|
565
467
|
if ((this.est.HiddenColumns || th.thVisible) && th.thIf) {
|
|
566
468
|
let previouslyPinned = !this.est.ColumnsList || this.est.ColumnsList.length == 0 ? null : this.est.ColumnsList.find(t => t.id == column) || null;
|
|
567
|
-
let toAdd = new EsTableColumn(column, null, th.thVisible, (th.thFixed || th.thGroup), previouslyPinned == null ? th.thPinned : previouslyPinned.pinned, th.thPinnedWidth, th.Template, th._thParents);
|
|
469
|
+
let toAdd = new EsTableColumn(column, null, th.thVisible, (th.thFixed || th.thGroup), previouslyPinned == null ? th.thPinned : previouslyPinned.pinned, th.thPinnable, th.thPinnedWidth, th.Template, th._thParents);
|
|
568
470
|
if (previouslyPinned)
|
|
569
471
|
toAdd.prev_index = previouslyPinned.prev_index;
|
|
570
472
|
this.est.TMPColumnsList.push(toAdd);
|
|
@@ -1147,171 +1049,96 @@ class ColumnMetadataHandler {
|
|
|
1147
1049
|
}
|
|
1148
1050
|
}
|
|
1149
1051
|
|
|
1150
|
-
|
|
1151
|
-
|
|
1152
|
-
|
|
1153
|
-
|
|
1154
|
-
|
|
1155
|
-
|
|
1156
|
-
|
|
1157
|
-
|
|
1158
|
-
*
|
|
1159
|
-
*
|
|
1160
|
-
* @param {
|
|
1161
|
-
* @param {
|
|
1162
|
-
*
|
|
1163
|
-
* @param {
|
|
1164
|
-
*
|
|
1165
|
-
* @
|
|
1166
|
-
*/
|
|
1167
|
-
|
|
1168
|
-
|
|
1169
|
-
|
|
1170
|
-
|
|
1171
|
-
|
|
1172
|
-
|
|
1173
|
-
|
|
1174
|
-
|
|
1175
|
-
|
|
1176
|
-
|
|
1177
|
-
|
|
1178
|
-
|
|
1179
|
-
|
|
1180
|
-
|
|
1181
|
-
|
|
1182
|
-
|
|
1183
|
-
|
|
1184
|
-
|
|
1185
|
-
|
|
1186
|
-
*/
|
|
1187
|
-
getRouterLink(path, pars, item) {
|
|
1188
|
-
for (let i = 0; i < pars.length; i++)
|
|
1189
|
-
path = path.replace('{' + i + '}', item.properties[pars[i]]);
|
|
1190
|
-
path = path.replace(/'/g, '"').replace(/ /g, '');
|
|
1191
|
-
return JSON.parse(path);
|
|
1192
|
-
}
|
|
1193
|
-
/** Se non ho l'Input **DynamicRowColumnsDefinition** in modalità dinamica lo riempio con il default nome della colonna = testo della colonna */
|
|
1194
|
-
eventuallyReviewDynamicColumns() {
|
|
1195
|
-
// Senza oggetti esco
|
|
1196
|
-
if (!this.est.TMPBoundSource || this.est.TMPBoundSource.length == 0)
|
|
1197
|
-
return;
|
|
1198
|
-
var useGenericItems = !!this.est.TMPBoundSource[0]["properties"];
|
|
1199
|
-
if (!useGenericItems || (!this.est.FirstBind && this.est.DynamicRowColumnsDefinition && this.est.DynamicRowColumnsDefinition.length > 0))
|
|
1200
|
-
return;
|
|
1201
|
-
if ((!this.est.DynamicRowColumnsDefinition || this.est.DynamicRowColumnsDefinition.length == 0)) {
|
|
1202
|
-
var props = this.est.TMPBoundSource[0]["properties"];
|
|
1203
|
-
this.est.DynamicRowColumnsDefinition = [];
|
|
1204
|
-
for (let key in props)
|
|
1205
|
-
this.est.DynamicRowColumnsDefinition.push(new EsTableColumnsDefinition(key, key));
|
|
1206
|
-
this.est.UserDefinedDynamicCols = false;
|
|
1207
|
-
}
|
|
1208
|
-
else
|
|
1209
|
-
this.est.UserDefinedDynamicCols = true;
|
|
1210
|
-
}
|
|
1211
|
-
}
|
|
1212
|
-
|
|
1213
|
-
/** Classe contenente la gestione delle importazioni */
|
|
1214
|
-
class ExportHandler {
|
|
1215
|
-
/** @ignore Costruttore*/
|
|
1216
|
-
constructor(est, expExts, msgExts, utiExts, dateExts) {
|
|
1217
|
-
this.est = est;
|
|
1218
|
-
this.expExts = expExts;
|
|
1219
|
-
this.msgExts = msgExts;
|
|
1220
|
-
this.utiExts = utiExts;
|
|
1221
|
-
this.dateExts = dateExts;
|
|
1222
|
-
}
|
|
1223
|
-
/**
|
|
1224
|
-
* Effettua l'esportazione dei dati
|
|
1225
|
-
*
|
|
1226
|
-
* @param {string} format Formato di esportazione. Letto solo in modalità Report della tabella
|
|
1227
|
-
*/
|
|
1228
|
-
tryExport(format) {
|
|
1229
|
-
if (!this.est.ExportFunction)
|
|
1230
|
-
return;
|
|
1231
|
-
if (this.est.reportMode)
|
|
1232
|
-
this.est.ExportFunction(format);
|
|
1233
|
-
else
|
|
1234
|
-
this.est.ExportFunction((data, cancel = false) => __awaiter(this, void 0, void 0, function* () {
|
|
1235
|
-
if (cancel)
|
|
1236
|
-
return;
|
|
1237
|
-
if (data.length == 0) {
|
|
1238
|
-
this.msgExts.simpleWarning(this.est.lc.loc("Cannot export an empty dataset"));
|
|
1239
|
-
return;
|
|
1240
|
-
}
|
|
1241
|
-
this.setupExport(data);
|
|
1242
|
-
if (format == "CSV") {
|
|
1243
|
-
this.est.cdr.detectChanges();
|
|
1244
|
-
setTimeout(() => { this.est.exportDownloader.nativeElement.click(); });
|
|
1245
|
-
}
|
|
1246
|
-
else if (format == "XLSX") {
|
|
1247
|
-
if (this.ExcelJS != null) {
|
|
1248
|
-
this.exportExcel();
|
|
1249
|
-
return;
|
|
1250
|
-
}
|
|
1251
|
-
try {
|
|
1252
|
-
this.ExcelJS = yield import('exceljs');
|
|
1253
|
-
this.exportExcel();
|
|
1254
|
-
}
|
|
1255
|
-
catch (_a) {
|
|
1256
|
-
throw "Impossibile caricare la libreria per l'esportazione in Excel";
|
|
1257
|
-
}
|
|
1258
|
-
}
|
|
1259
|
-
else
|
|
1260
|
-
throw "Formato di esportazione non riconosciuto";
|
|
1261
|
-
}));
|
|
1262
|
-
}
|
|
1263
|
-
/** Effettua l'esportazione del file Excel basandosi sul modulo **ExcelJS**, sugli header **this.est.headers** e sui dati **this.est.data** */
|
|
1264
|
-
exportExcel() {
|
|
1265
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
1266
|
-
let iFix = 1;
|
|
1267
|
-
let workbook = new this.ExcelJS.Workbook();
|
|
1268
|
-
workbook.creator = "Ema's big Es-Table";
|
|
1269
|
-
workbook.created = new Date();
|
|
1270
|
-
let sheet = workbook.addWorksheet('Data');
|
|
1271
|
-
let header = sheet.getRow(1);
|
|
1272
|
-
header.font = { bold: true };
|
|
1273
|
-
this.est.headers = this.est.headers.sort((a, b) => a.order - b.order);
|
|
1274
|
-
for (let i = 0; i < this.est.headers.length; i++) {
|
|
1275
|
-
let h = this.est.headers[i];
|
|
1276
|
-
header.getCell(i + iFix).value = h.label;
|
|
1277
|
-
}
|
|
1278
|
-
for (let i = 0; i < this.est.data.length; i++) {
|
|
1279
|
-
let row = sheet.getRow(i + iFix + 1);
|
|
1280
|
-
let item = this.est.data[i];
|
|
1281
|
-
for (let i = 0; i < this.est.headers.length; i++) {
|
|
1282
|
-
let h = this.est.headers[i];
|
|
1283
|
-
let cell = row.getCell(i + 1);
|
|
1284
|
-
let val = item[h.key];
|
|
1285
|
-
if (val == null || val == undefined)
|
|
1286
|
-
cell.value = "";
|
|
1287
|
-
else {
|
|
1288
|
-
switch (h.type) {
|
|
1289
|
-
case 'date':
|
|
1290
|
-
cell.value = this.dateExts.getDateConvertion(val).toDate();
|
|
1291
|
-
case 'number':
|
|
1292
|
-
cell.value = parseFloat(val.replace(',', '.'));
|
|
1293
|
-
default:
|
|
1294
|
-
cell.value = val;
|
|
1295
|
-
}
|
|
1296
|
-
}
|
|
1297
|
-
}
|
|
1298
|
-
}
|
|
1299
|
-
let buffer = yield workbook.xlsx.writeBuffer();
|
|
1300
|
-
let blob = new Blob([buffer], { type: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet;" });
|
|
1301
|
-
let objectUrl = window.URL.createObjectURL(blob);
|
|
1302
|
-
let fn = this.est.ExportFileName;
|
|
1303
|
-
this.utiExts.fileDownload(objectUrl, fn.endsWith('.csv') ? fn.replace('.csv', '.xlsx') : fn.endsWith('.xlsx') ? fn : fn + ".xlsx");
|
|
1304
|
-
});
|
|
1052
|
+
/** Classe che identifica una colonna. Utilizzata in modalità "Colonne dinamiche" */
|
|
1053
|
+
class EsTableColumnsDefinition {
|
|
1054
|
+
/**
|
|
1055
|
+
* Costruttore
|
|
1056
|
+
*
|
|
1057
|
+
* @param {string} description Descrizione della colonna
|
|
1058
|
+
* @param {string} propertyName Nome della proprietà del modello in cui sono contenuti i dati da visualizzare per questa colonna
|
|
1059
|
+
* @param {string} routePath Route di navigazione. Es. "['/pages/mod/mod_detail', { 'idItem': '{0}', 'idItem2' : '{1}' }]"
|
|
1060
|
+
* @param {string[]} routeParameterProperties Proprietà da bindare a **routePath** per generare la route completa.
|
|
1061
|
+
* L'indice scritto in **routePath** è l'indice di accesso a questo array. Es. ["iditem", "iditem2"]
|
|
1062
|
+
* @param {'ASC' | 'DESC' } dataOrder Ordinamento dei dati presentati in questa colonna
|
|
1063
|
+
* @param {number} columnOrder Ordinamento di questa colonna
|
|
1064
|
+
* @param {boolean} visible Visibilità o meno della colonna
|
|
1065
|
+
* @param {string} clss Classe da applicare sia ai TD che ai TH relativi a questa colonna
|
|
1066
|
+
* @param {boolean} orderable Indica se la colonna è ordinabile o no (nel senso ASC / DESC / NONE)
|
|
1067
|
+
* @param {boolean} headerWraps Indica se il testo dell'header dev'essere wrappato all'interno del th. Di default no.
|
|
1068
|
+
*/
|
|
1069
|
+
constructor(description, propertyName, routePath = null, routeParameterProperties = null, dataOrder = null, columnOrder = null, visible = true, clss = null, orderable = true, headerWraps = false) {
|
|
1070
|
+
this.description = description;
|
|
1071
|
+
this.propertyName = propertyName;
|
|
1072
|
+
this.routePath = routePath;
|
|
1073
|
+
this.routeParameterProperties = routeParameterProperties;
|
|
1074
|
+
this.dataOrder = dataOrder;
|
|
1075
|
+
this.columnOrder = columnOrder;
|
|
1076
|
+
this.visible = visible;
|
|
1077
|
+
this.clss = clss;
|
|
1078
|
+
this.orderable = orderable;
|
|
1079
|
+
this.headerWraps = headerWraps;
|
|
1080
|
+
}
|
|
1081
|
+
}
|
|
1082
|
+
|
|
1083
|
+
/** Classe contenente le gestioni particolari della modalità dinamica dell'es-table */
|
|
1084
|
+
class DynamicModeHandler {
|
|
1085
|
+
/** @ignore Costruttore*/
|
|
1086
|
+
constructor(est) {
|
|
1087
|
+
this.est = est;
|
|
1305
1088
|
}
|
|
1306
1089
|
/**
|
|
1307
|
-
* Metodo
|
|
1090
|
+
* Metodo di supporto alla creazione di un router link parametrizzato all'oggetto corrente utilizzato nella modalità dinamica
|
|
1308
1091
|
*
|
|
1309
|
-
* @param {
|
|
1092
|
+
* @param {string} path Path su cui navigare con eventuali parametri riferiti all'oggetto cotnestuale come {0}, {1}, ecc...
|
|
1093
|
+
* @param {string[]} parameterProps Lista posizionale delle proprietà a cui bindare i riferimenti del parametro **path**
|
|
1094
|
+
* Es. Il valore dela proprietà all'indice 0 di questo array verrà sostituita al valore {0} del parametro **path**
|
|
1095
|
+
* @param {GenericItem} item Oggetto generico collegato a questo contesto
|
|
1096
|
+
*
|
|
1097
|
+
* @returns {any} Router link generato in base al parametri
|
|
1310
1098
|
*/
|
|
1311
|
-
|
|
1312
|
-
|
|
1313
|
-
|
|
1314
|
-
|
|
1099
|
+
generateRouterLink(path, parameterProps, item) {
|
|
1100
|
+
if (this.est.DynamicTableRouterLinkCache[item._hash + path]) {
|
|
1101
|
+
return this.est.DynamicTableRouterLinkCache[item._hash + path];
|
|
1102
|
+
}
|
|
1103
|
+
else {
|
|
1104
|
+
let link = this.getRouterLink(path, parameterProps, item);
|
|
1105
|
+
this.est.DynamicTableRouterLinkCache[item._hash + path] = link;
|
|
1106
|
+
return link;
|
|
1107
|
+
}
|
|
1108
|
+
}
|
|
1109
|
+
/**
|
|
1110
|
+
* Crea un router link
|
|
1111
|
+
*
|
|
1112
|
+
* @param {string} path Path su cui navigare con eventuali parametri riferiti all'oggetto cotnestuale come {0}, {1}, ecc...
|
|
1113
|
+
* @param {string[]} pars Lista posizionale delle proprietà a cui bindare i riferimenti del parametro **path**
|
|
1114
|
+
* Es. Il valore dela proprietà all'indice 0 di questo array verrà sostituita al valore {0} del parametro **path**
|
|
1115
|
+
* @param {GenericItem} item Oggetto generico collegato a questo contesto
|
|
1116
|
+
*
|
|
1117
|
+
* @returns {any} Router link generato in base al parametri
|
|
1118
|
+
*/
|
|
1119
|
+
getRouterLink(path, pars, item) {
|
|
1120
|
+
for (let i = 0; i < pars.length; i++)
|
|
1121
|
+
path = path.replace('{' + i + '}', item.properties[pars[i]]);
|
|
1122
|
+
path = path.replace(/'/g, '"').replace(/ /g, '');
|
|
1123
|
+
return JSON.parse(path);
|
|
1124
|
+
}
|
|
1125
|
+
/** Se non ho l'Input **DynamicRowColumnsDefinition** in modalità dinamica lo riempio con il default nome della colonna = testo della colonna */
|
|
1126
|
+
eventuallyReviewDynamicColumns() {
|
|
1127
|
+
// Senza oggetti esco
|
|
1128
|
+
if (!this.est.TMPBoundSource || this.est.TMPBoundSource.length == 0)
|
|
1129
|
+
return;
|
|
1130
|
+
var useGenericItems = !!this.est.TMPBoundSource[0]["properties"];
|
|
1131
|
+
if (!useGenericItems || (!this.est.FirstBind && this.est.DynamicRowColumnsDefinition && this.est.DynamicRowColumnsDefinition.length > 0))
|
|
1132
|
+
return;
|
|
1133
|
+
if ((!this.est.DynamicRowColumnsDefinition || this.est.DynamicRowColumnsDefinition.length == 0)) {
|
|
1134
|
+
var props = this.est.TMPBoundSource[0]["properties"];
|
|
1135
|
+
this.est.DynamicRowColumnsDefinition = [];
|
|
1136
|
+
for (let key in props)
|
|
1137
|
+
this.est.DynamicRowColumnsDefinition.push(new EsTableColumnsDefinition(key, key));
|
|
1138
|
+
this.est.UserDefinedDynamicCols = false;
|
|
1139
|
+
}
|
|
1140
|
+
else
|
|
1141
|
+
this.est.UserDefinedDynamicCols = true;
|
|
1315
1142
|
}
|
|
1316
1143
|
}
|
|
1317
1144
|
|
|
@@ -1562,7 +1389,10 @@ class ItemsHandler {
|
|
|
1562
1389
|
}
|
|
1563
1390
|
}
|
|
1564
1391
|
|
|
1565
|
-
|
|
1392
|
+
/** Classe che identifica una direttiva di ordinamento per un report */
|
|
1393
|
+
class ReportOrder {
|
|
1394
|
+
}
|
|
1395
|
+
|
|
1566
1396
|
/** Classe che gestisce la modalità Report dell'es-table utilizzata nel Metering */
|
|
1567
1397
|
class ReportModeHandler {
|
|
1568
1398
|
/** @ignore Costruttore */
|
|
@@ -1631,7 +1461,94 @@ class ReportModeHandler {
|
|
|
1631
1461
|
}
|
|
1632
1462
|
}
|
|
1633
1463
|
|
|
1634
|
-
|
|
1464
|
+
/** Classe che rappresenta un Gruppo con le proprie aggregazioni */
|
|
1465
|
+
class Group {
|
|
1466
|
+
/**
|
|
1467
|
+
* Costruttore
|
|
1468
|
+
*
|
|
1469
|
+
* @param {string} column ID della colonna raggruppata
|
|
1470
|
+
* @param {number} count Numero di elementi raggruppati sotto questa colonna
|
|
1471
|
+
* @param {string} value Valore del Gruppo
|
|
1472
|
+
*/
|
|
1473
|
+
constructor(column, count, value) {
|
|
1474
|
+
this.column = column;
|
|
1475
|
+
this.count = count;
|
|
1476
|
+
this.value = value;
|
|
1477
|
+
this.aggregations = [];
|
|
1478
|
+
}
|
|
1479
|
+
}
|
|
1480
|
+
|
|
1481
|
+
/** Classe che rappresenta un'aggregazione */
|
|
1482
|
+
class GroupAggregation {
|
|
1483
|
+
/**
|
|
1484
|
+
* Costruttore
|
|
1485
|
+
*
|
|
1486
|
+
* @param {string} column ID della colonna aggregata
|
|
1487
|
+
* @param {'min' | 'max' | 'sum' } aggregation Aggregazione da effettuare su questa colonna
|
|
1488
|
+
* @param {string} value Valore dell'aggregazione
|
|
1489
|
+
*/
|
|
1490
|
+
constructor(column, aggregation, value) {
|
|
1491
|
+
this.column = column;
|
|
1492
|
+
this.aggregation = aggregation;
|
|
1493
|
+
this.value = value;
|
|
1494
|
+
}
|
|
1495
|
+
}
|
|
1496
|
+
|
|
1497
|
+
/** Classe che rappresenta o un gruppo o una aggregazione su una colonna. Usata solo internamente */
|
|
1498
|
+
class GroupOrAggregation {
|
|
1499
|
+
/**
|
|
1500
|
+
* Costruttore
|
|
1501
|
+
*
|
|
1502
|
+
* @param {string} column Colonna su cui è presente o un gruppo o un'aggregazione
|
|
1503
|
+
* @param {'min' | 'max' | 'sum' } aggregation Aggregazione presente sulla **column**. Se questo campo è nullo significa che è un gruppo.
|
|
1504
|
+
* @param {'string' | 'date' | 'number'} datatype Tipo di dati contenuto nella colonna **column** se non c'è alcuna aggregazione è inutile, pertanto non sarà valorizzato
|
|
1505
|
+
*/
|
|
1506
|
+
constructor(column, aggregation, datatype) {
|
|
1507
|
+
this.column = column;
|
|
1508
|
+
this.aggregation = aggregation;
|
|
1509
|
+
this.datatype = datatype;
|
|
1510
|
+
}
|
|
1511
|
+
}
|
|
1512
|
+
|
|
1513
|
+
/** Classe che rappresenta un separatore da inserire fra gli oggetti dell'es-table per le operazioni di paginazione dei raggruppamenti per riga */
|
|
1514
|
+
class GroupPager {
|
|
1515
|
+
/**
|
|
1516
|
+
* Costruttore
|
|
1517
|
+
*
|
|
1518
|
+
* @param {number} groupLevel Livello del gruppo a cui questo separatore fa riferimento
|
|
1519
|
+
* @param {string} parentKey Chiave del gruppo parent se esiste
|
|
1520
|
+
* @param {AppSearch<any>} view Vista di ricerca collegata a questo elemento
|
|
1521
|
+
* @param {'groups' | 'items'} searches Indica che cosa cerca questo separatore, se sottogruppi o oggetti
|
|
1522
|
+
*/
|
|
1523
|
+
constructor(_grouplevel, _thisRoute, _parent, view, searches) {
|
|
1524
|
+
this._grouplevel = _grouplevel;
|
|
1525
|
+
this._thisRoute = _thisRoute;
|
|
1526
|
+
this._parent = _parent;
|
|
1527
|
+
this.view = view;
|
|
1528
|
+
this.searches = searches;
|
|
1529
|
+
this._sep = true;
|
|
1530
|
+
this.buttons = [];
|
|
1531
|
+
this._thisKey = _parent + "_sep";
|
|
1532
|
+
}
|
|
1533
|
+
}
|
|
1534
|
+
|
|
1535
|
+
/**
|
|
1536
|
+
* Classe che rappresenta un singolo frammento di route di un elemento gruppo o non. Un array di questi indica tutte le colonne di gruppo con i loro valori
|
|
1537
|
+
* per arrivare ad una ricerca su sottogruppi o elementi relativi
|
|
1538
|
+
*/
|
|
1539
|
+
class GroupRouteFragment {
|
|
1540
|
+
/**
|
|
1541
|
+
* Costruttore
|
|
1542
|
+
*
|
|
1543
|
+
* @param {string} column Colonna di raggruppamento
|
|
1544
|
+
* @param {string} value Valore della colonna di raggruppamento
|
|
1545
|
+
*/
|
|
1546
|
+
constructor(column, value) {
|
|
1547
|
+
this.column = column;
|
|
1548
|
+
this.value = value;
|
|
1549
|
+
}
|
|
1550
|
+
}
|
|
1551
|
+
|
|
1635
1552
|
/** Classe che gestisce la modalità Row Grouping dell'es-table */
|
|
1636
1553
|
class RowGroupingHandler {
|
|
1637
1554
|
/** @ignore Costruttore */
|
|
@@ -1678,7 +1595,7 @@ class RowGroupingHandler {
|
|
|
1678
1595
|
this.est.BaseItemsCount = view.objectcount;
|
|
1679
1596
|
}
|
|
1680
1597
|
else {
|
|
1681
|
-
// 2) Se viene richiesto il dettaglio di un qualsiasi gruppo diverso dall'ultimo vuol dire che devo aggiungere
|
|
1598
|
+
// 2) Se viene richiesto il dettaglio di un qualsiasi gruppo diverso dall'ultimo vuol dire che devo aggiungere
|
|
1682
1599
|
// dopo al gruppo che ho cliccato la lista dei gruppi tirata fuori questa volta (intermediateGroup = true)
|
|
1683
1600
|
/*
|
|
1684
1601
|
* GruppoA GruppoA
|
|
@@ -1689,7 +1606,7 @@ class RowGroupingHandler {
|
|
|
1689
1606
|
* GruppoD
|
|
1690
1607
|
* GruppoE
|
|
1691
1608
|
*/
|
|
1692
|
-
// 3) se i gruppi richiesti dalla view sono uguali ai gruppi presenti vuol dire che sto prendendo gli oggetti veri e propri, sono in
|
|
1609
|
+
// 3) se i gruppi richiesti dalla view sono uguali ai gruppi presenti vuol dire che sto prendendo gli oggetti veri e propri, sono in
|
|
1693
1610
|
// view.items e quindi in TMPBoundSource, ho inoltre le informazioni di paginazione **per il singolo sottogruppo** (intermediateGroup = false)
|
|
1694
1611
|
/*
|
|
1695
1612
|
* GruppoA GruppoA
|
|
@@ -1763,15 +1680,20 @@ class RowGroupingHandler {
|
|
|
1763
1680
|
itemsCacheReference.push(itm);
|
|
1764
1681
|
}
|
|
1765
1682
|
});
|
|
1766
|
-
// Elimino gli oggetti vecchi
|
|
1683
|
+
// Elimino gli oggetti vecchi
|
|
1767
1684
|
// 1) Ricerca intermedia, stato salvato - Elimino tutti gli item e tutti i gruppi la cui route è più lunga della corrente, tutti gli item relativi alla path corrente, e tutte
|
|
1768
1685
|
// le cache di ricerca effettuate su una path più profonda dell'attuale
|
|
1769
1686
|
// 2) Ricerca finale o ricerca intermedia senza stato salvato - Elimino tutti gli item relativi alla path corrente
|
|
1770
|
-
// Per "stato salvato" si intendono ricerche vecchie salvate per poter essere rieffettuate in caso di ordinamenti su colonne di interesse
|
|
1687
|
+
// Per "stato salvato" si intendono ricerche vecchie salvate per poter essere rieffettuate in caso di ordinamenti su colonne di interesse
|
|
1771
1688
|
if (intermediateGroup && view.savedstate) {
|
|
1772
1689
|
this.est.boundSource = this.est.boundSource.filter(t => !(t._item || t._thisRoute.length > groupRoute.length));
|
|
1773
1690
|
this.est.groupSearchRequestsCache = this.est.groupSearchRequestsCache.filter(t => !(t.route.length > groupRoute.length));
|
|
1774
1691
|
}
|
|
1692
|
+
else if (intermediateGroup) {
|
|
1693
|
+
// Se invece lo stato non è salvato vuol dire che c'è stato un cambio di pagina interno ad un gruppo già aperto:
|
|
1694
|
+
// - Elimino tutti gli elementi riconducibili a questo gruppo che erano già presenti
|
|
1695
|
+
this.est.boundSource = this.est.boundSource.filter(t => !(t._item || (t._thisKey.startsWith(groupKey) && t._thisKey != groupKey)));
|
|
1696
|
+
}
|
|
1775
1697
|
this.est.boundSource = this.est.boundSource.filter(t => !(t._parent == groupKey));
|
|
1776
1698
|
let thisGroup = this.est.boundSource[insertIndex];
|
|
1777
1699
|
if (intermediateGroup)
|
|
@@ -1907,7 +1829,7 @@ class RowGroupingHandler {
|
|
|
1907
1829
|
anygp._thisKey = parent._thisKey + gp.value;
|
|
1908
1830
|
anygp._grouplevel = parent._grouplevel + 1;
|
|
1909
1831
|
}
|
|
1910
|
-
// Pusho il gruppo, tutti i gruppi del livello sotto, o gli item se io sono l'ultimo gruppo.
|
|
1832
|
+
// Pusho il gruppo, tutti i gruppi del livello sotto, o gli item se io sono l'ultimo gruppo.
|
|
1911
1833
|
// La visibilità è solo per il gruppo a livello 0, tutti gli altri gruppi saranno mostrati o nascosti di conseguenza
|
|
1912
1834
|
if (currentIndex == 0)
|
|
1913
1835
|
anygp._visible = true;
|
|
@@ -2103,7 +2025,22 @@ class RowGroupingHandler {
|
|
|
2103
2025
|
}
|
|
2104
2026
|
}
|
|
2105
2027
|
|
|
2106
|
-
|
|
2028
|
+
/** Rappresenta un trittico formato da un array e due cache relative a tale array per un accesso estremamente veloce per tutte le operazioni del caso */
|
|
2029
|
+
class CacheTriptic {
|
|
2030
|
+
/**
|
|
2031
|
+
* Costruttore
|
|
2032
|
+
*
|
|
2033
|
+
* @param {Map<string, any>} cache Cache Chiave-Oggetto
|
|
2034
|
+
* @param {Map<string, number>} index_cache Cache Indice-Oggetto
|
|
2035
|
+
* @param {any[]} array Array contenente gli oggetti
|
|
2036
|
+
*/
|
|
2037
|
+
constructor(cache, index_cache, array) {
|
|
2038
|
+
this.cache = cache;
|
|
2039
|
+
this.index_cache = index_cache;
|
|
2040
|
+
this.array = array;
|
|
2041
|
+
}
|
|
2042
|
+
}
|
|
2043
|
+
|
|
2107
2044
|
/** Classe che gestisce le selezioni degli oggetti */
|
|
2108
2045
|
class SelectionHandler {
|
|
2109
2046
|
/** @ignore Costruttore */
|
|
@@ -2783,7 +2720,7 @@ UtilitiesHandler.ctorParameters = () => [
|
|
|
2783
2720
|
class EsTableComponent {
|
|
2784
2721
|
/** @ignore */
|
|
2785
2722
|
constructor(ngControl, prefService, deafults, locale, lc, cdr, utilities_H, utiExts, expExts, dateExts, msgExts) {
|
|
2786
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r;
|
|
2723
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s;
|
|
2787
2724
|
this.ngControl = ngControl;
|
|
2788
2725
|
this.prefService = prefService;
|
|
2789
2726
|
this.deafults = deafults;
|
|
@@ -2872,6 +2809,8 @@ class EsTableComponent {
|
|
|
2872
2809
|
this.CornerMenuOptions = null;
|
|
2873
2810
|
/** Indica se dev'essere possibile effettuare il resize delle colonne */
|
|
2874
2811
|
this.ColumnsResizable = null;
|
|
2812
|
+
/** Indica se dev'essere possibile effettuare il pinning delle colonne */
|
|
2813
|
+
this.ColumnsPinnable = null;
|
|
2875
2814
|
/** Indica se dev'essere disponibile il sistema di aggiornamento automatico */
|
|
2876
2815
|
this.AutoUpdate = null;
|
|
2877
2816
|
/**
|
|
@@ -3097,6 +3036,7 @@ class EsTableComponent {
|
|
|
3097
3036
|
this.UseSelectionCache = this.utilities_H.InputOrDefault(this.UseSelectionCache, (_p = this.deafults) === null || _p === void 0 ? void 0 : _p.UseSelectionCache, true);
|
|
3098
3037
|
this.ShowItemGroupsColumns = this.utilities_H.InputOrDefault(this.ShowItemGroupsColumns, (_q = this.deafults) === null || _q === void 0 ? void 0 : _q.ShowItemGroupsColumns, false);
|
|
3099
3038
|
this.ArraymodeItemsPerPage = this.utilities_H.InputOrDefault(this.ArraymodeItemsPerPage, (_r = this.deafults) === null || _r === void 0 ? void 0 : _r.ArraymodeItemsPerPage, 15);
|
|
3039
|
+
this.ColumnsPinnable = this.utilities_H.InputOrDefault(this.ColumnsPinnable, (_s = this.deafults) === null || _s === void 0 ? void 0 : _s.ColumnsPinnable, true);
|
|
3100
3040
|
}
|
|
3101
3041
|
/** @ignore */
|
|
3102
3042
|
ngOnInit() {
|
|
@@ -3384,20 +3324,20 @@ class EsTableComponent {
|
|
|
3384
3324
|
*/
|
|
3385
3325
|
bindDisplayToLoadedItemsOrGroups(view) {
|
|
3386
3326
|
var _a, _b;
|
|
3387
|
-
if (this.TMPBoundSource.length == 0) {
|
|
3327
|
+
if (!this.TMPBoundSource || this.TMPBoundSource.length == 0) {
|
|
3388
3328
|
this.BaseItemsCount = 0;
|
|
3389
|
-
this.boundSource =
|
|
3329
|
+
this.boundSource = [];
|
|
3390
3330
|
return;
|
|
3391
3331
|
}
|
|
3392
3332
|
if (this.arrayMode || !this.UseCustomCells) {
|
|
3393
3333
|
this.boundSource = this.TMPBoundSource;
|
|
3394
|
-
this.BaseItemsCount = (view === null || view === void 0 ? void 0 : view.objectcount) || view.length;
|
|
3334
|
+
this.BaseItemsCount = (view === null || view === void 0 ? void 0 : view.objectcount) || (view === null || view === void 0 ? void 0 : view.length) || 0;
|
|
3395
3335
|
return;
|
|
3396
3336
|
}
|
|
3397
|
-
let groupingKeys = ((_b = (_a = view.groupings) === null || _a === void 0 ? void 0 : _a.filter(t => !t.aggregation)) === null || _b === void 0 ? void 0 : _b.length) || 0;
|
|
3337
|
+
let groupingKeys = ((_b = (_a = view === null || view === void 0 ? void 0 : view.groupings) === null || _a === void 0 ? void 0 : _a.filter(t => !t.aggregation)) === null || _b === void 0 ? void 0 : _b.length) || 0;
|
|
3398
3338
|
if (groupingKeys == 0) {
|
|
3399
3339
|
this.boundSource = this.TMPBoundSource;
|
|
3400
|
-
this.BaseItemsCount = view.objectcount;
|
|
3340
|
+
this.BaseItemsCount = (view === null || view === void 0 ? void 0 : view.objectcount) || 0;
|
|
3401
3341
|
return;
|
|
3402
3342
|
}
|
|
3403
3343
|
this.rowGrouping_H.handleNewDataOnRowGrouping(view, groupingKeys);
|
|
@@ -3852,7 +3792,7 @@ EsTableComponent.decorators = [
|
|
|
3852
3792
|
viewProviders: [{ provide: LocalizationService, useClass: EsTableLoc }],
|
|
3853
3793
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
3854
3794
|
encapsulation: ViewEncapsulation.None,
|
|
3855
|
-
template: "<!-- Patacchino di autoaggiornamento -->\r\n<div class=\"w-100\" *ngIf=\"AutoUpdate\">\r\n <div class=\"pull-right\">\r\n {{'Update every' | localize : lc}} <input [readonly]=\"autoUpdate\" maxlength=\"3\" class=\"form-control est-custom-input\" type=\"text\" [(ngModel)]=\"seconds\" /> {{'second/s' | localize : lc}}\r\n </div>\r\n <div class=\"pull-right m-t-2\">\r\n <label class=\"est-switch\">\r\n <input type=\"checkbox\" [(ngModel)]=\"autoUpdate\" (ngModelChange)=\"autoUpdateChanged();\" />\r\n <div class=\"est-slider round\"></div>\r\n </label>\r\n </div>\r\n <div class=\"clearfix\"></div>\r\n</div>\r\n\r\n<div *ngIf=\"View\" class=\"est-relative\">\r\n <div *ngIf=\"FirstBind && ShowLoadingOnBootstrap\" class=\"est-loading-box\">\r\n <div class=\"est-loading-content\">\r\n <span class=\"fa fa-spinner fa-spin\"></span> {{'Performing Table bootstrap' | localize: lc}}...\r\n </div>\r\n </div>\r\n\r\n <div class=\"est-top-pager\" *ngIf=\"PagingStyle == 'both' || PagingStyle == 'top'\">\r\n <ng-container *ngTemplateOutlet=\"pagingElement\"></ng-container>\r\n </div>\r\n\r\n <div class=\"est-top-allselect\" *ngIf=\"canSelectAll || (!reportMode && (View?.selection || arraymodeSelection).all)\">\r\n <span>{{ (selectedObjects == -1 ? ('All the' | localize : lc) : ((selectedObjects || 0) | number : '0.0-0' : locale)) + ' ' + ((selectedObjects == 1 ? 'Object Selected' : 'Objects Selected') | localize : lc) }}</span> \r\n <span class=\"est-link est-inline\" (click)=\"selection_H.selectAllOrResetSelection()\">{{ (View?.selection || arraymodeSelection).all ? ('Reset Selection' | localize : lc) : ('Select Everything' | localize : lc)}}</span>\r\n </div>\r\n\r\n <div class=\"table-responsive datatable {{ContainerClass}}\" [style.max-height.px]=\"MaxHeight\">\r\n <table class=\"{{ TableClass }} est-margin-bottom-10\" [class.est-high-density]=\"HighCellDensity\">\r\n <thead [hidden]=\"HeaderHidden || FirstBind\">\r\n <!-- Aggiungo il pezzo che gestisce la selezione di tutto se attivo da config -->\r\n <tr *ngIf=\"SelectAll || PagingStyle != 'bottom'\">\r\n <th class=\"est-no-selection\" [attr.colspan]=\"Columns.Global\" [class.est-hidden-view]=\"!canSelectAll && (reportMode || !(View?.selection || arraymodeSelection).all) && PagingStyle == 'bottom'\">\r\n <p class=\"est-hidden-view app-margin-bottom-0\">\u00A7</p>\r\n </th>\r\n </tr>\r\n\r\n <!-- Blocco header group -->\r\n <ng-container *ngIf=\"RowThGroups\">\r\n <tr *ngFor=\"let level of RowThGroups\">\r\n <th *ngFor=\"let cell of level\" [attr.colspan]=\"cell.Span\" \r\n [class.est-pinned-header]=\"cell.Pinned\" [class.est-col-min]=\"cell.Pinned\"\r\n [class.est-ltab-border]=\"cell.Borders\" [class.est-rtab-border]=\"cell.Borders\"\r\n class=\"est-text-center\">\r\n <ng-container *ngIf=\"cell.Pinned; Else: cell.Template\">\r\n <div class=\"est-pinned-border est-cell-group-padding\"></div>\r\n </ng-container>\r\n </th>\r\n </tr>\r\n </ng-container>\r\n\r\n <ng-container *ngIf=\"!RowThGroups\">\r\n <tr *ngIf=\"HasHeaderGroup\">\r\n <ng-container *ngTemplateOutlet=\"headerGroupRef\"></ng-container>\r\n <th *ngIf=\"Export\"></th>\r\n </tr>\r\n \r\n <!-- Blocco header group secondario -->\r\n <tr *ngIf=\"HasSecondaryHeaderGroup\">\r\n <ng-container *ngTemplateOutlet=\"secondaryHeaderGroupRef\"></ng-container>\r\n <th *ngIf=\"Export\"></th>\r\n </tr>\r\n </ng-container>\r\n\r\n <!-- Blocco effettivo degli header -->\r\n <tr>\r\n <!-- Aggiungo una checkbox se la selezione \u00E8 attiva -->\r\n <th class=\"est-col-min\" *ngIf=\"Selection && !HasPinnedColumns\">\r\n <input *ngIf=\"!SingleSelection\" class=\"est-pointer\" type=\"checkbox\" [disabled]=\"SelectionDisabled\" [(ngModel)]=\"globalCheck\" [ngModelOptions]=\"{'standalone': true}\" (ngModelChange)=\"globalCheckChanged();\">\r\n </th>\r\n\r\n <!-- Header che valgono per view mode e array mode -->\r\n <ng-container *ngIf=\"(viewMode || arrayMode)\">\r\n\r\n <!-- In una tabella base prendo semplicemente i th scritti dall'utente nell'HTML -->\r\n <ng-container *ngIf=\"(!UseCustomCells || !RowTHs) && !DynamicRowColumnsDefinition\">\r\n <ng-container *ngTemplateOutlet=\"headerRef\"></ng-container>\r\n </ng-container>\r\n\r\n <!-- Se ho un modello dinamico dell'oggetto creo le colonne in base alle propriet\u00E0 -->\r\n <ng-container *ngIf=\"(!UseCustomCells || !RowTHs) && DynamicRowColumnsDefinition\">\r\n <th *ngFor=\"let operation of DynamicOperations\" class=\"est-col-min est-no-side-padding\"></th>\r\n \r\n <ng-container *ngFor=\"let rowHeader of DynamicRowColumnsDefinition\">\r\n <ng-container *ngIf=\"rowHeader.visible\">\r\n <th *ngIf=\"OrderByColumn\" es-th=\"{{rowHeader.propertyName}}\" class=\"{{UserDefinedDynamicCols ? ((rowHeader.clss || '') + (rowHeader.headerWraps ? '' : ' est-nowrap')) : ' est-nowrap'}}\" [Order]=\"rowHeader.dataOrder\" [Resizable]=\"ColumnsResizable\" [Orderable]=\"rowHeader.orderable\" [OrderBy]=\"OrderByColumn\" [SearchInProgress]=\"!!researchInProgress\" (onOrderChange)=\"thOrderChanged(rowHeader.propertyName, $event)\">{{rowHeader.description}}</th>\r\n <th *ngIf=\"!OrderByColumn\" es-th=\"{{rowHeader.propertyName}}\" class=\"{{UserDefinedDynamicCols ? ((rowHeader.clss || '') + (rowHeader.headerWraps ? '' : ' est-nowrap')) : ' est-nowrap'}}\" [Order]=\"rowHeader.dataOrder\" [Resizable]=\"ColumnsResizable\" [Orderable]=\"rowHeader.orderable\" [OrderBy]=\"OrderByColumn\">{{rowHeader.description}}</th>\r\n </ng-container>\r\n </ng-container>\r\n </ng-container>\r\n\r\n <!-- Se non ho un modello dinamico ma invece delle celle custom, genero gli header in base ai row th -->\r\n <ng-container *ngIf=\"UseCustomCells && RowTHs\">\r\n <th *ngIf=\"HasPinnedColumns\" class=\"est-pinned-header est-col-min\">\r\n <div [style.width.px]=\"PinnedContainerWidth\" class=\"est-pinned-border est-simple-border-bottom\">\r\n <th class=\"est-col-min est-no-border\" *ngIf=\"Selection\" [style.width.px]=\"20\">\r\n <input *ngIf=\"!SingleSelection\" class=\"est-pointer\" type=\"checkbox\" [disabled]=\"SelectionDisabled\" [(ngModel)]=\"globalCheck\" [ngModelOptions]=\"{'standalone': true}\" (ngModelChange)=\"globalCheckChanged();\">\r\n </th>\r\n <ng-container *ngFor=\"let rowHeader of RowTHs\">\r\n <th *ngIf=\"rowHeader && rowHeader.Visible && rowHeader.Pinned\" [style.width.px]=\"rowHeader.PinnedWidth\" es-th=\"{{rowHeader.ID}}\" \r\n class=\"{{rowHeader.Class || ''}}\" \r\n [class.est-pinned-internal-header]=\"true\" \r\n [class.est-no-border]=\"true\" \r\n [class.est-nowrap]=\"!rowHeader.Wrap\" \r\n [Pinned]=\"true\" [Fixed]=\"rowHeader.Fixed\" [Order]=\"rowHeader.Order\" [Resizable]=\"ColumnsResizable\" [Orderable]=\"rowHeader.Orderable\" [OrderBy]=\"OrderByColumn\" [SearchInProgress]=\"!!researchInProgress\" (onUnpinning)=\"columnMetadata_H.unpinColumn($event)\" (onOrderChange)=\"OrderByColumn && thOrderChanged(rowHeader.ID, $event)\">\r\n <ng-container *ngIf=\"rowHeader.Template\"><ng-container *ngTemplateOutlet=\"rowHeader.Template;\"></ng-container></ng-container>\r\n <span *ngIf=\"!rowHeader.Template\">{{rowHeader.Content}}</span>\r\n </th>\r\n </ng-container>\r\n </div>\r\n </th>\r\n <ng-container *ngFor=\"let rowHeader of RowTHs\">\r\n <th *ngIf=\"rowHeader && rowHeader.Visible && !rowHeader.Pinned\" es-th=\"{{rowHeader.ID}}\" class=\"{{rowHeader.Class || ''}}\" [class.est-ltab-border]=\"rowHeader.LeftBorder\" [class.est-rtab-border]=\"rowHeader.RightBorder\" [class.est-nowrap]=\"!rowHeader.Wrap\" [Order]=\"rowHeader.Order\" [Resizable]=\"ColumnsResizable\" [Orderable]=\"rowHeader.Orderable\" [OrderBy]=\"OrderByColumn\" [SearchInProgress]=\"!!researchInProgress\" (onOrderChange)=\"OrderByColumn && thOrderChanged(rowHeader.ID, $event)\">\r\n <ng-container *ngIf=\"rowHeader.Template\"><ng-container *ngTemplateOutlet=\"rowHeader.Template;\"></ng-container></ng-container>\r\n <span *ngIf=\"!rowHeader.Template\">{{rowHeader.Content}}</span>\r\n </th>\r\n </ng-container>\r\n </ng-container>\r\n </ng-container>\r\n\r\n <!--Casistica in cui ho il setup proveniente da un report. Gli header sono definiti da come \u00E8 fatto il report-->\r\n <ng-container *ngIf=\"reportMode\">\r\n <th [style.color]=\"clm.color\" *ngFor=\"let clm of ReportValues.columns\" class=\"est-no-selection est-pointer est-nowrap\" (click)=\"reportMode_H.setupNextOrderAndSearch(clm)\">\r\n {{clm.description}}<span class=\"fa\" [class.fa-chevron-down]=\"clm.order == 'DESC'\" [class.fa-chevron-up]=\"clm.order == 'ASC'\"></span>\r\n </th>\r\n </ng-container>\r\n\r\n <!--Per l'eliminazione mi serve un header aggiuntivo-->\r\n <th *ngIf=\"Removal\" [class.est-right-9]=\"Export || HiddenColumns\" class=\"est-col-min est-sticky-last-column\"><span class=\"fa fa-trash\"></span></th>\r\n\r\n <!--Per l'esportazione mi serve l'header extra da cui faccio uscire i 3 pallocchi-->\r\n <th *ngIf=\"Export || HiddenColumns || ColumnsOrdering || CornerMenuOptions\" class=\"est-table-dotted-menu est-sticky-last-column est-col-min text-sm-center\">\r\n \r\n <!-- Link nascosto che serve a scaricare il file -->\r\n <a *ngIf=\"headers\" hidden #exportDownloader csvLink [data]=\"data\" [headers]=\"headers\" [delimiter]=\"';'\" [filename]=\"ExportFileName.endsWith('.xlsx') ? ExportFileName.replace('.xlsx', '.csv') : ExportFileName.endsWith('.csv') ? ExportFileName : ExportFileName + '.csv'\"></a>\r\n\r\n <!-- Blocco con i 3 pallocchi che tira fuori il context menu delle operazioni -->\r\n <div class=\"btn-group\" container=\"body\" placement=\"bottom right\" dropdown #dropdown=\"bs-dropdown\" [autoClose]=\"true\">\r\n <span dropdownToggle class=\"fa fa-ellipsis-v est-fs-18 est-pointer est-padding-3\"></span>\r\n\r\n <div *dropdownMenu class=\"dropdown-menu dropdown-menu-right est-bring-to-front-strong\">\r\n <div class=\"est-pointer\">\r\n <a class=\"dropdown-item\" *ngIf=\"HiddenColumns || ColumnsOrdering\" (click)=\"columnMetadata_H.resetColumnVisSelection(); changeColumnVisibilityModal.show();\">\r\n <ng-container *ngIf=\"!HiddenColumns && ColumnsOrdering\">\r\n {{'Columns Order' | localize : lc}}\r\n </ng-container>\r\n <ng-container *ngIf=\"HiddenColumns && !ColumnsOrdering\">\r\n {{'Columns Visibility' | localize : lc}}\r\n </ng-container>\r\n <ng-container *ngIf=\"HiddenColumns && ColumnsOrdering\">\r\n {{'Columns Visibility and Order' | localize : lc}}\r\n </ng-container>\r\n </a>\r\n <a class=\"dropdown-item\" *ngIf=\"Export && CSVExport\" (click)=\"export_H.tryExport('CSV')\">{{'Export View' | localize : lc}} (CSV)</a>\r\n <a class=\"dropdown-item\" *ngIf=\"Export && XLSXExport\" (click)=\"export_H.tryExport('XLSX')\">{{'Export View' | localize : lc}} (XLSX)</a>\r\n <a class=\"dropdown-item\" *ngFor=\"let option of CornerMenuOptions\" (click)=\"cornerActionClicked(option.id)\">{{option.description}}</a>\r\n </div>\r\n </div>\r\n </div>\r\n </th>\r\n </tr>\r\n </thead>\r\n \r\n <!-- Valido per modalit\u00E0 View o Array. Se sono in report mode il body \u00E8 creato in altro modo -->\r\n <tbody [hidden]=\"BodyHidden || FirstBind\" *ngIf=\"(arrayMode || viewMode)\">\r\n <!--Con selection attiva richiamo il template che gestisce il context menu-->\r\n <ng-container *ngIf=\"Selection\">\r\n <ng-container *ngTemplateOutlet=\"TBodySelection; context: { $implicit: { selDisabled: arrayMode ? false : SelectionDisabled, sel: Selection }}\"></ng-container>\r\n </ng-container>\r\n\r\n <!--Senza selection richiamo il template che NON gestisce il context menu-->\r\n <ng-container *ngIf=\"!Selection\">\r\n <ng-container *ngTemplateOutlet=\"TBody\"></ng-container>\r\n </ng-container>\r\n </tbody>\r\n\r\n <!-- Per la modalit\u00E0 a report c'\u00E8 un body particolare semi-dinamico -->\r\n <tbody [hidden]=\"BodyHidden\" *ngIf=\"reportMode\">\r\n <tr *ngFor=\"let row of ReportValues.rows; let even = even;\">\r\n <td class=\"est-nowrap\" *ngFor=\"let val of row.values\">{{val}}</td>\r\n <td class=\"est-sticky-last-column{{even && !Hierarchy ? '-alt' : ''}}\"></td>\r\n </tr>\r\n </tbody>\r\n </table>\r\n </div>\r\n\r\n <div *ngIf=\"PagingStyle == 'both' || PagingStyle == 'bottom'\">\r\n <ng-container *ngTemplateOutlet=\"pagingElement\"></ng-container>\r\n </div>\r\n</div>\r\n\r\n<!-- Template che contiene tutte le info di paginazione in modo da poterlo replicare anche sopra -->\r\n<ng-template #pagingElement>\r\n <ng-container *ngIf=\"!FirstBind\">\r\n <!-- Pulsanti avanti-indietro di paginazione -->\r\n <div *ngIf=\"PagerOptions.ShowPaging && PagerOptions.ShowButtons && (PagerOptions.PagerCount > 10 || PagerOptions.PagerCount == -1)\" class=\"pull-right btn-toolbar\">\r\n <ng-container *ngIf=\"(!reportMode || View?.pagingavailable) && (!arrayMode || SearchView)\">\r\n <ng-container *ngTemplateOutlet=\"pagingButtons; context: { $implicit: { Margin: true, ATP: addToPage.bind(this), GTP: goToPage.bind(this), Array: arrayPulsanti }}\"></ng-container>\r\n </ng-container>\r\n <ng-container *ngIf=\"arrayMode && UseArrayModePaging && !SearchView\">\r\n <ng-container *ngTemplateOutlet=\"pagingButtons; context: { $implicit: { Margin: true, ATP: arrayAddToPage.bind(this), GTP: arrayGoToPage.bind(this), Array: arrayPulsanti }}\"></ng-container>\r\n </ng-container>\r\n </div>\r\n <!-- Paginatore dove appare la count e le opzioni di paginazione -->\r\n <div class=\"pull-right\" *ngIf=\"PagerOptions.ShowCount || PagerOptions.ShowPagingOptions\">\r\n <div class=\"est-mt-min-5\" *ngIf=\"PagerOptions.ShowPaging\">\r\n <app-paging *ngIf=\"!PagerOptions.UsesView\" [CountLabel]=\"CountLabel\" [ShowPaging]=\"PagerOptions.ShowPagingOptions\" [ShowCount]=\"PagerOptions.ShowCount\" [PagerCount]=\"PagerOptions.PagerCount\" [WarnOnAll]=\"false\" [CurrentPageSize]=\"ArraymodeItemsPerPage\" (pagingSelected)=\"items_H.refreshPaging($event)\"></app-paging>\r\n <app-paging *ngIf=\"PagerOptions.UsesView\" [CountLabel]=\"CountLabel\" [ShowPaging]=\"PagerOptions.ShowPagingOptions\" [ShowCount]=\"PagerOptions.ShowCount\" [PagerCount]=\"PagerOptions.PagerCount\" [GroupMode]=\"PagerOptions.Searches == 'groups'\" [AllSearch]=\"AllSearch\" [View]=\"PagerOptions.View\" (pagingSelected)=\"onItemsPerPageChanged($event);\"></app-paging>\r\n </div>\r\n <div *ngIf=\"reportMode && !PagerOptions.ShowPaging\"><em>{{'Paging options are not available for this report' | localize: lc}}</em></div>\r\n </div>\r\n <div class=\"clearfix\"></div>\r\n </ng-container>\r\n</ng-template>\r\n\r\n<!-- Template che contiene i pulsanti per cambiare pagina -->\r\n<ng-template #pagingButtons let-options>\r\n <div class=\"est-flex\" [class.est-margin-left-50]=\"options.Margin\">\r\n <a class=\"btn\" class=\"est-page-prev app-pointer\" (click)=\"options.ATP(-1, options.separator)\"><span class=\"fa fa-chevron-left\"></span></a>\r\n <div *ngIf=\"options.Array\" class=\"est-inline\"><a *ngFor=\"let p of options.Array\" class=\"btn est-page-sel {{p.cssClass}}\" (click)=\"options.GTP(p.val, options.separator)\">{{p.val}}</a></div>\r\n <a class=\"btn\" class=\"est-page-next app-pointer\" (click)=\"options.ATP(1, options.separator)\"><span class=\"fa fa-chevron-right\"></span></a>\r\n </div>\r\n</ng-template>\r\n\r\n<!-- Questi due template rappresentano effettivamente il body della tabella. essendo il tr l'unica cosa che davvero cambia, il resto \u00E8 templatizzato -->\r\n<ng-template #TBodySelection let-templateOptions>\r\n <ng-container *ngFor=\"let item of boundSource; let even = even; let i=index; trackBy: bodyTrackBy\">\r\n <tr *ngIf=\"item._visible || (!Hierarchy && !ArrayGrouping)\" \r\n [class]=\"item._rowClass ? item._rowClass : ''\" \r\n [class.est-line-through]=\"item.removed || item.deleted\" \r\n [class.est-pointer]=\"!item.locked\" \r\n [class.est-white-selected]=\"item._selected && !item.locked\"\r\n [class.est-rg]=\"item._group\"\r\n [class.est-rg-sep]=\"item._sep\"\r\n [contextMenu]=\"!item.locked ? (ContextMenu || emptyMenu) : emptyMenu\" [contextMenuSubject]=\"item\"\r\n (click)=\"(!item.locked && !item._sep && !item._group && handleClick($event, item)) || item._group && handleGroupClick(item)\">\r\n\r\n <td *ngIf=\"!item.locked && !item._sep && !HasPinnedColumns\">\r\n <input type=\"checkbox\" \r\n [disabled]=\"templateOptions.selDisabled\" \r\n [class.est-pointer]=\"!item.locked\"\r\n [(ngModel)]=\"item._selected\" name=\"check{{i}}\" \r\n (click)=\"$event.stopPropagation(); handleClick($event, item);\">\r\n </td>\r\n <td *ngIf=\"(item.locked || item._sep) && !HasPinnedColumns\"></td>\r\n\r\n <ng-container *ngIf=\"item._sep\"><ng-container *ngTemplateOutlet=\"groupPager; context: { $implicit: item }\"></ng-container> </ng-container>\r\n\r\n <ng-container *ngIf=\"!item._sep\">\r\n <ng-container *ngTemplateOutlet=\"basicColumns; context: { $implicit: item }\"></ng-container>\r\n <ng-container *ngTemplateOutlet=\"dynamicColumns; context: { $implicit: item }\"></ng-container>\r\n <ng-container *ngTemplateOutlet=\"customCells; context: { $implicit: item, templateOptions: templateOptions }\"></ng-container>\r\n </ng-container>\r\n <ng-container *ngTemplateOutlet=\"bodyDeleteAndExport; context: { $implicit: { even: even, item: item }}\"></ng-container>\r\n </tr>\r\n </ng-container>\r\n</ng-template>\r\n\r\n<ng-template #TBody>\r\n <ng-container *ngFor=\"let item of boundSource; let even = even;\">\r\n <tr *ngIf=\"item._visible || !Hierarchy\" \r\n [class]=\"item._rowClass ? item._rowClass : ''\" \r\n [class.est-line-through]=\"item.removed || item.deleted\"\r\n [class.est-rg]=\"item._group\"\r\n [class.est-rg-sep]=\"item._sep\"\r\n (click)=\"item._group && handleGroupClick(item)\">\r\n\r\n <ng-container *ngIf=\"item._sep\"><ng-container *ngTemplateOutlet=\"groupPager; context: { $implicit: item }\"></ng-container></ng-container>\r\n\r\n <ng-container *ngIf=\"!item._sep\">\r\n <ng-container *ngTemplateOutlet=\"basicColumns; context: { $implicit: item }\"></ng-container>\r\n <ng-container *ngTemplateOutlet=\"dynamicColumns; context: { $implicit: item }\"></ng-container>\r\n <ng-container *ngTemplateOutlet=\"customCells; context: { $implicit: item }\"></ng-container>\r\n </ng-container>\r\n <ng-container *ngTemplateOutlet=\"bodyDeleteAndExport; context: { $implicit: { even: even, item: item }}\"></ng-container>\r\n </tr>\r\n </ng-container>\r\n</ng-template>\r\n\r\n<ng-template #groupPager let-item>\r\n <td class=\"est-pinned-body \" *ngIf=\"HasPinnedColumns\"><div class=\"est-pinned-border est-cell-group-padding\"></div></td>\r\n <td *ngIf=\"item._grouplevel > 1\" [attr.colspan]=\"item._grouplevel-1\"></td>\r\n <td [attr.colspan]=\"Columns.VisibleUnpinned - (item._grouplevel > 0 ? item._grouplevel - 1 : 0)\">\r\n <div class=\"est-rg-sep-flex-right\" *ngIf=\"RowGroupingPagingStyle == 'right'\">\r\n <div class=\"est-rg-page\"><ng-container *ngTemplateOutlet=\"pagingButtons; context: { $implicit: { separator: item, ATP: addToPageGroup.bind(this), GTP: goToPageGroup.bind(this), Array: item.buttons }}\"></ng-container></div>\r\n <div class=\"est-rg-ipp\" *ngIf=\"(item.searches == 'groups' ? item.view.groupcount : item.view.objectcount) > 10\"><app-paging [CountLabel]=\"CountLabel\" [AllSearch]=\"AllSearch\" [GroupMode]=\"item.searches == 'groups'\" [PagerCount]=\"item.searches == 'groups' ? item.view.groupcount : item.view.objectcount\" [View]=\"item.view\" (pagingSelected)=\"onGroupItemsPerPageChanged(item, $event);\"></app-paging></div>\r\n </div>\r\n\r\n <div class=\"est-rg-sep-flex-left\" *ngIf=\"RowGroupingPagingStyle == 'left'\">\r\n <div class=\"est-rg-ipp\"><app-paging [AllSearch]=\"AllSearch\" [CountLabel]=\"CountLabel\" [GroupMode]=\"item.searches == 'groups'\" [PagerCount]=\"item.searches == 'groups' ? item.view.groupcount : item.view.objectcount\" [View]=\"item.view\" (pagingSelected)=\"onGroupItemsPerPageChanged(item, $event);\"></app-paging></div>\r\n <div class=\"est-rg-page\" *ngIf=\"(item.searches == 'groups' ? item.view.groupcount : item.view.objectcount) > 10\"><ng-container *ngTemplateOutlet=\"pagingButtons; context: { $implicit: { separator: item, ATP: addToPageGroup.bind(this), GTP: goToPageGroup.bind(this), Array: item.buttons }}\"></ng-container></div>\r\n </div>\r\n </td>\r\n</ng-template>\r\n\r\n<!-- Questo template contiene la print condizionale su tabelle semplici, con header e body scritti a manazza -->\r\n<ng-template #basicColumns let-item>\r\n <ng-container *ngIf=\"(!UseCustomCells || !RowTDs) && !DynamicRowColumnsDefinition\">\r\n <ng-container *ngTemplateOutlet=\"bodyRef; context : {$implicit: item}\"></ng-container>\r\n </ng-container>\r\n</ng-template>\r\n\r\n<!-- Questo template contiene la print condizionale su tabelle definite in maniera dinamica dal modello -->\r\n<ng-template #dynamicColumns let-item>\r\n <ng-container *ngIf=\"(!UseCustomCells || !RowTDs) && DynamicRowColumnsDefinition\">\r\n <ng-container *ngFor=\"let operation of DynamicOperations; let first = first; let last = last;\">\r\n <ng-container *ngIf=\"!operation.conditionField || (item.properties[operation.conditionField] == operation.conditionValue)\">\r\n <td [class.est-no-right-padding]=\"last\" [class.est-no-left-padding]=\"!first\" class=\"est-col-min\"><span title=\"{{operation.title}}\" class=\"{{operation.iconClass}} est-pointer\" (click)=\"dynamicOperation(item, operation.id)\">{{operation.text}}</span></td>\r\n </ng-container>\r\n <ng-container *ngIf=\"operation.conditionField && (item.properties[operation.conditionField] != operation.conditionValue)\">\r\n <td class=\"est-col-min est-no-side-padding\"></td>\r\n </ng-container>\r\n </ng-container>\r\n <ng-container *ngFor=\"let rowItem of DynamicRowColumnsDefinition\">\r\n <ng-container *ngIf=\"rowItem.routePath && rowItem.visible\">\r\n <td es-td=\"{{rowItem.propertyName}}\" class=\"{{UserDefinedDynamicCols ? rowItem.clss : 'est-nowrap'}}\" [Internal]=\"false\" [Context]=\"item._hash\">\r\n <a [routerLink]=\"dynamicMode_H.generateRouterLink(rowItem.routePath, rowItem.routeParameterProperties, item)\" class=\"est-link\" [innerHTML]=\"item.properties[rowItem.propertyName]\"></a>\r\n </td>\r\n </ng-container>\r\n <ng-container *ngIf=\"!rowItem.routePath && rowItem.visible\">\r\n <ng-container *ngTemplateOutlet=\"findEsTd(rowItem.propertyName) || defaultEsTd; context: { $implicit: item.properties[rowItem.propertyName], rowItem : rowItem, item : item }\"> </ng-container>\r\n </ng-container>\r\n </ng-container>\r\n </ng-container>\r\n</ng-template>\r\n\r\n<ng-template #defaultEsTd let-value let-rowItem='rowItem' let-item='item'>\r\n <td es-td=\"{{rowItem.propertyName}}\" class=\"{{UserDefinedDynamicCols ? rowItem.clss : 'est-nowrap'}}\" [Internal]=\"false\" [Context]=\"item._hash\">\r\n {{value}}\r\n </td>\r\n</ng-template>\r\n\r\n<!-- Questo template contiene la print condizionale delle celle custom se configurate -->\r\n<ng-template #customCells let-item let-opt=\"templateOptions\">\r\n <ng-container *ngIf=\"UseCustomCells && RowTDs\">\r\n\r\n <td *ngIf=\"HasPinnedColumns\" class=\"est-pinned-body est-col-min\" [class.est-white-selected]=\"item._selected\">\r\n <div [style.width.px]=\"PinnedContainerWidth\" class=\"est-pinned-border\">\r\n <td *ngIf=\"!item.locked && !item._sep && Selection\" class=\"est-no-border est-col-min\" [style.width.px]=\"20\">\r\n <input type=\"checkbox\" [disabled]=\"opt.selDisabled\" [class.est-pointer]=\"!item.locked\" [(ngModel)]=\"item._selected\" name=\"check{{item._hash}}\" (click)=\"$event.stopPropagation(); handleClick($event, item);\">\r\n </td>\r\n <td class=\"est-no-border est-col-min\" *ngIf=\"(item.locked || item._sep) && Selection\" [style.width.px]=\"20\"></td>\r\n\r\n <ng-container *ngFor=\"let rowItem of RowTDs[item._hash]; let i = index\">\r\n <td *ngIf=\"rowItem && rowItem.Pinned\" [style.width.px]=\"rowItem.PinnedWidth\" es-td=\"{{rowItem.ID}}\" class=\"{{rowItem.Class}}\" [class.est-no-border]=\"true\" [class.est-rg-hdr]=\"rowItem.GroupHeader\" [class.est-rg-agg]=\"rowItem.GroupAggregation\" \r\n [class.est-nowrap]=\"Hierarchy || !rowItem.Wraps\" [Internal]=\"true\">\r\n <ng-container *ngIf=\"Hierarchy && i == 0\"><ng-container *ngTemplateOutlet=\"HierarchyNavigator; context: { $implicit: item }\"></ng-container></ng-container>\r\n <ng-container *ngIf=\"rowItem.Template\"><ng-container *ngTemplateOutlet=\"rowItem.Template; context: { $implicit: item }\"></ng-container></ng-container>\r\n <span *ngIf=\"!rowItem.Template\">{{rowItem.Content}}</span>\r\n </td>\r\n </ng-container>\r\n </div>\r\n </td>\r\n\r\n <ng-container *ngFor=\"let rowItem of RowTDs[item._hash]; let i = index\">\r\n <ng-container *ngIf=\"rowItem && !rowItem.Pinned\">\r\n\r\n <!-- Casistica senza bodyRef, quindi con direttive per i td -->\r\n <ng-container *ngIf=\"!bodyRef && rowItem.Visible\">\r\n <td es-td=\"{{rowItem.ID}}\" class=\"{{rowItem.Class}}\" [class.est-ltab-border]=\"rowItem.LeftBorder\" [class.est-rtab-border]=\"rowItem.RightBorder\" [class.est-rg-hdr]=\"rowItem.GroupHeader\" [class.est-rg-agg]=\"rowItem.GroupAggregation\" \r\n [class.est-nowrap]=\"Hierarchy || !rowItem.Wraps\" [Internal]=\"true\">\r\n <ng-container *ngIf=\"Hierarchy && i == 0\"><ng-container *ngTemplateOutlet=\"HierarchyNavigator; context: { $implicit: item }\"></ng-container></ng-container>\r\n <ng-container *ngIf=\"rowItem.Template\"><ng-container *ngTemplateOutlet=\"rowItem.Template; context: { $implicit: item }\"></ng-container></ng-container>\r\n <span *ngIf=\"!rowItem.Template\">{{rowItem.Content}}</span>\r\n </td>\r\n </ng-container>\r\n\r\n <!-- Casistica bodyRef, quindi con componenti per i td (RouterLink) DEPRECATO -->\r\n <ng-container *ngIf=\"rowItem.RouterLink && rowItem.Visible && bodyRef\">\r\n <td es-td=\"{{rowItem.ID}}\" class=\"{{rowItem.Class}}\" [class.est-nowrap]=\"Hierarchy || !rowItem.Wraps\" [Internal]=\"true\">\r\n <ng-container *ngIf=\"Hierarchy && i == 0\">\r\n <ng-container *ngTemplateOutlet=\"HierarchyNavigator; context: { $implicit: item }\"></ng-container>\r\n </ng-container>\r\n <a [routerLink]='rowItem.RouterLink' class=\"est-link\" [innerHTML]=\"rowItem.Content\"></a>\r\n </td>\r\n </ng-container>\r\n\r\n <!-- Casistica bodyRef, quindi con componenti per i td (NON RouterLink) DEPRECATO -->\r\n <ng-container *ngIf=\"!rowItem.RouterLink && rowItem.Visible && bodyRef\">\r\n <td es-td=\"{{rowItem.ID}}\" class=\"{{rowItem.Class}}\" [class.est-nowrap]=\"Hierarchy || !rowItem.Wraps\" [Internal]=\"true\">\r\n <ng-container *ngIf=\"Hierarchy && i == 0\">\r\n <ng-container *ngTemplateOutlet=\"HierarchyNavigator; context: { $implicit: item }\"></ng-container>\r\n </ng-container>\r\n <ng-container *ngIf=\"rowItem.Template\">\r\n <ng-container *ngTemplateOutlet=\"rowItem.Template; context: { $implicit: item }\"></ng-container>\r\n </ng-container>\r\n <span *ngIf=\"!rowItem.Template\" [innerHTML]=\"rowItem.Content\"></span>\r\n </td>\r\n </ng-container>\r\n </ng-container>\r\n </ng-container>\r\n </ng-container>\r\n</ng-template>\r\n\r\n<ng-template #HierarchyNavigator let-item>\r\n <span *ngIf=\"!item.parent\" class=\"fa fa-chevron-down\" style=\"visibility:hidden\"></span>\r\n <span *ngIf=\"item.parent && item._expanded\" class=\"fa fa-chevron-down est-pointer est-no-selection\" (click)=\"hierarchyMode_H.collapseParent(item[this.OwnKey])\"></span>\r\n <span *ngIf=\"item.parent && !item._expanded\" class=\"fa fa-chevron-up est-pointer est-no-selection\" (click)=\"hierarchyMode_H.expandParent(item[this.OwnKey])\"></span>\r\n \r\n</ng-template>\r\n\r\n<!-- Questo template contiene i pulsanti di eliminazione/undo eliminazione ed esportazione che vanno in fondo ad un record edlla tabella -->\r\n<ng-template #bodyDeleteAndExport let-options>\r\n <ng-container *ngIf=\"Removal && !RemovalCondition\">\r\n <td class=\"est-sticky-last-column{{options.even? '-alt' : ''}} {{Export || HiddenColumns || CornerMenuOptions ? 'est-right-9' : ''}}\" *ngIf=\"!(options.item.removed || options.item.deleted)\"><span class=\"fa fa-remove est-pointer text-danger\" [hidden]=\"options.item.removable != undefined && !options.item.removable\" (click)=\"onRemoval.emit(options.item)\"></span></td>\r\n <td class=\"est-sticky-last-column{{options.even? '-alt' : ''}} {{Export || HiddenColumns || CornerMenuOptions ? 'est-right-9' : ''}}\" *ngIf=\"(options.item.removed || options.item.deleted)\"><span class=\"fa fa-undo text-warning est-pointer\" (click)=\"onAbortRemoval.emit(options.item)\"></span></td>\r\n </ng-container>\r\n <ng-container *ngIf=\"Removal && RemovalCondition\">\r\n <td class=\"est-sticky-last-column{{options.even? '-alt' : ''}} {{Export || HiddenColumns || CornerMenuOptions ? 'est-right-9' : ''}}\" *ngIf=\"!(options.item.removed || options.item.deleted) && options.item[RemovalCondition]\"><span class=\"fa fa-remove est-pointer text-danger\" [hidden]=\"options.item.removable != undefined && !options.item.removable\" (click)=\"onRemoval.emit(options.item)\"></span></td>\r\n <td class=\"est-sticky-last-column{{options.even? '-alt' : ''}} {{Export || HiddenColumns || CornerMenuOptions ? 'est-right-9' : ''}}\" *ngIf=\"(options.item.removed || options.item.deleted) && options.item[RemovalCondition]\"><span class=\"fa fa-undo text-warning est-pointer\" (click)=\"onAbortRemoval.emit(options.item)\"></span></td>\r\n <td class=\"est-sticky-last-column{{options.even? '-alt' : ''}} {{Export || HiddenColumns || CornerMenuOptions ? 'est-right-9' : ''}}\" *ngIf=\"!options.item[RemovalCondition]\"><span class=\"fa fa-remove est-hidden-view\"></span></td>\r\n </ng-container>\r\n <td *ngIf=\"Export || HiddenColumns || CornerMenuOptions\" class=\"est-sticky-last-column{{options.even && !Hierarchy ? '-alt' : ''}}\"></td>\r\n</ng-template>\r\n\r\n<!-- Context menu vuoto default per tutte le tabella che non ce l'hanno, in modo che al click destro appaia \"nessuna op disponibile\" -->\r\n<context-menu #emptyMenu>\r\n <ng-template contextMenuItem>\r\n <span>\r\n <em>{{'No operations available' | localize : lc}}...</em>\r\n </span>\r\n </ng-template>\r\n</context-menu>\r\n\r\n<!-- Modal per cambiare posizione e visibilit\u00E0 delle colonne dell'es-table -->\r\n<div bsModal #changeColumnVisibilityModal=\"bs-modal\" class=\"modal fade\" role=\"dialog\" aria-hidden=\"true\">\r\n <div class=\"modal-dialog modal-lg\" cdkDrag>\r\n <div class=\"modal-content\">\r\n <div class=\"modal-header est-pointer\" cdkDragHandle>\r\n <h5 class=\"modal-title pull-left\">\r\n <ng-container *ngIf=\"!HiddenColumns && ColumnsOrdering\">\r\n {{'Columns Order' | localize : lc}}\r\n </ng-container>\r\n <ng-container *ngIf=\"HiddenColumns && !ColumnsOrdering\">\r\n {{'Columns Visibility' | localize : lc}}\r\n </ng-container>\r\n <ng-container *ngIf=\"HiddenColumns && ColumnsOrdering\">\r\n {{'Columns Visibility and Order' | localize : lc}}\r\n </ng-container>\r\n </h5>\r\n <button type=\"button\" class=\"close pull-right\" (click)=\"changeColumnVisibilityModal.hide();\" aria-label=\"Close\">\r\n <span aria-hidden=\"true\">×</span>\r\n </button>\r\n </div>\r\n <div class=\"modal-body\">\r\n <div *ngIf=\"!TMPColumnsList || TMPColumnsList.length == 0\" class=\"card card-info est-padding-10 est-margin-bottom-0\">\r\n {{'There are no columns configured to be hidden/shown in this view' | localize : lc}}\r\n </div>\r\n <div *ngIf=\"TMPColumnsList && TMPColumnsList.length > 0\" style=\"max-height:500px; overflow-y:auto\">\r\n <!--Aaaaaaah la tristezza... qui mi servirebbe l'es-table per facilitare la selezione multipla ecc... peccato che se la linko qui entro in un loop impressionante-->\r\n <table class=\"table table-striped table-sm est-margin-bottom-0\">\r\n <thead>\r\n <tr>\r\n <th class=\"est-col-min\" *ngIf=\"HiddenColumns\">\r\n <input class=\"est-pointer\" type=\"checkbox\" [(ngModel)]=\"globalColVisCheck\" [ngModelOptions]=\"{'standalone': true}\" (ngModelChange)=\"columnMetadata_H.globalColVisCheckChanged();\">\r\n </th>\r\n <!-- <th class=\"est-col-min\" *ngIf=\"ColumnsOrdering\"></th> -->\r\n <th class=\"est-col-min est-nowrap\">{{'Column Name' | localize : lc}}</th>\r\n <!--Filler-->\r\n <th></th>\r\n <!-- Pinner -->\r\n <th *ngIf=\"DirectivesBased\" class=\"est-col-min\"></th>\r\n </tr>\r\n </thead>\r\n <tbody \r\n cdkDropList \r\n [cdkDropListData]=\"TMPColumnsList\" \r\n (cdkDropListDropped)=\"columnMetadata_H.columnReordered($event)\" \r\n [cdkDropListSortPredicate]=\"columnMetadata_H.sortPredicate.bind(this.columnMetadata_H)\"\r\n class=\"est-dropbox\">\r\n\r\n <tr *ngFor=\"let item of TMPColumnsList; let i = index; let last = last\" \r\n class=\"est-pointer est-droplist\" \r\n [class.est-white-selected]=\"lastSelectedItemID == item.id\" \r\n [class.est-no-selection]=\"!item.visible\"\r\n cdkDrag\r\n [cdkDragData]=\"item\"\r\n [cdkDragDisabled]=\"!ColumnsOrdering || item.fixed || item.pinned\">\r\n\r\n <td *ngIf=\"HiddenColumns\">\r\n <input type=\"checkbox\" [class.est-hidden-view]=\"item.fixed\" class=\"est-pointer\" [(ngModel)]=\"item.visible\" name=\"visible{{i}}\" (ngModelChange)=\"columnMetadata_H.updateGlobalColVisCheck();\" />\r\n </td>\r\n <!-- <td class=\"est-nowrap\" *ngIf=\"ColumnsOrdering\">\r\n <span class=\"fa fa-arrow-up\" [class.est-hidden-view]=\"item.fixed || item.pinned\" (click)=\"lastSelectedItemID = item.id; i != 0 && !item.fixed && columnMetadata_H.sendUp(item); $event.stopPropagation();\"></span>\r\n <span class=\"fa fa-arrow-down\" [class.est-hidden-view]=\"item.fixed || item.pinned\" (click)=\"lastSelectedItemID = item.id; !last && !item.fixed && columnMetadata_H.sendDown(item); $event.stopPropagation();\"></span>\r\n </td> -->\r\n <td class=\"est-nowrap drag-visible\" (click)=\"columnMetadata_H.columnClicked(item);\">\r\n <ng-container *ngIf=\"item.template\">\r\n <!-- Padri -->\r\n <span *ngIf=\"item.parentTemplates && item.parentTemplates.length > 0\" class=\"est-fw-bold est-fs-13\">\r\n ( \r\n <ng-container *ngFor=\"let parent of item.parentTemplates; let last=last\">\r\n <ng-container *ngTemplateOutlet=\"parent\"></ng-container>\r\n <span *ngIf=\"!last\"> - </span>\r\n </ng-container>\r\n )\r\n </span>\r\n <!-- Template header originale -->\r\n <ng-container *ngTemplateOutlet=\"item.template\"></ng-container>\r\n </ng-container>\r\n <ng-container *ngIf=\"!item.template\">{{item.description}}</ng-container>\r\n </td>\r\n <!--Filler-->\r\n <td (click)=\"columnMetadata_H.columnClicked(item);\"></td>\r\n <!-- Pinner -->\r\n <td *ngIf=\"DirectivesBased\"><span *ngIf=\"!item.fixed\" class=\"fa fa-thumb-tack\" [class.text-success]=\"item.pinned\" (click)=\"columnMetadata_H.pinOrUnpinColumn(item)\"></span></td>\r\n </tr>\r\n </tbody>\r\n </table>\r\n </div>\r\n </div>\r\n <div class=\"modal-footer\">\r\n <button type=\"button\" class=\"btn btn-secondary est-margin-right-10\" (click)=\"lastSelectedItemID = null; changeColumnVisibilityModal.hide();\">{{'Close' | localize : lc}}</button>\r\n <button type=\"button\" [disabled]=\"!TMPColumnsList || TMPColumnsList.length == 0\" class=\"btn btn-primary\" (click)=\"columnMetadata_H.confirmColumnVisibilitySelection() && changeColumnVisibilityModal.hide()\">{{'Confirm' | localize : lc}}</button>\r\n </div>\r\n </div>\r\n </div>\r\n</div>",
|
|
3795
|
+
template: "<!-- Patacchino di autoaggiornamento -->\r\n<div class=\"w-100\" *ngIf=\"AutoUpdate\">\r\n <div class=\"pull-right\">\r\n {{'Update every' | localize : lc}} <input [readonly]=\"autoUpdate\" maxlength=\"3\" class=\"form-control est-custom-input\" type=\"text\" [(ngModel)]=\"seconds\" /> {{'second/s' | localize : lc}}\r\n </div>\r\n <div class=\"pull-right m-t-2\">\r\n <label class=\"est-switch\">\r\n <input type=\"checkbox\" [(ngModel)]=\"autoUpdate\" (ngModelChange)=\"autoUpdateChanged();\" />\r\n <div class=\"est-slider round\"></div>\r\n </label>\r\n </div>\r\n <div class=\"clearfix\"></div>\r\n</div>\r\n\r\n<div *ngIf=\"View\" class=\"est-relative\">\r\n <div *ngIf=\"FirstBind && ShowLoadingOnBootstrap\" class=\"est-loading-box\">\r\n <div class=\"est-loading-content\">\r\n <span class=\"fa fa-spinner fa-spin\"></span> {{'Performing Table bootstrap' | localize: lc}}...\r\n </div>\r\n </div>\r\n\r\n <div class=\"est-top-pager\" *ngIf=\"PagingStyle == 'both' || PagingStyle == 'top'\">\r\n <ng-container *ngTemplateOutlet=\"pagingElement\"></ng-container>\r\n </div>\r\n\r\n <div class=\"est-top-allselect\" *ngIf=\"canSelectAll || (!reportMode && (View?.selection || arraymodeSelection)?.all)\">\r\n <span>{{ (selectedObjects == -1 ? ('All the' | localize : lc) : ((selectedObjects || 0) | number : '0.0-0' : locale)) + ' ' + ((selectedObjects == 1 ? 'Object Selected' : 'Objects Selected') | localize : lc) }}</span> \r\n <span class=\"est-link est-inline\" (click)=\"selection_H.selectAllOrResetSelection()\">{{ (View?.selection || arraymodeSelection)?.all ? ('Reset Selection' | localize : lc) : ('Select Everything' | localize : lc)}}</span>\r\n </div>\r\n\r\n <div class=\"table-responsive datatable {{ContainerClass}}\" [style.max-height.px]=\"MaxHeight\">\r\n <table class=\"{{ TableClass }} est-margin-bottom-10\" [class.est-high-density]=\"HighCellDensity\">\r\n <thead [hidden]=\"HeaderHidden || FirstBind\">\r\n <!-- Aggiungo il pezzo che gestisce la selezione di tutto se attivo da config -->\r\n <tr *ngIf=\"SelectAll || PagingStyle != 'bottom'\">\r\n <th class=\"est-no-selection\" [attr.colspan]=\"Columns.Global\" [class.est-hidden-view]=\"!canSelectAll && (reportMode || !(View?.selection || arraymodeSelection)?.all) && PagingStyle == 'bottom'\">\r\n <p class=\"est-hidden-view app-margin-bottom-0\">\u00A7</p>\r\n </th>\r\n </tr>\r\n\r\n <!-- Blocco header group -->\r\n <ng-container *ngIf=\"RowThGroups\">\r\n <tr *ngFor=\"let level of RowThGroups\">\r\n <th *ngFor=\"let cell of level\" [attr.colspan]=\"cell.Span\" \r\n [class.est-pinned-header]=\"cell.Pinned\" [class.est-col-min]=\"cell.Pinned\"\r\n [class.est-ltab-border]=\"cell.Borders\" [class.est-rtab-border]=\"cell.Borders\"\r\n class=\"est-text-center\">\r\n <ng-container *ngIf=\"cell.Pinned; Else: cell.Template\">\r\n <div class=\"est-pinned-border est-cell-group-padding\"></div>\r\n </ng-container>\r\n </th>\r\n </tr>\r\n </ng-container>\r\n\r\n <ng-container *ngIf=\"!RowThGroups\">\r\n <tr *ngIf=\"HasHeaderGroup\">\r\n <ng-container *ngTemplateOutlet=\"headerGroupRef\"></ng-container>\r\n <th *ngIf=\"Export\"></th>\r\n </tr>\r\n \r\n <!-- Blocco header group secondario -->\r\n <tr *ngIf=\"HasSecondaryHeaderGroup\">\r\n <ng-container *ngTemplateOutlet=\"secondaryHeaderGroupRef\"></ng-container>\r\n <th *ngIf=\"Export\"></th>\r\n </tr>\r\n </ng-container>\r\n\r\n <!-- Blocco effettivo degli header -->\r\n <tr>\r\n <!-- Aggiungo una checkbox se la selezione \u00E8 attiva -->\r\n <th class=\"est-col-min\" *ngIf=\"Selection && !HasPinnedColumns\">\r\n <input *ngIf=\"!SingleSelection\" class=\"est-pointer\" type=\"checkbox\" [disabled]=\"SelectionDisabled\" [(ngModel)]=\"globalCheck\" [ngModelOptions]=\"{'standalone': true}\" (ngModelChange)=\"globalCheckChanged();\">\r\n </th>\r\n\r\n <!-- Header che valgono per view mode e array mode -->\r\n <ng-container *ngIf=\"(viewMode || arrayMode)\">\r\n\r\n <!-- In una tabella base prendo semplicemente i th scritti dall'utente nell'HTML -->\r\n <ng-container *ngIf=\"(!UseCustomCells || !RowTHs) && !DynamicRowColumnsDefinition\">\r\n <ng-container *ngTemplateOutlet=\"headerRef\"></ng-container>\r\n </ng-container>\r\n\r\n <!-- Se ho un modello dinamico dell'oggetto creo le colonne in base alle propriet\u00E0 -->\r\n <ng-container *ngIf=\"(!UseCustomCells || !RowTHs) && DynamicRowColumnsDefinition\">\r\n <th *ngFor=\"let operation of DynamicOperations\" class=\"est-col-min est-no-side-padding\"></th>\r\n \r\n <ng-container *ngFor=\"let rowHeader of DynamicRowColumnsDefinition\">\r\n <ng-container *ngIf=\"rowHeader.visible\">\r\n <th *ngIf=\"OrderByColumn\" es-th=\"{{rowHeader.propertyName}}\" class=\"{{UserDefinedDynamicCols ? ((rowHeader.clss || '') + (rowHeader.headerWraps ? '' : ' est-nowrap')) : ' est-nowrap'}}\" [Order]=\"rowHeader.dataOrder\" [Resizable]=\"ColumnsResizable\" [Orderable]=\"rowHeader.orderable\" [OrderBy]=\"OrderByColumn\" [SearchInProgress]=\"!!researchInProgress\" (onOrderChange)=\"thOrderChanged(rowHeader.propertyName, $event)\">{{rowHeader.description}}</th>\r\n <th *ngIf=\"!OrderByColumn\" es-th=\"{{rowHeader.propertyName}}\" class=\"{{UserDefinedDynamicCols ? ((rowHeader.clss || '') + (rowHeader.headerWraps ? '' : ' est-nowrap')) : ' est-nowrap'}}\" [Order]=\"rowHeader.dataOrder\" [Resizable]=\"ColumnsResizable\" [Orderable]=\"rowHeader.orderable\" [OrderBy]=\"OrderByColumn\">{{rowHeader.description}}</th>\r\n </ng-container>\r\n </ng-container>\r\n </ng-container>\r\n\r\n <!-- Se non ho un modello dinamico ma invece delle celle custom, genero gli header in base ai row th -->\r\n <ng-container *ngIf=\"UseCustomCells && RowTHs\">\r\n <th *ngIf=\"HasPinnedColumns\" class=\"est-pinned-header est-col-min\">\r\n <div [style.width.px]=\"PinnedContainerWidth\" class=\"est-pinned-border est-simple-border-bottom\">\r\n <th class=\"est-col-min est-no-border\" *ngIf=\"Selection\" [style.width.px]=\"20\">\r\n <input *ngIf=\"!SingleSelection\" class=\"est-pointer\" type=\"checkbox\" [disabled]=\"SelectionDisabled\" [(ngModel)]=\"globalCheck\" [ngModelOptions]=\"{'standalone': true}\" (ngModelChange)=\"globalCheckChanged();\">\r\n </th>\r\n <ng-container *ngFor=\"let rowHeader of RowTHs\">\r\n <th *ngIf=\"rowHeader && rowHeader.Visible && rowHeader.Pinned\" [style.width.px]=\"rowHeader.PinnedWidth\" es-th=\"{{rowHeader.ID}}\" \r\n class=\"{{rowHeader.Class || ''}}\" \r\n [class.est-pinned-internal-header]=\"true\" \r\n [class.est-no-border]=\"true\" \r\n [class.est-nowrap]=\"!rowHeader.Wrap\" \r\n [Pinned]=\"true\" [Fixed]=\"rowHeader.Fixed\" [Order]=\"rowHeader.Order\" [Resizable]=\"ColumnsResizable\" [Orderable]=\"rowHeader.Orderable\" [OrderBy]=\"OrderByColumn\" [SearchInProgress]=\"!!researchInProgress\" (onUnpinning)=\"columnMetadata_H.unpinColumn($event)\" (onOrderChange)=\"OrderByColumn && thOrderChanged(rowHeader.ID, $event)\">\r\n <ng-container *ngIf=\"rowHeader.Template\"><ng-container *ngTemplateOutlet=\"rowHeader.Template;\"></ng-container></ng-container>\r\n <span *ngIf=\"!rowHeader.Template\">{{rowHeader.Content}}</span>\r\n </th>\r\n </ng-container>\r\n </div>\r\n </th>\r\n <ng-container *ngFor=\"let rowHeader of RowTHs\">\r\n <th *ngIf=\"rowHeader && rowHeader.Visible && !rowHeader.Pinned\" es-th=\"{{rowHeader.ID}}\" class=\"{{rowHeader.Class || ''}}\" [class.est-ltab-border]=\"rowHeader.LeftBorder\" [class.est-rtab-border]=\"rowHeader.RightBorder\" [class.est-nowrap]=\"!rowHeader.Wrap\" [Order]=\"rowHeader.Order\" [Resizable]=\"ColumnsResizable\" [Orderable]=\"rowHeader.Orderable\" [OrderBy]=\"OrderByColumn\" [SearchInProgress]=\"!!researchInProgress\" (onOrderChange)=\"OrderByColumn && thOrderChanged(rowHeader.ID, $event)\">\r\n <ng-container *ngIf=\"rowHeader.Template\"><ng-container *ngTemplateOutlet=\"rowHeader.Template;\"></ng-container></ng-container>\r\n <span *ngIf=\"!rowHeader.Template\">{{rowHeader.Content}}</span>\r\n </th>\r\n </ng-container>\r\n </ng-container>\r\n </ng-container>\r\n\r\n <!--Casistica in cui ho il setup proveniente da un report. Gli header sono definiti da come \u00E8 fatto il report-->\r\n <ng-container *ngIf=\"reportMode\">\r\n <th [style.color]=\"clm.color\" *ngFor=\"let clm of ReportValues.columns\" class=\"est-no-selection est-pointer est-nowrap\" (click)=\"reportMode_H.setupNextOrderAndSearch(clm)\">\r\n {{clm.description}}<span class=\"fa\" [class.fa-chevron-down]=\"clm.order == 'DESC'\" [class.fa-chevron-up]=\"clm.order == 'ASC'\"></span>\r\n </th>\r\n </ng-container>\r\n\r\n <!--Per l'eliminazione mi serve un header aggiuntivo-->\r\n <th *ngIf=\"Removal\" [class.est-right-9]=\"Export || HiddenColumns\" class=\"est-col-min est-sticky-last-column\"><span class=\"fa fa-trash\"></span></th>\r\n\r\n <!--Per l'esportazione mi serve l'header extra da cui faccio uscire i 3 pallocchi-->\r\n <th *ngIf=\"Export || HiddenColumns || ColumnsOrdering || CornerMenuOptions\" class=\"est-table-dotted-menu est-sticky-last-column est-col-min text-sm-center\">\r\n \r\n <!-- Link nascosto che serve a scaricare il file -->\r\n <a *ngIf=\"headers\" hidden #exportDownloader csvLink [data]=\"data\" [headers]=\"headers\" [delimiter]=\"';'\" [filename]=\"ExportFileName.endsWith('.xlsx') ? ExportFileName.replace('.xlsx', '.csv') : ExportFileName.endsWith('.csv') ? ExportFileName : ExportFileName + '.csv'\"></a>\r\n\r\n <!-- Blocco con i 3 pallocchi che tira fuori il context menu delle operazioni -->\r\n <div class=\"btn-group\" container=\"body\" placement=\"bottom right\" dropdown #dropdown=\"bs-dropdown\" [autoClose]=\"true\">\r\n <span dropdownToggle class=\"fa fa-ellipsis-v est-fs-18 est-pointer est-padding-3\"></span>\r\n\r\n <div *dropdownMenu class=\"dropdown-menu dropdown-menu-right est-bring-to-front-strong\">\r\n <div class=\"est-pointer\">\r\n <a class=\"dropdown-item\" *ngIf=\"HiddenColumns || ColumnsOrdering\" (click)=\"columnMetadata_H.resetColumnVisSelection(); changeColumnVisibilityModal.show();\">\r\n <ng-container *ngIf=\"!HiddenColumns && ColumnsOrdering\">\r\n {{'Columns Order' | localize : lc}}\r\n </ng-container>\r\n <ng-container *ngIf=\"HiddenColumns && !ColumnsOrdering\">\r\n {{'Columns Visibility' | localize : lc}}\r\n </ng-container>\r\n <ng-container *ngIf=\"HiddenColumns && ColumnsOrdering\">\r\n {{'Columns Visibility and Order' | localize : lc}}\r\n </ng-container>\r\n </a>\r\n <a class=\"dropdown-item\" *ngIf=\"Export && CSVExport\" (click)=\"export_H.tryExport('CSV')\">{{'Export View' | localize : lc}} (CSV)</a>\r\n <a class=\"dropdown-item\" *ngIf=\"Export && XLSXExport\" (click)=\"export_H.tryExport('XLSX')\">{{'Export View' | localize : lc}} (XLSX)</a>\r\n <a class=\"dropdown-item\" *ngFor=\"let option of CornerMenuOptions\" (click)=\"cornerActionClicked(option.id)\">{{option.description}}</a>\r\n </div>\r\n </div>\r\n </div>\r\n </th>\r\n </tr>\r\n </thead>\r\n \r\n <!-- Valido per modalit\u00E0 View o Array. Se sono in report mode il body \u00E8 creato in altro modo -->\r\n <tbody [hidden]=\"BodyHidden || FirstBind\" *ngIf=\"(arrayMode || viewMode)\">\r\n <!--Con selection attiva richiamo il template che gestisce il context menu-->\r\n <ng-container *ngIf=\"Selection\">\r\n <ng-container *ngTemplateOutlet=\"TBodySelection; context: { $implicit: { selDisabled: arrayMode ? false : SelectionDisabled, sel: Selection }}\"></ng-container>\r\n </ng-container>\r\n\r\n <!--Senza selection richiamo il template che NON gestisce il context menu-->\r\n <ng-container *ngIf=\"!Selection\">\r\n <ng-container *ngTemplateOutlet=\"TBody\"></ng-container>\r\n </ng-container>\r\n </tbody>\r\n\r\n <!-- Per la modalit\u00E0 a report c'\u00E8 un body particolare semi-dinamico -->\r\n <tbody [hidden]=\"BodyHidden\" *ngIf=\"reportMode\">\r\n <tr *ngFor=\"let row of ReportValues.rows; let even = even;\">\r\n <td class=\"est-nowrap\" *ngFor=\"let val of row.values\">{{val}}</td>\r\n <td class=\"est-sticky-last-column{{even && !Hierarchy ? '-alt' : ''}}\"></td>\r\n </tr>\r\n </tbody>\r\n </table>\r\n </div>\r\n\r\n <div *ngIf=\"PagingStyle == 'both' || PagingStyle == 'bottom'\">\r\n <ng-container *ngTemplateOutlet=\"pagingElement\"></ng-container>\r\n </div>\r\n</div>\r\n\r\n<!-- Template che contiene tutte le info di paginazione in modo da poterlo replicare anche sopra -->\r\n<ng-template #pagingElement>\r\n <ng-container *ngIf=\"!FirstBind\">\r\n <!-- Pulsanti avanti-indietro di paginazione -->\r\n <div *ngIf=\"PagerOptions.ShowPaging && PagerOptions.ShowButtons && (PagerOptions.PagerCount > 10 || PagerOptions.PagerCount == -1)\" class=\"pull-right btn-toolbar\">\r\n <ng-container *ngIf=\"(!reportMode || View?.pagingavailable) && (!arrayMode || SearchView)\">\r\n <ng-container *ngTemplateOutlet=\"pagingButtons; context: { $implicit: { Margin: true, ATP: addToPage.bind(this), GTP: goToPage.bind(this), Array: arrayPulsanti }}\"></ng-container>\r\n </ng-container>\r\n <ng-container *ngIf=\"arrayMode && UseArrayModePaging && !SearchView\">\r\n <ng-container *ngTemplateOutlet=\"pagingButtons; context: { $implicit: { Margin: true, ATP: arrayAddToPage.bind(this), GTP: arrayGoToPage.bind(this), Array: arrayPulsanti }}\"></ng-container>\r\n </ng-container>\r\n </div>\r\n <!-- Paginatore dove appare la count e le opzioni di paginazione -->\r\n <div class=\"pull-right\" *ngIf=\"PagerOptions.ShowCount || PagerOptions.ShowPagingOptions\">\r\n <div class=\"est-mt-min-5\" *ngIf=\"PagerOptions.ShowPaging\">\r\n <app-paging *ngIf=\"!PagerOptions.UsesView\" [CountLabel]=\"CountLabel\" [ShowPaging]=\"PagerOptions.ShowPagingOptions\" [ShowCount]=\"PagerOptions.ShowCount\" [PagerCount]=\"PagerOptions.PagerCount\" [WarnOnAll]=\"false\" [CurrentPageSize]=\"ArraymodeItemsPerPage\" (pagingSelected)=\"items_H.refreshPaging($event)\"></app-paging>\r\n <app-paging *ngIf=\"PagerOptions.UsesView\" [CountLabel]=\"CountLabel\" [ShowPaging]=\"PagerOptions.ShowPagingOptions\" [ShowCount]=\"PagerOptions.ShowCount\" [PagerCount]=\"PagerOptions.PagerCount\" [GroupMode]=\"PagerOptions.Searches == 'groups'\" [AllSearch]=\"AllSearch\" [View]=\"PagerOptions.View\" (pagingSelected)=\"onItemsPerPageChanged($event);\"></app-paging>\r\n </div>\r\n <div *ngIf=\"reportMode && !PagerOptions.ShowPaging\"><em>{{'Paging options are not available for this report' | localize: lc}}</em></div>\r\n </div>\r\n <div class=\"clearfix\"></div>\r\n </ng-container>\r\n</ng-template>\r\n\r\n<!-- Template che contiene i pulsanti per cambiare pagina -->\r\n<ng-template #pagingButtons let-options>\r\n <div class=\"est-flex\" [class.est-margin-left-50]=\"options.Margin\">\r\n <a class=\"btn\" class=\"est-page-prev app-pointer\" (click)=\"options.ATP(-1, options.separator)\"><span class=\"fa fa-chevron-left\"></span></a>\r\n <div *ngIf=\"options.Array\" class=\"est-inline\"><a *ngFor=\"let p of options.Array\" class=\"btn est-page-sel {{p.cssClass}}\" (click)=\"options.GTP(p.val, options.separator)\">{{p.val}}</a></div>\r\n <a class=\"btn\" class=\"est-page-next app-pointer\" (click)=\"options.ATP(1, options.separator)\"><span class=\"fa fa-chevron-right\"></span></a>\r\n </div>\r\n</ng-template>\r\n\r\n<!-- Questi due template rappresentano effettivamente il body della tabella. essendo il tr l'unica cosa che davvero cambia, il resto \u00E8 templatizzato -->\r\n<ng-template #TBodySelection let-templateOptions>\r\n <ng-container *ngFor=\"let item of boundSource; let even = even; let i=index; trackBy: bodyTrackBy\">\r\n <tr *ngIf=\"item._visible || (!Hierarchy && !ArrayGrouping)\" \r\n [class]=\"item._rowClass ? item._rowClass : ''\" \r\n [class.est-line-through]=\"item.removed || item.deleted\" \r\n [class.est-pointer]=\"!item.locked\" \r\n [class.est-white-selected]=\"item._selected && !item.locked\"\r\n [class.est-rg]=\"item._group\"\r\n [class.est-rg-sep]=\"item._sep\"\r\n [contextMenu]=\"!item.locked ? (ContextMenu || emptyMenu) : emptyMenu\" [contextMenuSubject]=\"item\"\r\n (click)=\"(!item.locked && !item._sep && !item._group && handleClick($event, item)) || item._group && handleGroupClick(item)\">\r\n\r\n <td *ngIf=\"!item.locked && !item._sep && !HasPinnedColumns\">\r\n <input type=\"checkbox\" \r\n [disabled]=\"templateOptions.selDisabled\" \r\n [class.est-pointer]=\"!item.locked\"\r\n [(ngModel)]=\"item._selected\" name=\"check{{i}}\" \r\n (click)=\"$event.stopPropagation(); handleClick($event, item);\">\r\n </td>\r\n <td *ngIf=\"(item.locked || item._sep) && !HasPinnedColumns\"></td>\r\n\r\n <ng-container *ngIf=\"item._sep\"><ng-container *ngTemplateOutlet=\"groupPager; context: { $implicit: item }\"></ng-container> </ng-container>\r\n\r\n <ng-container *ngIf=\"!item._sep\">\r\n <ng-container *ngTemplateOutlet=\"basicColumns; context: { $implicit: item }\"></ng-container>\r\n <ng-container *ngTemplateOutlet=\"dynamicColumns; context: { $implicit: item }\"></ng-container>\r\n <ng-container *ngTemplateOutlet=\"customCells; context: { $implicit: item, templateOptions: templateOptions }\"></ng-container>\r\n </ng-container>\r\n <ng-container *ngTemplateOutlet=\"bodyDeleteAndExport; context: { $implicit: { even: even, item: item }}\"></ng-container>\r\n </tr>\r\n </ng-container>\r\n</ng-template>\r\n\r\n<ng-template #TBody>\r\n <ng-container *ngFor=\"let item of boundSource; let even = even;\">\r\n <tr *ngIf=\"item._visible || !Hierarchy\" \r\n [class]=\"item._rowClass ? item._rowClass : ''\" \r\n [class.est-line-through]=\"item.removed || item.deleted\"\r\n [class.est-rg]=\"item._group\"\r\n [class.est-rg-sep]=\"item._sep\"\r\n (click)=\"item._group && handleGroupClick(item)\">\r\n\r\n <ng-container *ngIf=\"item._sep\"><ng-container *ngTemplateOutlet=\"groupPager; context: { $implicit: item }\"></ng-container></ng-container>\r\n\r\n <ng-container *ngIf=\"!item._sep\">\r\n <ng-container *ngTemplateOutlet=\"basicColumns; context: { $implicit: item }\"></ng-container>\r\n <ng-container *ngTemplateOutlet=\"dynamicColumns; context: { $implicit: item }\"></ng-container>\r\n <ng-container *ngTemplateOutlet=\"customCells; context: { $implicit: item }\"></ng-container>\r\n </ng-container>\r\n <ng-container *ngTemplateOutlet=\"bodyDeleteAndExport; context: { $implicit: { even: even, item: item }}\"></ng-container>\r\n </tr>\r\n </ng-container>\r\n</ng-template>\r\n\r\n<ng-template #groupPager let-item>\r\n <td class=\"est-pinned-body \" *ngIf=\"HasPinnedColumns\"><div class=\"est-pinned-border est-cell-group-padding\"></div></td>\r\n <td *ngIf=\"item._grouplevel > 1\" [attr.colspan]=\"item._grouplevel-1\"></td>\r\n <td [attr.colspan]=\"Columns.VisibleUnpinned - (item._grouplevel > 0 ? item._grouplevel - 1 : 0)\">\r\n <div class=\"est-rg-sep-flex-right\" *ngIf=\"RowGroupingPagingStyle == 'right'\">\r\n <div class=\"est-rg-page\"><ng-container *ngTemplateOutlet=\"pagingButtons; context: { $implicit: { separator: item, ATP: addToPageGroup.bind(this), GTP: goToPageGroup.bind(this), Array: item.buttons }}\"></ng-container></div>\r\n <div class=\"est-rg-ipp\" *ngIf=\"(item.searches == 'groups' ? item.view.groupcount : item.view.objectcount) > 10\"><app-paging [CountLabel]=\"CountLabel\" [AllSearch]=\"AllSearch\" [GroupMode]=\"item.searches == 'groups'\" [PagerCount]=\"item.searches == 'groups' ? item.view.groupcount : item.view.objectcount\" [View]=\"item.view\" (pagingSelected)=\"onGroupItemsPerPageChanged(item, $event);\"></app-paging></div>\r\n </div>\r\n\r\n <div class=\"est-rg-sep-flex-left\" *ngIf=\"RowGroupingPagingStyle == 'left'\">\r\n <div class=\"est-rg-ipp\"><app-paging [AllSearch]=\"AllSearch\" [CountLabel]=\"CountLabel\" [GroupMode]=\"item.searches == 'groups'\" [PagerCount]=\"item.searches == 'groups' ? item.view.groupcount : item.view.objectcount\" [View]=\"item.view\" (pagingSelected)=\"onGroupItemsPerPageChanged(item, $event);\"></app-paging></div>\r\n <div class=\"est-rg-page\" *ngIf=\"(item.searches == 'groups' ? item.view.groupcount : item.view.objectcount) > 10\"><ng-container *ngTemplateOutlet=\"pagingButtons; context: { $implicit: { separator: item, ATP: addToPageGroup.bind(this), GTP: goToPageGroup.bind(this), Array: item.buttons }}\"></ng-container></div>\r\n </div>\r\n </td>\r\n</ng-template>\r\n\r\n<!-- Questo template contiene la print condizionale su tabelle semplici, con header e body scritti a manazza -->\r\n<ng-template #basicColumns let-item>\r\n <ng-container *ngIf=\"(!UseCustomCells || !RowTDs) && !DynamicRowColumnsDefinition\">\r\n <ng-container *ngTemplateOutlet=\"bodyRef; context : {$implicit: item}\"></ng-container>\r\n </ng-container>\r\n</ng-template>\r\n\r\n<!-- Questo template contiene la print condizionale su tabelle definite in maniera dinamica dal modello -->\r\n<ng-template #dynamicColumns let-item>\r\n <ng-container *ngIf=\"(!UseCustomCells || !RowTDs) && DynamicRowColumnsDefinition\">\r\n <ng-container *ngFor=\"let operation of DynamicOperations; let first = first; let last = last;\">\r\n <ng-container *ngIf=\"!operation.conditionField || (item.properties[operation.conditionField] == operation.conditionValue)\">\r\n <td [class.est-no-right-padding]=\"last\" [class.est-no-left-padding]=\"!first\" class=\"est-col-min\"><span title=\"{{operation.title}}\" class=\"{{operation.iconClass}} est-pointer\" (click)=\"dynamicOperation(item, operation.id)\">{{operation.text}}</span></td>\r\n </ng-container>\r\n <ng-container *ngIf=\"operation.conditionField && (item.properties[operation.conditionField] != operation.conditionValue)\">\r\n <td class=\"est-col-min est-no-side-padding\"></td>\r\n </ng-container>\r\n </ng-container>\r\n <ng-container *ngFor=\"let rowItem of DynamicRowColumnsDefinition\">\r\n <ng-container *ngIf=\"rowItem.routePath && rowItem.visible\">\r\n <td es-td=\"{{rowItem.propertyName}}\" class=\"{{UserDefinedDynamicCols ? rowItem.clss : 'est-nowrap'}}\" [Internal]=\"false\" [Context]=\"item._hash\">\r\n <a [routerLink]=\"dynamicMode_H.generateRouterLink(rowItem.routePath, rowItem.routeParameterProperties, item)\" class=\"est-link\" [innerHTML]=\"item.properties[rowItem.propertyName]\"></a>\r\n </td>\r\n </ng-container>\r\n <ng-container *ngIf=\"!rowItem.routePath && rowItem.visible\">\r\n <ng-container *ngTemplateOutlet=\"findEsTd(rowItem.propertyName) || defaultEsTd; context: { $implicit: item.properties[rowItem.propertyName], rowItem : rowItem, item : item }\"> </ng-container>\r\n </ng-container>\r\n </ng-container>\r\n </ng-container>\r\n</ng-template>\r\n\r\n<ng-template #defaultEsTd let-value let-rowItem='rowItem' let-item='item'>\r\n <td es-td=\"{{rowItem.propertyName}}\" class=\"{{UserDefinedDynamicCols ? rowItem.clss : 'est-nowrap'}}\" [Internal]=\"false\" [Context]=\"item._hash\">\r\n {{value}}\r\n </td>\r\n</ng-template>\r\n\r\n<!-- Questo template contiene la print condizionale delle celle custom se configurate -->\r\n<ng-template #customCells let-item let-opt=\"templateOptions\">\r\n <ng-container *ngIf=\"UseCustomCells && RowTDs\">\r\n\r\n <td *ngIf=\"HasPinnedColumns\" class=\"est-pinned-body est-col-min\" [class.est-white-selected]=\"item._selected\">\r\n <div [style.width.px]=\"PinnedContainerWidth\" class=\"est-pinned-border\">\r\n <td *ngIf=\"!item.locked && !item._sep && Selection\" class=\"est-no-border est-col-min\" [style.width.px]=\"20\">\r\n <input type=\"checkbox\" [disabled]=\"opt.selDisabled\" [class.est-pointer]=\"!item.locked\" [(ngModel)]=\"item._selected\" name=\"check{{item._hash}}\" (click)=\"$event.stopPropagation(); handleClick($event, item);\">\r\n </td>\r\n <td class=\"est-no-border est-col-min\" *ngIf=\"(item.locked || item._sep) && Selection\" [style.width.px]=\"20\"></td>\r\n\r\n <ng-container *ngFor=\"let rowItem of RowTDs[item._hash]; let i = index\">\r\n <td *ngIf=\"rowItem && rowItem.Pinned && rowItem.Visible\" [style.width.px]=\"rowItem.PinnedWidth\" es-td=\"{{rowItem.ID}}\" class=\"{{rowItem.Class}}\" [class.est-no-border]=\"true\" [class.est-rg-hdr]=\"rowItem.GroupHeader\" [class.est-rg-agg]=\"rowItem.GroupAggregation\" \r\n [class.est-nowrap]=\"Hierarchy || !rowItem.Wraps\" [Internal]=\"true\">\r\n <ng-container *ngIf=\"Hierarchy && i == 0\"><ng-container *ngTemplateOutlet=\"HierarchyNavigator; context: { $implicit: item }\"></ng-container></ng-container>\r\n <ng-container *ngIf=\"rowItem.Template\"><ng-container *ngTemplateOutlet=\"rowItem.Template; context: { $implicit: item }\"></ng-container></ng-container>\r\n <span *ngIf=\"!rowItem.Template\">{{rowItem.Content}}</span>\r\n </td>\r\n </ng-container>\r\n </div>\r\n </td>\r\n\r\n <ng-container *ngFor=\"let rowItem of RowTDs[item._hash]; let i = index\">\r\n <ng-container *ngIf=\"rowItem && !rowItem.Pinned\">\r\n\r\n <!-- Casistica senza bodyRef, quindi con direttive per i td -->\r\n <ng-container *ngIf=\"!bodyRef && rowItem.Visible\">\r\n <td es-td=\"{{rowItem.ID}}\" class=\"{{rowItem.Class}}\" [class.est-ltab-border]=\"rowItem.LeftBorder\" [class.est-rtab-border]=\"rowItem.RightBorder\" [class.est-rg-hdr]=\"rowItem.GroupHeader\" [class.est-rg-agg]=\"rowItem.GroupAggregation\" \r\n [class.est-nowrap]=\"Hierarchy || !rowItem.Wraps\" [Internal]=\"true\">\r\n <ng-container *ngIf=\"Hierarchy && i == 0\"><ng-container *ngTemplateOutlet=\"HierarchyNavigator; context: { $implicit: item }\"></ng-container></ng-container>\r\n <ng-container *ngIf=\"rowItem.Template\"><ng-container *ngTemplateOutlet=\"rowItem.Template; context: { $implicit: item }\"></ng-container></ng-container>\r\n <span *ngIf=\"!rowItem.Template\">{{rowItem.Content}}</span>\r\n </td>\r\n </ng-container>\r\n\r\n <!-- Casistica bodyRef, quindi con componenti per i td (RouterLink) DEPRECATO -->\r\n <ng-container *ngIf=\"rowItem.RouterLink && rowItem.Visible && bodyRef\">\r\n <td es-td=\"{{rowItem.ID}}\" class=\"{{rowItem.Class}}\" [class.est-nowrap]=\"Hierarchy || !rowItem.Wraps\" [Internal]=\"true\">\r\n <ng-container *ngIf=\"Hierarchy && i == 0\">\r\n <ng-container *ngTemplateOutlet=\"HierarchyNavigator; context: { $implicit: item }\"></ng-container>\r\n </ng-container>\r\n <a [routerLink]='rowItem.RouterLink' class=\"est-link\" [innerHTML]=\"rowItem.Content\"></a>\r\n </td>\r\n </ng-container>\r\n\r\n <!-- Casistica bodyRef, quindi con componenti per i td (NON RouterLink) DEPRECATO -->\r\n <ng-container *ngIf=\"!rowItem.RouterLink && rowItem.Visible && bodyRef\">\r\n <td es-td=\"{{rowItem.ID}}\" class=\"{{rowItem.Class}}\" [class.est-nowrap]=\"Hierarchy || !rowItem.Wraps\" [Internal]=\"true\">\r\n <ng-container *ngIf=\"Hierarchy && i == 0\">\r\n <ng-container *ngTemplateOutlet=\"HierarchyNavigator; context: { $implicit: item }\"></ng-container>\r\n </ng-container>\r\n <ng-container *ngIf=\"rowItem.Template\">\r\n <ng-container *ngTemplateOutlet=\"rowItem.Template; context: { $implicit: item }\"></ng-container>\r\n </ng-container>\r\n <span *ngIf=\"!rowItem.Template\" [innerHTML]=\"rowItem.Content\"></span>\r\n </td>\r\n </ng-container>\r\n </ng-container>\r\n </ng-container>\r\n </ng-container>\r\n</ng-template>\r\n\r\n<ng-template #HierarchyNavigator let-item>\r\n <span *ngIf=\"!item.parent\" class=\"fa fa-chevron-down\" style=\"visibility:hidden\"></span>\r\n <span *ngIf=\"item.parent && item._expanded\" class=\"fa fa-chevron-down est-pointer est-no-selection\" (click)=\"hierarchyMode_H.collapseParent(item[this.OwnKey])\"></span>\r\n <span *ngIf=\"item.parent && !item._expanded\" class=\"fa fa-chevron-up est-pointer est-no-selection\" (click)=\"hierarchyMode_H.expandParent(item[this.OwnKey])\"></span>\r\n \r\n</ng-template>\r\n\r\n<!-- Questo template contiene i pulsanti di eliminazione/undo eliminazione ed esportazione che vanno in fondo ad un record edlla tabella -->\r\n<ng-template #bodyDeleteAndExport let-options>\r\n <ng-container *ngIf=\"Removal && !RemovalCondition\">\r\n <td class=\"est-sticky-last-column{{options.even? '-alt' : ''}} {{Export || HiddenColumns || CornerMenuOptions ? 'est-right-9' : ''}}\" *ngIf=\"!(options.item.removed || options.item.deleted)\"><span class=\"fa fa-remove est-pointer text-danger\" [hidden]=\"options.item.removable != undefined && !options.item.removable\" (click)=\"onRemoval.emit(options.item)\"></span></td>\r\n <td class=\"est-sticky-last-column{{options.even? '-alt' : ''}} {{Export || HiddenColumns || CornerMenuOptions ? 'est-right-9' : ''}}\" *ngIf=\"(options.item.removed || options.item.deleted)\"><span class=\"fa fa-undo text-warning est-pointer\" (click)=\"onAbortRemoval.emit(options.item)\"></span></td>\r\n </ng-container>\r\n <ng-container *ngIf=\"Removal && RemovalCondition\">\r\n <td class=\"est-sticky-last-column{{options.even? '-alt' : ''}} {{Export || HiddenColumns || CornerMenuOptions ? 'est-right-9' : ''}}\" *ngIf=\"!(options.item.removed || options.item.deleted) && options.item[RemovalCondition]\"><span class=\"fa fa-remove est-pointer text-danger\" [hidden]=\"options.item.removable != undefined && !options.item.removable\" (click)=\"onRemoval.emit(options.item)\"></span></td>\r\n <td class=\"est-sticky-last-column{{options.even? '-alt' : ''}} {{Export || HiddenColumns || CornerMenuOptions ? 'est-right-9' : ''}}\" *ngIf=\"(options.item.removed || options.item.deleted) && options.item[RemovalCondition]\"><span class=\"fa fa-undo text-warning est-pointer\" (click)=\"onAbortRemoval.emit(options.item)\"></span></td>\r\n <td class=\"est-sticky-last-column{{options.even? '-alt' : ''}} {{Export || HiddenColumns || CornerMenuOptions ? 'est-right-9' : ''}}\" *ngIf=\"!options.item[RemovalCondition]\"><span class=\"fa fa-remove est-hidden-view\"></span></td>\r\n </ng-container>\r\n <td *ngIf=\"Export || HiddenColumns || CornerMenuOptions\" class=\"est-sticky-last-column{{options.even && !Hierarchy ? '-alt' : ''}}\"></td>\r\n</ng-template>\r\n\r\n<!-- Context menu vuoto default per tutte le tabella che non ce l'hanno, in modo che al click destro appaia \"nessuna op disponibile\" -->\r\n<context-menu #emptyMenu>\r\n <ng-template contextMenuItem>\r\n <span>\r\n <em>{{'No operations available' | localize : lc}}...</em>\r\n </span>\r\n </ng-template>\r\n</context-menu>\r\n\r\n<!-- Modal per cambiare posizione e visibilit\u00E0 delle colonne dell'es-table -->\r\n<div bsModal #changeColumnVisibilityModal=\"bs-modal\" class=\"modal fade\" role=\"dialog\" aria-hidden=\"true\">\r\n <div class=\"modal-dialog modal-lg\" cdkDrag>\r\n <div class=\"modal-content\">\r\n <div class=\"modal-header est-pointer\" cdkDragHandle>\r\n <h5 class=\"modal-title pull-left\">\r\n <ng-container *ngIf=\"!HiddenColumns && ColumnsOrdering\">\r\n {{'Columns Order' | localize : lc}}\r\n </ng-container>\r\n <ng-container *ngIf=\"HiddenColumns && !ColumnsOrdering\">\r\n {{'Columns Visibility' | localize : lc}}\r\n </ng-container>\r\n <ng-container *ngIf=\"HiddenColumns && ColumnsOrdering\">\r\n {{'Columns Visibility and Order' | localize : lc}}\r\n </ng-container>\r\n </h5>\r\n <button type=\"button\" class=\"close pull-right\" (click)=\"changeColumnVisibilityModal.hide();\" aria-label=\"Close\">\r\n <span aria-hidden=\"true\">×</span>\r\n </button>\r\n </div>\r\n <div class=\"modal-body\">\r\n <div *ngIf=\"!TMPColumnsList || TMPColumnsList.length == 0\" class=\"card card-info est-padding-10 est-margin-bottom-0\">\r\n {{'There are no columns configured to be hidden/shown in this view' | localize : lc}}\r\n </div>\r\n <div *ngIf=\"TMPColumnsList && TMPColumnsList.length > 0\" style=\"max-height:500px; overflow-y:auto\">\r\n <!--Aaaaaaah la tristezza... qui mi servirebbe l'es-table per facilitare la selezione multipla ecc... peccato che se la linko qui entro in un loop impressionante-->\r\n <table class=\"table table-striped table-sm est-margin-bottom-0\">\r\n <thead>\r\n <tr>\r\n <th class=\"est-col-min\" *ngIf=\"HiddenColumns\">\r\n <input class=\"est-pointer\" type=\"checkbox\" [(ngModel)]=\"globalColVisCheck\" [ngModelOptions]=\"{'standalone': true}\" (ngModelChange)=\"columnMetadata_H.globalColVisCheckChanged();\">\r\n </th>\r\n <!-- <th class=\"est-col-min\" *ngIf=\"ColumnsOrdering\"></th> -->\r\n <th class=\"est-col-min est-nowrap\">{{'Column Name' | localize : lc}}</th>\r\n <!--Filler-->\r\n <th></th>\r\n <!-- Pinner -->\r\n <th *ngIf=\"DirectivesBased\" class=\"est-col-min\"></th>\r\n </tr>\r\n </thead>\r\n <tbody \r\n cdkDropList \r\n [cdkDropListData]=\"TMPColumnsList\" \r\n (cdkDropListDropped)=\"columnMetadata_H.columnReordered($event)\" \r\n [cdkDropListSortPredicate]=\"columnMetadata_H.sortPredicate.bind(this.columnMetadata_H)\"\r\n class=\"est-dropbox\">\r\n\r\n <tr *ngFor=\"let item of TMPColumnsList; let i = index; let last = last\" \r\n class=\"est-pointer est-droplist\" \r\n [class.est-white-selected]=\"lastSelectedItemID == item.id\" \r\n [class.est-no-selection]=\"!item.visible\"\r\n cdkDrag\r\n [cdkDragData]=\"item\"\r\n [cdkDragDisabled]=\"!ColumnsOrdering || item.fixed || item.pinned\">\r\n\r\n <td *ngIf=\"HiddenColumns\">\r\n <input type=\"checkbox\" [class.est-hidden-view]=\"item.fixed\" class=\"est-pointer\" [(ngModel)]=\"item.visible\" name=\"visible{{i}}\" (ngModelChange)=\"columnMetadata_H.updateGlobalColVisCheck();\" />\r\n </td>\r\n <td class=\"est-nowrap drag-visible\" (click)=\"columnMetadata_H.columnClicked(item);\">\r\n <ng-container *ngIf=\"item.template\">\r\n <!-- Padri -->\r\n <span *ngIf=\"item.parentTemplates && item.parentTemplates.length > 0\" class=\"est-fw-bold est-fs-13\">\r\n ( \r\n <ng-container *ngFor=\"let parent of item.parentTemplates; let last=last\">\r\n <ng-container *ngTemplateOutlet=\"parent\"></ng-container>\r\n <span *ngIf=\"!last\"> - </span>\r\n </ng-container>\r\n )\r\n </span>\r\n <!-- Template header originale -->\r\n <ng-container *ngTemplateOutlet=\"item.template\"></ng-container>\r\n </ng-container>\r\n <ng-container *ngIf=\"!item.template\">{{item.description}}</ng-container>\r\n </td>\r\n <!--Filler-->\r\n <td (click)=\"columnMetadata_H.columnClicked(item);\"></td>\r\n <!-- Pinner -->\r\n <td *ngIf=\"DirectivesBased && ColumnsPinnable\"><span *ngIf=\"!item.fixed && item.pinnable\" class=\"fa fa-thumb-tack\" [class.text-success]=\"item.pinned\" (click)=\"columnMetadata_H.pinOrUnpinColumn(item)\"></span></td>\r\n </tr>\r\n </tbody>\r\n </table>\r\n </div>\r\n </div>\r\n <div class=\"modal-footer\">\r\n <button type=\"button\" class=\"btn btn-secondary est-margin-right-10\" (click)=\"lastSelectedItemID = null; changeColumnVisibilityModal.hide();\">{{'Close' | localize : lc}}</button>\r\n <button type=\"button\" [disabled]=\"!TMPColumnsList || TMPColumnsList.length == 0\" class=\"btn btn-primary\" (click)=\"columnMetadata_H.confirmColumnVisibilitySelection() && changeColumnVisibilityModal.hide()\">{{'Confirm' | localize : lc}}</button>\r\n </div>\r\n </div>\r\n </div>\r\n</div>",
|
|
3856
3796
|
styles: [".est-loading-box{height:200px;text-align:center;position:relative;background:#ccc}.est-loading-content{margin:0;position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);font-size:35px}.est-scrollable{max-height:600px;overflow:auto}.est-head-resizer{top:0;right:0;bottom:0;width:7px;position:absolute;cursor:col-resize}.est-head-resizer-internal{top:0;right:0;left:6px;bottom:0;width:1px;position:absolute;background-color:#ccc;height:100%}.est-pointer{cursor:pointer}.est-high-density td,.est-high-density th{padding:0 .2rem}.est-no-selection{-webkit-user-select:none;-moz-user-select:none;-khtml-user-select:none;-ms-user-select:none}.est-hidden-view{visibility:hidden}.est-no-border{border:none!important}.est-nowrap{white-space:nowrap}.est-mt-min-5{margin-top:-5px}.est-white-selected{background-color:#ddd!important}.est-line-through{text-decoration:line-through}.est-no-side-padding{padding-left:0;padding-right:0}.est-no-left-padding,.est-no-right-padding{padding-left:0}.est-col-min{width:1px}.est-margin-bottom-0{margin-bottom:0!important}.est-margin-right-10{margin-right:10px!important}.est-right-9{right:9px!important}.est-table-dotted-menu{padding:0 0 2px!important;color:#999}.est-fs-18{font-size:18px}.est-fs-13,.est-fs-14{font-size:14px}.est-fw-bold{font-weight:700}.est-padding-3{padding:3px!important}.est-page-container{position:relative}.est-bring-to-front-strong{z-index:99999999!important}.est-switch{position:relative;display:inline-block;width:30px;height:17px;margin-bottom:0;margin-right:5px;margin-left:5px}.est-switch input{display:none}.est-slider{cursor:pointer;top:0;left:0;right:0;bottom:0;background-color:#ccc}.est-slider,.est-slider:before{position:absolute;transition:.4s}.est-slider:before{content:\"\";height:13px;width:13px;left:3px;bottom:2px;background-color:#fff}input:checked+.est-slider{background-color:#2196f3}input:focus+.est-slider{box-shadow:0 0 1px #2196f3}input:checked+.est-slider:before{transform:translateX(11px)}.est-slider.round{border-radius:10px}.est-slider.round:before{border-radius:50%}.est-custom-input{width:30px;display:inline;padding:1px;height:20px}.est-row-lvl-1 td:first-child{padding-left:5px}.est-row-lvl-2 td:first-child{padding-left:20px}.est-row-lvl-3 td:first-child{padding-left:35px}.est-row-lvl-4 td:first-child{padding-left:50px}.est-row-lvl-5 td:first-child{padding-left:65px}.est-row-lvl-6 td:first-child{padding-left:80px}.est-row-lvl-7 td:first-child{padding-left:95px}.est-row-lvl-8 td:first-child{padding-left:110px}.est-row-lvl-9 td:first-child{padding-left:125px}.est-row-lvl-10 td:first-child{padding-left:140px}.est-row-lvl-11 td:first-child{padding-left:155px}.est-row-lvl-12 td:first-child{padding-left:170px}.est-row-lvl-13 td:first-child{padding-left:185px}.est-row-lvl-14 td:first-child{padding-left:200px}.est-row-lvl-15 td:first-child{padding-left:215px}.est-row-lvl-16 td:first-child{padding-left:230px}.est-row-lvl-17 td:first-child{padding-left:245px}.est-row-lvl-18 td:first-child{padding-left:260px}.est-row-lvl-19 td:first-child{padding-left:275px}.est-row-lvl-20 td:first-child{padding-left:290px}.est-row-lvl-21 td:first-child{padding-left:305px}.est-row-lvl-22 td:first-child{padding-left:320px}.est-row-lvl-23 td:first-child{padding-left:335px}.est-row-lvl-24 td:first-child{padding-left:350px}.est-row-lvl-25 td:first-child{padding-left:365px}.est-row-lvl-26 td:first-child{padding-left:380px}.est-row-lvl-27 td:first-child{padding-left:395px}.est-row-lvl-28 td:first-child{padding-left:410px}.est-row-lvl-29 td:first-child{padding-left:425px}.est-row-lvl-30 td:first-child{padding-left:440px}.est-row-lvl-31 td:first-child{padding-left:455px}.est-row-lvl-32 td:first-child{padding-left:470px}.est-row-lvl-33 td:first-child{padding-left:485px}.est-row-lvl-34 td:first-child{padding-left:500px}.est-row-lvl-35 td:first-child{padding-left:515px}.est-row-lvl-36 td:first-child{padding-left:530px}.est-row-lvl-37 td:first-child{padding-left:545px}.est-row-lvl-38 td:first-child{padding-left:560px}.est-row-lvl-39 td:first-child{padding-left:575px}.est-row-lvl-40 td:first-child{padding-left:590px}.est-row-lvl-41 td:first-child{padding-left:605px}.est-row-lvl-42 td:first-child{padding-left:620px}.est-row-lvl-43 td:first-child{padding-left:635px}.est-row-lvl-44 td:first-child{padding-left:650px}.est-row-lvl-45 td:first-child{padding-left:665px}.est-row-lvl-46 td:first-child{padding-left:680px}.est-row-lvl-47 td:first-child{padding-left:695px}.est-row-lvl-48 td:first-child{padding-left:710px}.est-row-lvl-49 td:first-child{padding-left:725px}.est-row-lvl-50 td:first-child{padding-left:740px}.est-row-lvl-51 td:first-child{padding-left:755px}.est-row-lvl-52 td:first-child{padding-left:770px}.est-row-lvl-53 td:first-child{padding-left:785px}.est-row-lvl-54 td:first-child{padding-left:800px}.est-row-lvl-55 td:first-child{padding-left:815px}.est-row-lvl-56 td:first-child{padding-left:830px}.est-row-lvl-57 td:first-child{padding-left:845px}.est-row-lvl-58 td:first-child{padding-left:860px}.est-row-lvl-59 td:first-child{padding-left:875px}.est-row-lvl-60 td:first-child{padding-left:890px}.est-row-lvl-61 td:first-child{padding-left:905px}.est-row-lvl-62 td:first-child{padding-left:920px}.est-row-lvl-63 td:first-child{padding-left:935px}.est-row-lvl-64 td:first-child{padding-left:950px}.est-row-lvl-65 td:first-child{padding-left:965px}.est-row-lvl-66 td:first-child{padding-left:980px}.est-row-lvl-67 td:first-child{padding-left:995px}.est-row-lvl-68 td:first-child{padding-left:1010px}.est-row-lvl-69 td:first-child{padding-left:1025px}.est-row-lvl-70 td:first-child{padding-left:1040px}.est-row-lvl-71 td:first-child{padding-left:1055px}.est-row-lvl-72 td:first-child{padding-left:1070px}.est-row-lvl-73 td:first-child{padding-left:1085px}.est-row-lvl-74 td:first-child{padding-left:1100px}.est-row-lvl-75 td:first-child{padding-left:1115px}.est-row-lvl-76 td:first-child{padding-left:1130px}.est-row-lvl-77 td:first-child{padding-left:1145px}.est-row-lvl-78 td:first-child{padding-left:1160px}.est-row-lvl-79 td:first-child{padding-left:1175px}.est-row-lvl-80 td:first-child{padding-left:1190px}.est-row-lvl-81 td:first-child{padding-left:1205px}.est-row-lvl-82 td:first-child{padding-left:1220px}.est-row-lvl-83 td:first-child{padding-left:1235px}.est-row-lvl-84 td:first-child{padding-left:1250px}.est-row-lvl-85 td:first-child{padding-left:1265px}.est-row-lvl-86 td:first-child{padding-left:1280px}.est-row-lvl-87 td:first-child{padding-left:1295px}.est-row-lvl-88 td:first-child{padding-left:1310px}.est-row-lvl-89 td:first-child{padding-left:1325px}.est-row-lvl-90 td:first-child{padding-left:1340px}.est-row-lvl-91 td:first-child{padding-left:1355px}.est-row-lvl-92 td:first-child{padding-left:1370px}.est-row-lvl-93 td:first-child{padding-left:1385px}.est-row-lvl-94 td:first-child{padding-left:1400px}.est-row-lvl-95 td:first-child{padding-left:1415px}.est-row-lvl-96 td:first-child{padding-left:1430px}.est-row-lvl-97 td:first-child{padding-left:1445px}.est-row-lvl-98 td:first-child{padding-left:1460px}.est-row-lvl-99 td:first-child{padding-left:1475px}.est-relative{position:relative}.est-top-pager{position:absolute;right:0;top:5px}.est-top-allselect{position:absolute;left:0;top:5px;font-weight:700}.est-padding-10{padding:10px!important}.est-margin-right-50{margin-right:50px}.est-margin-left-50{margin-left:50px}.est-quick-unpin{color:#000;margin-left:8px;font-size:14px;transform:rotate(45deg)}.est-page-sel{color:#000;margin-left:3px;margin-right:3px;padding:0 5px;font-size:inherit;border:none;border-radius:15px}.est-page-next,.est-page-prev{color:#000;font-size:inherit;padding:2px 0 0}.est-pinned-header{background-color:#fff;left:0;top:0;position:sticky;z-index:1;border-bottom:1px solid #dee2e6!important;padding:0!important}.est-simple-border-bottom{border-bottom:1px solid #dee2e6}.est-pinned-internal-header{border-top:0;border-bottom:0 solid #dee2e6}.est-pinned-border{border-right:2px solid #dee2e6!important}.est-cell-padding{padding:.3rem}.est-pinned-body{background-color:#fff;left:0;position:sticky;z-index:1;border-top:1px solid #dee2e6!important;padding:0!important}.est-inline{display:inline!important}.est-inline-block{display:inline-block!important}.est-link{color:#0275d8!important;cursor:pointer;text-decoration:none;display:block}.est-link:hover{color:#23527c!important;cursor:pointer;text-decoration:underline!important}.est-sticky-last-column{right:-1px;position:sticky;z-index:0;background-color:#fff}.est-sticky-last-column-alt{right:-1px;position:sticky;z-index:0;background-color:#f2f2f2}.est-ltab-border{border-left:2px solid #bbb}.est-rtab-border{border-right:2px solid #bbb}.est-cell-group-padding{padding:calc(.3rem + 1px);position:absolute;top:0;left:0;height:100%;width:100%}.est-margin-bottom-10{margin-bottom:10px}.est-text-center{text-align:center}.est-flex{display:flex}.est-rg-sep-flex-right{display:flex;flex-direction:row-reverse;width:100%;margin:-5px}.est-rg-sep-flex-left{display:flex;flex-direction:row;width:100%;margin:-5px}.est-rg-hdr{font-weight:700}.est-rg-agg{font-style:italic}.est-rg{background-color:hsla(0,0%,46.7%,.4666666666666667)!important}.est-rg-sep{font-size:12px;padding-right:20px!important;background-color:hsla(0,0%,73.3%,.7333333333333333)!important}.est-rg-ipp{text-align:left;display:inline-flex;margin-right:25px}.est-rg-page{text-align:right;display:inline-flex;font-size:inherit;padding-top:5px}.est-droplist.cdk-drag-placeholder{opacity:0}.est-droplist.cdk-drag-preview{z-index:999999999!important;opacity:1;box-sizing:border-box;border-radius:4px;background-color:#fff;box-shadow:0 5px 5px -3px rgba(0,0,0,.2),0 8px 10px 1px rgba(0,0,0,.14),0 3px 14px 2px rgba(0,0,0,.12)}.est-droplist.cdk-drag-preview td:not(.drag-visible){visibility:hidden}.est-droplist.cdk-drag-preview td.drag-visible{padding-top:3px}.est-droplist.cdk-drag-animating,.est-droplist.cdk-drop-list-dragging .est-dropbox:not(.cdk-drag-placeholder){transition:transform .25s cubic-bezier(0,0,.2,1)}"]
|
|
3857
3797
|
},] }
|
|
3858
3798
|
];
|
|
@@ -3878,6 +3818,7 @@ EsTableComponent.propDecorators = {
|
|
|
3878
3818
|
secondaryHeaderGroupRef: [{ type: ContentChild, args: ['secondaryHeaderGroup', { static: false },] }],
|
|
3879
3819
|
CornerMenuOptions: [{ type: Input }],
|
|
3880
3820
|
ColumnsResizable: [{ type: Input }],
|
|
3821
|
+
ColumnsPinnable: [{ type: Input }],
|
|
3881
3822
|
AutoUpdate: [{ type: Input }],
|
|
3882
3823
|
UseCustomCells: [{ type: Input }],
|
|
3883
3824
|
MaxHeight: [{ type: Input }],
|
|
@@ -4322,9 +4263,58 @@ EsTableModule.decorators = [
|
|
|
4322
4263
|
},] }
|
|
4323
4264
|
];
|
|
4324
4265
|
|
|
4325
|
-
|
|
4326
|
-
|
|
4327
|
-
|
|
4266
|
+
/** Indica un'opzione cliccabile nel Corner Menù della tabella (il menù richiamabile dai 3 pallini verticli in alto a destra) */
|
|
4267
|
+
class CornerMenuOption {
|
|
4268
|
+
}
|
|
4269
|
+
|
|
4270
|
+
/** Indica operazioni dinamiche generiche che possono essere effettuate per riga. Appaiono come colonne extra sul lato sinistro della tabella */
|
|
4271
|
+
class EsTableOperationDefinition {
|
|
4272
|
+
/**
|
|
4273
|
+
* Costruttore
|
|
4274
|
+
*
|
|
4275
|
+
* @param {string} id Codice dell'operazione
|
|
4276
|
+
* @param {string} title Titolo dell'operazione, da presentare all'utente su hover della cella
|
|
4277
|
+
* @param {string} iconClass Classe che fornisca un iconcina Es. "fa fa-remove"
|
|
4278
|
+
* @param {string} text Eventuale testo presentato nella cella, genericamente va in alternativa a **iconClass**
|
|
4279
|
+
* @param {string} conditionField Indica il campo dell'oggetto sottostante su cui verificare la visibilità o meno di questa icona
|
|
4280
|
+
* @param {string} conditionValue Indica il valore che la proprietà **conditionField** dell'oggetto sottostante deve assumere affinché questa opzione si veda
|
|
4281
|
+
*/
|
|
4282
|
+
constructor(id, title, iconClass, text, conditionField, conditionValue) {
|
|
4283
|
+
this.id = id;
|
|
4284
|
+
this.title = title;
|
|
4285
|
+
this.iconClass = iconClass;
|
|
4286
|
+
this.text = text;
|
|
4287
|
+
this.conditionField = conditionField;
|
|
4288
|
+
this.conditionValue = conditionValue;
|
|
4289
|
+
}
|
|
4290
|
+
}
|
|
4291
|
+
|
|
4292
|
+
/** Classe che definisce un oggetto generico come lista di proprietà-valore */
|
|
4293
|
+
class GenericItem {
|
|
4294
|
+
/** @ignore */
|
|
4295
|
+
constructor() {
|
|
4296
|
+
this._selected = false;
|
|
4297
|
+
this._rowClass = null;
|
|
4298
|
+
this._hash = null;
|
|
4299
|
+
this.properties = {};
|
|
4300
|
+
}
|
|
4301
|
+
}
|
|
4302
|
+
|
|
4303
|
+
/** Classe che rappresenta una colonna di un report */
|
|
4304
|
+
class ReportColumn {
|
|
4305
|
+
}
|
|
4306
|
+
|
|
4307
|
+
/** Classe che identifica un parametro generico per un report */
|
|
4308
|
+
class ReportParam {
|
|
4309
|
+
}
|
|
4310
|
+
|
|
4311
|
+
/** Classe che rappresenta una lista di oggetti generati da un report */
|
|
4312
|
+
class ReportResult {
|
|
4313
|
+
}
|
|
4314
|
+
|
|
4315
|
+
/** Classe che rappresenta i valori delle proprietà di un oggetto Report */
|
|
4316
|
+
class ReportRow {
|
|
4317
|
+
}
|
|
4328
4318
|
|
|
4329
4319
|
/**
|
|
4330
4320
|
* Generated bundle index. Do not edit.
|