@jvsoft/components 1.0.0-alpha.16 → 1.0.0-alpha.17
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/.storybook/tema-demo.css +188 -0
- package/dialog-flotante/README.md +21 -1
- package/fesm2022/jvsoft-components-dialog-flotante.mjs +18 -12
- package/fesm2022/jvsoft-components-dialog-flotante.mjs.map +1 -1
- package/fesm2022/jvsoft-components-lista-arbol.mjs +1 -0
- package/fesm2022/jvsoft-components-lista-arbol.mjs.map +1 -1
- package/fesm2022/jvsoft-components-luces-navidad.mjs +2 -2
- package/fesm2022/jvsoft-components-luces-navidad.mjs.map +1 -1
- package/fesm2022/jvsoft-components-menu.mjs +4 -1
- package/fesm2022/jvsoft-components-menu.mjs.map +1 -1
- package/fesm2022/jvsoft-components-tabla-mantenimiento.mjs +472 -273
- package/fesm2022/jvsoft-components-tabla-mantenimiento.mjs.map +1 -1
- package/lista-arbol/README.md +1 -1
- package/package.json +2 -2
- package/src/styles/base-jvsoft-components.css +4 -5
- package/tabla-mantenimiento/README.md +204 -0
- package/types/jvsoft-components-dialog-flotante.d.ts +2 -0
- package/types/jvsoft-components-lista-arbol.d.ts +2 -1
- package/types/jvsoft-components-menu.d.ts +1 -0
- package/types/jvsoft-components-tabla-mantenimiento.d.ts +151 -9
|
@@ -4,7 +4,7 @@ import * as i1 from '@angular/common';
|
|
|
4
4
|
import { CommonModule, DecimalPipe } from '@angular/common';
|
|
5
5
|
import * as i0 from '@angular/core';
|
|
6
6
|
import { EventEmitter, HostListener, Output, Input, Directive, ViewChild, Optional, Component, inject, Pipe, NgModule, ContentChildren, ViewChildren, Injectable, DestroyRef, input, signal, ElementRef, HostBinding } from '@angular/core';
|
|
7
|
-
import * as
|
|
7
|
+
import * as i4$2 from '@angular/forms';
|
|
8
8
|
import { Validators, FormControl, FormGroup, ReactiveFormsModule, FormsModule } from '@angular/forms';
|
|
9
9
|
import * as i14 from '@angular/material/badge';
|
|
10
10
|
import { MatBadgeModule } from '@angular/material/badge';
|
|
@@ -23,12 +23,12 @@ import { MatPaginatorModule, MatPaginator, MAT_PAGINATOR_DEFAULT_OPTIONS } from
|
|
|
23
23
|
import * as i3 from '@angular/material/sort';
|
|
24
24
|
import { MatSortModule, MatSort } from '@angular/material/sort';
|
|
25
25
|
import * as i2 from '@angular/material/table';
|
|
26
|
-
import { MatColumnDef, MatTable, MatTableModule, MatTableDataSource,
|
|
26
|
+
import { MatColumnDef, MatTable, MatTableModule, MatTableDataSource, MatRow } from '@angular/material/table';
|
|
27
27
|
import * as i4$1 from '@angular/material/tooltip';
|
|
28
28
|
import { MatTooltipModule } from '@angular/material/tooltip';
|
|
29
29
|
import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
|
|
30
30
|
import { addMinutes } from 'date-fns';
|
|
31
|
-
import {
|
|
31
|
+
import { startWith, of, fromEvent } from 'rxjs';
|
|
32
32
|
import { filter, map, take } from 'rxjs/operators';
|
|
33
33
|
import * as i4 from '@jvsoft/utils';
|
|
34
34
|
import { JvsPopoverDirective, JvsPopoverListenerDirective, simpleHash } from '@jvsoft/utils';
|
|
@@ -36,7 +36,7 @@ import * as i1$1 from '@angular/platform-browser';
|
|
|
36
36
|
import { DomSanitizer } from '@angular/platform-browser';
|
|
37
37
|
import * as XLSX from 'xlsx';
|
|
38
38
|
import { Router, ActivatedRoute, NavigationEnd } from '@angular/router';
|
|
39
|
-
import * as
|
|
39
|
+
import * as i1$2 from '@angular/cdk/overlay';
|
|
40
40
|
|
|
41
41
|
function buscarEnArray(coleccion, idBuscar, dato) {
|
|
42
42
|
if (!Array.isArray(coleccion) || coleccion.length === 0)
|
|
@@ -99,7 +99,32 @@ class DataModel {
|
|
|
99
99
|
}
|
|
100
100
|
return campoValor.map(data => row[data]).join(separador);
|
|
101
101
|
}
|
|
102
|
-
|
|
102
|
+
/**
|
|
103
|
+
* Prepara una casilla por fila usando como clave el mismo identificador con el que la celda
|
|
104
|
+
* lee y escribe (`generarId`). `agregarControles` compone la clave de otra manera cuando el
|
|
105
|
+
* campo es un texto o un array sin separador, así que el modelo y la casilla acababan
|
|
106
|
+
* hablando de claves distintas: la casilla salía vacía y la lista de seleccionados
|
|
107
|
+
* devolvía filas que nadie había marcado.
|
|
108
|
+
*
|
|
109
|
+
* Con `limpiar` en false conserva lo ya marcado, que es lo que espera `chkFieldPersistente`
|
|
110
|
+
* cuando la selección tiene que sobrevivir al cambio de página.
|
|
111
|
+
*/
|
|
112
|
+
prepararCasillas(lista, campoValor, separador = '', limpiar = true) {
|
|
113
|
+
if (limpiar) {
|
|
114
|
+
this.modelosChk = {};
|
|
115
|
+
}
|
|
116
|
+
lista.forEach(dat => {
|
|
117
|
+
const clave = this.generarId(dat, campoValor, separador);
|
|
118
|
+
if (!(clave in this.modelosChk)) {
|
|
119
|
+
this.modelosChk[clave] = false;
|
|
120
|
+
}
|
|
121
|
+
});
|
|
122
|
+
}
|
|
123
|
+
/**
|
|
124
|
+
* @deprecated Para las casillas de `tabla-mantenimiento` usar `prepararCasillas`, que
|
|
125
|
+
* compone la clave igual que la celda. Este método compone claves distintas según el tipo
|
|
126
|
+
* de `campoValor`, que es de donde venía el desajuste entre lo marcado y lo informado.
|
|
127
|
+
*/
|
|
103
128
|
agregarControles(lista, idLista, limpiar = true, campoValor = null, campoValorSeparador = '') {
|
|
104
129
|
if (limpiar) {
|
|
105
130
|
this.modelosChk = {};
|
|
@@ -192,20 +217,34 @@ class ForCheckboxModel {
|
|
|
192
217
|
constructor(modeloCheck) {
|
|
193
218
|
this.modeloCheck = modeloCheck;
|
|
194
219
|
}
|
|
220
|
+
/**
|
|
221
|
+
* Cuenta casillas y marcadas en un solo recorrido. La cabecera consulta el estado en cada
|
|
222
|
+
* ciclo de detección de cambios, y antes cada consulta recorría el modelo dos veces
|
|
223
|
+
* creando dos arrays intermedios; con mil filas marcadas eso era trabajo y basura de sobra.
|
|
224
|
+
*/
|
|
225
|
+
contar() {
|
|
226
|
+
let total = 0;
|
|
227
|
+
let activos = 0;
|
|
228
|
+
for (const clave in this.modeloCheck.modelosChk) {
|
|
229
|
+
total++;
|
|
230
|
+
if (this.modeloCheck.modelosChk[clave]) {
|
|
231
|
+
activos++;
|
|
232
|
+
}
|
|
233
|
+
}
|
|
234
|
+
return { total, activos };
|
|
235
|
+
}
|
|
195
236
|
get cantidadActivos() {
|
|
196
|
-
return
|
|
237
|
+
return this.contar().activos;
|
|
197
238
|
}
|
|
198
239
|
get existenActivados() {
|
|
199
|
-
return this.
|
|
240
|
+
return this.contar().activos > 0;
|
|
200
241
|
}
|
|
201
242
|
get todosActivos() {
|
|
202
|
-
const total =
|
|
203
|
-
const activos = this.cantidadActivos;
|
|
243
|
+
const { total, activos } = this.contar();
|
|
204
244
|
return activos > 0 && total === activos;
|
|
205
245
|
}
|
|
206
246
|
get algunosActivos() {
|
|
207
|
-
const total =
|
|
208
|
-
const activos = this.cantidadActivos;
|
|
247
|
+
const { total, activos } = this.contar();
|
|
209
248
|
return activos > 0 && total !== activos;
|
|
210
249
|
}
|
|
211
250
|
establecerTodos(activo) {
|
|
@@ -223,83 +262,75 @@ function tipoValorFuncion(datoParam, defaultValue, ...param) {
|
|
|
223
262
|
return datoParam;
|
|
224
263
|
}
|
|
225
264
|
|
|
265
|
+
/** Campos donde las teclas son del usuario y no de la tabla. */
|
|
266
|
+
const CAMPOS_DE_ENTRADA = ['input', 'textarea', 'select'];
|
|
267
|
+
/**
|
|
268
|
+
* Navegación de filas con el teclado: flechas para moverse, Enter o Espacio para abrir.
|
|
269
|
+
*
|
|
270
|
+
* Se mueve por el DOM, de hermano en hermano, saltando las filas que no llevan id —las de
|
|
271
|
+
* detalle desplegable y el pie—. Antes guardaba una copia de los datos y una lista de todas
|
|
272
|
+
* las filas, que reconstruía consultando la tabla entera **por cada fila** cada vez que los
|
|
273
|
+
* datos cambiaban: con quinientas filas eso eran doscientas cincuenta mil consultas al DOM por
|
|
274
|
+
* recarga. Y esa copia se quedaba vieja en cuanto la tabla volvía a cargar, así que Enter
|
|
275
|
+
* acababa avisando sin registro.
|
|
276
|
+
*/
|
|
226
277
|
class MatRowKeyboardSelectionDirective {
|
|
227
278
|
el;
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
seleccionarSiguiente = new EventEmitter();
|
|
233
|
-
|
|
279
|
+
/** @deprecated Ya no se consulta; queda por el selector y se retirará en una versión mayor. */
|
|
280
|
+
tabla;
|
|
281
|
+
rowModel;
|
|
282
|
+
/** Enter sobre la fila: se avisa con su registro. */
|
|
283
|
+
seleccionarSiguiente = new EventEmitter();
|
|
284
|
+
/** Espacio sobre la fila: la tabla decide si marca la casilla o abre el registro. */
|
|
285
|
+
espacioEnFila = new EventEmitter();
|
|
286
|
+
/** Id del `<tr>` al que se movió el foco con las flechas, para que la tabla lo seleccione. */
|
|
287
|
+
filaEnfocada = new EventEmitter();
|
|
234
288
|
constructor(el) {
|
|
235
289
|
this.el = el;
|
|
236
290
|
}
|
|
237
291
|
ngOnInit() {
|
|
238
|
-
// Asignar tabindex si no está definido
|
|
239
292
|
if (this.el.nativeElement.tabIndex < 0) {
|
|
240
293
|
this.el.nativeElement.tabIndex = 0;
|
|
241
294
|
}
|
|
242
|
-
// Obtener la fuente de datos de la tabla
|
|
243
|
-
const dataSource = this.tabla.dataSource;
|
|
244
|
-
// Suscribirse a los cambios en los datos
|
|
245
|
-
dataSource.connect().pipe(takeUntil(this.unsubscriber$)).subscribe(data => {
|
|
246
|
-
this.renderedData = data;
|
|
247
|
-
this.rows = Array.from(this.getTableRows());
|
|
248
|
-
});
|
|
249
|
-
}
|
|
250
|
-
ngOnDestroy() {
|
|
251
|
-
// Finalizar la suscripción al destruir la directiva
|
|
252
|
-
this.unsubscriber$.next(null);
|
|
253
|
-
this.unsubscriber$.complete();
|
|
254
295
|
}
|
|
255
296
|
onKeydown(event) {
|
|
256
|
-
|
|
257
|
-
|
|
297
|
+
const origen = event.target;
|
|
298
|
+
const etiqueta = origen?.tagName?.toLowerCase() ?? '';
|
|
299
|
+
if (CAMPOS_DE_ENTRADA.includes(etiqueta) || origen?.isContentEditable) {
|
|
258
300
|
event.stopPropagation();
|
|
301
|
+
return;
|
|
259
302
|
}
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
case 'Enter':
|
|
277
|
-
case ' ':
|
|
278
|
-
this.seleccionarSiguiente.next(this.renderedData[currentIndex]);
|
|
279
|
-
event.preventDefault();
|
|
280
|
-
break;
|
|
281
|
-
}
|
|
282
|
-
// Enfocar la nueva fila seleccionada
|
|
283
|
-
if (newRow) {
|
|
284
|
-
newRow.classList.add('estaFocus');
|
|
285
|
-
newRow.focus();
|
|
286
|
-
}
|
|
303
|
+
switch (event.key) {
|
|
304
|
+
case 'ArrowDown':
|
|
305
|
+
this.moverFoco('nextElementSibling');
|
|
306
|
+
break;
|
|
307
|
+
case 'ArrowUp':
|
|
308
|
+
this.moverFoco('previousElementSibling');
|
|
309
|
+
break;
|
|
310
|
+
case 'Enter':
|
|
311
|
+
this.seleccionarSiguiente.next(this.rowModel);
|
|
312
|
+
event.preventDefault();
|
|
313
|
+
break;
|
|
314
|
+
case ' ':
|
|
315
|
+
this.espacioEnFila.next(this.rowModel);
|
|
316
|
+
// Sin esto la página baja una pantalla, que es lo que hace el espacio por defecto.
|
|
317
|
+
event.preventDefault();
|
|
318
|
+
break;
|
|
287
319
|
}
|
|
288
320
|
}
|
|
289
|
-
|
|
290
|
-
let
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
return el.querySelectorAll('mat-row, tr[mat-row]');
|
|
321
|
+
moverFoco(direccion) {
|
|
322
|
+
let hermano = this.el.nativeElement[direccion];
|
|
323
|
+
while (hermano) {
|
|
324
|
+
if (hermano.matches('tr[mat-row][id], mat-row[id]')) {
|
|
325
|
+
hermano.focus();
|
|
326
|
+
this.filaEnfocada.emit(hermano.id);
|
|
327
|
+
return;
|
|
297
328
|
}
|
|
329
|
+
hermano = hermano[direccion];
|
|
298
330
|
}
|
|
299
|
-
return undefined;
|
|
300
331
|
}
|
|
301
332
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.18", ngImport: i0, type: MatRowKeyboardSelectionDirective, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive });
|
|
302
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.18", type: MatRowKeyboardSelectionDirective, isStandalone: true, selector: "[matRowKeyboardSelection]", inputs: { tabla: ["matRowKeyboardSelection", "tabla"], rowModel: "rowModel" }, outputs: { seleccionarSiguiente: "seleccionarSiguiente" }, host: { listeners: { "keydown": "onKeydown($event)" } }, ngImport: i0 });
|
|
333
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.18", type: MatRowKeyboardSelectionDirective, isStandalone: true, selector: "[matRowKeyboardSelection]", inputs: { tabla: ["matRowKeyboardSelection", "tabla"], rowModel: "rowModel" }, outputs: { seleccionarSiguiente: "seleccionarSiguiente", espacioEnFila: "espacioEnFila", filaEnfocada: "filaEnfocada" }, host: { listeners: { "keydown": "onKeydown($event)" } }, ngImport: i0 });
|
|
303
334
|
}
|
|
304
335
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.18", ngImport: i0, type: MatRowKeyboardSelectionDirective, decorators: [{
|
|
305
336
|
type: Directive,
|
|
@@ -313,6 +344,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.18", ngImpo
|
|
|
313
344
|
type: Input
|
|
314
345
|
}], seleccionarSiguiente: [{
|
|
315
346
|
type: Output
|
|
347
|
+
}], espacioEnFila: [{
|
|
348
|
+
type: Output
|
|
349
|
+
}], filaEnfocada: [{
|
|
350
|
+
type: Output
|
|
316
351
|
}], onKeydown: [{
|
|
317
352
|
type: HostListener,
|
|
318
353
|
args: ['keydown', ['$event']]
|
|
@@ -681,6 +716,10 @@ class TablaMantenimientoColumnDefsComponent {
|
|
|
681
716
|
nombreColeccion;
|
|
682
717
|
colDetalle;
|
|
683
718
|
chkLista; // = new DataModel();
|
|
719
|
+
/** Si la fila está desplegada. Lo resuelve la tabla, que es donde vive ese estado. */
|
|
720
|
+
estaExpandida = () => false;
|
|
721
|
+
/** Pulsaron el botón de expandir: la tabla decide. */
|
|
722
|
+
alternarExpansion = new EventEmitter();
|
|
684
723
|
chkListaChange = new EventEmitter();
|
|
685
724
|
columnDefLocales;
|
|
686
725
|
columnDefEnSubComponentes;
|
|
@@ -703,7 +742,7 @@ class TablaMantenimientoColumnDefsComponent {
|
|
|
703
742
|
return column.property;
|
|
704
743
|
}
|
|
705
744
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.18", ngImport: i0, type: TablaMantenimientoColumnDefsComponent, deps: [{ token: i2.MatTable, optional: true }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
706
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.18", type: TablaMantenimientoColumnDefsComponent, isStandalone: true, selector: "jvs-tabla-mantenimiento-column-defs", inputs: { objThis: "objThis", nombreColeccion: "nombreColeccion", colDetalle: "colDetalle", chkLista: "chkLista" }, outputs: { chkListaChange: "chkListaChange" }, queries: [{ propertyName: "columnDefEnSubComponentes", predicate: MatColumnDef, descendants: true }], viewQueries: [{ propertyName: "columnDefLocales", predicate: MatColumnDef, descendants: true }], ngImport: i0, template: "<ng-content></ng-content>\n\n\n\n@for (column of colDetalle; track trackByProperty($index, column)) {\n @if (column.type === 'expandir') {\n <ng-container [matColumnDef]=\"column.property\">\n <th *matHeaderCellDef class=\"w-4\" mat-header-cell> <span [innerHTML]=\"column.label ?? ''\">{{ column.label }} </span></th>\n <td *matCellDef=\"let row\" class=\"w-4 text-center\" mat-cell>\n @if (column.click) {\n <button type=\"button\" class=\"boton-circular text-primary-contrast bg-primary mat-elevation-z2\" matRipple\n (click)=\"column.click(row);
|
|
745
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.18", type: TablaMantenimientoColumnDefsComponent, isStandalone: true, selector: "jvs-tabla-mantenimiento-column-defs", inputs: { objThis: "objThis", nombreColeccion: "nombreColeccion", colDetalle: "colDetalle", chkLista: "chkLista", estaExpandida: "estaExpandida" }, outputs: { alternarExpansion: "alternarExpansion", chkListaChange: "chkListaChange" }, queries: [{ propertyName: "columnDefEnSubComponentes", predicate: MatColumnDef, descendants: true }], viewQueries: [{ propertyName: "columnDefLocales", predicate: MatColumnDef, descendants: true }], ngImport: i0, template: "<ng-content></ng-content>\n\n\n\n@for (column of colDetalle; track trackByProperty($index, column)) {\n @if (column.type === 'expandir') {\n <ng-container [matColumnDef]=\"column.property\">\n <th *matHeaderCellDef class=\"w-4\" mat-header-cell> <span [innerHTML]=\"column.label ?? ''\">{{ column.label }} </span></th>\n <td *matCellDef=\"let row\" class=\"w-4 text-center\" mat-cell>\n @if (column.click) {\n <button type=\"button\" class=\"boton-circular text-primary-contrast bg-primary mat-elevation-z2\" matRipple\n (click)=\"column.click(row); alternarExpansion.emit(row); $event.stopPropagation()\"\n matTooltip=\"Expandir / Contraer\">\n <mat-icon class=\"icon-xs\" [svgIcon]=\"(estaExpandida(row) ? 'roundExpandLess' : 'roundExpandMore')\"></mat-icon>\n </button>\n }\n @if (!column.click) {\n <button type=\"button\" class=\"boton-circular text-primary-contrast bg-primary mat-elevation-z2\" matRipple\n (click)=\"alternarExpansion.emit(row); $event.stopPropagation()\"\n matTooltip=\"Expandir / Contraer\">\n <mat-icon class=\"icon-xs\" [svgIcon]=\"(estaExpandida(row) ? 'roundExpandLess' : 'roundExpandMore')\"></mat-icon>\n </button>\n }\n </td>\n <td *matFooterCellDef [ngClass]=\"column.cssFooterClasses\" mat-footer-cell></td>\n </ng-container>\n }\n @if (column.type === 'checkbox') {\n <ng-container [matColumnDef]=\"column.property\">\n <th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"w-4 text-center\" mat-header-cell>\n @if (chkLista) {\n <mat-checkbox\n (click)=\"$event.stopPropagation()\"\n (change)=\"chkLista.checkbox.establecerTodos($event.checked)\"\n [indeterminate]=\"chkLista.checkbox.algunosActivos\"\n [checked]=\"chkLista.checkbox.todosActivos\"\n ></mat-checkbox>\n }\n </th>\n <td *matCellDef=\"let row\" class=\"w-4 text-center\" mat-cell>\n @if (chkLista) {\n <mat-checkbox\n (click)=\"$event.stopPropagation()\"\n [(ngModel)]=\"chkLista.modelosChk[chkLista.generarId(row, (column.chkField ?? column.property), column.chkFieldSeparador)]\"\n [ngModelOptions]=\"{standalone: true}\"\n ></mat-checkbox>\n }\n </td>\n <td *matFooterCellDef [ngClass]=\"column.cssFooterClasses\" mat-footer-cell></td>\n </ng-container>\n }\n @if (column.type === 'estiloEstablecido') {\n <ng-container [matColumnDef]=\"column.property\">\n <th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"uppercase text-center\" mat-header-cell\n mat-sort-header\n [disabled]=\"column.sort === false\">\n <span [innerHTML]=\"column.label ?? ''\">{{ column.label }} </span>\n <span class=\"text-red-900 font-bold bg-white\">CONFIGURAR ESTILO ESTABLECIDO</span>\n </th>\n <td *matCellDef=\"let row\" [ngClass]=\"column.cssClasses\" mat-cell>\n {{ column.property }}\n <span class=\"text-red-900 font-bold bg-white\">CONFIGURAR ESTILO ESTABLECIDO</span>\n </td>\n <th *matFooterCellDef [ngClass]=\"column.cssFooterClasses\" style=\"height: unset !important;\" mat-footer-cell\n [innerHTML]=\"column.transformarFooter ? column.transformarFooter() : ''\">\n </th>\n </ng-container>\n }\n @if (column.type == 'text') {\n <jvs-column-type-text [column]=\"column\"></jvs-column-type-text>\n }\n @if (column.type == 'money') {\n <jvs-column-type-money [column]=\"column\"></jvs-column-type-money>\n }\n @if (column.type == 'number') {\n <jvs-column-type-number [column]=\"column\"></jvs-column-type-number>\n }\n @if (column.type == 'date') {\n <jvs-column-type-date [column]=\"column\"></jvs-column-type-date>\n }\n @if (column.type == 'icons') {\n <jvs-column-type-icons [column]=\"column\"></jvs-column-type-icons>\n }\n @if (column.type == 'yes_no') {\n <jvs-column-type-sino [column]=\"column\"></jvs-column-type-sino>\n }\n @if (column.type == 'progress') {\n <jvs-column-type-progressbar [column]=\"column\"></jvs-column-type-progressbar>\n }\n}\n", styles: [""], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "ngmodule", type: MatCheckboxModule }, { kind: "component", type: i3$1.MatCheckbox, selector: "mat-checkbox", inputs: ["aria-label", "aria-labelledby", "aria-describedby", "aria-expanded", "aria-controls", "aria-owns", "id", "required", "labelPosition", "name", "value", "disableRipple", "tabIndex", "color", "disabledInteractive", "checked", "disabled", "indeterminate"], outputs: ["change", "indeterminateChange"], exportAs: ["matCheckbox"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i5.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatRippleModule }, { kind: "directive", type: i5$1.MatRipple, selector: "[mat-ripple], [matRipple]", inputs: ["matRippleColor", "matRippleUnbounded", "matRippleCentered", "matRippleRadius", "matRippleAnimation", "matRippleDisabled", "matRippleTrigger"], exportAs: ["matRipple"] }, { kind: "ngmodule", type: MatSortModule }, { kind: "component", type: i3.MatSortHeader, selector: "[mat-sort-header]", inputs: ["mat-sort-header", "arrowPosition", "start", "disabled", "sortActionDescription", "disableClear"], exportAs: ["matSortHeader"] }, { kind: "ngmodule", type: MatTableModule }, { kind: "directive", type: i2.MatHeaderCellDef, selector: "[matHeaderCellDef]" }, { kind: "directive", type: i2.MatColumnDef, selector: "[matColumnDef]", inputs: ["matColumnDef"] }, { kind: "directive", type: i2.MatCellDef, selector: "[matCellDef]" }, { kind: "directive", type: i2.MatFooterCellDef, selector: "[matFooterCellDef]" }, { kind: "directive", type: i2.MatHeaderCell, selector: "mat-header-cell, th[mat-header-cell]" }, { kind: "directive", type: i2.MatCell, selector: "mat-cell, td[mat-cell]" }, { kind: "directive", type: i2.MatFooterCell, selector: "mat-footer-cell, td[mat-footer-cell]" }, { kind: "ngmodule", type: MatTooltipModule }, { kind: "directive", type: i4$1.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i4$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i4$2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: ColumnTypeModule }, { kind: "component", type: ColumnTypeTextComponent, selector: "jvs-column-type-text", inputs: ["column"] }, { kind: "component", type: ColumnTypeMoneyComponent, selector: "jvs-column-type-money", inputs: ["column"] }, { kind: "component", type: ColumnTypeNumberComponent, selector: "jvs-column-type-number", inputs: ["column"] }, { kind: "component", type: ColumnTypeDateComponent, selector: "jvs-column-type-date", inputs: ["column"] }, { kind: "component", type: ColumnTypeIconsComponent, selector: "jvs-column-type-icons", inputs: ["column"] }, { kind: "component", type: ColumnTypeSinoComponent, selector: "jvs-column-type-sino", inputs: ["column"] }, { kind: "component", type: ColumnTypeProgressbarComponent, selector: "jvs-column-type-progressbar", inputs: ["column"] }] });
|
|
707
746
|
}
|
|
708
747
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.18", ngImport: i0, type: TablaMantenimientoColumnDefsComponent, decorators: [{
|
|
709
748
|
type: Component,
|
|
@@ -718,7 +757,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.18", ngImpo
|
|
|
718
757
|
ReactiveFormsModule,
|
|
719
758
|
FormsModule,
|
|
720
759
|
ColumnTypeModule,
|
|
721
|
-
], template: "<ng-content></ng-content>\n\n\n\n@for (column of colDetalle; track trackByProperty($index, column)) {\n @if (column.type === 'expandir') {\n <ng-container [matColumnDef]=\"column.property\">\n <th *matHeaderCellDef class=\"w-4\" mat-header-cell> <span [innerHTML]=\"column.label ?? ''\">{{ column.label }} </span></th>\n <td *matCellDef=\"let row\" class=\"w-4 text-center\" mat-cell>\n @if (column.click) {\n <button type=\"button\" class=\"boton-circular text-primary-contrast bg-primary mat-elevation-z2\" matRipple\n (click)=\"column.click(row);
|
|
760
|
+
], template: "<ng-content></ng-content>\n\n\n\n@for (column of colDetalle; track trackByProperty($index, column)) {\n @if (column.type === 'expandir') {\n <ng-container [matColumnDef]=\"column.property\">\n <th *matHeaderCellDef class=\"w-4\" mat-header-cell> <span [innerHTML]=\"column.label ?? ''\">{{ column.label }} </span></th>\n <td *matCellDef=\"let row\" class=\"w-4 text-center\" mat-cell>\n @if (column.click) {\n <button type=\"button\" class=\"boton-circular text-primary-contrast bg-primary mat-elevation-z2\" matRipple\n (click)=\"column.click(row); alternarExpansion.emit(row); $event.stopPropagation()\"\n matTooltip=\"Expandir / Contraer\">\n <mat-icon class=\"icon-xs\" [svgIcon]=\"(estaExpandida(row) ? 'roundExpandLess' : 'roundExpandMore')\"></mat-icon>\n </button>\n }\n @if (!column.click) {\n <button type=\"button\" class=\"boton-circular text-primary-contrast bg-primary mat-elevation-z2\" matRipple\n (click)=\"alternarExpansion.emit(row); $event.stopPropagation()\"\n matTooltip=\"Expandir / Contraer\">\n <mat-icon class=\"icon-xs\" [svgIcon]=\"(estaExpandida(row) ? 'roundExpandLess' : 'roundExpandMore')\"></mat-icon>\n </button>\n }\n </td>\n <td *matFooterCellDef [ngClass]=\"column.cssFooterClasses\" mat-footer-cell></td>\n </ng-container>\n }\n @if (column.type === 'checkbox') {\n <ng-container [matColumnDef]=\"column.property\">\n <th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"w-4 text-center\" mat-header-cell>\n @if (chkLista) {\n <mat-checkbox\n (click)=\"$event.stopPropagation()\"\n (change)=\"chkLista.checkbox.establecerTodos($event.checked)\"\n [indeterminate]=\"chkLista.checkbox.algunosActivos\"\n [checked]=\"chkLista.checkbox.todosActivos\"\n ></mat-checkbox>\n }\n </th>\n <td *matCellDef=\"let row\" class=\"w-4 text-center\" mat-cell>\n @if (chkLista) {\n <mat-checkbox\n (click)=\"$event.stopPropagation()\"\n [(ngModel)]=\"chkLista.modelosChk[chkLista.generarId(row, (column.chkField ?? column.property), column.chkFieldSeparador)]\"\n [ngModelOptions]=\"{standalone: true}\"\n ></mat-checkbox>\n }\n </td>\n <td *matFooterCellDef [ngClass]=\"column.cssFooterClasses\" mat-footer-cell></td>\n </ng-container>\n }\n @if (column.type === 'estiloEstablecido') {\n <ng-container [matColumnDef]=\"column.property\">\n <th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"uppercase text-center\" mat-header-cell\n mat-sort-header\n [disabled]=\"column.sort === false\">\n <span [innerHTML]=\"column.label ?? ''\">{{ column.label }} </span>\n <span class=\"text-red-900 font-bold bg-white\">CONFIGURAR ESTILO ESTABLECIDO</span>\n </th>\n <td *matCellDef=\"let row\" [ngClass]=\"column.cssClasses\" mat-cell>\n {{ column.property }}\n <span class=\"text-red-900 font-bold bg-white\">CONFIGURAR ESTILO ESTABLECIDO</span>\n </td>\n <th *matFooterCellDef [ngClass]=\"column.cssFooterClasses\" style=\"height: unset !important;\" mat-footer-cell\n [innerHTML]=\"column.transformarFooter ? column.transformarFooter() : ''\">\n </th>\n </ng-container>\n }\n @if (column.type == 'text') {\n <jvs-column-type-text [column]=\"column\"></jvs-column-type-text>\n }\n @if (column.type == 'money') {\n <jvs-column-type-money [column]=\"column\"></jvs-column-type-money>\n }\n @if (column.type == 'number') {\n <jvs-column-type-number [column]=\"column\"></jvs-column-type-number>\n }\n @if (column.type == 'date') {\n <jvs-column-type-date [column]=\"column\"></jvs-column-type-date>\n }\n @if (column.type == 'icons') {\n <jvs-column-type-icons [column]=\"column\"></jvs-column-type-icons>\n }\n @if (column.type == 'yes_no') {\n <jvs-column-type-sino [column]=\"column\"></jvs-column-type-sino>\n }\n @if (column.type == 'progress') {\n <jvs-column-type-progressbar [column]=\"column\"></jvs-column-type-progressbar>\n }\n}\n" }]
|
|
722
761
|
}], ctorParameters: () => [{ type: i2.MatTable, decorators: [{
|
|
723
762
|
type: Optional
|
|
724
763
|
}] }, { type: i0.ChangeDetectorRef }], propDecorators: { objThis: [{
|
|
@@ -729,6 +768,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.18", ngImpo
|
|
|
729
768
|
type: Input
|
|
730
769
|
}], chkLista: [{
|
|
731
770
|
type: Input
|
|
771
|
+
}], estaExpandida: [{
|
|
772
|
+
type: Input
|
|
773
|
+
}], alternarExpansion: [{
|
|
774
|
+
type: Output
|
|
732
775
|
}], chkListaChange: [{
|
|
733
776
|
type: Output
|
|
734
777
|
}], columnDefLocales: [{
|
|
@@ -796,7 +839,6 @@ const getFileName = (name) => {
|
|
|
796
839
|
class TableUtil {
|
|
797
840
|
static exportTableToExcelV2(targetTableElm, name) {
|
|
798
841
|
const { sheetName, fileName } = getFileName(name);
|
|
799
|
-
console.log(targetTableElm);
|
|
800
842
|
const wb = XLSX.utils.table_to_book(targetTableElm, {
|
|
801
843
|
sheet: sheetName
|
|
802
844
|
});
|
|
@@ -805,7 +847,6 @@ class TableUtil {
|
|
|
805
847
|
static exportTableToExcel(tableId, name) {
|
|
806
848
|
const { sheetName, fileName } = getFileName(name);
|
|
807
849
|
const targetTableElm = document.getElementById(tableId);
|
|
808
|
-
console.log(targetTableElm);
|
|
809
850
|
const wb = XLSX.utils.table_to_book(targetTableElm, {
|
|
810
851
|
sheet: sheetName
|
|
811
852
|
});
|
|
@@ -870,7 +911,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.18", ngImpo
|
|
|
870
911
|
}] });
|
|
871
912
|
|
|
872
913
|
class TablaMantenimientoComponent {
|
|
873
|
-
fb;
|
|
874
914
|
overlay;
|
|
875
915
|
viewContainerRef;
|
|
876
916
|
tablaMantenimientoService;
|
|
@@ -900,6 +940,7 @@ class TablaMantenimientoComponent {
|
|
|
900
940
|
filaExtraHeader;
|
|
901
941
|
filaFooter = false;
|
|
902
942
|
botonesCRUD = 'CUD';
|
|
943
|
+
/** @deprecated El doble clic ya llega por `opcionSelecionada` con tipo `seleccionar`. */
|
|
903
944
|
dblclickItem = new EventEmitter();
|
|
904
945
|
objBotonesCRUD = [
|
|
905
946
|
{ tipo: 'nuevo', sinCondicion: true },
|
|
@@ -907,13 +948,17 @@ class TablaMantenimientoComponent {
|
|
|
907
948
|
{ tipo: 'eliminar' },
|
|
908
949
|
];
|
|
909
950
|
classSeleccionado = ['elemento-seleccionado', /*'!bg-primary-activo','text-primary-contrast', */ 'mat-elevation-z8', /*'dark:!bg-primary-dark-activo',*/ 'border-y-2 border-primary-contrast', 'font-bold', 'text-2xl'];
|
|
910
|
-
// @Input() classAnulado = ['line-through', 'text-red', 'italic'];
|
|
911
951
|
classAnulado = ['elemento-anulado', /*'line-through', */ 'text-red-900', 'bg-red-200'];
|
|
912
952
|
campoAnulado = null;
|
|
913
953
|
campoAnuladoMensaje = null;
|
|
914
954
|
opcionSelecionada = new EventEmitter();
|
|
915
955
|
opcBusqueda = new EventEmitter();
|
|
916
956
|
accionRecargar = new EventEmitter();
|
|
957
|
+
/**
|
|
958
|
+
* Registro seleccionado. El nombre viene de cuando se pensó guardarlo en un
|
|
959
|
+
* `SelectionModel` del CDK; lo que viaja es la fila, y así lo usan las apps con el enlace
|
|
960
|
+
* de dos sentidos `[(selectionModel)]`.
|
|
961
|
+
*/
|
|
917
962
|
set selectionModel(val) {
|
|
918
963
|
this.objSeleccionado = val;
|
|
919
964
|
}
|
|
@@ -928,6 +973,10 @@ class TablaMantenimientoComponent {
|
|
|
928
973
|
// MIO
|
|
929
974
|
pageSize = 25;
|
|
930
975
|
pageSizeOptions = [5, 10, 25, 50, 100, 500, 1000];
|
|
976
|
+
/**
|
|
977
|
+
* @deprecated Entrega la instancia interna del `MatTableDataSource`, que ahora se reutiliza
|
|
978
|
+
* entre cargas: quien la guarde estará tocando el estado de la tabla por la espalda.
|
|
979
|
+
*/
|
|
931
980
|
dataSourceChange = new EventEmitter();
|
|
932
981
|
resultados = new EventEmitter();
|
|
933
982
|
dataSource = new MatTableDataSource(); // or whatever type of datasource you have
|
|
@@ -945,10 +994,22 @@ class TablaMantenimientoComponent {
|
|
|
945
994
|
};
|
|
946
995
|
// All that's left is to add them to the table ourselves:
|
|
947
996
|
ignorarDerechos = false;
|
|
948
|
-
|
|
997
|
+
derechosDelPadre = false;
|
|
998
|
+
_derechosActuales = null;
|
|
999
|
+
get derechosActuales() {
|
|
1000
|
+
return this._derechosActuales;
|
|
1001
|
+
}
|
|
1002
|
+
/**
|
|
1003
|
+
* Permisos con los que se habilitan los botones. Normalmente se leen solos del `data` de la
|
|
1004
|
+
* ruta, pero si la pantalla los pasa a mano, mandan los suyos: antes cada navegación
|
|
1005
|
+
* sobrescribía lo que el padre acababa de poner.
|
|
1006
|
+
*/
|
|
1007
|
+
set derechosActuales(val) {
|
|
1008
|
+
this.derechosDelPadre = true;
|
|
1009
|
+
this._derechosActuales = val;
|
|
1010
|
+
}
|
|
949
1011
|
// listaCRUD: BotonMantenimiento[] = [];
|
|
950
1012
|
rows;
|
|
951
|
-
rowFooter;
|
|
952
1013
|
mouseEvent$;
|
|
953
1014
|
overlayRef;
|
|
954
1015
|
userMenu;
|
|
@@ -961,13 +1022,11 @@ class TablaMantenimientoComponent {
|
|
|
961
1022
|
chkLista = new DataModel();
|
|
962
1023
|
bDireccionOrden = signal(1, ...(ngDevMode ? [{ debugName: "bDireccionOrden" }] : /* istanbul ignore next */ []));
|
|
963
1024
|
mostrarBotonOrden = input(false, ...(ngDevMode ? [{ debugName: "mostrarBotonOrden" }] : /* istanbul ignore next */ []));
|
|
964
|
-
constructor(
|
|
965
|
-
this.fb = fb;
|
|
1025
|
+
constructor(overlay, viewContainerRef, tablaMantenimientoService, cdRef) {
|
|
966
1026
|
this.overlay = overlay;
|
|
967
1027
|
this.viewContainerRef = viewContainerRef;
|
|
968
1028
|
this.tablaMantenimientoService = tablaMantenimientoService;
|
|
969
1029
|
this.cdRef = cdRef;
|
|
970
|
-
// this._seleccionado[this.nombreColeccion] = null;
|
|
971
1030
|
}
|
|
972
1031
|
busquedaTipo = input('simple', { ...(ngDevMode ? { debugName: "busquedaTipo" } : /* istanbul ignore next */ {}), alias: 'ctrlBusqueda',
|
|
973
1032
|
transform: (val) => {
|
|
@@ -975,7 +1034,6 @@ class TablaMantenimientoComponent {
|
|
|
975
1034
|
return 'simple';
|
|
976
1035
|
return val;
|
|
977
1036
|
} });
|
|
978
|
-
// @Input() leyenda;
|
|
979
1037
|
_leyenda = undefined;
|
|
980
1038
|
get leyenda() {
|
|
981
1039
|
return this._leyenda;
|
|
@@ -988,88 +1046,64 @@ class TablaMantenimientoComponent {
|
|
|
988
1046
|
this._leyenda = val;
|
|
989
1047
|
}
|
|
990
1048
|
}
|
|
991
|
-
// @Input() idTabla: string[];
|
|
992
1049
|
_idTabla = [];
|
|
993
1050
|
get idTabla() {
|
|
994
1051
|
return this._idTabla;
|
|
995
1052
|
}
|
|
996
1053
|
set idTabla(val) {
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
else {
|
|
1001
|
-
this._idTabla.push(val);
|
|
1002
|
-
}
|
|
1054
|
+
// Un solo campo también reemplaza: antes se acumulaba sobre lo anterior, así que al
|
|
1055
|
+
// cambiar el valor la fila pasaba a identificarse por dos campos y se perdía la selección.
|
|
1056
|
+
this._idTabla = Array.isArray(val) ? val : [val];
|
|
1003
1057
|
}
|
|
1004
1058
|
_columnasTabla = [];
|
|
1005
1059
|
get columnasTabla() {
|
|
1006
1060
|
return this._columnasTabla ?? [];
|
|
1007
1061
|
}
|
|
1062
|
+
/**
|
|
1063
|
+
* Columnas a pintar, mezcladas con el catálogo del servicio.
|
|
1064
|
+
*
|
|
1065
|
+
* Devuelve una lista nueva con copias: antes transformaba el array del consumidor en su
|
|
1066
|
+
* sitio, así que su definición quedaba con el tipo cambiado (`estado` pasa a `icons`) y las
|
|
1067
|
+
* columnas `custom` marcadas como no visibles. Reutilizar esa misma definición en otra
|
|
1068
|
+
* tabla dejaba la columna `custom` oculta para siempre, porque la segunda pasada guardaba
|
|
1069
|
+
* como visibilidad original el `false` que había dejado la primera.
|
|
1070
|
+
*/
|
|
1008
1071
|
set columnasTabla(val) {
|
|
1009
|
-
const
|
|
1010
|
-
|
|
1011
|
-
|
|
1012
|
-
|
|
1013
|
-
|
|
1014
|
-
|
|
1015
|
-
|
|
1016
|
-
|
|
1017
|
-
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
|
|
1022
|
-
|
|
1023
|
-
|
|
1024
|
-
|
|
1025
|
-
|
|
1026
|
-
|
|
1027
|
-
|
|
1028
|
-
|
|
1029
|
-
|
|
1030
|
-
|
|
1031
|
-
|
|
1032
|
-
|
|
1033
|
-
|
|
1034
|
-
|
|
1035
|
-
|
|
1036
|
-
|
|
1037
|
-
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
// esVisible: (row) => row['iCredDepenTareaEstado'] == 1
|
|
1044
|
-
// },
|
|
1045
|
-
]
|
|
1046
|
-
},
|
|
1047
|
-
};
|
|
1048
|
-
if (listaInicial[idx].estados) {
|
|
1049
|
-
listaInicial[idx].estados.forEach((estado) => {
|
|
1050
|
-
if (Array.isArray(mutar.iconsDef.items)) {
|
|
1051
|
-
mutar.iconsDef.items.push({
|
|
1052
|
-
icon: estado.icon, contentCss: estado.cssClasses,
|
|
1053
|
-
esVisible: (row) => row[listaInicial[idx].property] == estado.estado,
|
|
1054
|
-
});
|
|
1055
|
-
}
|
|
1056
|
-
});
|
|
1057
|
-
}
|
|
1058
|
-
listaInicial[idx] = mutar;
|
|
1059
|
-
}
|
|
1060
|
-
if (btnActual.type == 'custom') {
|
|
1061
|
-
listaInicial[idx].datosExtra = {
|
|
1062
|
-
...listaInicial[idx].datosExtra,
|
|
1063
|
-
tabla_mantenimiento_config_visibleAlias: listaInicial[idx].visible == undefined ? true : listaInicial[idx].visible,
|
|
1064
|
-
};
|
|
1065
|
-
listaInicial[idx].visible = false;
|
|
1066
|
-
}
|
|
1067
|
-
});
|
|
1068
|
-
return listaInicial;
|
|
1069
|
-
};
|
|
1070
|
-
this._columnasTabla = val ? reemplazarConTemplate(val) : [];
|
|
1072
|
+
const conPlantilla = (listaInicial = []) => listaInicial.map(original => {
|
|
1073
|
+
const enPlantilla = buscarEnArray(this.templateColumnasTabla, 'property', original.property);
|
|
1074
|
+
let columna = enPlantilla ? { ...enPlantilla, ...original } : { ...original };
|
|
1075
|
+
if (columna.type == 'text') {
|
|
1076
|
+
columna.text = { ...(columna.text ?? {}), cssStyle: { ...(columna.text?.cssStyle ?? {}) } };
|
|
1077
|
+
}
|
|
1078
|
+
else if (columna.type == 'estado') {
|
|
1079
|
+
// `estado` es la forma antigua de `icons`: un icono por valor posible.
|
|
1080
|
+
const items = (columna.estados ?? []).map((estado) => ({
|
|
1081
|
+
icon: estado.icon,
|
|
1082
|
+
contentCss: estado.cssClasses,
|
|
1083
|
+
esVisible: (row) => row[columna.property] == estado.estado,
|
|
1084
|
+
}));
|
|
1085
|
+
columna = {
|
|
1086
|
+
...columna,
|
|
1087
|
+
type: 'icons',
|
|
1088
|
+
iconsDef: { soloIcono: true, iconSize: '16px', items },
|
|
1089
|
+
};
|
|
1090
|
+
}
|
|
1091
|
+
if (original.type == 'custom') {
|
|
1092
|
+
// Las `custom` las pinta el consumidor con su plantilla, así que se ocultan
|
|
1093
|
+
// hasta que `ngAfterContentInit` confirme que esa plantilla existe.
|
|
1094
|
+
columna = {
|
|
1095
|
+
...columna,
|
|
1096
|
+
datosExtra: {
|
|
1097
|
+
...(columna.datosExtra ?? {}),
|
|
1098
|
+
tabla_mantenimiento_config_visibleAlias: original.visible === undefined ? true : original.visible,
|
|
1099
|
+
},
|
|
1100
|
+
visible: false,
|
|
1101
|
+
};
|
|
1102
|
+
}
|
|
1103
|
+
return columna;
|
|
1104
|
+
});
|
|
1105
|
+
this._columnasTabla = val ? conPlantilla(val) : [];
|
|
1071
1106
|
}
|
|
1072
|
-
// @Input() botonesMenu: BotonMantenimiento[] = [];
|
|
1073
1107
|
_botonesMenu = {
|
|
1074
1108
|
crud: undefined,
|
|
1075
1109
|
principal: [],
|
|
@@ -1081,22 +1115,36 @@ class TablaMantenimientoComponent {
|
|
|
1081
1115
|
get botonesMenu() {
|
|
1082
1116
|
return this._botonesMenu;
|
|
1083
1117
|
}
|
|
1118
|
+
/**
|
|
1119
|
+
* Los botones que tocan pintar. En solo lectura quedan los marcados con `ignorarReadOnly`,
|
|
1120
|
+
* y de los que tienen submenú quedan sus opciones permitidas.
|
|
1121
|
+
*
|
|
1122
|
+
* Devuelve estructuras nuevas y no toca `botonesMenu`. Antes filtraba sobre el propio
|
|
1123
|
+
* estado, y como la plantilla lo consulta seis veces por ciclo, cada lectura se comía lo
|
|
1124
|
+
* que quedaba: en solo lectura la tabla acababa sin ningún botón, ni siquiera los CRUD.
|
|
1125
|
+
* La condición de los submenús estaba además al revés, así que descartaba justo los
|
|
1126
|
+
* botones cuyas opciones sí estaban permitidas.
|
|
1127
|
+
*/
|
|
1084
1128
|
get botonesMenuFinal() {
|
|
1085
|
-
|
|
1086
|
-
|
|
1087
|
-
|
|
1088
|
-
|
|
1089
|
-
|
|
1090
|
-
|
|
1091
|
-
|
|
1092
|
-
|
|
1129
|
+
if (!this.readOnly) {
|
|
1130
|
+
return this.botonesMenu;
|
|
1131
|
+
}
|
|
1132
|
+
const resultado = {};
|
|
1133
|
+
Object.keys(this.botonesMenu).forEach(seccion => {
|
|
1134
|
+
resultado[seccion] = (this.botonesMenu[seccion] ?? []).reduce((permitidos, boton) => {
|
|
1135
|
+
if (boton.subItems) {
|
|
1136
|
+
const subItems = boton.subItems.filter((subItem) => subItem.ignorarReadOnly === true);
|
|
1137
|
+
if (subItems.length > 0) {
|
|
1138
|
+
permitidos.push({ ...boton, subItems });
|
|
1093
1139
|
}
|
|
1094
|
-
return boton.ignorarReadOnly === true;
|
|
1095
1140
|
}
|
|
1096
|
-
|
|
1097
|
-
|
|
1141
|
+
else if (boton.ignorarReadOnly === true) {
|
|
1142
|
+
permitidos.push(boton);
|
|
1143
|
+
}
|
|
1144
|
+
return permitidos;
|
|
1145
|
+
}, []);
|
|
1098
1146
|
});
|
|
1099
|
-
return
|
|
1147
|
+
return resultado;
|
|
1100
1148
|
}
|
|
1101
1149
|
set botonesMenu(val) {
|
|
1102
1150
|
const reemplazarConTemplate = (listaInicial = []) => listaInicial.map((btnActual) => {
|
|
@@ -1134,24 +1182,42 @@ class TablaMantenimientoComponent {
|
|
|
1134
1182
|
menuTotal = menuTotal.concat(this.botonesMenu.inferior ?? []);
|
|
1135
1183
|
return menuTotal;
|
|
1136
1184
|
}
|
|
1185
|
+
/** Si la columna se ofrece en el menú de columnas. `noMostrar` es el alias antiguo. */
|
|
1186
|
+
esColumnaEnLista(column) {
|
|
1187
|
+
return !tipoValorFuncion(column.noMostrarEnLista ?? column.noMostrar, false);
|
|
1188
|
+
}
|
|
1189
|
+
/** Si la columna se pinta ahora mismo, sin escribir la respuesta dentro de la columna. */
|
|
1190
|
+
esColumnaVisible(column) {
|
|
1191
|
+
const visible = tipoValorFuncion(column.visible, true);
|
|
1192
|
+
if (!visible && column.esVisible != undefined) {
|
|
1193
|
+
return column.esVisible();
|
|
1194
|
+
}
|
|
1195
|
+
return visible;
|
|
1196
|
+
}
|
|
1197
|
+
/**
|
|
1198
|
+
* Columnas que toca pintar. Consultarlo no escribe en las columnas del consumidor: antes
|
|
1199
|
+
* copiaba `noMostrar` a `noMostrarEnLista` y fijaba `visible`, de modo que una columna
|
|
1200
|
+
* declarada con una función dejaba de ser dinámica en cuanto se pintaba la tabla una vez.
|
|
1201
|
+
*
|
|
1202
|
+
* Sigue escribiendo `sort` cuando hay fila extra, porque es el único canal por el que la
|
|
1203
|
+
* definición de columnas se entera de que no debe ofrecer el ordenamiento.
|
|
1204
|
+
*/
|
|
1137
1205
|
get objVisibleColumns() {
|
|
1138
|
-
return this.columnasTabla
|
|
1139
|
-
|
|
1140
|
-
|
|
1141
|
-
|
|
1142
|
-
|
|
1143
|
-
|
|
1144
|
-
|
|
1145
|
-
|
|
1146
|
-
|
|
1147
|
-
|
|
1148
|
-
|
|
1149
|
-
|
|
1150
|
-
|
|
1151
|
-
|
|
1152
|
-
|
|
1153
|
-
return column.visible;
|
|
1154
|
-
});
|
|
1206
|
+
return this.columnasTabla
|
|
1207
|
+
.filter(column => this.esColumnaEnLista(column))
|
|
1208
|
+
.filter(column => this.esColumnaVisible(column));
|
|
1209
|
+
}
|
|
1210
|
+
/**
|
|
1211
|
+
* Columnas que recibe la definición de columnas. Con fila extra desplegable el
|
|
1212
|
+
* ordenamiento se bloquea, y eso se resuelve aquí entregando copias: antes se lograba
|
|
1213
|
+
* escribiendo `sort: false` dentro de la columna del consumidor, que quedaba marcada para
|
|
1214
|
+
* siempre aunque la tabla dejara de usar la fila extra.
|
|
1215
|
+
*/
|
|
1216
|
+
get columnasParaDefinir() {
|
|
1217
|
+
if (!this.filaExtraTemplate) {
|
|
1218
|
+
return this.columnasTabla;
|
|
1219
|
+
}
|
|
1220
|
+
return this.columnasTabla.map(column => ({ ...column, sort: false }));
|
|
1155
1221
|
}
|
|
1156
1222
|
get visibleColumns() {
|
|
1157
1223
|
return this.objVisibleColumns.map(column => column.property);
|
|
@@ -1159,20 +1225,41 @@ class TablaMantenimientoComponent {
|
|
|
1159
1225
|
get tieneCheckbox() {
|
|
1160
1226
|
return this.columnasTabla && this.columnasTabla.length > 0 && this.columnasTabla.find(col => col.type === 'checkbox') || false;
|
|
1161
1227
|
}
|
|
1228
|
+
/**
|
|
1229
|
+
* Última búsqueda del registro seleccionado, guardada para no repetirla. Vale mientras no
|
|
1230
|
+
* cambien ni la selección ni los datos: `classFila` consulta esto una vez por fila y por
|
|
1231
|
+
* ciclo, así que sin memoria una tabla de N filas hacía N búsquedas sobre N registros.
|
|
1232
|
+
*/
|
|
1233
|
+
cacheSeleccionado = null;
|
|
1162
1234
|
get buscarItemSeleccionado() {
|
|
1163
|
-
|
|
1235
|
+
const datos = this.dataSource?.data;
|
|
1236
|
+
if (!datos || !Array.isArray(datos)) {
|
|
1164
1237
|
return null;
|
|
1165
1238
|
}
|
|
1166
|
-
|
|
1167
|
-
|
|
1239
|
+
if (this.cacheSeleccionado
|
|
1240
|
+
&& this.cacheSeleccionado.seleccionado === this._seleccionado
|
|
1241
|
+
&& this.cacheSeleccionado.datos === datos) {
|
|
1242
|
+
return this.cacheSeleccionado.item;
|
|
1243
|
+
}
|
|
1244
|
+
const dRet = datos.find(itm => this._seleccionado === this.propiedadSeleccion(itm)) ?? null;
|
|
1245
|
+
this.cacheSeleccionado = { seleccionado: this._seleccionado, datos, item: dRet };
|
|
1246
|
+
return dRet;
|
|
1168
1247
|
}
|
|
1169
1248
|
get objSeleccionado() {
|
|
1249
|
+
// `_seleccionado` en null es "aquí no hay nada seleccionado" —volver a pulsar la fila—,
|
|
1250
|
+
// distinto de "hay una selección que no está en los datos cargados", que es cuando vale
|
|
1251
|
+
// mirar lo que guarda el padre. Sin esa distinción, deseleccionar nunca llegaba al padre:
|
|
1252
|
+
// el respaldo devolvía el registro anterior y la fila seguía pintada.
|
|
1253
|
+
if (this._seleccionado === null) {
|
|
1254
|
+
return null;
|
|
1255
|
+
}
|
|
1256
|
+
// @deprecated El respaldo en `objThis.seleccionados[nombreColeccion]` se retirará: el
|
|
1257
|
+
// canal es `[(selectionModel)]`, que no obliga a que la pantalla nombre su propiedad
|
|
1258
|
+
// igual que la colección para que esto funcione.
|
|
1170
1259
|
return this.buscarItemSeleccionado ?? this.objThis?.['seleccionados']?.[this.nombreColeccion];
|
|
1171
1260
|
}
|
|
1172
1261
|
set objSeleccionado(val) {
|
|
1173
|
-
// if (val) {
|
|
1174
1262
|
this.seleccionarItem(val, true);
|
|
1175
|
-
// }
|
|
1176
1263
|
/*if (this.objThis) {
|
|
1177
1264
|
if (!this.objThis['seleccionados']) {
|
|
1178
1265
|
this.objThis['seleccionados'] = {};
|
|
@@ -1196,7 +1283,12 @@ class TablaMantenimientoComponent {
|
|
|
1196
1283
|
idTablaValor(data) {
|
|
1197
1284
|
if (data) {
|
|
1198
1285
|
if (this.idTabla.length < 1) {
|
|
1199
|
-
|
|
1286
|
+
// Sin `idTabla` la fila se identifica por su contenido, así que hay que dejar
|
|
1287
|
+
// fuera lo que cambia mientras se mira la tabla: el estado de expansión (que
|
|
1288
|
+
// escriben el botón de expandir y varias pantallas) y las clases de la fila.
|
|
1289
|
+
// Si entraran, la fila cambiaría de identidad al expandirla y la selección se
|
|
1290
|
+
// perdería sola.
|
|
1291
|
+
return simpleHash(JSON.stringify({ ...data, claseFinal: undefined, isExpanded: undefined }));
|
|
1200
1292
|
}
|
|
1201
1293
|
return this.idTabla.map(d => data[d]).join('-');
|
|
1202
1294
|
}
|
|
@@ -1206,47 +1298,77 @@ class TablaMantenimientoComponent {
|
|
|
1206
1298
|
rowTooltip = (item) => '';
|
|
1207
1299
|
soloIconos = false;
|
|
1208
1300
|
ngOnInit() {
|
|
1209
|
-
this.router.events.pipe(filter(event => event instanceof NavigationEnd), startWith(null), map(() => this.getDeepestRoute(this.route)), map(route => route.snapshot.data), takeUntilDestroyed(this.destroyRef)).subscribe(data =>
|
|
1210
|
-
console.log(data);
|
|
1211
|
-
this.derechosActuales = data['derechos'];
|
|
1212
|
-
this.ignorarDerechos = data['ignorarDerechos'] ?? false;
|
|
1213
|
-
});
|
|
1301
|
+
this.router.events.pipe(filter(event => event instanceof NavigationEnd), startWith(null), map(() => this.getDeepestRoute(this.route)), map(route => route.snapshot.data), takeUntilDestroyed(this.destroyRef)).subscribe(data => this.aplicarDerechosDeRuta(data));
|
|
1214
1302
|
this.paginacion.pageSize = this.pageSize;
|
|
1215
1303
|
this.paginacion.pageSizeOptions = this.pageSizeOptions;
|
|
1216
1304
|
this.actualizarCrud();
|
|
1217
1305
|
this.agregarBotonesExportacion();
|
|
1218
1306
|
if (this.dataSuscription) {
|
|
1219
|
-
this.dataSuscription.subscribe(res => {
|
|
1307
|
+
this.dataSuscription.pipe(takeUntilDestroyed(this.destroyRef)).subscribe(res => {
|
|
1220
1308
|
if (res) {
|
|
1221
|
-
|
|
1222
|
-
|
|
1223
|
-
|
|
1224
|
-
|
|
1225
|
-
|
|
1226
|
-
|
|
1227
|
-
|
|
1228
|
-
|
|
1229
|
-
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
else {
|
|
1235
|
-
console.log('eLSE ID TABLA');
|
|
1236
|
-
const dataStr = Array.isArray(res) ? res.find((itm) => simpleHash(JSON.stringify({
|
|
1237
|
-
...itm, claseFinal: undefined
|
|
1238
|
-
})) == simpleHash(JSON.stringify({ ...this.objSeleccionado, claseFinal: undefined }))) : null;
|
|
1239
|
-
if (dataStr) {
|
|
1240
|
-
this.objSeleccionado = dataStr;
|
|
1241
|
-
}
|
|
1309
|
+
// El registro que estaba seleccionado hay que buscarlo en los datos nuevos,
|
|
1310
|
+
// pero la restauración va DESPUÉS de `setData`: al avisar al padre se lee
|
|
1311
|
+
// `dataSource`, y si todavía tuviera la lista anterior emitiría el registro viejo.
|
|
1312
|
+
const anterior = this.objSeleccionado;
|
|
1313
|
+
this.setData(res);
|
|
1314
|
+
if (anterior) {
|
|
1315
|
+
const renovado = (this.idTabla && this.idTabla.length > 0)
|
|
1316
|
+
? buscarEnArray(res, this.idTabla, this.idTabla.map(d => anterior[d]))
|
|
1317
|
+
: (Array.isArray(res)
|
|
1318
|
+
? res.find((itm) => this.propiedadSeleccion(itm) === this.propiedadSeleccion(anterior))
|
|
1319
|
+
: null);
|
|
1320
|
+
if (renovado) {
|
|
1321
|
+
this.objSeleccionado = renovado;
|
|
1242
1322
|
}
|
|
1243
1323
|
}
|
|
1244
|
-
this.setData(res);
|
|
1245
1324
|
}
|
|
1246
1325
|
});
|
|
1247
1326
|
}
|
|
1248
1327
|
this.isRecargarUsed = this.accionRecargar.observed;
|
|
1249
1328
|
}
|
|
1329
|
+
/** Filas desplegadas, por su identificador. El estado es de la tabla, no del registro. */
|
|
1330
|
+
filasExpandidas = new Set();
|
|
1331
|
+
/** Se pasa a la definición de columnas, que pregunta por fila al pintar el icono. */
|
|
1332
|
+
estaExpandidaFn = (item) => this.estaExpandida(item);
|
|
1333
|
+
/**
|
|
1334
|
+
* Si la fila está desplegada. Además del estado propio se mira `isExpanded` dentro del
|
|
1335
|
+
* registro, porque varias pantallas lo traen puesto para abrir una fila de entrada
|
|
1336
|
+
* (archivo digital hace `firstRow.isExpanded = true` antes de entregar los datos).
|
|
1337
|
+
*/
|
|
1338
|
+
estaExpandida(item) {
|
|
1339
|
+
if (this.filasExpandidas.has(this.propiedadSeleccion(item))) {
|
|
1340
|
+
return true;
|
|
1341
|
+
}
|
|
1342
|
+
return !!item?.['isExpanded'];
|
|
1343
|
+
}
|
|
1344
|
+
/**
|
|
1345
|
+
* Despliega o pliega la fila. El estado vive aquí.
|
|
1346
|
+
*
|
|
1347
|
+
* @deprecated El espejo `isExpanded` dentro del registro se mantiene solo por
|
|
1348
|
+
* compatibilidad y se retirará: las pantallas que lo leen (`*ngIf="row.isExpanded"`) o lo
|
|
1349
|
+
* escriben para abrir una fila de entrada deben pasar a `estaExpandida()` y
|
|
1350
|
+
* `alternarExpansion()`.
|
|
1351
|
+
*/
|
|
1352
|
+
alternarExpansion(item) {
|
|
1353
|
+
const clave = this.propiedadSeleccion(item);
|
|
1354
|
+
const expandida = this.estaExpandida(item);
|
|
1355
|
+
if (expandida) {
|
|
1356
|
+
this.filasExpandidas.delete(clave);
|
|
1357
|
+
}
|
|
1358
|
+
else {
|
|
1359
|
+
this.filasExpandidas.add(clave);
|
|
1360
|
+
}
|
|
1361
|
+
if (item && typeof item === 'object') {
|
|
1362
|
+
item['isExpanded'] = !expandida;
|
|
1363
|
+
}
|
|
1364
|
+
}
|
|
1365
|
+
/** Toma del `data` de la ruta lo que la pantalla no haya pasado por entrada. */
|
|
1366
|
+
aplicarDerechosDeRuta(data) {
|
|
1367
|
+
if (!this.derechosDelPadre) {
|
|
1368
|
+
this._derechosActuales = data['derechos'];
|
|
1369
|
+
}
|
|
1370
|
+
this.ignorarDerechos = data['ignorarDerechos'] ?? false;
|
|
1371
|
+
}
|
|
1250
1372
|
ngAfterContentInit() {
|
|
1251
1373
|
this.componenteCargadoTotalmente = true;
|
|
1252
1374
|
this.cdRef.detectChanges();
|
|
@@ -1261,7 +1383,6 @@ class TablaMantenimientoComponent {
|
|
|
1261
1383
|
}
|
|
1262
1384
|
}
|
|
1263
1385
|
});
|
|
1264
|
-
// console.log(a);
|
|
1265
1386
|
if (this.busquedaValor()) {
|
|
1266
1387
|
this.cCampoBusqueda.setValue(this.busquedaValor());
|
|
1267
1388
|
}
|
|
@@ -1288,8 +1409,11 @@ class TablaMantenimientoComponent {
|
|
|
1288
1409
|
const fnAddBoton = (condicion, tipoBoton) => {
|
|
1289
1410
|
if (condicion) {
|
|
1290
1411
|
const objBoton = buscarEnArray(this.templateBotonesComunes, 'tipo', tipoBoton);
|
|
1291
|
-
|
|
1292
|
-
|
|
1412
|
+
// Se busca en todas las secciones, no solo en la inferior: una pantalla que
|
|
1413
|
+
// declare el botón donde quiera acababa viéndolo dos veces.
|
|
1414
|
+
const yaDeclarado = Object.values(this.botonesMenu ?? {})
|
|
1415
|
+
.some(seccion => (seccion ?? []).some((btn) => btn?.tipo === tipoBoton));
|
|
1416
|
+
if (!yaDeclarado && objBoton) {
|
|
1293
1417
|
if (!this.botonesMenu.inferior) {
|
|
1294
1418
|
this.botonesMenu.inferior = [];
|
|
1295
1419
|
}
|
|
@@ -1352,14 +1476,34 @@ class TablaMantenimientoComponent {
|
|
|
1352
1476
|
claseFinal = claseFinal.concat(this.classSeleccionado);
|
|
1353
1477
|
}
|
|
1354
1478
|
claseFinal = claseFinal.concat(this.condicionesClaseFila(item));
|
|
1355
|
-
|
|
1479
|
+
// No se guarda en el registro: es dato del padre, y escribir aquí cambiaba el hash con
|
|
1480
|
+
// el que se identifica la fila cuando no hay `idTabla`, haciendo que la selección se
|
|
1481
|
+
// perdiera sola al repintarse.
|
|
1356
1482
|
return claseFinal;
|
|
1357
1483
|
}
|
|
1484
|
+
/**
|
|
1485
|
+
* Memoria del tooltip por registro. La plantilla lo pide tres veces por fila (texto,
|
|
1486
|
+
* `matTooltipDisabled` y la clase `regTooltip`), y cada llamada ejecuta el `rowTooltip` del
|
|
1487
|
+
* consumidor. Se recalcula cuando cambian los datos.
|
|
1488
|
+
*/
|
|
1489
|
+
cacheTooltip = new WeakMap();
|
|
1358
1490
|
procesarRowTooltip(item) {
|
|
1491
|
+
if (item && typeof item === 'object') {
|
|
1492
|
+
const guardado = this.cacheTooltip.get(item);
|
|
1493
|
+
if (guardado !== undefined) {
|
|
1494
|
+
return guardado;
|
|
1495
|
+
}
|
|
1496
|
+
}
|
|
1497
|
+
const texto = this.calcularRowTooltip(item);
|
|
1498
|
+
if (item && typeof item === 'object') {
|
|
1499
|
+
this.cacheTooltip.set(item, texto);
|
|
1500
|
+
}
|
|
1501
|
+
return texto;
|
|
1502
|
+
}
|
|
1503
|
+
calcularRowTooltip(item) {
|
|
1359
1504
|
let txtTooptip = [];
|
|
1360
1505
|
if (this.campoAnuladoMensaje && (item[this.campoAnulado] == 1)) {
|
|
1361
1506
|
txtTooptip.push(item[this.campoAnuladoMensaje]);
|
|
1362
|
-
// return item[this.campoAnuladoMensaje];
|
|
1363
1507
|
}
|
|
1364
1508
|
if (this.rowTooltip) {
|
|
1365
1509
|
txtTooptip.push(this.rowTooltip(item));
|
|
@@ -1369,15 +1513,17 @@ class TablaMantenimientoComponent {
|
|
|
1369
1513
|
subItemsActivos(btn, item) {
|
|
1370
1514
|
return btn.subItems.filter((sub) => !sub.esVisible || sub.esVisible(item)).length > 0;
|
|
1371
1515
|
}
|
|
1516
|
+
/** Se arma una sola vez: la plantilla lo consume con `async`, y devolver un observable nuevo
|
|
1517
|
+
* en cada ciclo hacía que la tubería se desuscribiera y volviera a suscribirse sin parar. */
|
|
1518
|
+
noData$ = null;
|
|
1372
1519
|
get noData() {
|
|
1373
|
-
if (!this.esTabla) {
|
|
1520
|
+
if (!this.esTabla || !this.dataSource) {
|
|
1374
1521
|
return of(true);
|
|
1375
1522
|
}
|
|
1376
|
-
if (!this.
|
|
1377
|
-
|
|
1523
|
+
if (!this.noData$) {
|
|
1524
|
+
this.noData$ = this.dataSource.connect().pipe(map(data => (data?.length ?? 0) === 0));
|
|
1378
1525
|
}
|
|
1379
|
-
|
|
1380
|
-
return this.table.dataSource?.connect().pipe(map(data => data?.length === 0));
|
|
1526
|
+
return this.noData$;
|
|
1381
1527
|
}
|
|
1382
1528
|
onFilterChange(value) {
|
|
1383
1529
|
if (!this.dataSource) {
|
|
@@ -1421,18 +1567,20 @@ class TablaMantenimientoComponent {
|
|
|
1421
1567
|
toggleDireccionOrden() {
|
|
1422
1568
|
this.bDireccionOrden.update((v) => v === 0 ? 1 : 0);
|
|
1423
1569
|
this.emitirResultados();
|
|
1424
|
-
// if (this.busquedaTipo() === 'query') {
|
|
1425
|
-
// this.cargarData();
|
|
1426
|
-
// } else {
|
|
1427
|
-
// this.emitirAccionRecargar();
|
|
1428
|
-
// }
|
|
1429
1570
|
}
|
|
1430
1571
|
// FIN FILTRO BUSQUEDA INTEGRAR
|
|
1431
1572
|
setData(data) {
|
|
1432
1573
|
if (!Array.isArray(data)) {
|
|
1433
1574
|
data = [];
|
|
1434
1575
|
}
|
|
1435
|
-
|
|
1576
|
+
// Se reutiliza la misma instancia en vez de crear otra en cada carga. Crear una nueva
|
|
1577
|
+
// dejaba el texto del buscador sin efecto (el filtro vive en el dataSource), obligaba a
|
|
1578
|
+
// recablear orden y paginador, y dejaba colgada la suscripción que la navegación por
|
|
1579
|
+
// teclado toma de `connect()`, que entonces trabajaba con los datos anteriores.
|
|
1580
|
+
this.dataSource.data = data;
|
|
1581
|
+
this.filasExpandidas.clear();
|
|
1582
|
+
this.cacheSeleccionado = null;
|
|
1583
|
+
this.cacheTooltip = new WeakMap();
|
|
1436
1584
|
this.dataSource.sortingDataAccessor = (item, property) => {
|
|
1437
1585
|
const dColumn = buscarEnArray(this.columnasTabla, 'property', property);
|
|
1438
1586
|
if (dColumn) {
|
|
@@ -1452,14 +1600,10 @@ class TablaMantenimientoComponent {
|
|
|
1452
1600
|
}
|
|
1453
1601
|
}
|
|
1454
1602
|
};
|
|
1455
|
-
// this.paginator.length = (data && data[0] && data[0]['iTotalRegistros']) ? data[0]['iTotalRegistros'] : data.length;
|
|
1456
|
-
// this.dataSource.paginator = this.paginator;
|
|
1457
1603
|
if (this.sort) {
|
|
1458
1604
|
this.dataSource.sort = this.sort;
|
|
1459
1605
|
}
|
|
1460
|
-
// this.dataSource.filter = this.filter;
|
|
1461
1606
|
this.dataSourceChange.emit(this.dataSource);
|
|
1462
|
-
// this.dataSource.paginator.pageSize = this.paginacion.pageSize;
|
|
1463
1607
|
if (data && data[0] && data[0]['iPageNumber']) {
|
|
1464
1608
|
this.paginacion.pageIndex = (data && data[0] && data[0]['iPageNumber']) ? data[0]['iPageNumber'] : 0;
|
|
1465
1609
|
}
|
|
@@ -1467,11 +1611,16 @@ class TablaMantenimientoComponent {
|
|
|
1467
1611
|
this.bDireccionOrden.set(data[0]['bDireccionOrden']);
|
|
1468
1612
|
}
|
|
1469
1613
|
this.paginacion.pageLength = (data && data[0] && data[0]['iTotalRegistros']) ? data[0]['iTotalRegistros'] : data.length;
|
|
1470
|
-
if (data && data[0]
|
|
1471
|
-
|
|
1614
|
+
if (data && data[0]) {
|
|
1615
|
+
// Con una sola instancia hay que decir las dos cosas: quién pagina en cliente y
|
|
1616
|
+
// quién no. Si el servidor ya manda la página (`iTotalRegistros`) y el paginador
|
|
1617
|
+
// siguiera enganchado de una carga anterior, recortaría esa página por el índice
|
|
1618
|
+
// que tuviera y la tabla saldría vacía.
|
|
1619
|
+
this.dataSource.paginator = data[0]['iTotalRegistros'] ? null : this.paginator;
|
|
1472
1620
|
}
|
|
1473
1621
|
if (this.tieneCheckbox) {
|
|
1474
|
-
|
|
1622
|
+
const casilla = this.tieneCheckbox;
|
|
1623
|
+
this.chkLista.prepararCasillas(data, casilla.chkField ?? casilla.property, casilla.chkFieldSeparador ?? '', !casilla.chkFieldPersistente);
|
|
1475
1624
|
}
|
|
1476
1625
|
}
|
|
1477
1626
|
botonDisabled(btn, item) {
|
|
@@ -1485,9 +1634,7 @@ class TablaMantenimientoComponent {
|
|
|
1485
1634
|
}
|
|
1486
1635
|
}
|
|
1487
1636
|
if (!disabled && !btn.esIndependiente && !btn.ignorarDerecho && this.derechosActuales) {
|
|
1488
|
-
// if (!this.usuarioService.esEquipoJVSoft()) {
|
|
1489
1637
|
disabled = !(this.derechosActuales[btn.cDerechoCodigo ?? btn.tipo]);
|
|
1490
|
-
// }
|
|
1491
1638
|
}
|
|
1492
1639
|
return disabled;
|
|
1493
1640
|
}
|
|
@@ -1497,7 +1644,86 @@ class TablaMantenimientoComponent {
|
|
|
1497
1644
|
esSeleccionActual(item) {
|
|
1498
1645
|
return this._seleccionado === this.propiedadSeleccion(item);
|
|
1499
1646
|
}
|
|
1647
|
+
/**
|
|
1648
|
+
* `Supr` sobre la fila pide eliminar. Se ignora cuando la tecla viene de un campo de la
|
|
1649
|
+
* celda: ahí el usuario está borrando texto, no el registro.
|
|
1650
|
+
*/
|
|
1651
|
+
teclaEliminarEnFila(item, evento) {
|
|
1652
|
+
if (this.readOnly) {
|
|
1653
|
+
return;
|
|
1654
|
+
}
|
|
1655
|
+
const origen = evento.target;
|
|
1656
|
+
const etiqueta = origen?.tagName?.toLowerCase();
|
|
1657
|
+
if (etiqueta === 'input' || etiqueta === 'textarea' || etiqueta === 'select' || origen?.isContentEditable) {
|
|
1658
|
+
return;
|
|
1659
|
+
}
|
|
1660
|
+
this.opcMenu(item, { seccion: this.nombreColeccion, tipo: 'eliminar' });
|
|
1661
|
+
}
|
|
1662
|
+
/**
|
|
1663
|
+
* Espacio sobre la fila enfocada. Con columna de casillas marca o desmarca la suya, que es
|
|
1664
|
+
* lo que se espera de esa tecla en una lista con selección múltiple; sin casillas se
|
|
1665
|
+
* comporta como Enter y abre el registro.
|
|
1666
|
+
*/
|
|
1667
|
+
teclaEspacioEnFila(item) {
|
|
1668
|
+
const casilla = this.tieneCheckbox;
|
|
1669
|
+
if (!casilla) {
|
|
1670
|
+
this.opcMenu(item, { seccion: this.nombreColeccion, tipo: 'ver' });
|
|
1671
|
+
return;
|
|
1672
|
+
}
|
|
1673
|
+
const clave = this.chkLista.generarId(item, casilla.chkField ?? casilla.property, casilla.chkFieldSeparador);
|
|
1674
|
+
this.chkLista.setState(clave, !this.chkLista.getState(clave));
|
|
1675
|
+
}
|
|
1676
|
+
/**
|
|
1677
|
+
* El teclado movió el foco a otra fila: se selecciona, pero sin avisar `ver`. Recorrer la
|
|
1678
|
+
* tabla con las flechas dispararía un aviso por fila, y los padres suelen cargar datos con él.
|
|
1679
|
+
*/
|
|
1680
|
+
seleccionarFilaPorId(id) {
|
|
1681
|
+
const item = (this.dataSource?.data ?? []).find((itm) => this.propiedadSeleccion(itm) === id);
|
|
1682
|
+
if (item) {
|
|
1683
|
+
this.seleccionarItem(item, true);
|
|
1684
|
+
}
|
|
1685
|
+
}
|
|
1686
|
+
/**
|
|
1687
|
+
* Clic sobre una fila. `evento.detail` es el contador de clics del navegador: en un clic
|
|
1688
|
+
* suelto vale 1 y la selección alterna, así que volver a pulsar la fila la deselecciona.
|
|
1689
|
+
* El segundo clic de un doble clic llega con 2: ahí la selección se fuerza —alternar dejaba
|
|
1690
|
+
* la fila apagada justo al abrir el registro— y no se vuelve a avisar `ver`, porque los
|
|
1691
|
+
* consumidores que alternan su propia selección con ese evento acababan en desacuerdo con
|
|
1692
|
+
* la tabla.
|
|
1693
|
+
*/
|
|
1694
|
+
/**
|
|
1695
|
+
* Doble clic sobre la fila. En solo lectura no dispara la acción: `permitirSeleccion` deja
|
|
1696
|
+
* elegir la fila, pero ni ese modo ni el solo lectura completo ejecutan nada.
|
|
1697
|
+
*/
|
|
1698
|
+
dobleClicFila(item) {
|
|
1699
|
+
if (this.readOnly) {
|
|
1700
|
+
return;
|
|
1701
|
+
}
|
|
1702
|
+
this.opcMenu(item, { seccion: this.nombreColeccion, tipo: 'seleccionar' });
|
|
1703
|
+
this.dblclickItem.emit(item);
|
|
1704
|
+
}
|
|
1705
|
+
clicFila(item, tableDataIndex, evento) {
|
|
1706
|
+
const esSegundoClic = evento.detail > 1;
|
|
1707
|
+
this.seleccionarItem(item, esSegundoClic);
|
|
1708
|
+
if (!esSegundoClic) {
|
|
1709
|
+
this.opcMenu(item, { seccion: this.nombreColeccion, tipo: 'ver', tableDataIndex });
|
|
1710
|
+
}
|
|
1711
|
+
}
|
|
1500
1712
|
seleccionarItem(item, forzado = false) {
|
|
1713
|
+
this.cacheSeleccionado = null;
|
|
1714
|
+
if (item == null) {
|
|
1715
|
+
// Sin registro no hay selección. Antes se guardaba `coleccion_` a secas, y cualquier
|
|
1716
|
+
// fila cuyo campo identificador viniera vacío coincidía con ese valor.
|
|
1717
|
+
const habiaSeleccion = this.objSeleccionado != null;
|
|
1718
|
+
this._seleccionado = null;
|
|
1719
|
+
// Solo se avisa si de verdad había algo: al arrancar, el enlace de dos sentidos entra
|
|
1720
|
+
// aquí con `undefined`, y emitir entonces cambiaría el valor del padre a media
|
|
1721
|
+
// detección de cambios (NG0100).
|
|
1722
|
+
if (habiaSeleccion) {
|
|
1723
|
+
this.selectionModelChange.emit(null);
|
|
1724
|
+
}
|
|
1725
|
+
return;
|
|
1726
|
+
}
|
|
1501
1727
|
const idItem = this.propiedadSeleccion(item);
|
|
1502
1728
|
if (forzado) {
|
|
1503
1729
|
this._seleccionado = idItem;
|
|
@@ -1514,16 +1740,6 @@ class TablaMantenimientoComponent {
|
|
|
1514
1740
|
}*/
|
|
1515
1741
|
}
|
|
1516
1742
|
opcMenu(item, objMenu, modal = null, retorno = false) {
|
|
1517
|
-
// console.log(this.buscarItemSeleccionado);
|
|
1518
|
-
// console.log(objMenu);
|
|
1519
|
-
// let salir = this.readOnly;
|
|
1520
|
-
// if (salir && this.readOnly === 'permitirSeleccion' && ['ver', 'seleccionar'].includes(objMenu.tipo)) {
|
|
1521
|
-
// salir = false;
|
|
1522
|
-
// }
|
|
1523
|
-
// if (salir) {
|
|
1524
|
-
// return false;
|
|
1525
|
-
// }
|
|
1526
|
-
// console.warn(objMenu);
|
|
1527
1743
|
if (objMenu.tipo == 'exportar_excel' && this.exportarExcel) {
|
|
1528
1744
|
/*
|
|
1529
1745
|
TableUtil.exportArrayToExcel(this.dataSource.data.map(x => {
|
|
@@ -1536,16 +1752,10 @@ class TablaMantenimientoComponent {
|
|
|
1536
1752
|
*/
|
|
1537
1753
|
const dataGeneradoPorHtml = TableUtil.getWorkBook('tabla_' + this.nombreColeccion, []);
|
|
1538
1754
|
const objetosExtraidos = this.dataSource.filteredData.map((objeto, idx) => this.objVisibleColumns.reduce((acumulador, columna) => {
|
|
1539
|
-
// console.log(propiedad);
|
|
1540
1755
|
const nColumn = (columna.labelLista ?? columna.label).toUpperCase().replace('<BR>', ' ');
|
|
1541
1756
|
switch (columna.type) {
|
|
1542
1757
|
case 'date':
|
|
1543
|
-
// acumulador[nColumn] = (new DatePipe('es-PE')).transform(objeto[columna.property], 'dd/MM/yyyy' /*'yyyy-MM-dd'*/);
|
|
1544
1758
|
// new Date(dateString.replace(/(\d{2}:\d{2}:\d{2}):\w{2}/, '$1'));
|
|
1545
|
-
// acumulador[nColumn] = new Date(objeto[columna.property].replace(/(\d{2}:\d{2}:\d{2}):\w{2}/, '$1'));
|
|
1546
|
-
// acumulador[nColumn] = formatearFechaFormato(objeto[columna.property], 'dd/MM/yyyy');
|
|
1547
|
-
// acumulador[nColumn] = formatearFechaTimezone(objeto[columna.property]);
|
|
1548
|
-
// acumulador[nColumn] = new Date(objeto[columna.property]);
|
|
1549
1759
|
let fecha = objeto[columna.property];
|
|
1550
1760
|
if (objeto[columna.property]) {
|
|
1551
1761
|
fecha = new Date(objeto[columna.property].replace(/(\d{2}:\d{2}:\d{2}):\w{2}/, '$1'));
|
|
@@ -1554,7 +1764,6 @@ class TablaMantenimientoComponent {
|
|
|
1554
1764
|
}
|
|
1555
1765
|
}
|
|
1556
1766
|
acumulador[nColumn] = fecha;
|
|
1557
|
-
// acumulador[nColumn] = objeto[columna.property];
|
|
1558
1767
|
break;
|
|
1559
1768
|
case 'number':
|
|
1560
1769
|
case 'money':
|
|
@@ -1591,9 +1800,7 @@ class TablaMantenimientoComponent {
|
|
|
1591
1800
|
return acumulador;
|
|
1592
1801
|
}, {}));
|
|
1593
1802
|
// TableUtil.exportTableToExcel('tabla_' + this.nombreColeccion);
|
|
1594
|
-
// console.log(objetosExtraidos);
|
|
1595
1803
|
TableUtil.exportArrayToExcel(objetosExtraidos, this.nombreColeccion);
|
|
1596
|
-
// this.tableExporter.exportTable('xlsx', {fileName: 'JVSoftExport'});
|
|
1597
1804
|
}
|
|
1598
1805
|
const opAdic = { seccion: this.nombreColeccion };
|
|
1599
1806
|
if (item) {
|
|
@@ -1610,19 +1817,18 @@ class TablaMantenimientoComponent {
|
|
|
1610
1817
|
if (retorno) {
|
|
1611
1818
|
return objMenu;
|
|
1612
1819
|
}
|
|
1613
|
-
// console.warn(objMenu);
|
|
1614
1820
|
this.opcionSelecionada.emit(objMenu);
|
|
1615
1821
|
return 1;
|
|
1616
1822
|
}
|
|
1617
1823
|
emitirResultados(evento = {}) {
|
|
1618
1824
|
this.opcFiltroActual = { ...this.opcFiltroActual, ...evento, ...this.cargarData(true) };
|
|
1619
|
-
// console.warn('resultadosFILTRO', this.opcFiltroActual);
|
|
1620
1825
|
this.resultados.emit(this.opcFiltroActual);
|
|
1621
1826
|
}
|
|
1622
1827
|
abrirMenuContextual({ x, y }, user) {
|
|
1623
|
-
// console.log(user);
|
|
1624
|
-
// this.opcMenu(user, {tipo: 'ver'});
|
|
1625
1828
|
this.objSeleccionado = user;
|
|
1829
|
+
// El aviso es lo que mantiene al padre en la misma fila que la tabla: sin él, los
|
|
1830
|
+
// botones del menú actuaban sobre el registro seleccionado antes del clic derecho.
|
|
1831
|
+
this.opcMenu(user, { seccion: this.nombreColeccion, tipo: 'ver' });
|
|
1626
1832
|
this.cerrarMenuContextual();
|
|
1627
1833
|
const positionStrategy = this.overlay.position().flexibleConnectedTo({ x, y }).withPositions([
|
|
1628
1834
|
{
|
|
@@ -1659,17 +1865,13 @@ class TablaMantenimientoComponent {
|
|
|
1659
1865
|
this.compactSearchMenuTrigger.closeMenu();
|
|
1660
1866
|
}
|
|
1661
1867
|
emitirAccionRecargar() {
|
|
1662
|
-
if (!this.idTabla) {
|
|
1663
|
-
this.objSeleccionado = null;
|
|
1664
|
-
}
|
|
1665
1868
|
this.accionRecargar.emit(this.opcFiltroActual);
|
|
1666
|
-
// this.accionRecargar.emit({ ...this.opcFiltroActual, ...{seleccionado: this.objSeleccionado}});
|
|
1667
1869
|
}
|
|
1668
1870
|
tipoValorFuncion = tipoValorFuncion;
|
|
1669
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.18", ngImport: i0, type: TablaMantenimientoComponent, deps: [{ token: i1$2.
|
|
1871
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.18", ngImport: i0, type: TablaMantenimientoComponent, deps: [{ token: i1$2.Overlay }, { token: i0.ViewContainerRef }, { token: TablaMantenimientoService }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
1670
1872
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.18", type: TablaMantenimientoComponent, isStandalone: true, selector: "jvs-tabla-mantenimiento", inputs: { dataSuscription: { classPropertyName: "dataSuscription", publicName: "dataSuscription", isSignal: false, isRequired: false, transformFunction: null }, objThis: { classPropertyName: "objThis", publicName: "objThis", isSignal: false, isRequired: true, transformFunction: null }, nombreColeccion: { classPropertyName: "nombreColeccion", publicName: "nombreColeccion", isSignal: false, isRequired: true, transformFunction: null }, busquedaValor: { classPropertyName: "busquedaValor", publicName: "ctrlBusquedaValue", isSignal: true, isRequired: false, transformFunction: null }, busquedaPlaceholder: { classPropertyName: "busquedaPlaceholder", publicName: "ctrlBusquedaPlaceholder", isSignal: true, isRequired: false, transformFunction: null }, filtroCampos: { classPropertyName: "filtroCampos", publicName: "filtroCampos", isSignal: false, isRequired: false, transformFunction: null }, paginador: { classPropertyName: "paginador", publicName: "paginador", isSignal: false, isRequired: false, transformFunction: null }, esTabla: { classPropertyName: "esTabla", publicName: "esTabla", isSignal: false, isRequired: false, transformFunction: null }, readOnly: { classPropertyName: "readOnly", publicName: "readOnly", isSignal: false, isRequired: false, transformFunction: null }, filaExtraHeader: { classPropertyName: "filaExtraHeader", publicName: "filaExtraHeader", isSignal: false, isRequired: false, transformFunction: null }, filaFooter: { classPropertyName: "filaFooter", publicName: "filaFooter", isSignal: false, isRequired: false, transformFunction: null }, botonesCRUD: { classPropertyName: "botonesCRUD", publicName: "botonesCRUD", isSignal: false, isRequired: false, transformFunction: null }, objBotonesCRUD: { classPropertyName: "objBotonesCRUD", publicName: "objBotonesCRUD", isSignal: false, isRequired: false, transformFunction: null }, classSeleccionado: { classPropertyName: "classSeleccionado", publicName: "classSeleccionado", isSignal: false, isRequired: false, transformFunction: null }, classAnulado: { classPropertyName: "classAnulado", publicName: "classAnulado", isSignal: false, isRequired: false, transformFunction: null }, campoAnulado: { classPropertyName: "campoAnulado", publicName: "campoAnulado", isSignal: false, isRequired: false, transformFunction: null }, campoAnuladoMensaje: { classPropertyName: "campoAnuladoMensaje", publicName: "campoAnuladoMensaje", isSignal: false, isRequired: false, transformFunction: null }, selectionModel: { classPropertyName: "selectionModel", publicName: "selectionModel", isSignal: false, isRequired: false, transformFunction: null }, filaExtraTemplate: { classPropertyName: "filaExtraTemplate", publicName: "filaExtraTemplate", isSignal: false, isRequired: false, transformFunction: null }, exportarExcel: { classPropertyName: "exportarExcel", publicName: "exportarExcel", isSignal: false, isRequired: false, transformFunction: null }, busquedaCompacta: { classPropertyName: "busquedaCompacta", publicName: "busquedaCompacta", isSignal: true, isRequired: false, transformFunction: null }, alturaFull: { classPropertyName: "alturaFull", publicName: "alturaFull", isSignal: true, isRequired: false, transformFunction: null }, pageSize: { classPropertyName: "pageSize", publicName: "pageSize", isSignal: false, isRequired: false, transformFunction: null }, pageSizeOptions: { classPropertyName: "pageSizeOptions", publicName: "pageSizeOptions", isSignal: false, isRequired: false, transformFunction: null }, derechosActuales: { classPropertyName: "derechosActuales", publicName: "derechosActuales", isSignal: false, isRequired: false, transformFunction: null }, mostrarBotonOrden: { classPropertyName: "mostrarBotonOrden", publicName: "mostrarBotonOrden", isSignal: true, isRequired: false, transformFunction: null }, busquedaTipo: { classPropertyName: "busquedaTipo", publicName: "ctrlBusqueda", isSignal: true, isRequired: false, transformFunction: null }, leyenda: { classPropertyName: "leyenda", publicName: "leyenda", isSignal: false, isRequired: false, transformFunction: null }, idTabla: { classPropertyName: "idTabla", publicName: "idTabla", isSignal: false, isRequired: true, transformFunction: null }, columnasTabla: { classPropertyName: "columnasTabla", publicName: "columnasTabla", isSignal: false, isRequired: false, transformFunction: null }, botonesMenu: { classPropertyName: "botonesMenu", publicName: "botonesMenu", isSignal: false, isRequired: false, transformFunction: null }, condicionesClaseFila: { classPropertyName: "condicionesClaseFila", publicName: "condicionesClaseFila", isSignal: false, isRequired: false, transformFunction: null }, rowTooltip: { classPropertyName: "rowTooltip", publicName: "rowTooltip", isSignal: false, isRequired: false, transformFunction: null }, soloIconos: { classPropertyName: "soloIconos", publicName: "soloIconos", isSignal: false, isRequired: false, transformFunction: null } }, outputs: { dblclickItem: "dblclickItem", opcionSelecionada: "opcionSelecionada", opcBusqueda: "opcBusqueda", accionRecargar: "accionRecargar", selectionModelChange: "selectionModelChange", dataSourceChange: "dataSourceChange", resultados: "resultados" }, host: { properties: { "class.h-full": "alturaFull()", "id": "this.id" }, classAttribute: "jvs-tabla-mantenimiento" }, providers: [
|
|
1671
1873
|
{ provide: MAT_PAGINATOR_DEFAULT_OPTIONS, useValue: { formFieldAppearance: 'outline' } }
|
|
1672
|
-
], queries: [{ propertyName: "columnDefs", predicate: MatColumnDef, descendants: true }], viewQueries: [{ propertyName: "paginator", first: true, predicate: MatPaginator, descendants: true }, { propertyName: "sort", first: true, predicate: MatSort, descendants: true }, { propertyName: "table", first: true, predicate: MatTable, descendants: true }, { propertyName: "rowFooter", first: true, predicate: MatFooterRow, descendants: true, read: ElementRef }, { propertyName: "userMenu", first: true, predicate: ["userMenu"], descendants: true }, { propertyName: "compactSearchMenuTrigger", first: true, predicate: ["compactSearchMenuTrigger"], descendants: true, read: MatMenuTrigger }, { propertyName: "rows", predicate: MatRow, descendants: true, read: ElementRef }], usesOnChanges: true, ngImport: i0, template: "<div class=\"flex flex-col\" [ngClass]=\"alturaFull() ? 'h-full' : 'h-fit'\">\n <div class=\"flex-none flex items-center justify-between bg-white\">\n <ng-content select=\"[filtro]\"></ng-content>\n </div>\n\n <div class=\"flex flex-col border-t\" [ngClass]=\"alturaFull() ? 'grow' : ''\">\n <div class=\"flex-none bg-app-bar flex items-center justify-between p-1\">\n <!-- <div class=\"hidden flex-1 sm:flex items-center flex-wrap gap-1\">-->\n <!-- </div>-->\n @if (leyenda) {\n <div class=\"flex items-center flex-wrap mr-1 h-full\">\n <span class=\"font-bold\" [class]=\"leyenda.class\">{{ leyenda.text }}</span>\n </div>\n }\n <div class=\"hidden flex-1 sm:flex items-center flex-wrap gap-1\">\n @if ((botonesMenuFinal.izquierda ?? []).length > 0 ) {\n <div class=\" flex items-center flex-wrap contenedor-botones\">\n @for (btn of botonesMenu.izquierda; track btn; let idx = $index) {\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.izquierda?.length}}\"></ng-container>\n }\n </div>\n }\n\n @if ((botonesMenuFinal.crud ?? []).length > 0) {\n <div class=\" flex items-center flex-wrap contenedor-botones\">\n @for (btn of botonesMenu.crud; track btn; let idx = $index) {\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.crud?.length}}\"></ng-container>\n }\n </div>\n }\n\n @if ((botonesMenuFinal.principal ?? []).length > 0) {\n <div class=\" flex items-center flex-wrap contenedor-botones\">\n @for (btn of botonesMenu.principal; track btn; let idx = $index) {\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.principal?.length}}\"></ng-container>\n }\n </div>\n }\n\n @if ((botonesMenuFinal.derecha ?? []).length > 0) {\n <div class=\"flex-auto flex items-center justify-end contenedor-botones\">\n @for (btn of botonesMenu.derecha; track btn; let idx = $index) {\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.derecha?.length}}\"></ng-container>\n }\n </div>\n }\n <ng-content select=\"[objetosMenuPegado]\"></ng-content>\n </div>\n <div class=\"flex flex-1 sm:hidden items-center flex-wrap gap-1\">\n <button class=\"flex items-center justify-center text-2xs leading-none rounded-full p-1\"\n matRipple\n matTooltip=\"Botones de Acci\u00F3n\"\n type=\"button\"\n [matMenuTriggerFor]=\"menuOpciones\"\n >\n <mat-icon class=\"icon-xs\" svgIcon=\"roundMenu\"></mat-icon>\n </button>\n </div>\n <div class=\"flex-none flex items-center justify-end border-l-2\">\n <div class=\"flex-1 sm:flex-none flex items-center justify-end\">\n <ng-content select=\"[objetosMenu]\"></ng-content>\n </div>\n </div>\n @if (busquedaTipo() && !busquedaCompacta()) {\n <div class=\"hidden flex-initial sm:flex items-center form-input max-w-[150px] bg-card rounded-full border m-1 px-1 border-l-2\"\n >\n <mat-icon svgIcon=\"roundSearch\" class=\"icon-xs\"></mat-icon>\n <input [formControl]=\"cCampoBusqueda\"\n class=\"text-xs px-1 py-1 border-0 outline-none w-full bg-transparent max-w-sm\"\n [placeholder]=\"busquedaPlaceholder()\"\n (keyup.enter)=\"busquedaTipo() == 'query' ? cargarData() : false;\"\n type=\"search\">\n </div>\n }\n\n\n <mat-menu #compactSearchMenu=\"matMenu\" class=\"compact-search-menu\">\n <div class=\"flex items-center gap-1\" (click)=\"$event.stopPropagation()\">\n <mat-icon svgIcon=\"roundSearch\" class=\"icon-xs text-gray-400\"></mat-icon>\n <input [formControl]=\"cCampoBusqueda\"\n class=\"text-xs px-2 py-1 border border-gray-200 rounded outline-none w-[180px] bg-white\"\n [placeholder]=\"busquedaPlaceholder()\"\n (keyup.enter)=\"ejecutarBusquedaCompacta()\"\n type=\"search\"\n (click)=\"$event.stopPropagation()\">\n </div>\n </mat-menu>\n <div class=\"flex-none flex items-center justify-end border-l-2\">\n <ng-content select=\"[botonesFiltro]\"></ng-content>\n <ng-content select=\"[botonesConfig]\"></ng-content>\n\n @if (busquedaTipo() && busquedaCompacta()) {\n <button matRipple\n class=\"flex items-center justify-center text-2xs leading-none rounded-full p-1\"\n matTooltip=\"Buscar...\"\n [matMenuTriggerFor]=\"compactSearchMenu\"\n #compactSearchMenuTrigger=\"matMenuTrigger\"\n type=\"button\">\n <mat-icon svgIcon=\"roundSearch\" class=\"icon-xs\"></mat-icon>\n </button>\n }\n\n @if (isRecargarUsed || busquedaTipo() == 'query') {\n <button matRipple\n class=\"flex items-center justify-center text-2xs leading-none rounded-full p-1 text-green-700\"\n matTooltip=\"Actualizar datos\"\n (click)=\"(busquedaTipo() == 'query' ? cargarData() : emitirAccionRecargar())\"\n type=\"button\">\n <mat-icon svgIcon=\"roundRefresh\" class=\"icon-xs\"></mat-icon>\n </button>\n }\n @if (mostrarBotonOrden()) {\n <button matRipple\n class=\"flex items-center justify-center text-2xs leading-none rounded-full p-1 text-blue-700\"\n [matTooltip]=\"bDireccionOrden() === 0 ? 'Orden Ascendente' : 'Orden Descendente'\"\n (click)=\"toggleDireccionOrden()\"\n type=\"button\">\n <mat-icon [svgIcon]=\"bDireccionOrden() === 0 ? 'roundArrowUpward' : 'roundArrowDownward'\" class=\"icon-xs\"></mat-icon>\n </button>\n }\n @if (filtroCampos) {\n <button matRipple [matMenuTriggerFor]=\"columnFilterMenu\"\n class=\"flex items-center justify-center text-2xs leading-none rounded-full p-1\"\n matTooltip=\"Columnas Filtro\"\n type=\"button\">\n <mat-icon svgIcon=\"roundFilterList\" class=\"icon-xs\"></mat-icon>\n </button>\n }\n </div>\n </div>\n\n @if ((botonesMenuFinal.secundario ?? []).length > 0) {\n <div class=\"flex-1 bg-app-bar flex items-center justify-between p-1 border-t\">\n <div class=\"hidden flex-1 sm:flex items-center flex-wrap gap-1\">\n <div class=\" flex items-center flex-wrap contenedor-botones\">\n @for (btn of botonesMenu.secundario; track btn; let idx = $index) {\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.secundario?.length}}\"></ng-container>\n }\n </div>\n </div>\n </div>\n }\n <!--<div class=\"grow flex flex-col items-stretch contenedor-tabla\" [ngClass]=\"{'table-container overflow-auto': esTabla}\">\n <pre>{{ this.chkLista.modelosChk | json }}</pre>\n <pre>{{ this.chkLista.checkbox.cantidadActivos | json }}</pre>\n <pre>{{ this.chkLista.checkbox.algunosActivos | json }}</pre>\n</div>-->\n<div class=\"grow flex flex-col items-stretch contenedor-tabla\" [ngClass]=\"{'table-container overflow-auto': esTabla}\">\n <ng-content select=\"[cuerpo]\"></ng-content>\n\n <table [id]=\"'tabla_' + nombreColeccion\" [dataSource]=\"dataSource\" [multiTemplateDataRows]=\"true\"\n [hidden]=\"!esTabla\"\n class=\"table-mantenimiento table-auto h-fit\" mat-table matSort\n [trackBy]=\"trackByFn\"\n #tablaMantenimiento\n >\n\n <!--<table [dataSource]=\"dataSource\" class=\"table-mantenimiento table-auto h-auto w-full justify-center\" mat-table matSort>-->\n\n\n <ng-content select=\"[tableDefinitions]\"></ng-content>\n <ng-container matColumnDef=\"numeracion_automatica\">\n <th mat-header-cell *matHeaderCellDef style=\"width: 16px !important\">N\u00BA</th>\n <td mat-cell *matCellDef=\"let element; let i = dataIndex\" class=\"p-0 celda-numeracion-fila\">\n <div class=\"flex items-center justify-center font-bold numeracionFila\">\n @if (esTabla && paginador) {\n {{ (this.paginator?.pageIndex == 0 ? i + 1 : 1 + i + (this.paginator?.pageIndex ?? 1) * (this.paginator?.pageSize ?? 1)) }}\n }\n @if (!paginador) {\n {{ (i + 1) }}\n }\n </div>\n </td>\n <td mat-footer-cell *matFooterCellDef class=\"uppercase\"></td>\n </ng-container>\n <jvs-tabla-mantenimiento-column-defs [objThis]=\"this\" [colDetalle]=\"columnasTabla\"\n [nombreColeccion]=\"nombreColeccion\" [(chkLista)]=\"chkLista\"></jvs-tabla-mantenimiento-column-defs>\n\n <tr *matHeaderRowDef=\"visibleColumns; sticky: true\" mat-header-row class=\"title\" matHeader\n ></tr>\n\n @if (!!filaExtraHeader) {\n <tr mat-row *matRowDef=\"let row; columns: ['filaExtraHeader']\" class=\"student-detail-row\"\n [style.height.px]=\"0\"\n ></tr>\n <ng-container matColumnDef=\"filaExtraHeader\">\n <td mat-cell *matCellDef=\"let row; let i = dataIndex\" [attr.colspan]=\"visibleColumns.length\">\n <div class=\"row m-0 student-element-detail\"\n [@detailExpand]=\"(i == 0 && filaExtraHeader.esVisible && filaExtraHeader.esVisible()) ? 'expanded' : 'collapsed'\"\n [style.padding-right.px]=\"row.isExpanded ? 5 : 0\"\n [style.padding-left.px]=\"row.isExpanded ? 5 : 0\"\n >\n @if (filaExtraHeader.template) {\n <ng-container\n [ngTemplateOutlet]=\"filaExtraHeader.template\"\n [ngTemplateOutletContext]=\"{ row: row }\"></ng-container>\n }\n </div>\n </td>\n </ng-container>\n }\n @if (filaFooter) {\n <tr *matFooterRowDef=\"visibleColumns\" mat-footer-row\n [style.height.px]=\"0\"\n [id]=\"nombreColeccion + '_filaFooter'\"\n ></tr>\n }\n\n <!--\t<tr\n *matRowDef=\"let row; columns: visibleColumns;\"\n class=\"hover:bg-secondary trans-ease-out cursor-pointer\"\n mat-row></tr>-->\n <tr\n [matRowKeyboardSelection]=\"tablaMantenimiento\"\n [rowModel]=\"row\"\n (seleccionarSiguiente)=\"opcMenu($event, {seccion: nombreColeccion, tipo: 'ver'});\"\n\n *matRowDef=\"let row; let idxTabla = dataIndex; columns: visibleColumns;\"\n (click)=\"seleccionarItem(row); opcMenu(row, {seccion: nombreColeccion, tipo: 'ver', tableDataIndex: idxTabla });\"\n (dblclick)=\"opcMenu(row, {seccion: nombreColeccion, tipo: 'seleccionar'}); dblclickItem.emit(row)\"\n (contextmenu)=\"(abrirMenuContextual($event, row)); $event. preventDefault();\"\n [ngClass]=\"classFila(row)\"\n @fadeInUp\n class=\"trans-ease-out cursor-pointer h-auto\"\n [style.height.px]=\"0\"\n [id]=\"propiedadSeleccion(row)\"\n [matTooltip]=\"procesarRowTooltip(row)\"\n matTooltipPosition=\"below\"\n [matTooltipPositionAtOrigin]=\"true\"\n [matTooltipClass]=\"['bg-red-700', 'text-red-100', 'm-0']\"\n [matTooltipDisabled]=\"!procesarRowTooltip(row)\"\n [class.regAnulado]=\"row[campoAnulado] == 1\"\n [class.regTooltip]=\"!!procesarRowTooltip(row)\"\n (keyup.delete)=\"opcMenu(row, {seccion: nombreColeccion, tipo: 'eliminar'})\"\n mat-row></tr>\n @if (filaExtraTemplate) {\n <tr mat-row *matRowDef=\"let row; columns: ['expandedDetail']\" class=\"student-detail-row h-0\"></tr>\n <ng-container matColumnDef=\"expandedDetail\">\n <td mat-cell *matCellDef=\"let row\" [attr.colspan]=\"visibleColumns.length\">\n <div class=\"row m-0 student-element-detail\"\n [@detailExpand]=\"row.isExpanded ? 'expanded' : 'collapsed'\"\n [style.padding-right.px]=\"row.isExpanded ? 5 : 0\"\n [style.padding-left.px]=\"row.isExpanded ? 5 : 0\"\n >\n <ng-container [ngTemplateOutlet]=\"filaExtraTemplate\"\n [ngTemplateOutletContext]=\"{ row: row }\"></ng-container>\n </div>\n </td>\n </ng-container>\n }\n</table>\n\n@if (componenteCargadoTotalmente) {\n @if ((noData | async) && esTabla) {\n <div class=\"flex-1 text-center text-secondary font-medium\">\n No se encontraron datos\n </div>\n }\n}\n</div>\n<ng-content select=\"[appendTable]\"></ng-content>\n<div class=\"flex-none bg-app-bar flex flex-col sm:flex-row items-start justify-between p-1\">\n <div class=\"flex-1 flex items-start flex-wrap gap-1\">\n\n @if ((botonesMenuFinal.inferior ?? []).length > 0) {\n <div class=\"flex items-center contenedor-botones\">\n @for (btn of botonesMenu.inferior; track btn; let idx = $index) {\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.inferior?.length}}\"></ng-container>\n }\n </div>\n }\n <!--<div *ngIf=\"(botonesMenuFinal.inferior ?? []).length > 0\" class=\" flex items-center flex-wrap\">\n <ng-container *ngFor=\"let btn of botonesMenu.inferior; let idx = index;\">\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.inferior?.length}}\"></ng-container>\n </ng-container>\n </div>-->\n</div>\n\n@if (esTabla && paginador) {\n <div class=\"flex-1 sm:flex-none flex items-center justify-end\">\n <mat-paginator class=\"tabla-mantenimiento-paginador\" [pageSizeOptions]=\"paginacion.pageSizeOptions\" [pageIndex]=\"paginacion.pageIndex - 1\" [length]=\"paginacion.pageLength\" [pageSize]=\"paginacion.pageSize\" (page)=\"paginacion.pageCurrent = $event; emitirResultados();\" ></mat-paginator>\n </div>\n}\n</div>\n</div>\n\n</div>\n\n\n\n<!-- SECCION DE TEMPLATES O MENUS -->\n\n\n<mat-menu #columnFilterMenu=\"matMenu\" xPosition=\"before\" yPosition=\"below\">\n @for (column of columnasTabla; track column) {\n @if (!tipoValorFuncion(column.noMostrarEnLista, false)) {\n <button (click)=\"toggleColumnVisibility(column, $event)\"\n class=\"checkbox-item mat-menu-item\">\n <mat-checkbox (click)=\"$event.stopPropagation()\" [(ngModel)]=\"column.visible\" [ngModelOptions]=\"{standalone: true}\" color=\"primary\">\n <span [innerHTML]=\"(column.labelLista ?? column.label).replace('<br>', ' ')\"></span>\n </mat-checkbox>\n </button>\n }\n }\n</mat-menu>\n\n\n\n\n\n\n<ng-template #botonesSuperiores let-btn=\"btn\" let-idx=\"idx\">\n <ng-container *ngTemplateOutlet=\"botonesContextual; context:{btn: btn, item: objSeleccionado, barraSuperior: true, idx: idx}\"></ng-container>\n</ng-template>\n\n<ng-template #botonesContextual let-btn=\"btn\" let-item=\"item\" let-barraSuperior=\"barraSuperior\" let-idx=\"idx\">\n\n @if (barraSuperior) {\n <!--\t\t<button mat-button style=\"min-width: unset; border: 1px !important;\" class=\"uppercase border border-gray rounded-none h-full px-1 disabled:opacity-50 disabled:text-secondary disabled:bg-transparent\">-->\n <!--\t\t\t<mat-icon *ngIf=\"btn.icono\" [svgIcon]=\"btn.icono\" size=\"15px\" class=\"icon-xs\"></mat-icon>-->\n <!--\t\t</button>-->\n @if (btn.subItems && btn.subItems.length > 0) {\n @if ((!btn.esVisible || btn.esVisible(item, this)) && subItemsActivos(btn, item)) {\n <button class=\"flex items-center justify-between uppercase text-2xs leading-none rounded-none px-2 py-1 bg-opacity-95 hover:bg-opacity-100 disabled:opacity-50 disabled:text-secondary disabled:!bg-gray-300 dark:disabled:!bg-gray-500 mat-elevation-z2\" type=\"button\"\n [class]=\"(btn.class?btn.class:'')\"\n (click)=\"opcMenu(item, btn)\"\n [style.min-width]=\"((btn.soloIcono ?? tipoValorFuncion(soloIconos)) ? 'unset' : '')\"\n [matTooltip]=\"btn.tooltip || (btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo))) \"\n [matMenuTriggerFor]=\"menuOtrosBarra.menu\"\n [matBadge]=\"btn.badge\"\n matBadgeSize=\"small\"\n >\n @if (btn.icono) {\n <mat-icon class=\"icon-xs\" [class.mr-0.5]=\"!(btn.soloIcono ?? tipoValorFuncion(soloIconos))\" [svgIcon]=\"btn.icono\" ></mat-icon>\n }\n @if (!(btn.soloIcono ?? tipoValorFuncion(soloIconos))) {\n <span class=\"whitespace-nowrap\">{{ btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo)) }}</span>\n }\n <mat-icon class=\"icon-xs\" svgIcon=\"fa5sCaretDown\" ></mat-icon>\n </button>\n }\n <jvs-tabla-mantenimiento-menu #menuOtrosBarra\n [objThis]=\"objThis\"\n [nombreColeccion]=\"nombreColeccion\"\n [item]=\"item\"\n [derechosActuales]=\"derechosActuales\"\n [subItems]=\"btn.subItems\"\n (opcionSelecionada)=\"opcMenu($event.item, $event.btn)\"\n [botonTemplate]=\"botonesContextual\"\n >\n </jvs-tabla-mantenimiento-menu>\n }\n @if (!btn.subItems || btn.subItems.length == 0) {\n @if (!btn.esVisible || btn.esVisible(item, this)) {\n <button class=\"flex items-center justify-between uppercase text-2xs leading-none rounded-none px-2 py-1 bg-opacity-95 hover:bg-opacity-100 disabled:opacity-50 disabled:text-secondary disabled:!bg-gray-300 dark:disabled:!bg-gray-500 mat-elevation-z2\" type=\"button\"\n [class]=\"(btn.class?btn.class:'text-secondary')\"\n [ngClass]=\"{'text-secondary italic': !ignorarDerechos && !btn.esIndependiente && (!btn.ignorarDerecho && (!derechosActuales || !derechosActuales[btn.cDerechoCodigo ?? btn.tipo])) && !(['nuevo', 'editar', 'eliminar'].includes(btn.tipo))}\"\n [disabled]=\"!btn.esIndependiente && botonDisabled(btn, item)\"\n (click)=\"opcMenu(item, btn)\"\n [style.min-width]=\"((btn.soloIcono ?? tipoValorFuncion(soloIconos)) ? 'unset' : '')\"\n [matTooltip]=\"btn.tooltip || (btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo))) \"\n [matBadge]=\"btn.badge\"\n matBadgeSize=\"small\"\n >\n @if (btn.icono) {\n <mat-icon class=\"icon-xs\" [class.mr-0.5]=\"!(btn.soloIcono ?? tipoValorFuncion(soloIconos))\" [svgIcon]=\"btn.icono\"></mat-icon>\n }\n @if (!(btn.soloIcono ?? tipoValorFuncion(soloIconos))) {\n <span class=\"whitespace-nowrap\">{{ btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo)) }}</span>\n }\n </button>\n }\n }\n} @else {\n @if (btn.subItems && btn.subItems.length > 0) {\n @if (!btn.noContextual && (!btn.esVisible || btn.esVisible(item, this))) {\n <button class=\"flex items-center justify-between uppercase w-full rounded-none px-2 disabled:opacity-50 disabled:text-secondary disabled:bg-transparent\" mat-menu-item type=\"button\"\n [class]=\"(btn.class?btn.class.replace('text-white', '').replace('bg', 'text'):'text-secondary')\"\n [ngClass]=\"{'text-secondary italic': !ignorarDerechos && !btn.esIndependiente && (!btn.ignorarDerecho && (!derechosActuales || !derechosActuales[btn.cDerechoCodigo ?? btn.tipo]))}\"\n [disabled]=\"!btn.esIndependiente && botonDisabled(btn, item)\"\n (click)=\"opcMenu(item, btn); $event.stopPropagation();\"\n [matMenuTriggerFor]=\"menuOtrosBarra.menu\"\n >\n <div class=\"flex w-full items-center justify-between uppercase text-2xs\"\n >\n @if (btn.icono) {\n <mat-icon [svgIcon]=\"btn.icono\"\n class=\"flex-none icon-xs\"\n ></mat-icon>\n }\n <span class=\"grow text-2xs\">{{ btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo)) }}</span>\n <mat-icon class=\"flex-none icon-xs\" svgIcon=\"fa5sCaretRight\"></mat-icon>\n </div>\n </button>\n }\n <jvs-tabla-mantenimiento-menu #menuOtrosBarra\n [objThis]=\"objThis\"\n [nombreColeccion]=\"nombreColeccion\"\n [item]=\"item\"\n [derechosActuales]=\"derechosActuales\"\n [subItems]=\"btn.subItems\"\n (opcionSelecionada)=\"opcMenu($event.item, $event.btn)\"\n [botonTemplate]=\"botonesContextual\"\n >\n </jvs-tabla-mantenimiento-menu>\n }\n @if (!btn.subItems || btn.subItems.length == 0) {\n @if (btn.tipo == '-#SEPARADOR#-') {\n <mat-divider></mat-divider>\n } @else {\n @if (!btn.noContextual && (!btn.esVisible || btn.esVisible(item, this))) {\n <button class=\"flex items-center justify-between uppercase w-full rounded-none px-2 disabled:opacity-50 disabled:text-secondary disabled:bg-transparent\" mat-menu-item type=\"button\"\n [class]=\"(btn.class?btn.class.replace('text-white', '').replace('bg', 'text'):'text-secondary')\"\n [ngClass]=\"{'text-secondary italic': !ignorarDerechos && !btn.esIndependiente && (!btn.ignorarDerecho && (!derechosActuales || !derechosActuales[btn.cDerechoCodigo ?? btn.tipo]))}\"\n [disabled]=\"!btn.esIndependiente && botonDisabled(btn, item)\"\n (click)=\"opcMenu(item, btn)\"\n >\n <div class=\"flex w-full items-center justify-between uppercase text-2xs\">\n @if (btn.icono) {\n <mat-icon [svgIcon]=\"btn.icono\" class=\"flex-none icon-xs\"\n ></mat-icon>\n }\n <span class=\"grow text-2xs\">{{ btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo)) }}</span>\n </div>\n </button>\n }\n }\n }\n}\n\n</ng-template>\n\n<ng-template #userMenu let-item=\"item\">\n <div class=\"mat-menu bg-white rounded mat-elevation-z8 shadow botonesContextual\">\n @for (btn of listaMenuCompleto; track btn) {\n <ng-container *ngTemplateOutlet=\"botonesContextual; context:{btn: btn, item: objSeleccionado, barraSuperior: false}\"></ng-container>\n }\n </div>\n</ng-template>\n\n\n<mat-menu #menuOpciones=\"matMenu\" xPosition=\"before\" yPosition=\"below\">\n @for (btn of listaMenuCompleto; track btn) {\n <ng-container\n *ngTemplateOutlet=\"botonesContextual; context:{btn: btn, item: objSeleccionado, barraSuperior: false}\"></ng-container>\n }\n</mat-menu>\n\n", styles: ["@charset \"UTF-8\";:root{--tabla-mantenimiento-seleccion-fondo: rgb(179, 217, 252);--tabla-mantenimiento-seleccion-texto: rgb(1, 84, 164);--mat-paginator-container-size: 30px}:root .table-mantenimiento .elemento-seleccionado{background-color:var(--tabla-mantenimiento-seleccion-fondo)!important;color:var(--tabla-mantenimiento-seleccion-texto)!important;border-color:var(--tabla-mantenimiento-seleccion-texto)!important}.jvs-tabla-mantenimiento{width:inherit;display:flex;flex-direction:column}.jvs-tabla-mantenimiento .contenedor-botones>*:first-child{@apply rounded-l;}.jvs-tabla-mantenimiento .contenedor-botones>*:last-child{@apply rounded-r;}.jvs-tabla-mantenimiento tr.regTooltip>td:first-child div:first-child:before,.jvs-tabla-mantenimiento tr.regTooltip>th:first-child div:first-child:before{content:\"\\26a0\\fe0f \";color:red;margin-right:4px;font-size:12px}.jvs-tabla-mantenimiento tr.regTooltip>td:first-child:not(:has(div)):before,.jvs-tabla-mantenimiento tr.regTooltip>th:first-child:not(:has(div)):before{content:\"\\26a0\\fe0f \";color:red;margin-right:4px;font-size:12px}.jvs-tabla-mantenimiento .mat-mdc-menu-content:not(:empty){@apply flex flex-col items-start;padding:0!important}.jvs-tabla-mantenimiento .mat-mdc-menu-item{line-height:24px!important;height:24px!important;min-height:24px!important}.jvs-tabla-mantenimiento .mat-mdc-menu-panel{min-height:auto!important}.jvs-tabla-mantenimiento .mat-mdc-table .mat-mdc-cell,.jvs-tabla-mantenimiento .mat-mdc-table .mat-mdc-header-cell .mat-mdc-footer-cell{white-space:unset}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-table-sticky-border-elem-right{border-left:1px solid #e0e0e0}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-table-sticky-border-elem-left{border-right:1px solid #e0e0e0}.jvs-tabla-mantenimiento .table-mantenimiento tr.regAnulado .mat-mdc-cell{color:unset!important}.jvs-tabla-mantenimiento .table-mantenimiento .bg-primary-activo .numeracionFila{@apply rounded-full bg-primary-contrast text-primary mx-1 p-1 w-6 h-6;}.jvs-tabla-mantenimiento .table-mantenimiento th .form-input{@apply w-auto;}.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell:not(.celda-numeracion-fila),.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-cell:not(.celda-numeracion-fila),.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-footer-cell:not(.celda-numeracion-fila){padding:.05rem .25rem}.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell,.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-cell,.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-footer-cell{border-width:1px;border-style:solid}.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell:first-of-type:not(.celda-numeracion-fila),.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell:last-of-type:not(.celda-numeracion-fila),.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-cell:first-of-type:not(.celda-numeracion-fila),.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-cell:last-of-type:not(.celda-numeracion-fila),.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-footer-cell:first-of-type:not(.celda-numeracion-fila),.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-footer-cell:last-of-type:not(.celda-numeracion-fila){padding:0 .25rem}.jvs-tabla-mantenimiento .table-mantenimiento .student-element-detail{overflow:hidden;display:flex;align-items:center;justify-content:center}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-header-row{height:25px!important;color:rgb(var(--color-primary))!important;background-color:rgb(var(--color-primary-contrast))!important}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-header-cell{padding:5px;font-size:10px;line-height:10px;font-weight:700!important;color:inherit}.jvs-tabla-mantenimiento .table-mantenimiento .mdc-data-table__row:not(.mdc-data-table__row--selected):not(.elemento-seleccionado):hover,.jvs-tabla-mantenimiento .table-mantenimiento .mdc-data-table__row:not(.mdc-data-table__row--selected):not(.elemento-seleccionado):focus{background-color:rgba(var(--color-primary-contrast),.04)}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-row .mat-mdc-cell,.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-footer-row .mat-mdc-cell{font-size:10px}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-row .mat-mdc-footer-cell:empty,.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-footer-row .mat-mdc-footer-cell:empty{border-width:0!important}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-cell{@apply leading-tight;}.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell{border-color:#d4d0d0;@apply text-center uppercase;}.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell .mat-sort-header-container{@apply flex items-center justify-between w-full;}.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell .mat-sort-header-container .mat-sort-header-content{@apply inline w-full text-center;}.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell .mat-sort-header-container .mat-sort-header-arrow{@apply flex-none;}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-sort-header-content{width:100%;text-align:center;display:unset;align-items:center}.compact-search-menu{min-width:200px!important;overflow:hidden}.compact-search-menu input:focus{@apply border-primary;}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1$2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: MatCheckboxModule }, { kind: "component", type: i3$1.MatCheckbox, selector: "mat-checkbox", inputs: ["aria-label", "aria-labelledby", "aria-describedby", "aria-expanded", "aria-controls", "aria-owns", "id", "required", "labelPosition", "name", "value", "disableRipple", "tabIndex", "color", "disabledInteractive", "checked", "disabled", "indeterminate"], outputs: ["change", "indeterminateChange"], exportAs: ["matCheckbox"] }, { kind: "ngmodule", type: MatDividerModule }, { kind: "component", type: i6.MatDivider, selector: "mat-divider", inputs: ["vertical", "inset"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i5.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatMenuModule }, { kind: "component", type: i8.MatMenu, selector: "mat-menu", inputs: ["backdropClass", "aria-label", "aria-labelledby", "aria-describedby", "xPosition", "yPosition", "overlapTrigger", "hasBackdrop", "class", "classList"], outputs: ["closed", "close"], exportAs: ["matMenu"] }, { kind: "component", type: i8.MatMenuItem, selector: "[mat-menu-item]", inputs: ["role", "disabled", "disableRipple"], exportAs: ["matMenuItem"] }, { kind: "directive", type: i8.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", inputs: ["mat-menu-trigger-for", "matMenuTriggerFor", "matMenuTriggerData", "matMenuTriggerRestoreFocus"], outputs: ["menuOpened", "onMenuOpen", "menuClosed", "onMenuClose"], exportAs: ["matMenuTrigger"] }, { kind: "ngmodule", type: MatPaginatorModule }, { kind: "component", type: i9.MatPaginator, selector: "mat-paginator", inputs: ["color", "pageIndex", "length", "pageSize", "pageSizeOptions", "hidePageSize", "showFirstLastButtons", "selectConfig", "disabled"], outputs: ["page"], exportAs: ["matPaginator"] }, { kind: "ngmodule", type: MatRippleModule }, { kind: "directive", type: i5$1.MatRipple, selector: "[mat-ripple], [matRipple]", inputs: ["matRippleColor", "matRippleUnbounded", "matRippleCentered", "matRippleRadius", "matRippleAnimation", "matRippleDisabled", "matRippleTrigger"], exportAs: ["matRipple"] }, { kind: "ngmodule", type: MatSortModule }, { kind: "directive", type: i3.MatSort, selector: "[matSort]", inputs: ["matSortActive", "matSortStart", "matSortDirection", "matSortDisableClear", "matSortDisabled"], outputs: ["matSortChange"], exportAs: ["matSort"] }, { kind: "ngmodule", type: MatTableModule }, { kind: "component", type: i2.MatTable, selector: "mat-table, table[mat-table]", exportAs: ["matTable"] }, { kind: "directive", type: i2.MatHeaderCellDef, selector: "[matHeaderCellDef]" }, { kind: "directive", type: i2.MatHeaderRowDef, selector: "[matHeaderRowDef]", inputs: ["matHeaderRowDef", "matHeaderRowDefSticky"] }, { kind: "directive", type: i2.MatColumnDef, selector: "[matColumnDef]", inputs: ["matColumnDef"] }, { kind: "directive", type: i2.MatCellDef, selector: "[matCellDef]" }, { kind: "directive", type: i2.MatRowDef, selector: "[matRowDef]", inputs: ["matRowDefColumns", "matRowDefWhen"] }, { kind: "directive", type: i2.MatFooterCellDef, selector: "[matFooterCellDef]" }, { kind: "directive", type: i2.MatFooterRowDef, selector: "[matFooterRowDef]", inputs: ["matFooterRowDef", "matFooterRowDefSticky"] }, { kind: "directive", type: i2.MatHeaderCell, selector: "mat-header-cell, th[mat-header-cell]" }, { kind: "directive", type: i2.MatCell, selector: "mat-cell, td[mat-cell]" }, { kind: "directive", type: i2.MatFooterCell, selector: "mat-footer-cell, td[mat-footer-cell]" }, { kind: "component", type: i2.MatHeaderRow, selector: "mat-header-row, tr[mat-header-row]", exportAs: ["matHeaderRow"] }, { kind: "component", type: i2.MatRow, selector: "mat-row, tr[mat-row]", exportAs: ["matRow"] }, { kind: "component", type: i2.MatFooterRow, selector: "mat-footer-row, tr[mat-footer-row]", exportAs: ["matFooterRow"] }, { kind: "ngmodule", type: MatTooltipModule }, { kind: "directive", type: i4$1.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1$2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: TablaMantenimientoColumnDefsComponent, selector: "jvs-tabla-mantenimiento-column-defs", inputs: ["objThis", "nombreColeccion", "colDetalle", "chkLista"], outputs: ["chkListaChange"] }, { kind: "ngmodule", type: MatBadgeModule }, { kind: "directive", type: i14.MatBadge, selector: "[matBadge]", inputs: ["matBadgeColor", "matBadgeOverlap", "matBadgeDisabled", "matBadgePosition", "matBadge", "matBadgeDescription", "matBadgeSize", "matBadgeHidden"] }, { kind: "component", type: TablaMantenimientoMenuComponent, selector: "jvs-tabla-mantenimiento-menu", inputs: ["objThis", "nombreColeccion", "item", "derechosActuales", "subItems", "botonTemplate"], outputs: ["opcionSelecionada"] }, { kind: "directive", type: MatRowKeyboardSelectionDirective, selector: "[matRowKeyboardSelection]", inputs: ["matRowKeyboardSelection", "rowModel"], outputs: ["seleccionarSiguiente"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }], animations: [
|
|
1874
|
+
], queries: [{ propertyName: "columnDefs", predicate: MatColumnDef, descendants: true }], viewQueries: [{ propertyName: "paginator", first: true, predicate: MatPaginator, descendants: true }, { propertyName: "sort", first: true, predicate: MatSort, descendants: true }, { propertyName: "table", first: true, predicate: MatTable, descendants: true }, { propertyName: "userMenu", first: true, predicate: ["userMenu"], descendants: true }, { propertyName: "compactSearchMenuTrigger", first: true, predicate: ["compactSearchMenuTrigger"], descendants: true, read: MatMenuTrigger }, { propertyName: "rows", predicate: MatRow, descendants: true, read: ElementRef }], usesOnChanges: true, ngImport: i0, template: "<div class=\"flex flex-col\" [ngClass]=\"alturaFull() ? 'h-full' : 'h-fit'\">\n <div class=\"flex-none flex items-center justify-between bg-white\">\n <ng-content select=\"[filtro]\"></ng-content>\n </div>\n\n <div class=\"flex flex-col border-t\" [ngClass]=\"alturaFull() ? 'grow' : ''\">\n <div class=\"flex-none bg-app-bar flex items-center justify-between p-1\">\n <!-- <div class=\"hidden flex-1 sm:flex items-center flex-wrap gap-1\">-->\n <!-- </div>-->\n @if (leyenda) {\n <div class=\"flex items-center flex-wrap mr-1 h-full\">\n <span class=\"font-bold\" [class]=\"leyenda.class\">{{ leyenda.text }}</span>\n </div>\n }\n <div class=\"hidden flex-1 sm:flex items-center flex-wrap gap-1\">\n @if ((botonesMenuFinal.izquierda ?? []).length > 0 ) {\n <div class=\" flex items-center flex-wrap contenedor-botones\">\n @for (btn of botonesMenuFinal.izquierda; track btn; let idx = $index) {\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenuFinal.izquierda?.length}}\"></ng-container>\n }\n </div>\n }\n\n @if ((botonesMenuFinal.crud ?? []).length > 0) {\n <div class=\" flex items-center flex-wrap contenedor-botones\">\n @for (btn of botonesMenuFinal.crud; track btn; let idx = $index) {\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenuFinal.crud?.length}}\"></ng-container>\n }\n </div>\n }\n\n @if ((botonesMenuFinal.principal ?? []).length > 0) {\n <div class=\" flex items-center flex-wrap contenedor-botones\">\n @for (btn of botonesMenuFinal.principal; track btn; let idx = $index) {\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenuFinal.principal?.length}}\"></ng-container>\n }\n </div>\n }\n\n @if ((botonesMenuFinal.derecha ?? []).length > 0) {\n <div class=\"flex-auto flex items-center justify-end contenedor-botones\">\n @for (btn of botonesMenuFinal.derecha; track btn; let idx = $index) {\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenuFinal.derecha?.length}}\"></ng-container>\n }\n </div>\n }\n <ng-content select=\"[objetosMenuPegado]\"></ng-content>\n </div>\n <div class=\"flex flex-1 sm:hidden items-center flex-wrap gap-1\">\n <button class=\"flex items-center justify-center text-2xs leading-none rounded-full p-1\"\n matRipple\n matTooltip=\"Botones de Acci\u00F3n\"\n type=\"button\"\n [matMenuTriggerFor]=\"menuOpciones\"\n >\n <mat-icon class=\"icon-xs\" svgIcon=\"roundMenu\"></mat-icon>\n </button>\n </div>\n <div class=\"flex-none flex items-center justify-end border-l-2\">\n <div class=\"flex-1 sm:flex-none flex items-center justify-end\">\n <ng-content select=\"[objetosMenu]\"></ng-content>\n </div>\n </div>\n @if (busquedaTipo() && !busquedaCompacta()) {\n <div class=\"hidden flex-initial sm:flex items-center form-input max-w-[150px] bg-card rounded-full border m-1 px-1 border-l-2\"\n >\n <mat-icon svgIcon=\"roundSearch\" class=\"icon-xs\"></mat-icon>\n <input [formControl]=\"cCampoBusqueda\"\n class=\"text-xs px-1 py-1 border-0 outline-none w-full bg-transparent max-w-sm\"\n [placeholder]=\"busquedaPlaceholder()\"\n (keyup.enter)=\"busquedaTipo() == 'query' ? cargarData() : false;\"\n type=\"search\">\n </div>\n }\n\n\n <mat-menu #compactSearchMenu=\"matMenu\" class=\"compact-search-menu\">\n <div class=\"flex items-center gap-1\" (click)=\"$event.stopPropagation()\">\n <mat-icon svgIcon=\"roundSearch\" class=\"icon-xs text-gray-400\"></mat-icon>\n <input [formControl]=\"cCampoBusqueda\"\n class=\"text-xs px-2 py-1 border border-gray-200 rounded outline-none w-[180px] bg-white\"\n [placeholder]=\"busquedaPlaceholder()\"\n (keyup.enter)=\"ejecutarBusquedaCompacta()\"\n type=\"search\"\n (click)=\"$event.stopPropagation()\">\n </div>\n </mat-menu>\n <div class=\"flex-none flex items-center justify-end border-l-2\">\n <ng-content select=\"[botonesFiltro]\"></ng-content>\n <ng-content select=\"[botonesConfig]\"></ng-content>\n\n @if (busquedaTipo() && busquedaCompacta()) {\n <button matRipple\n class=\"flex items-center justify-center text-2xs leading-none rounded-full p-1\"\n matTooltip=\"Buscar...\"\n [matMenuTriggerFor]=\"compactSearchMenu\"\n #compactSearchMenuTrigger=\"matMenuTrigger\"\n type=\"button\">\n <mat-icon svgIcon=\"roundSearch\" class=\"icon-xs\"></mat-icon>\n </button>\n }\n\n @if (isRecargarUsed || busquedaTipo() == 'query') {\n <button matRipple\n class=\"flex items-center justify-center text-2xs leading-none rounded-full p-1 text-green-700\"\n matTooltip=\"Actualizar datos\"\n (click)=\"(busquedaTipo() == 'query' ? cargarData() : emitirAccionRecargar())\"\n type=\"button\">\n <mat-icon svgIcon=\"roundRefresh\" class=\"icon-xs\"></mat-icon>\n </button>\n }\n @if (mostrarBotonOrden()) {\n <button matRipple\n class=\"flex items-center justify-center text-2xs leading-none rounded-full p-1 text-blue-700\"\n [matTooltip]=\"bDireccionOrden() === 0 ? 'Orden Ascendente' : 'Orden Descendente'\"\n (click)=\"toggleDireccionOrden()\"\n type=\"button\">\n <mat-icon [svgIcon]=\"bDireccionOrden() === 0 ? 'roundArrowUpward' : 'roundArrowDownward'\" class=\"icon-xs\"></mat-icon>\n </button>\n }\n @if (filtroCampos) {\n <button matRipple [matMenuTriggerFor]=\"columnFilterMenu\"\n class=\"flex items-center justify-center text-2xs leading-none rounded-full p-1\"\n matTooltip=\"Columnas Filtro\"\n type=\"button\">\n <mat-icon svgIcon=\"roundFilterList\" class=\"icon-xs\"></mat-icon>\n </button>\n }\n </div>\n </div>\n\n @if ((botonesMenuFinal.secundario ?? []).length > 0) {\n <div class=\"flex-1 bg-app-bar flex items-center justify-between p-1 border-t\">\n <div class=\"hidden flex-1 sm:flex items-center flex-wrap gap-1\">\n <div class=\" flex items-center flex-wrap contenedor-botones\">\n @for (btn of botonesMenuFinal.secundario; track btn; let idx = $index) {\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenuFinal.secundario?.length}}\"></ng-container>\n }\n </div>\n </div>\n </div>\n }\n <!--<div class=\"grow flex flex-col items-stretch contenedor-tabla\" [ngClass]=\"{'table-container overflow-auto': esTabla}\">\n <pre>{{ this.chkLista.modelosChk | json }}</pre>\n <pre>{{ this.chkLista.checkbox.cantidadActivos | json }}</pre>\n <pre>{{ this.chkLista.checkbox.algunosActivos | json }}</pre>\n</div>-->\n<div class=\"grow flex flex-col items-stretch contenedor-tabla\" [ngClass]=\"{'table-container overflow-auto': esTabla}\">\n <ng-content select=\"[cuerpo]\"></ng-content>\n\n <table [id]=\"'tabla_' + nombreColeccion\" [dataSource]=\"dataSource\" [multiTemplateDataRows]=\"true\"\n [hidden]=\"!esTabla\"\n class=\"table-mantenimiento table-auto h-fit\" mat-table matSort\n [trackBy]=\"trackByFn\"\n #tablaMantenimiento\n >\n\n <!--<table [dataSource]=\"dataSource\" class=\"table-mantenimiento table-auto h-auto w-full justify-center\" mat-table matSort>-->\n\n\n <ng-content select=\"[tableDefinitions]\"></ng-content>\n <ng-container matColumnDef=\"numeracion_automatica\">\n <th mat-header-cell *matHeaderCellDef style=\"width: 16px !important\">N\u00BA</th>\n <td mat-cell *matCellDef=\"let element; let i = dataIndex\" class=\"p-0 celda-numeracion-fila\">\n <div class=\"flex items-center justify-center font-bold numeracionFila\">\n @if (esTabla && paginador) {\n {{ (this.paginator?.pageIndex == 0 ? i + 1 : 1 + i + (this.paginator?.pageIndex ?? 1) * (this.paginator?.pageSize ?? 1)) }}\n }\n @if (!paginador) {\n {{ (i + 1) }}\n }\n </div>\n </td>\n <td mat-footer-cell *matFooterCellDef class=\"uppercase\"></td>\n </ng-container>\n <jvs-tabla-mantenimiento-column-defs [objThis]=\"this\" [colDetalle]=\"columnasParaDefinir\" [estaExpandida]=\"estaExpandidaFn\" (alternarExpansion)=\"alternarExpansion($event)\"\n [nombreColeccion]=\"nombreColeccion\" [(chkLista)]=\"chkLista\"></jvs-tabla-mantenimiento-column-defs>\n\n <tr *matHeaderRowDef=\"visibleColumns; sticky: true\" mat-header-row class=\"title\" matHeader\n ></tr>\n\n @if (!!filaExtraHeader) {\n <tr mat-row *matRowDef=\"let row; columns: ['filaExtraHeader']\" class=\"student-detail-row\"\n [style.height.px]=\"0\"\n ></tr>\n <ng-container matColumnDef=\"filaExtraHeader\">\n <td mat-cell *matCellDef=\"let row; let i = dataIndex\" [attr.colspan]=\"visibleColumns.length\">\n <div class=\"row m-0 student-element-detail\"\n [@detailExpand]=\"(i == 0 && filaExtraHeader.esVisible && filaExtraHeader.esVisible()) ? 'expanded' : 'collapsed'\"\n [style.padding-right.px]=\"estaExpandida(row) ? 5 : 0\"\n [style.padding-left.px]=\"estaExpandida(row) ? 5 : 0\"\n >\n @if (filaExtraHeader.template) {\n <ng-container\n [ngTemplateOutlet]=\"filaExtraHeader.template\"\n [ngTemplateOutletContext]=\"{ row: row }\"></ng-container>\n }\n </div>\n </td>\n </ng-container>\n }\n @if (filaFooter) {\n <tr *matFooterRowDef=\"visibleColumns\" mat-footer-row\n [style.height.px]=\"0\"\n [id]=\"nombreColeccion + '_filaFooter'\"\n ></tr>\n }\n\n <!--\t<tr\n *matRowDef=\"let row; columns: visibleColumns;\"\n class=\"hover:bg-secondary trans-ease-out cursor-pointer\"\n mat-row></tr>-->\n <tr\n [matRowKeyboardSelection]=\"tablaMantenimiento\"\n [rowModel]=\"row\"\n (seleccionarSiguiente)=\"opcMenu($event, {seccion: nombreColeccion, tipo: 'ver'});\"\n (filaEnfocada)=\"seleccionarFilaPorId($event)\"\n (espacioEnFila)=\"teclaEspacioEnFila($event)\"\n\n *matRowDef=\"let row; let idxTabla = dataIndex; columns: visibleColumns;\"\n (click)=\"clicFila(row, idxTabla, $event)\"\n (dblclick)=\"dobleClicFila(row)\"\n (contextmenu)=\"(abrirMenuContextual($event, row)); $event. preventDefault();\"\n [ngClass]=\"classFila(row)\"\n @fadeInUp\n class=\"trans-ease-out cursor-pointer h-auto\"\n [style.height.px]=\"0\"\n [id]=\"propiedadSeleccion(row)\"\n [matTooltip]=\"procesarRowTooltip(row)\"\n matTooltipPosition=\"below\"\n [matTooltipPositionAtOrigin]=\"true\"\n [matTooltipClass]=\"['bg-red-700', 'text-red-100', 'm-0']\"\n [matTooltipDisabled]=\"!procesarRowTooltip(row)\"\n [class.regAnulado]=\"row[campoAnulado] == 1\"\n [class.regTooltip]=\"!!procesarRowTooltip(row)\"\n (keyup.delete)=\"teclaEliminarEnFila(row, $event)\"\n mat-row></tr>\n @if (filaExtraTemplate) {\n <tr mat-row *matRowDef=\"let row; columns: ['expandedDetail']\" class=\"student-detail-row h-0\"></tr>\n <ng-container matColumnDef=\"expandedDetail\">\n <td mat-cell *matCellDef=\"let row\" [attr.colspan]=\"visibleColumns.length\">\n <div class=\"row m-0 student-element-detail\"\n [@detailExpand]=\"estaExpandida(row) ? 'expanded' : 'collapsed'\"\n [style.padding-right.px]=\"estaExpandida(row) ? 5 : 0\"\n [style.padding-left.px]=\"estaExpandida(row) ? 5 : 0\"\n >\n <ng-container [ngTemplateOutlet]=\"filaExtraTemplate\"\n [ngTemplateOutletContext]=\"{ row: row }\"></ng-container>\n </div>\n </td>\n </ng-container>\n }\n</table>\n\n@if (componenteCargadoTotalmente) {\n @if ((noData | async) && esTabla) {\n <div class=\"flex-1 text-center text-secondary font-medium\">\n No se encontraron datos\n </div>\n }\n}\n</div>\n<ng-content select=\"[appendTable]\"></ng-content>\n<div class=\"flex-none bg-app-bar flex flex-col sm:flex-row items-start justify-between p-1\">\n <div class=\"flex-1 flex items-start flex-wrap gap-1\">\n\n @if ((botonesMenuFinal.inferior ?? []).length > 0) {\n <div class=\"flex items-center contenedor-botones\">\n @for (btn of botonesMenuFinal.inferior; track btn; let idx = $index) {\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenuFinal.inferior?.length}}\"></ng-container>\n }\n </div>\n }\n <!--<div *ngIf=\"(botonesMenuFinal.inferior ?? []).length > 0\" class=\" flex items-center flex-wrap\">\n <ng-container *ngFor=\"let btn of botonesMenuFinal.inferior; let idx = index;\">\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenuFinal.inferior?.length}}\"></ng-container>\n </ng-container>\n </div>-->\n</div>\n\n@if (esTabla && paginador) {\n <div class=\"flex-1 sm:flex-none flex items-center justify-end\">\n <mat-paginator class=\"tabla-mantenimiento-paginador\" [pageSizeOptions]=\"paginacion.pageSizeOptions\" [pageIndex]=\"paginacion.pageIndex - 1\" [length]=\"paginacion.pageLength\" [pageSize]=\"paginacion.pageSize\" (page)=\"paginacion.pageCurrent = $event; emitirResultados();\" ></mat-paginator>\n </div>\n}\n</div>\n</div>\n\n</div>\n\n\n\n<!-- SECCION DE TEMPLATES O MENUS -->\n\n\n<mat-menu #columnFilterMenu=\"matMenu\" xPosition=\"before\" yPosition=\"below\">\n @for (column of columnasTabla; track column) {\n @if (esColumnaEnLista(column)) {\n <button (click)=\"toggleColumnVisibility(column, $event)\"\n class=\"checkbox-item mat-menu-item\">\n <mat-checkbox (click)=\"$event.stopPropagation()\" [ngModel]=\"esColumnaVisible(column)\" (ngModelChange)=\"column.visible = $event\" [ngModelOptions]=\"{standalone: true}\" color=\"primary\">\n <span [innerHTML]=\"(column.labelLista ?? column.label).replace('<br>', ' ')\"></span>\n </mat-checkbox>\n </button>\n }\n }\n</mat-menu>\n\n\n\n\n\n\n<ng-template #botonesSuperiores let-btn=\"btn\" let-idx=\"idx\">\n <ng-container *ngTemplateOutlet=\"botonesContextual; context:{btn: btn, item: objSeleccionado, barraSuperior: true, idx: idx}\"></ng-container>\n</ng-template>\n\n<ng-template #botonesContextual let-btn=\"btn\" let-item=\"item\" let-barraSuperior=\"barraSuperior\" let-idx=\"idx\">\n\n @if (barraSuperior) {\n <!--\t\t<button mat-button style=\"min-width: unset; border: 1px !important;\" class=\"uppercase border border-gray rounded-none h-full px-1 disabled:opacity-50 disabled:text-secondary disabled:bg-transparent\">-->\n <!--\t\t\t<mat-icon *ngIf=\"btn.icono\" [svgIcon]=\"btn.icono\" size=\"15px\" class=\"icon-xs\"></mat-icon>-->\n <!--\t\t</button>-->\n @if (btn.subItems && btn.subItems.length > 0) {\n @if ((!btn.esVisible || btn.esVisible(item, this)) && subItemsActivos(btn, item)) {\n <button class=\"flex items-center justify-between uppercase text-2xs leading-none rounded-none px-2 py-1 bg-opacity-95 hover:bg-opacity-100 disabled:opacity-50 disabled:text-secondary disabled:!bg-gray-300 dark:disabled:!bg-gray-500 mat-elevation-z2\" type=\"button\"\n [class]=\"(btn.class?btn.class:'')\"\n (click)=\"opcMenu(item, btn)\"\n [style.min-width]=\"((btn.soloIcono ?? tipoValorFuncion(soloIconos)) ? 'unset' : '')\"\n [matTooltip]=\"btn.tooltip || (btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo))) \"\n [matMenuTriggerFor]=\"menuOtrosBarra.menu\"\n [matBadge]=\"btn.badge\"\n matBadgeSize=\"small\"\n >\n @if (btn.icono) {\n <mat-icon class=\"icon-xs\" [class.mr-0.5]=\"!(btn.soloIcono ?? tipoValorFuncion(soloIconos))\" [svgIcon]=\"btn.icono\" ></mat-icon>\n }\n @if (!(btn.soloIcono ?? tipoValorFuncion(soloIconos))) {\n <span class=\"whitespace-nowrap\">{{ btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo)) }}</span>\n }\n <mat-icon class=\"icon-xs\" svgIcon=\"fa5sCaretDown\" ></mat-icon>\n </button>\n }\n <jvs-tabla-mantenimiento-menu #menuOtrosBarra\n [objThis]=\"objThis\"\n [nombreColeccion]=\"nombreColeccion\"\n [item]=\"item\"\n [derechosActuales]=\"derechosActuales\"\n [subItems]=\"btn.subItems\"\n (opcionSelecionada)=\"opcMenu($event.item, $event.btn)\"\n [botonTemplate]=\"botonesContextual\"\n >\n </jvs-tabla-mantenimiento-menu>\n }\n @if (!btn.subItems || btn.subItems.length == 0) {\n @if (!btn.esVisible || btn.esVisible(item, this)) {\n <button class=\"flex items-center justify-between uppercase text-2xs leading-none rounded-none px-2 py-1 bg-opacity-95 hover:bg-opacity-100 disabled:opacity-50 disabled:text-secondary disabled:!bg-gray-300 dark:disabled:!bg-gray-500 mat-elevation-z2\" type=\"button\"\n [class]=\"(btn.class?btn.class:'text-secondary')\"\n [ngClass]=\"{'text-secondary italic': !ignorarDerechos && !btn.esIndependiente && (!btn.ignorarDerecho && (!derechosActuales || !derechosActuales[btn.cDerechoCodigo ?? btn.tipo])) && !(['nuevo', 'editar', 'eliminar'].includes(btn.tipo))}\"\n [disabled]=\"!btn.esIndependiente && botonDisabled(btn, item)\"\n (click)=\"opcMenu(item, btn)\"\n [style.min-width]=\"((btn.soloIcono ?? tipoValorFuncion(soloIconos)) ? 'unset' : '')\"\n [matTooltip]=\"btn.tooltip || (btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo))) \"\n [matBadge]=\"btn.badge\"\n matBadgeSize=\"small\"\n >\n @if (btn.icono) {\n <mat-icon class=\"icon-xs\" [class.mr-0.5]=\"!(btn.soloIcono ?? tipoValorFuncion(soloIconos))\" [svgIcon]=\"btn.icono\"></mat-icon>\n }\n @if (!(btn.soloIcono ?? tipoValorFuncion(soloIconos))) {\n <span class=\"whitespace-nowrap\">{{ btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo)) }}</span>\n }\n </button>\n }\n }\n} @else {\n @if (btn.subItems && btn.subItems.length > 0) {\n @if (!btn.noContextual && (!btn.esVisible || btn.esVisible(item, this))) {\n <button class=\"flex items-center justify-between uppercase w-full rounded-none px-2 disabled:opacity-50 disabled:text-secondary disabled:bg-transparent\" mat-menu-item type=\"button\"\n [class]=\"(btn.class?btn.class.replace('text-white', '').replace('bg', 'text'):'text-secondary')\"\n [ngClass]=\"{'text-secondary italic': !ignorarDerechos && !btn.esIndependiente && (!btn.ignorarDerecho && (!derechosActuales || !derechosActuales[btn.cDerechoCodigo ?? btn.tipo]))}\"\n [disabled]=\"!btn.esIndependiente && botonDisabled(btn, item)\"\n (click)=\"opcMenu(item, btn); $event.stopPropagation();\"\n [matMenuTriggerFor]=\"menuOtrosBarra.menu\"\n >\n <div class=\"flex w-full items-center justify-between uppercase text-2xs\"\n >\n @if (btn.icono) {\n <mat-icon [svgIcon]=\"btn.icono\"\n class=\"flex-none icon-xs\"\n ></mat-icon>\n }\n <span class=\"grow text-2xs\">{{ btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo)) }}</span>\n <mat-icon class=\"flex-none icon-xs\" svgIcon=\"fa5sCaretRight\"></mat-icon>\n </div>\n </button>\n }\n <jvs-tabla-mantenimiento-menu #menuOtrosBarra\n [objThis]=\"objThis\"\n [nombreColeccion]=\"nombreColeccion\"\n [item]=\"item\"\n [derechosActuales]=\"derechosActuales\"\n [subItems]=\"btn.subItems\"\n (opcionSelecionada)=\"opcMenu($event.item, $event.btn)\"\n [botonTemplate]=\"botonesContextual\"\n >\n </jvs-tabla-mantenimiento-menu>\n }\n @if (!btn.subItems || btn.subItems.length == 0) {\n @if (btn.tipo == '-#SEPARADOR#-') {\n <mat-divider></mat-divider>\n } @else {\n @if (!btn.noContextual && (!btn.esVisible || btn.esVisible(item, this))) {\n <button class=\"flex items-center justify-between uppercase w-full rounded-none px-2 disabled:opacity-50 disabled:text-secondary disabled:bg-transparent\" mat-menu-item type=\"button\"\n [class]=\"(btn.class?btn.class.replace('text-white', '').replace('bg', 'text'):'text-secondary')\"\n [ngClass]=\"{'text-secondary italic': !ignorarDerechos && !btn.esIndependiente && (!btn.ignorarDerecho && (!derechosActuales || !derechosActuales[btn.cDerechoCodigo ?? btn.tipo]))}\"\n [disabled]=\"!btn.esIndependiente && botonDisabled(btn, item)\"\n (click)=\"opcMenu(item, btn)\"\n >\n <div class=\"flex w-full items-center justify-between uppercase text-2xs\">\n @if (btn.icono) {\n <mat-icon [svgIcon]=\"btn.icono\" class=\"flex-none icon-xs\"\n ></mat-icon>\n }\n <span class=\"grow text-2xs\">{{ btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo)) }}</span>\n </div>\n </button>\n }\n }\n }\n}\n\n</ng-template>\n\n<ng-template #userMenu let-item=\"item\">\n <div class=\"mat-menu bg-white rounded mat-elevation-z8 shadow botonesContextual\">\n @for (btn of listaMenuCompleto; track btn) {\n <ng-container *ngTemplateOutlet=\"botonesContextual; context:{btn: btn, item: objSeleccionado, barraSuperior: false}\"></ng-container>\n }\n </div>\n</ng-template>\n\n\n<mat-menu #menuOpciones=\"matMenu\" xPosition=\"before\" yPosition=\"below\">\n @for (btn of listaMenuCompleto; track btn) {\n <ng-container\n *ngTemplateOutlet=\"botonesContextual; context:{btn: btn, item: objSeleccionado, barraSuperior: false}\"></ng-container>\n }\n</mat-menu>\n\n", styles: ["@charset \"UTF-8\";:root{--tabla-mantenimiento-seleccion-fondo: rgb(179, 217, 252);--tabla-mantenimiento-seleccion-texto: rgb(1, 84, 164);--mat-paginator-container-size: 30px}:root .table-mantenimiento .elemento-seleccionado{background-color:var(--tabla-mantenimiento-seleccion-fondo)!important;color:var(--tabla-mantenimiento-seleccion-texto)!important;border-color:var(--tabla-mantenimiento-seleccion-texto)!important}.jvs-tabla-mantenimiento{width:inherit;display:flex;flex-direction:column}.jvs-tabla-mantenimiento .contenedor-botones>*:first-child{@apply rounded-l;}.jvs-tabla-mantenimiento .contenedor-botones>*:last-child{@apply rounded-r;}.jvs-tabla-mantenimiento tr.regTooltip>td:first-child div:first-child:before,.jvs-tabla-mantenimiento tr.regTooltip>th:first-child div:first-child:before{content:\"\\26a0\\fe0f \";color:red;margin-right:4px;font-size:12px}.jvs-tabla-mantenimiento tr.regTooltip>td:first-child:not(:has(div)):before,.jvs-tabla-mantenimiento tr.regTooltip>th:first-child:not(:has(div)):before{content:\"\\26a0\\fe0f \";color:red;margin-right:4px;font-size:12px}.jvs-tabla-mantenimiento .mat-mdc-menu-content:not(:empty){@apply flex flex-col items-start;padding:0!important}.jvs-tabla-mantenimiento .mat-mdc-menu-item{line-height:24px!important;height:24px!important;min-height:24px!important}.jvs-tabla-mantenimiento .mat-mdc-menu-panel{min-height:auto!important}.jvs-tabla-mantenimiento .mat-mdc-table .mat-mdc-cell,.jvs-tabla-mantenimiento .mat-mdc-table .mat-mdc-header-cell .mat-mdc-footer-cell{white-space:unset}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-table-sticky-border-elem-right{border-left:1px solid #e0e0e0}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-table-sticky-border-elem-left{border-right:1px solid #e0e0e0}.jvs-tabla-mantenimiento .table-mantenimiento tr.regAnulado .mat-mdc-cell{color:unset!important}.jvs-tabla-mantenimiento .table-mantenimiento .bg-primary-activo .numeracionFila{@apply rounded-full bg-primary-contrast text-primary mx-1 p-1 w-6 h-6;}.jvs-tabla-mantenimiento .table-mantenimiento th .form-input{@apply w-auto;}.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell:not(.celda-numeracion-fila),.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-cell:not(.celda-numeracion-fila),.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-footer-cell:not(.celda-numeracion-fila){padding:.05rem .25rem}.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell,.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-cell,.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-footer-cell{border-width:1px;border-style:solid}.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell:first-of-type:not(.celda-numeracion-fila),.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell:last-of-type:not(.celda-numeracion-fila),.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-cell:first-of-type:not(.celda-numeracion-fila),.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-cell:last-of-type:not(.celda-numeracion-fila),.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-footer-cell:first-of-type:not(.celda-numeracion-fila),.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-footer-cell:last-of-type:not(.celda-numeracion-fila){padding:0 .25rem}.jvs-tabla-mantenimiento .table-mantenimiento .student-element-detail{overflow:hidden;display:flex;align-items:center;justify-content:center}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-header-row{height:25px!important;color:rgb(var(--color-primary))!important;background-color:rgb(var(--color-primary-contrast))!important}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-header-cell{padding:5px;font-size:10px;line-height:10px;font-weight:700!important;color:inherit}.jvs-tabla-mantenimiento .table-mantenimiento .mdc-data-table__row:not(.mdc-data-table__row--selected):not(.elemento-seleccionado):hover,.jvs-tabla-mantenimiento .table-mantenimiento .mdc-data-table__row:not(.mdc-data-table__row--selected):not(.elemento-seleccionado):focus{background-color:rgba(var(--color-primary-contrast),.04)}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-row .mat-mdc-cell,.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-footer-row .mat-mdc-cell{font-size:10px}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-row .mat-mdc-footer-cell:empty,.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-footer-row .mat-mdc-footer-cell:empty{border-width:0!important}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-cell{@apply leading-tight;}.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell{border-color:#d4d0d0;@apply text-center uppercase;}.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell .mat-sort-header-container{@apply flex items-center justify-between w-full;}.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell .mat-sort-header-container .mat-sort-header-content{@apply inline w-full text-center;}.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell .mat-sort-header-container .mat-sort-header-arrow{@apply flex-none;}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-sort-header-content{width:100%;text-align:center;display:unset;align-items:center}.compact-search-menu{min-width:200px!important;overflow:hidden}.compact-search-menu input:focus{@apply border-primary;}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i4$2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i4$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i4$2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: MatCheckboxModule }, { kind: "component", type: i3$1.MatCheckbox, selector: "mat-checkbox", inputs: ["aria-label", "aria-labelledby", "aria-describedby", "aria-expanded", "aria-controls", "aria-owns", "id", "required", "labelPosition", "name", "value", "disableRipple", "tabIndex", "color", "disabledInteractive", "checked", "disabled", "indeterminate"], outputs: ["change", "indeterminateChange"], exportAs: ["matCheckbox"] }, { kind: "ngmodule", type: MatDividerModule }, { kind: "component", type: i6.MatDivider, selector: "mat-divider", inputs: ["vertical", "inset"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i5.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatMenuModule }, { kind: "component", type: i8.MatMenu, selector: "mat-menu", inputs: ["backdropClass", "aria-label", "aria-labelledby", "aria-describedby", "xPosition", "yPosition", "overlapTrigger", "hasBackdrop", "class", "classList"], outputs: ["closed", "close"], exportAs: ["matMenu"] }, { kind: "component", type: i8.MatMenuItem, selector: "[mat-menu-item]", inputs: ["role", "disabled", "disableRipple"], exportAs: ["matMenuItem"] }, { kind: "directive", type: i8.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", inputs: ["mat-menu-trigger-for", "matMenuTriggerFor", "matMenuTriggerData", "matMenuTriggerRestoreFocus"], outputs: ["menuOpened", "onMenuOpen", "menuClosed", "onMenuClose"], exportAs: ["matMenuTrigger"] }, { kind: "ngmodule", type: MatPaginatorModule }, { kind: "component", type: i9.MatPaginator, selector: "mat-paginator", inputs: ["color", "pageIndex", "length", "pageSize", "pageSizeOptions", "hidePageSize", "showFirstLastButtons", "selectConfig", "disabled"], outputs: ["page"], exportAs: ["matPaginator"] }, { kind: "ngmodule", type: MatRippleModule }, { kind: "directive", type: i5$1.MatRipple, selector: "[mat-ripple], [matRipple]", inputs: ["matRippleColor", "matRippleUnbounded", "matRippleCentered", "matRippleRadius", "matRippleAnimation", "matRippleDisabled", "matRippleTrigger"], exportAs: ["matRipple"] }, { kind: "ngmodule", type: MatSortModule }, { kind: "directive", type: i3.MatSort, selector: "[matSort]", inputs: ["matSortActive", "matSortStart", "matSortDirection", "matSortDisableClear", "matSortDisabled"], outputs: ["matSortChange"], exportAs: ["matSort"] }, { kind: "ngmodule", type: MatTableModule }, { kind: "component", type: i2.MatTable, selector: "mat-table, table[mat-table]", exportAs: ["matTable"] }, { kind: "directive", type: i2.MatHeaderCellDef, selector: "[matHeaderCellDef]" }, { kind: "directive", type: i2.MatHeaderRowDef, selector: "[matHeaderRowDef]", inputs: ["matHeaderRowDef", "matHeaderRowDefSticky"] }, { kind: "directive", type: i2.MatColumnDef, selector: "[matColumnDef]", inputs: ["matColumnDef"] }, { kind: "directive", type: i2.MatCellDef, selector: "[matCellDef]" }, { kind: "directive", type: i2.MatRowDef, selector: "[matRowDef]", inputs: ["matRowDefColumns", "matRowDefWhen"] }, { kind: "directive", type: i2.MatFooterCellDef, selector: "[matFooterCellDef]" }, { kind: "directive", type: i2.MatFooterRowDef, selector: "[matFooterRowDef]", inputs: ["matFooterRowDef", "matFooterRowDefSticky"] }, { kind: "directive", type: i2.MatHeaderCell, selector: "mat-header-cell, th[mat-header-cell]" }, { kind: "directive", type: i2.MatCell, selector: "mat-cell, td[mat-cell]" }, { kind: "directive", type: i2.MatFooterCell, selector: "mat-footer-cell, td[mat-footer-cell]" }, { kind: "component", type: i2.MatHeaderRow, selector: "mat-header-row, tr[mat-header-row]", exportAs: ["matHeaderRow"] }, { kind: "component", type: i2.MatRow, selector: "mat-row, tr[mat-row]", exportAs: ["matRow"] }, { kind: "component", type: i2.MatFooterRow, selector: "mat-footer-row, tr[mat-footer-row]", exportAs: ["matFooterRow"] }, { kind: "ngmodule", type: MatTooltipModule }, { kind: "directive", type: i4$1.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i4$2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: TablaMantenimientoColumnDefsComponent, selector: "jvs-tabla-mantenimiento-column-defs", inputs: ["objThis", "nombreColeccion", "colDetalle", "chkLista", "estaExpandida"], outputs: ["alternarExpansion", "chkListaChange"] }, { kind: "ngmodule", type: MatBadgeModule }, { kind: "directive", type: i14.MatBadge, selector: "[matBadge]", inputs: ["matBadgeColor", "matBadgeOverlap", "matBadgeDisabled", "matBadgePosition", "matBadge", "matBadgeDescription", "matBadgeSize", "matBadgeHidden"] }, { kind: "component", type: TablaMantenimientoMenuComponent, selector: "jvs-tabla-mantenimiento-menu", inputs: ["objThis", "nombreColeccion", "item", "derechosActuales", "subItems", "botonTemplate"], outputs: ["opcionSelecionada"] }, { kind: "directive", type: MatRowKeyboardSelectionDirective, selector: "[matRowKeyboardSelection]", inputs: ["matRowKeyboardSelection", "rowModel"], outputs: ["seleccionarSiguiente", "espacioEnFila", "filaEnfocada"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }], animations: [
|
|
1673
1875
|
trigger('detailExpand', [
|
|
1674
1876
|
state('collapsed', style({ height: '0px', minHeight: '0' })),
|
|
1675
1877
|
state('expanded', style({ height: '*' })),
|
|
@@ -1732,8 +1934,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.18", ngImpo
|
|
|
1732
1934
|
]),
|
|
1733
1935
|
], providers: [
|
|
1734
1936
|
{ provide: MAT_PAGINATOR_DEFAULT_OPTIONS, useValue: { formFieldAppearance: 'outline' } }
|
|
1735
|
-
], template: "<div class=\"flex flex-col\" [ngClass]=\"alturaFull() ? 'h-full' : 'h-fit'\">\n <div class=\"flex-none flex items-center justify-between bg-white\">\n <ng-content select=\"[filtro]\"></ng-content>\n </div>\n\n <div class=\"flex flex-col border-t\" [ngClass]=\"alturaFull() ? 'grow' : ''\">\n <div class=\"flex-none bg-app-bar flex items-center justify-between p-1\">\n <!-- <div class=\"hidden flex-1 sm:flex items-center flex-wrap gap-1\">-->\n <!-- </div>-->\n @if (leyenda) {\n <div class=\"flex items-center flex-wrap mr-1 h-full\">\n <span class=\"font-bold\" [class]=\"leyenda.class\">{{ leyenda.text }}</span>\n </div>\n }\n <div class=\"hidden flex-1 sm:flex items-center flex-wrap gap-1\">\n @if ((botonesMenuFinal.izquierda ?? []).length > 0 ) {\n <div class=\" flex items-center flex-wrap contenedor-botones\">\n @for (btn of botonesMenu.izquierda; track btn; let idx = $index) {\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.izquierda?.length}}\"></ng-container>\n }\n </div>\n }\n\n @if ((botonesMenuFinal.crud ?? []).length > 0) {\n <div class=\" flex items-center flex-wrap contenedor-botones\">\n @for (btn of botonesMenu.crud; track btn; let idx = $index) {\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.crud?.length}}\"></ng-container>\n }\n </div>\n }\n\n @if ((botonesMenuFinal.principal ?? []).length > 0) {\n <div class=\" flex items-center flex-wrap contenedor-botones\">\n @for (btn of botonesMenu.principal; track btn; let idx = $index) {\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.principal?.length}}\"></ng-container>\n }\n </div>\n }\n\n @if ((botonesMenuFinal.derecha ?? []).length > 0) {\n <div class=\"flex-auto flex items-center justify-end contenedor-botones\">\n @for (btn of botonesMenu.derecha; track btn; let idx = $index) {\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.derecha?.length}}\"></ng-container>\n }\n </div>\n }\n <ng-content select=\"[objetosMenuPegado]\"></ng-content>\n </div>\n <div class=\"flex flex-1 sm:hidden items-center flex-wrap gap-1\">\n <button class=\"flex items-center justify-center text-2xs leading-none rounded-full p-1\"\n matRipple\n matTooltip=\"Botones de Acci\u00F3n\"\n type=\"button\"\n [matMenuTriggerFor]=\"menuOpciones\"\n >\n <mat-icon class=\"icon-xs\" svgIcon=\"roundMenu\"></mat-icon>\n </button>\n </div>\n <div class=\"flex-none flex items-center justify-end border-l-2\">\n <div class=\"flex-1 sm:flex-none flex items-center justify-end\">\n <ng-content select=\"[objetosMenu]\"></ng-content>\n </div>\n </div>\n @if (busquedaTipo() && !busquedaCompacta()) {\n <div class=\"hidden flex-initial sm:flex items-center form-input max-w-[150px] bg-card rounded-full border m-1 px-1 border-l-2\"\n >\n <mat-icon svgIcon=\"roundSearch\" class=\"icon-xs\"></mat-icon>\n <input [formControl]=\"cCampoBusqueda\"\n class=\"text-xs px-1 py-1 border-0 outline-none w-full bg-transparent max-w-sm\"\n [placeholder]=\"busquedaPlaceholder()\"\n (keyup.enter)=\"busquedaTipo() == 'query' ? cargarData() : false;\"\n type=\"search\">\n </div>\n }\n\n\n <mat-menu #compactSearchMenu=\"matMenu\" class=\"compact-search-menu\">\n <div class=\"flex items-center gap-1\" (click)=\"$event.stopPropagation()\">\n <mat-icon svgIcon=\"roundSearch\" class=\"icon-xs text-gray-400\"></mat-icon>\n <input [formControl]=\"cCampoBusqueda\"\n class=\"text-xs px-2 py-1 border border-gray-200 rounded outline-none w-[180px] bg-white\"\n [placeholder]=\"busquedaPlaceholder()\"\n (keyup.enter)=\"ejecutarBusquedaCompacta()\"\n type=\"search\"\n (click)=\"$event.stopPropagation()\">\n </div>\n </mat-menu>\n <div class=\"flex-none flex items-center justify-end border-l-2\">\n <ng-content select=\"[botonesFiltro]\"></ng-content>\n <ng-content select=\"[botonesConfig]\"></ng-content>\n\n @if (busquedaTipo() && busquedaCompacta()) {\n <button matRipple\n class=\"flex items-center justify-center text-2xs leading-none rounded-full p-1\"\n matTooltip=\"Buscar...\"\n [matMenuTriggerFor]=\"compactSearchMenu\"\n #compactSearchMenuTrigger=\"matMenuTrigger\"\n type=\"button\">\n <mat-icon svgIcon=\"roundSearch\" class=\"icon-xs\"></mat-icon>\n </button>\n }\n\n @if (isRecargarUsed || busquedaTipo() == 'query') {\n <button matRipple\n class=\"flex items-center justify-center text-2xs leading-none rounded-full p-1 text-green-700\"\n matTooltip=\"Actualizar datos\"\n (click)=\"(busquedaTipo() == 'query' ? cargarData() : emitirAccionRecargar())\"\n type=\"button\">\n <mat-icon svgIcon=\"roundRefresh\" class=\"icon-xs\"></mat-icon>\n </button>\n }\n @if (mostrarBotonOrden()) {\n <button matRipple\n class=\"flex items-center justify-center text-2xs leading-none rounded-full p-1 text-blue-700\"\n [matTooltip]=\"bDireccionOrden() === 0 ? 'Orden Ascendente' : 'Orden Descendente'\"\n (click)=\"toggleDireccionOrden()\"\n type=\"button\">\n <mat-icon [svgIcon]=\"bDireccionOrden() === 0 ? 'roundArrowUpward' : 'roundArrowDownward'\" class=\"icon-xs\"></mat-icon>\n </button>\n }\n @if (filtroCampos) {\n <button matRipple [matMenuTriggerFor]=\"columnFilterMenu\"\n class=\"flex items-center justify-center text-2xs leading-none rounded-full p-1\"\n matTooltip=\"Columnas Filtro\"\n type=\"button\">\n <mat-icon svgIcon=\"roundFilterList\" class=\"icon-xs\"></mat-icon>\n </button>\n }\n </div>\n </div>\n\n @if ((botonesMenuFinal.secundario ?? []).length > 0) {\n <div class=\"flex-1 bg-app-bar flex items-center justify-between p-1 border-t\">\n <div class=\"hidden flex-1 sm:flex items-center flex-wrap gap-1\">\n <div class=\" flex items-center flex-wrap contenedor-botones\">\n @for (btn of botonesMenu.secundario; track btn; let idx = $index) {\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.secundario?.length}}\"></ng-container>\n }\n </div>\n </div>\n </div>\n }\n <!--<div class=\"grow flex flex-col items-stretch contenedor-tabla\" [ngClass]=\"{'table-container overflow-auto': esTabla}\">\n <pre>{{ this.chkLista.modelosChk | json }}</pre>\n <pre>{{ this.chkLista.checkbox.cantidadActivos | json }}</pre>\n <pre>{{ this.chkLista.checkbox.algunosActivos | json }}</pre>\n</div>-->\n<div class=\"grow flex flex-col items-stretch contenedor-tabla\" [ngClass]=\"{'table-container overflow-auto': esTabla}\">\n <ng-content select=\"[cuerpo]\"></ng-content>\n\n <table [id]=\"'tabla_' + nombreColeccion\" [dataSource]=\"dataSource\" [multiTemplateDataRows]=\"true\"\n [hidden]=\"!esTabla\"\n class=\"table-mantenimiento table-auto h-fit\" mat-table matSort\n [trackBy]=\"trackByFn\"\n #tablaMantenimiento\n >\n\n <!--<table [dataSource]=\"dataSource\" class=\"table-mantenimiento table-auto h-auto w-full justify-center\" mat-table matSort>-->\n\n\n <ng-content select=\"[tableDefinitions]\"></ng-content>\n <ng-container matColumnDef=\"numeracion_automatica\">\n <th mat-header-cell *matHeaderCellDef style=\"width: 16px !important\">N\u00BA</th>\n <td mat-cell *matCellDef=\"let element; let i = dataIndex\" class=\"p-0 celda-numeracion-fila\">\n <div class=\"flex items-center justify-center font-bold numeracionFila\">\n @if (esTabla && paginador) {\n {{ (this.paginator?.pageIndex == 0 ? i + 1 : 1 + i + (this.paginator?.pageIndex ?? 1) * (this.paginator?.pageSize ?? 1)) }}\n }\n @if (!paginador) {\n {{ (i + 1) }}\n }\n </div>\n </td>\n <td mat-footer-cell *matFooterCellDef class=\"uppercase\"></td>\n </ng-container>\n <jvs-tabla-mantenimiento-column-defs [objThis]=\"this\" [colDetalle]=\"columnasTabla\"\n [nombreColeccion]=\"nombreColeccion\" [(chkLista)]=\"chkLista\"></jvs-tabla-mantenimiento-column-defs>\n\n <tr *matHeaderRowDef=\"visibleColumns; sticky: true\" mat-header-row class=\"title\" matHeader\n ></tr>\n\n @if (!!filaExtraHeader) {\n <tr mat-row *matRowDef=\"let row; columns: ['filaExtraHeader']\" class=\"student-detail-row\"\n [style.height.px]=\"0\"\n ></tr>\n <ng-container matColumnDef=\"filaExtraHeader\">\n <td mat-cell *matCellDef=\"let row; let i = dataIndex\" [attr.colspan]=\"visibleColumns.length\">\n <div class=\"row m-0 student-element-detail\"\n [@detailExpand]=\"(i == 0 && filaExtraHeader.esVisible && filaExtraHeader.esVisible()) ? 'expanded' : 'collapsed'\"\n [style.padding-right.px]=\"row.isExpanded ? 5 : 0\"\n [style.padding-left.px]=\"row.isExpanded ? 5 : 0\"\n >\n @if (filaExtraHeader.template) {\n <ng-container\n [ngTemplateOutlet]=\"filaExtraHeader.template\"\n [ngTemplateOutletContext]=\"{ row: row }\"></ng-container>\n }\n </div>\n </td>\n </ng-container>\n }\n @if (filaFooter) {\n <tr *matFooterRowDef=\"visibleColumns\" mat-footer-row\n [style.height.px]=\"0\"\n [id]=\"nombreColeccion + '_filaFooter'\"\n ></tr>\n }\n\n <!--\t<tr\n *matRowDef=\"let row; columns: visibleColumns;\"\n class=\"hover:bg-secondary trans-ease-out cursor-pointer\"\n mat-row></tr>-->\n <tr\n [matRowKeyboardSelection]=\"tablaMantenimiento\"\n [rowModel]=\"row\"\n (seleccionarSiguiente)=\"opcMenu($event, {seccion: nombreColeccion, tipo: 'ver'});\"\n\n *matRowDef=\"let row; let idxTabla = dataIndex; columns: visibleColumns;\"\n (click)=\"seleccionarItem(row); opcMenu(row, {seccion: nombreColeccion, tipo: 'ver', tableDataIndex: idxTabla });\"\n (dblclick)=\"opcMenu(row, {seccion: nombreColeccion, tipo: 'seleccionar'}); dblclickItem.emit(row)\"\n (contextmenu)=\"(abrirMenuContextual($event, row)); $event. preventDefault();\"\n [ngClass]=\"classFila(row)\"\n @fadeInUp\n class=\"trans-ease-out cursor-pointer h-auto\"\n [style.height.px]=\"0\"\n [id]=\"propiedadSeleccion(row)\"\n [matTooltip]=\"procesarRowTooltip(row)\"\n matTooltipPosition=\"below\"\n [matTooltipPositionAtOrigin]=\"true\"\n [matTooltipClass]=\"['bg-red-700', 'text-red-100', 'm-0']\"\n [matTooltipDisabled]=\"!procesarRowTooltip(row)\"\n [class.regAnulado]=\"row[campoAnulado] == 1\"\n [class.regTooltip]=\"!!procesarRowTooltip(row)\"\n (keyup.delete)=\"opcMenu(row, {seccion: nombreColeccion, tipo: 'eliminar'})\"\n mat-row></tr>\n @if (filaExtraTemplate) {\n <tr mat-row *matRowDef=\"let row; columns: ['expandedDetail']\" class=\"student-detail-row h-0\"></tr>\n <ng-container matColumnDef=\"expandedDetail\">\n <td mat-cell *matCellDef=\"let row\" [attr.colspan]=\"visibleColumns.length\">\n <div class=\"row m-0 student-element-detail\"\n [@detailExpand]=\"row.isExpanded ? 'expanded' : 'collapsed'\"\n [style.padding-right.px]=\"row.isExpanded ? 5 : 0\"\n [style.padding-left.px]=\"row.isExpanded ? 5 : 0\"\n >\n <ng-container [ngTemplateOutlet]=\"filaExtraTemplate\"\n [ngTemplateOutletContext]=\"{ row: row }\"></ng-container>\n </div>\n </td>\n </ng-container>\n }\n</table>\n\n@if (componenteCargadoTotalmente) {\n @if ((noData | async) && esTabla) {\n <div class=\"flex-1 text-center text-secondary font-medium\">\n No se encontraron datos\n </div>\n }\n}\n</div>\n<ng-content select=\"[appendTable]\"></ng-content>\n<div class=\"flex-none bg-app-bar flex flex-col sm:flex-row items-start justify-between p-1\">\n <div class=\"flex-1 flex items-start flex-wrap gap-1\">\n\n @if ((botonesMenuFinal.inferior ?? []).length > 0) {\n <div class=\"flex items-center contenedor-botones\">\n @for (btn of botonesMenu.inferior; track btn; let idx = $index) {\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.inferior?.length}}\"></ng-container>\n }\n </div>\n }\n <!--<div *ngIf=\"(botonesMenuFinal.inferior ?? []).length > 0\" class=\" flex items-center flex-wrap\">\n <ng-container *ngFor=\"let btn of botonesMenu.inferior; let idx = index;\">\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.inferior?.length}}\"></ng-container>\n </ng-container>\n </div>-->\n</div>\n\n@if (esTabla && paginador) {\n <div class=\"flex-1 sm:flex-none flex items-center justify-end\">\n <mat-paginator class=\"tabla-mantenimiento-paginador\" [pageSizeOptions]=\"paginacion.pageSizeOptions\" [pageIndex]=\"paginacion.pageIndex - 1\" [length]=\"paginacion.pageLength\" [pageSize]=\"paginacion.pageSize\" (page)=\"paginacion.pageCurrent = $event; emitirResultados();\" ></mat-paginator>\n </div>\n}\n</div>\n</div>\n\n</div>\n\n\n\n<!-- SECCION DE TEMPLATES O MENUS -->\n\n\n<mat-menu #columnFilterMenu=\"matMenu\" xPosition=\"before\" yPosition=\"below\">\n @for (column of columnasTabla; track column) {\n @if (!tipoValorFuncion(column.noMostrarEnLista, false)) {\n <button (click)=\"toggleColumnVisibility(column, $event)\"\n class=\"checkbox-item mat-menu-item\">\n <mat-checkbox (click)=\"$event.stopPropagation()\" [(ngModel)]=\"column.visible\" [ngModelOptions]=\"{standalone: true}\" color=\"primary\">\n <span [innerHTML]=\"(column.labelLista ?? column.label).replace('<br>', ' ')\"></span>\n </mat-checkbox>\n </button>\n }\n }\n</mat-menu>\n\n\n\n\n\n\n<ng-template #botonesSuperiores let-btn=\"btn\" let-idx=\"idx\">\n <ng-container *ngTemplateOutlet=\"botonesContextual; context:{btn: btn, item: objSeleccionado, barraSuperior: true, idx: idx}\"></ng-container>\n</ng-template>\n\n<ng-template #botonesContextual let-btn=\"btn\" let-item=\"item\" let-barraSuperior=\"barraSuperior\" let-idx=\"idx\">\n\n @if (barraSuperior) {\n <!--\t\t<button mat-button style=\"min-width: unset; border: 1px !important;\" class=\"uppercase border border-gray rounded-none h-full px-1 disabled:opacity-50 disabled:text-secondary disabled:bg-transparent\">-->\n <!--\t\t\t<mat-icon *ngIf=\"btn.icono\" [svgIcon]=\"btn.icono\" size=\"15px\" class=\"icon-xs\"></mat-icon>-->\n <!--\t\t</button>-->\n @if (btn.subItems && btn.subItems.length > 0) {\n @if ((!btn.esVisible || btn.esVisible(item, this)) && subItemsActivos(btn, item)) {\n <button class=\"flex items-center justify-between uppercase text-2xs leading-none rounded-none px-2 py-1 bg-opacity-95 hover:bg-opacity-100 disabled:opacity-50 disabled:text-secondary disabled:!bg-gray-300 dark:disabled:!bg-gray-500 mat-elevation-z2\" type=\"button\"\n [class]=\"(btn.class?btn.class:'')\"\n (click)=\"opcMenu(item, btn)\"\n [style.min-width]=\"((btn.soloIcono ?? tipoValorFuncion(soloIconos)) ? 'unset' : '')\"\n [matTooltip]=\"btn.tooltip || (btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo))) \"\n [matMenuTriggerFor]=\"menuOtrosBarra.menu\"\n [matBadge]=\"btn.badge\"\n matBadgeSize=\"small\"\n >\n @if (btn.icono) {\n <mat-icon class=\"icon-xs\" [class.mr-0.5]=\"!(btn.soloIcono ?? tipoValorFuncion(soloIconos))\" [svgIcon]=\"btn.icono\" ></mat-icon>\n }\n @if (!(btn.soloIcono ?? tipoValorFuncion(soloIconos))) {\n <span class=\"whitespace-nowrap\">{{ btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo)) }}</span>\n }\n <mat-icon class=\"icon-xs\" svgIcon=\"fa5sCaretDown\" ></mat-icon>\n </button>\n }\n <jvs-tabla-mantenimiento-menu #menuOtrosBarra\n [objThis]=\"objThis\"\n [nombreColeccion]=\"nombreColeccion\"\n [item]=\"item\"\n [derechosActuales]=\"derechosActuales\"\n [subItems]=\"btn.subItems\"\n (opcionSelecionada)=\"opcMenu($event.item, $event.btn)\"\n [botonTemplate]=\"botonesContextual\"\n >\n </jvs-tabla-mantenimiento-menu>\n }\n @if (!btn.subItems || btn.subItems.length == 0) {\n @if (!btn.esVisible || btn.esVisible(item, this)) {\n <button class=\"flex items-center justify-between uppercase text-2xs leading-none rounded-none px-2 py-1 bg-opacity-95 hover:bg-opacity-100 disabled:opacity-50 disabled:text-secondary disabled:!bg-gray-300 dark:disabled:!bg-gray-500 mat-elevation-z2\" type=\"button\"\n [class]=\"(btn.class?btn.class:'text-secondary')\"\n [ngClass]=\"{'text-secondary italic': !ignorarDerechos && !btn.esIndependiente && (!btn.ignorarDerecho && (!derechosActuales || !derechosActuales[btn.cDerechoCodigo ?? btn.tipo])) && !(['nuevo', 'editar', 'eliminar'].includes(btn.tipo))}\"\n [disabled]=\"!btn.esIndependiente && botonDisabled(btn, item)\"\n (click)=\"opcMenu(item, btn)\"\n [style.min-width]=\"((btn.soloIcono ?? tipoValorFuncion(soloIconos)) ? 'unset' : '')\"\n [matTooltip]=\"btn.tooltip || (btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo))) \"\n [matBadge]=\"btn.badge\"\n matBadgeSize=\"small\"\n >\n @if (btn.icono) {\n <mat-icon class=\"icon-xs\" [class.mr-0.5]=\"!(btn.soloIcono ?? tipoValorFuncion(soloIconos))\" [svgIcon]=\"btn.icono\"></mat-icon>\n }\n @if (!(btn.soloIcono ?? tipoValorFuncion(soloIconos))) {\n <span class=\"whitespace-nowrap\">{{ btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo)) }}</span>\n }\n </button>\n }\n }\n} @else {\n @if (btn.subItems && btn.subItems.length > 0) {\n @if (!btn.noContextual && (!btn.esVisible || btn.esVisible(item, this))) {\n <button class=\"flex items-center justify-between uppercase w-full rounded-none px-2 disabled:opacity-50 disabled:text-secondary disabled:bg-transparent\" mat-menu-item type=\"button\"\n [class]=\"(btn.class?btn.class.replace('text-white', '').replace('bg', 'text'):'text-secondary')\"\n [ngClass]=\"{'text-secondary italic': !ignorarDerechos && !btn.esIndependiente && (!btn.ignorarDerecho && (!derechosActuales || !derechosActuales[btn.cDerechoCodigo ?? btn.tipo]))}\"\n [disabled]=\"!btn.esIndependiente && botonDisabled(btn, item)\"\n (click)=\"opcMenu(item, btn); $event.stopPropagation();\"\n [matMenuTriggerFor]=\"menuOtrosBarra.menu\"\n >\n <div class=\"flex w-full items-center justify-between uppercase text-2xs\"\n >\n @if (btn.icono) {\n <mat-icon [svgIcon]=\"btn.icono\"\n class=\"flex-none icon-xs\"\n ></mat-icon>\n }\n <span class=\"grow text-2xs\">{{ btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo)) }}</span>\n <mat-icon class=\"flex-none icon-xs\" svgIcon=\"fa5sCaretRight\"></mat-icon>\n </div>\n </button>\n }\n <jvs-tabla-mantenimiento-menu #menuOtrosBarra\n [objThis]=\"objThis\"\n [nombreColeccion]=\"nombreColeccion\"\n [item]=\"item\"\n [derechosActuales]=\"derechosActuales\"\n [subItems]=\"btn.subItems\"\n (opcionSelecionada)=\"opcMenu($event.item, $event.btn)\"\n [botonTemplate]=\"botonesContextual\"\n >\n </jvs-tabla-mantenimiento-menu>\n }\n @if (!btn.subItems || btn.subItems.length == 0) {\n @if (btn.tipo == '-#SEPARADOR#-') {\n <mat-divider></mat-divider>\n } @else {\n @if (!btn.noContextual && (!btn.esVisible || btn.esVisible(item, this))) {\n <button class=\"flex items-center justify-between uppercase w-full rounded-none px-2 disabled:opacity-50 disabled:text-secondary disabled:bg-transparent\" mat-menu-item type=\"button\"\n [class]=\"(btn.class?btn.class.replace('text-white', '').replace('bg', 'text'):'text-secondary')\"\n [ngClass]=\"{'text-secondary italic': !ignorarDerechos && !btn.esIndependiente && (!btn.ignorarDerecho && (!derechosActuales || !derechosActuales[btn.cDerechoCodigo ?? btn.tipo]))}\"\n [disabled]=\"!btn.esIndependiente && botonDisabled(btn, item)\"\n (click)=\"opcMenu(item, btn)\"\n >\n <div class=\"flex w-full items-center justify-between uppercase text-2xs\">\n @if (btn.icono) {\n <mat-icon [svgIcon]=\"btn.icono\" class=\"flex-none icon-xs\"\n ></mat-icon>\n }\n <span class=\"grow text-2xs\">{{ btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo)) }}</span>\n </div>\n </button>\n }\n }\n }\n}\n\n</ng-template>\n\n<ng-template #userMenu let-item=\"item\">\n <div class=\"mat-menu bg-white rounded mat-elevation-z8 shadow botonesContextual\">\n @for (btn of listaMenuCompleto; track btn) {\n <ng-container *ngTemplateOutlet=\"botonesContextual; context:{btn: btn, item: objSeleccionado, barraSuperior: false}\"></ng-container>\n }\n </div>\n</ng-template>\n\n\n<mat-menu #menuOpciones=\"matMenu\" xPosition=\"before\" yPosition=\"below\">\n @for (btn of listaMenuCompleto; track btn) {\n <ng-container\n *ngTemplateOutlet=\"botonesContextual; context:{btn: btn, item: objSeleccionado, barraSuperior: false}\"></ng-container>\n }\n</mat-menu>\n\n", styles: ["@charset \"UTF-8\";:root{--tabla-mantenimiento-seleccion-fondo: rgb(179, 217, 252);--tabla-mantenimiento-seleccion-texto: rgb(1, 84, 164);--mat-paginator-container-size: 30px}:root .table-mantenimiento .elemento-seleccionado{background-color:var(--tabla-mantenimiento-seleccion-fondo)!important;color:var(--tabla-mantenimiento-seleccion-texto)!important;border-color:var(--tabla-mantenimiento-seleccion-texto)!important}.jvs-tabla-mantenimiento{width:inherit;display:flex;flex-direction:column}.jvs-tabla-mantenimiento .contenedor-botones>*:first-child{@apply rounded-l;}.jvs-tabla-mantenimiento .contenedor-botones>*:last-child{@apply rounded-r;}.jvs-tabla-mantenimiento tr.regTooltip>td:first-child div:first-child:before,.jvs-tabla-mantenimiento tr.regTooltip>th:first-child div:first-child:before{content:\"\\26a0\\fe0f \";color:red;margin-right:4px;font-size:12px}.jvs-tabla-mantenimiento tr.regTooltip>td:first-child:not(:has(div)):before,.jvs-tabla-mantenimiento tr.regTooltip>th:first-child:not(:has(div)):before{content:\"\\26a0\\fe0f \";color:red;margin-right:4px;font-size:12px}.jvs-tabla-mantenimiento .mat-mdc-menu-content:not(:empty){@apply flex flex-col items-start;padding:0!important}.jvs-tabla-mantenimiento .mat-mdc-menu-item{line-height:24px!important;height:24px!important;min-height:24px!important}.jvs-tabla-mantenimiento .mat-mdc-menu-panel{min-height:auto!important}.jvs-tabla-mantenimiento .mat-mdc-table .mat-mdc-cell,.jvs-tabla-mantenimiento .mat-mdc-table .mat-mdc-header-cell .mat-mdc-footer-cell{white-space:unset}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-table-sticky-border-elem-right{border-left:1px solid #e0e0e0}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-table-sticky-border-elem-left{border-right:1px solid #e0e0e0}.jvs-tabla-mantenimiento .table-mantenimiento tr.regAnulado .mat-mdc-cell{color:unset!important}.jvs-tabla-mantenimiento .table-mantenimiento .bg-primary-activo .numeracionFila{@apply rounded-full bg-primary-contrast text-primary mx-1 p-1 w-6 h-6;}.jvs-tabla-mantenimiento .table-mantenimiento th .form-input{@apply w-auto;}.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell:not(.celda-numeracion-fila),.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-cell:not(.celda-numeracion-fila),.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-footer-cell:not(.celda-numeracion-fila){padding:.05rem .25rem}.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell,.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-cell,.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-footer-cell{border-width:1px;border-style:solid}.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell:first-of-type:not(.celda-numeracion-fila),.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell:last-of-type:not(.celda-numeracion-fila),.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-cell:first-of-type:not(.celda-numeracion-fila),.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-cell:last-of-type:not(.celda-numeracion-fila),.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-footer-cell:first-of-type:not(.celda-numeracion-fila),.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-footer-cell:last-of-type:not(.celda-numeracion-fila){padding:0 .25rem}.jvs-tabla-mantenimiento .table-mantenimiento .student-element-detail{overflow:hidden;display:flex;align-items:center;justify-content:center}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-header-row{height:25px!important;color:rgb(var(--color-primary))!important;background-color:rgb(var(--color-primary-contrast))!important}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-header-cell{padding:5px;font-size:10px;line-height:10px;font-weight:700!important;color:inherit}.jvs-tabla-mantenimiento .table-mantenimiento .mdc-data-table__row:not(.mdc-data-table__row--selected):not(.elemento-seleccionado):hover,.jvs-tabla-mantenimiento .table-mantenimiento .mdc-data-table__row:not(.mdc-data-table__row--selected):not(.elemento-seleccionado):focus{background-color:rgba(var(--color-primary-contrast),.04)}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-row .mat-mdc-cell,.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-footer-row .mat-mdc-cell{font-size:10px}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-row .mat-mdc-footer-cell:empty,.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-footer-row .mat-mdc-footer-cell:empty{border-width:0!important}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-cell{@apply leading-tight;}.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell{border-color:#d4d0d0;@apply text-center uppercase;}.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell .mat-sort-header-container{@apply flex items-center justify-between w-full;}.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell .mat-sort-header-container .mat-sort-header-content{@apply inline w-full text-center;}.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell .mat-sort-header-container .mat-sort-header-arrow{@apply flex-none;}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-sort-header-content{width:100%;text-align:center;display:unset;align-items:center}.compact-search-menu{min-width:200px!important;overflow:hidden}.compact-search-menu input:focus{@apply border-primary;}\n"] }]
|
|
1736
|
-
}], ctorParameters: () => [{ type: i1$2.
|
|
1937
|
+
], template: "<div class=\"flex flex-col\" [ngClass]=\"alturaFull() ? 'h-full' : 'h-fit'\">\n <div class=\"flex-none flex items-center justify-between bg-white\">\n <ng-content select=\"[filtro]\"></ng-content>\n </div>\n\n <div class=\"flex flex-col border-t\" [ngClass]=\"alturaFull() ? 'grow' : ''\">\n <div class=\"flex-none bg-app-bar flex items-center justify-between p-1\">\n <!-- <div class=\"hidden flex-1 sm:flex items-center flex-wrap gap-1\">-->\n <!-- </div>-->\n @if (leyenda) {\n <div class=\"flex items-center flex-wrap mr-1 h-full\">\n <span class=\"font-bold\" [class]=\"leyenda.class\">{{ leyenda.text }}</span>\n </div>\n }\n <div class=\"hidden flex-1 sm:flex items-center flex-wrap gap-1\">\n @if ((botonesMenuFinal.izquierda ?? []).length > 0 ) {\n <div class=\" flex items-center flex-wrap contenedor-botones\">\n @for (btn of botonesMenuFinal.izquierda; track btn; let idx = $index) {\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenuFinal.izquierda?.length}}\"></ng-container>\n }\n </div>\n }\n\n @if ((botonesMenuFinal.crud ?? []).length > 0) {\n <div class=\" flex items-center flex-wrap contenedor-botones\">\n @for (btn of botonesMenuFinal.crud; track btn; let idx = $index) {\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenuFinal.crud?.length}}\"></ng-container>\n }\n </div>\n }\n\n @if ((botonesMenuFinal.principal ?? []).length > 0) {\n <div class=\" flex items-center flex-wrap contenedor-botones\">\n @for (btn of botonesMenuFinal.principal; track btn; let idx = $index) {\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenuFinal.principal?.length}}\"></ng-container>\n }\n </div>\n }\n\n @if ((botonesMenuFinal.derecha ?? []).length > 0) {\n <div class=\"flex-auto flex items-center justify-end contenedor-botones\">\n @for (btn of botonesMenuFinal.derecha; track btn; let idx = $index) {\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenuFinal.derecha?.length}}\"></ng-container>\n }\n </div>\n }\n <ng-content select=\"[objetosMenuPegado]\"></ng-content>\n </div>\n <div class=\"flex flex-1 sm:hidden items-center flex-wrap gap-1\">\n <button class=\"flex items-center justify-center text-2xs leading-none rounded-full p-1\"\n matRipple\n matTooltip=\"Botones de Acci\u00F3n\"\n type=\"button\"\n [matMenuTriggerFor]=\"menuOpciones\"\n >\n <mat-icon class=\"icon-xs\" svgIcon=\"roundMenu\"></mat-icon>\n </button>\n </div>\n <div class=\"flex-none flex items-center justify-end border-l-2\">\n <div class=\"flex-1 sm:flex-none flex items-center justify-end\">\n <ng-content select=\"[objetosMenu]\"></ng-content>\n </div>\n </div>\n @if (busquedaTipo() && !busquedaCompacta()) {\n <div class=\"hidden flex-initial sm:flex items-center form-input max-w-[150px] bg-card rounded-full border m-1 px-1 border-l-2\"\n >\n <mat-icon svgIcon=\"roundSearch\" class=\"icon-xs\"></mat-icon>\n <input [formControl]=\"cCampoBusqueda\"\n class=\"text-xs px-1 py-1 border-0 outline-none w-full bg-transparent max-w-sm\"\n [placeholder]=\"busquedaPlaceholder()\"\n (keyup.enter)=\"busquedaTipo() == 'query' ? cargarData() : false;\"\n type=\"search\">\n </div>\n }\n\n\n <mat-menu #compactSearchMenu=\"matMenu\" class=\"compact-search-menu\">\n <div class=\"flex items-center gap-1\" (click)=\"$event.stopPropagation()\">\n <mat-icon svgIcon=\"roundSearch\" class=\"icon-xs text-gray-400\"></mat-icon>\n <input [formControl]=\"cCampoBusqueda\"\n class=\"text-xs px-2 py-1 border border-gray-200 rounded outline-none w-[180px] bg-white\"\n [placeholder]=\"busquedaPlaceholder()\"\n (keyup.enter)=\"ejecutarBusquedaCompacta()\"\n type=\"search\"\n (click)=\"$event.stopPropagation()\">\n </div>\n </mat-menu>\n <div class=\"flex-none flex items-center justify-end border-l-2\">\n <ng-content select=\"[botonesFiltro]\"></ng-content>\n <ng-content select=\"[botonesConfig]\"></ng-content>\n\n @if (busquedaTipo() && busquedaCompacta()) {\n <button matRipple\n class=\"flex items-center justify-center text-2xs leading-none rounded-full p-1\"\n matTooltip=\"Buscar...\"\n [matMenuTriggerFor]=\"compactSearchMenu\"\n #compactSearchMenuTrigger=\"matMenuTrigger\"\n type=\"button\">\n <mat-icon svgIcon=\"roundSearch\" class=\"icon-xs\"></mat-icon>\n </button>\n }\n\n @if (isRecargarUsed || busquedaTipo() == 'query') {\n <button matRipple\n class=\"flex items-center justify-center text-2xs leading-none rounded-full p-1 text-green-700\"\n matTooltip=\"Actualizar datos\"\n (click)=\"(busquedaTipo() == 'query' ? cargarData() : emitirAccionRecargar())\"\n type=\"button\">\n <mat-icon svgIcon=\"roundRefresh\" class=\"icon-xs\"></mat-icon>\n </button>\n }\n @if (mostrarBotonOrden()) {\n <button matRipple\n class=\"flex items-center justify-center text-2xs leading-none rounded-full p-1 text-blue-700\"\n [matTooltip]=\"bDireccionOrden() === 0 ? 'Orden Ascendente' : 'Orden Descendente'\"\n (click)=\"toggleDireccionOrden()\"\n type=\"button\">\n <mat-icon [svgIcon]=\"bDireccionOrden() === 0 ? 'roundArrowUpward' : 'roundArrowDownward'\" class=\"icon-xs\"></mat-icon>\n </button>\n }\n @if (filtroCampos) {\n <button matRipple [matMenuTriggerFor]=\"columnFilterMenu\"\n class=\"flex items-center justify-center text-2xs leading-none rounded-full p-1\"\n matTooltip=\"Columnas Filtro\"\n type=\"button\">\n <mat-icon svgIcon=\"roundFilterList\" class=\"icon-xs\"></mat-icon>\n </button>\n }\n </div>\n </div>\n\n @if ((botonesMenuFinal.secundario ?? []).length > 0) {\n <div class=\"flex-1 bg-app-bar flex items-center justify-between p-1 border-t\">\n <div class=\"hidden flex-1 sm:flex items-center flex-wrap gap-1\">\n <div class=\" flex items-center flex-wrap contenedor-botones\">\n @for (btn of botonesMenuFinal.secundario; track btn; let idx = $index) {\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenuFinal.secundario?.length}}\"></ng-container>\n }\n </div>\n </div>\n </div>\n }\n <!--<div class=\"grow flex flex-col items-stretch contenedor-tabla\" [ngClass]=\"{'table-container overflow-auto': esTabla}\">\n <pre>{{ this.chkLista.modelosChk | json }}</pre>\n <pre>{{ this.chkLista.checkbox.cantidadActivos | json }}</pre>\n <pre>{{ this.chkLista.checkbox.algunosActivos | json }}</pre>\n</div>-->\n<div class=\"grow flex flex-col items-stretch contenedor-tabla\" [ngClass]=\"{'table-container overflow-auto': esTabla}\">\n <ng-content select=\"[cuerpo]\"></ng-content>\n\n <table [id]=\"'tabla_' + nombreColeccion\" [dataSource]=\"dataSource\" [multiTemplateDataRows]=\"true\"\n [hidden]=\"!esTabla\"\n class=\"table-mantenimiento table-auto h-fit\" mat-table matSort\n [trackBy]=\"trackByFn\"\n #tablaMantenimiento\n >\n\n <!--<table [dataSource]=\"dataSource\" class=\"table-mantenimiento table-auto h-auto w-full justify-center\" mat-table matSort>-->\n\n\n <ng-content select=\"[tableDefinitions]\"></ng-content>\n <ng-container matColumnDef=\"numeracion_automatica\">\n <th mat-header-cell *matHeaderCellDef style=\"width: 16px !important\">N\u00BA</th>\n <td mat-cell *matCellDef=\"let element; let i = dataIndex\" class=\"p-0 celda-numeracion-fila\">\n <div class=\"flex items-center justify-center font-bold numeracionFila\">\n @if (esTabla && paginador) {\n {{ (this.paginator?.pageIndex == 0 ? i + 1 : 1 + i + (this.paginator?.pageIndex ?? 1) * (this.paginator?.pageSize ?? 1)) }}\n }\n @if (!paginador) {\n {{ (i + 1) }}\n }\n </div>\n </td>\n <td mat-footer-cell *matFooterCellDef class=\"uppercase\"></td>\n </ng-container>\n <jvs-tabla-mantenimiento-column-defs [objThis]=\"this\" [colDetalle]=\"columnasParaDefinir\" [estaExpandida]=\"estaExpandidaFn\" (alternarExpansion)=\"alternarExpansion($event)\"\n [nombreColeccion]=\"nombreColeccion\" [(chkLista)]=\"chkLista\"></jvs-tabla-mantenimiento-column-defs>\n\n <tr *matHeaderRowDef=\"visibleColumns; sticky: true\" mat-header-row class=\"title\" matHeader\n ></tr>\n\n @if (!!filaExtraHeader) {\n <tr mat-row *matRowDef=\"let row; columns: ['filaExtraHeader']\" class=\"student-detail-row\"\n [style.height.px]=\"0\"\n ></tr>\n <ng-container matColumnDef=\"filaExtraHeader\">\n <td mat-cell *matCellDef=\"let row; let i = dataIndex\" [attr.colspan]=\"visibleColumns.length\">\n <div class=\"row m-0 student-element-detail\"\n [@detailExpand]=\"(i == 0 && filaExtraHeader.esVisible && filaExtraHeader.esVisible()) ? 'expanded' : 'collapsed'\"\n [style.padding-right.px]=\"estaExpandida(row) ? 5 : 0\"\n [style.padding-left.px]=\"estaExpandida(row) ? 5 : 0\"\n >\n @if (filaExtraHeader.template) {\n <ng-container\n [ngTemplateOutlet]=\"filaExtraHeader.template\"\n [ngTemplateOutletContext]=\"{ row: row }\"></ng-container>\n }\n </div>\n </td>\n </ng-container>\n }\n @if (filaFooter) {\n <tr *matFooterRowDef=\"visibleColumns\" mat-footer-row\n [style.height.px]=\"0\"\n [id]=\"nombreColeccion + '_filaFooter'\"\n ></tr>\n }\n\n <!--\t<tr\n *matRowDef=\"let row; columns: visibleColumns;\"\n class=\"hover:bg-secondary trans-ease-out cursor-pointer\"\n mat-row></tr>-->\n <tr\n [matRowKeyboardSelection]=\"tablaMantenimiento\"\n [rowModel]=\"row\"\n (seleccionarSiguiente)=\"opcMenu($event, {seccion: nombreColeccion, tipo: 'ver'});\"\n (filaEnfocada)=\"seleccionarFilaPorId($event)\"\n (espacioEnFila)=\"teclaEspacioEnFila($event)\"\n\n *matRowDef=\"let row; let idxTabla = dataIndex; columns: visibleColumns;\"\n (click)=\"clicFila(row, idxTabla, $event)\"\n (dblclick)=\"dobleClicFila(row)\"\n (contextmenu)=\"(abrirMenuContextual($event, row)); $event. preventDefault();\"\n [ngClass]=\"classFila(row)\"\n @fadeInUp\n class=\"trans-ease-out cursor-pointer h-auto\"\n [style.height.px]=\"0\"\n [id]=\"propiedadSeleccion(row)\"\n [matTooltip]=\"procesarRowTooltip(row)\"\n matTooltipPosition=\"below\"\n [matTooltipPositionAtOrigin]=\"true\"\n [matTooltipClass]=\"['bg-red-700', 'text-red-100', 'm-0']\"\n [matTooltipDisabled]=\"!procesarRowTooltip(row)\"\n [class.regAnulado]=\"row[campoAnulado] == 1\"\n [class.regTooltip]=\"!!procesarRowTooltip(row)\"\n (keyup.delete)=\"teclaEliminarEnFila(row, $event)\"\n mat-row></tr>\n @if (filaExtraTemplate) {\n <tr mat-row *matRowDef=\"let row; columns: ['expandedDetail']\" class=\"student-detail-row h-0\"></tr>\n <ng-container matColumnDef=\"expandedDetail\">\n <td mat-cell *matCellDef=\"let row\" [attr.colspan]=\"visibleColumns.length\">\n <div class=\"row m-0 student-element-detail\"\n [@detailExpand]=\"estaExpandida(row) ? 'expanded' : 'collapsed'\"\n [style.padding-right.px]=\"estaExpandida(row) ? 5 : 0\"\n [style.padding-left.px]=\"estaExpandida(row) ? 5 : 0\"\n >\n <ng-container [ngTemplateOutlet]=\"filaExtraTemplate\"\n [ngTemplateOutletContext]=\"{ row: row }\"></ng-container>\n </div>\n </td>\n </ng-container>\n }\n</table>\n\n@if (componenteCargadoTotalmente) {\n @if ((noData | async) && esTabla) {\n <div class=\"flex-1 text-center text-secondary font-medium\">\n No se encontraron datos\n </div>\n }\n}\n</div>\n<ng-content select=\"[appendTable]\"></ng-content>\n<div class=\"flex-none bg-app-bar flex flex-col sm:flex-row items-start justify-between p-1\">\n <div class=\"flex-1 flex items-start flex-wrap gap-1\">\n\n @if ((botonesMenuFinal.inferior ?? []).length > 0) {\n <div class=\"flex items-center contenedor-botones\">\n @for (btn of botonesMenuFinal.inferior; track btn; let idx = $index) {\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenuFinal.inferior?.length}}\"></ng-container>\n }\n </div>\n }\n <!--<div *ngIf=\"(botonesMenuFinal.inferior ?? []).length > 0\" class=\" flex items-center flex-wrap\">\n <ng-container *ngFor=\"let btn of botonesMenuFinal.inferior; let idx = index;\">\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenuFinal.inferior?.length}}\"></ng-container>\n </ng-container>\n </div>-->\n</div>\n\n@if (esTabla && paginador) {\n <div class=\"flex-1 sm:flex-none flex items-center justify-end\">\n <mat-paginator class=\"tabla-mantenimiento-paginador\" [pageSizeOptions]=\"paginacion.pageSizeOptions\" [pageIndex]=\"paginacion.pageIndex - 1\" [length]=\"paginacion.pageLength\" [pageSize]=\"paginacion.pageSize\" (page)=\"paginacion.pageCurrent = $event; emitirResultados();\" ></mat-paginator>\n </div>\n}\n</div>\n</div>\n\n</div>\n\n\n\n<!-- SECCION DE TEMPLATES O MENUS -->\n\n\n<mat-menu #columnFilterMenu=\"matMenu\" xPosition=\"before\" yPosition=\"below\">\n @for (column of columnasTabla; track column) {\n @if (esColumnaEnLista(column)) {\n <button (click)=\"toggleColumnVisibility(column, $event)\"\n class=\"checkbox-item mat-menu-item\">\n <mat-checkbox (click)=\"$event.stopPropagation()\" [ngModel]=\"esColumnaVisible(column)\" (ngModelChange)=\"column.visible = $event\" [ngModelOptions]=\"{standalone: true}\" color=\"primary\">\n <span [innerHTML]=\"(column.labelLista ?? column.label).replace('<br>', ' ')\"></span>\n </mat-checkbox>\n </button>\n }\n }\n</mat-menu>\n\n\n\n\n\n\n<ng-template #botonesSuperiores let-btn=\"btn\" let-idx=\"idx\">\n <ng-container *ngTemplateOutlet=\"botonesContextual; context:{btn: btn, item: objSeleccionado, barraSuperior: true, idx: idx}\"></ng-container>\n</ng-template>\n\n<ng-template #botonesContextual let-btn=\"btn\" let-item=\"item\" let-barraSuperior=\"barraSuperior\" let-idx=\"idx\">\n\n @if (barraSuperior) {\n <!--\t\t<button mat-button style=\"min-width: unset; border: 1px !important;\" class=\"uppercase border border-gray rounded-none h-full px-1 disabled:opacity-50 disabled:text-secondary disabled:bg-transparent\">-->\n <!--\t\t\t<mat-icon *ngIf=\"btn.icono\" [svgIcon]=\"btn.icono\" size=\"15px\" class=\"icon-xs\"></mat-icon>-->\n <!--\t\t</button>-->\n @if (btn.subItems && btn.subItems.length > 0) {\n @if ((!btn.esVisible || btn.esVisible(item, this)) && subItemsActivos(btn, item)) {\n <button class=\"flex items-center justify-between uppercase text-2xs leading-none rounded-none px-2 py-1 bg-opacity-95 hover:bg-opacity-100 disabled:opacity-50 disabled:text-secondary disabled:!bg-gray-300 dark:disabled:!bg-gray-500 mat-elevation-z2\" type=\"button\"\n [class]=\"(btn.class?btn.class:'')\"\n (click)=\"opcMenu(item, btn)\"\n [style.min-width]=\"((btn.soloIcono ?? tipoValorFuncion(soloIconos)) ? 'unset' : '')\"\n [matTooltip]=\"btn.tooltip || (btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo))) \"\n [matMenuTriggerFor]=\"menuOtrosBarra.menu\"\n [matBadge]=\"btn.badge\"\n matBadgeSize=\"small\"\n >\n @if (btn.icono) {\n <mat-icon class=\"icon-xs\" [class.mr-0.5]=\"!(btn.soloIcono ?? tipoValorFuncion(soloIconos))\" [svgIcon]=\"btn.icono\" ></mat-icon>\n }\n @if (!(btn.soloIcono ?? tipoValorFuncion(soloIconos))) {\n <span class=\"whitespace-nowrap\">{{ btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo)) }}</span>\n }\n <mat-icon class=\"icon-xs\" svgIcon=\"fa5sCaretDown\" ></mat-icon>\n </button>\n }\n <jvs-tabla-mantenimiento-menu #menuOtrosBarra\n [objThis]=\"objThis\"\n [nombreColeccion]=\"nombreColeccion\"\n [item]=\"item\"\n [derechosActuales]=\"derechosActuales\"\n [subItems]=\"btn.subItems\"\n (opcionSelecionada)=\"opcMenu($event.item, $event.btn)\"\n [botonTemplate]=\"botonesContextual\"\n >\n </jvs-tabla-mantenimiento-menu>\n }\n @if (!btn.subItems || btn.subItems.length == 0) {\n @if (!btn.esVisible || btn.esVisible(item, this)) {\n <button class=\"flex items-center justify-between uppercase text-2xs leading-none rounded-none px-2 py-1 bg-opacity-95 hover:bg-opacity-100 disabled:opacity-50 disabled:text-secondary disabled:!bg-gray-300 dark:disabled:!bg-gray-500 mat-elevation-z2\" type=\"button\"\n [class]=\"(btn.class?btn.class:'text-secondary')\"\n [ngClass]=\"{'text-secondary italic': !ignorarDerechos && !btn.esIndependiente && (!btn.ignorarDerecho && (!derechosActuales || !derechosActuales[btn.cDerechoCodigo ?? btn.tipo])) && !(['nuevo', 'editar', 'eliminar'].includes(btn.tipo))}\"\n [disabled]=\"!btn.esIndependiente && botonDisabled(btn, item)\"\n (click)=\"opcMenu(item, btn)\"\n [style.min-width]=\"((btn.soloIcono ?? tipoValorFuncion(soloIconos)) ? 'unset' : '')\"\n [matTooltip]=\"btn.tooltip || (btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo))) \"\n [matBadge]=\"btn.badge\"\n matBadgeSize=\"small\"\n >\n @if (btn.icono) {\n <mat-icon class=\"icon-xs\" [class.mr-0.5]=\"!(btn.soloIcono ?? tipoValorFuncion(soloIconos))\" [svgIcon]=\"btn.icono\"></mat-icon>\n }\n @if (!(btn.soloIcono ?? tipoValorFuncion(soloIconos))) {\n <span class=\"whitespace-nowrap\">{{ btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo)) }}</span>\n }\n </button>\n }\n }\n} @else {\n @if (btn.subItems && btn.subItems.length > 0) {\n @if (!btn.noContextual && (!btn.esVisible || btn.esVisible(item, this))) {\n <button class=\"flex items-center justify-between uppercase w-full rounded-none px-2 disabled:opacity-50 disabled:text-secondary disabled:bg-transparent\" mat-menu-item type=\"button\"\n [class]=\"(btn.class?btn.class.replace('text-white', '').replace('bg', 'text'):'text-secondary')\"\n [ngClass]=\"{'text-secondary italic': !ignorarDerechos && !btn.esIndependiente && (!btn.ignorarDerecho && (!derechosActuales || !derechosActuales[btn.cDerechoCodigo ?? btn.tipo]))}\"\n [disabled]=\"!btn.esIndependiente && botonDisabled(btn, item)\"\n (click)=\"opcMenu(item, btn); $event.stopPropagation();\"\n [matMenuTriggerFor]=\"menuOtrosBarra.menu\"\n >\n <div class=\"flex w-full items-center justify-between uppercase text-2xs\"\n >\n @if (btn.icono) {\n <mat-icon [svgIcon]=\"btn.icono\"\n class=\"flex-none icon-xs\"\n ></mat-icon>\n }\n <span class=\"grow text-2xs\">{{ btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo)) }}</span>\n <mat-icon class=\"flex-none icon-xs\" svgIcon=\"fa5sCaretRight\"></mat-icon>\n </div>\n </button>\n }\n <jvs-tabla-mantenimiento-menu #menuOtrosBarra\n [objThis]=\"objThis\"\n [nombreColeccion]=\"nombreColeccion\"\n [item]=\"item\"\n [derechosActuales]=\"derechosActuales\"\n [subItems]=\"btn.subItems\"\n (opcionSelecionada)=\"opcMenu($event.item, $event.btn)\"\n [botonTemplate]=\"botonesContextual\"\n >\n </jvs-tabla-mantenimiento-menu>\n }\n @if (!btn.subItems || btn.subItems.length == 0) {\n @if (btn.tipo == '-#SEPARADOR#-') {\n <mat-divider></mat-divider>\n } @else {\n @if (!btn.noContextual && (!btn.esVisible || btn.esVisible(item, this))) {\n <button class=\"flex items-center justify-between uppercase w-full rounded-none px-2 disabled:opacity-50 disabled:text-secondary disabled:bg-transparent\" mat-menu-item type=\"button\"\n [class]=\"(btn.class?btn.class.replace('text-white', '').replace('bg', 'text'):'text-secondary')\"\n [ngClass]=\"{'text-secondary italic': !ignorarDerechos && !btn.esIndependiente && (!btn.ignorarDerecho && (!derechosActuales || !derechosActuales[btn.cDerechoCodigo ?? btn.tipo]))}\"\n [disabled]=\"!btn.esIndependiente && botonDisabled(btn, item)\"\n (click)=\"opcMenu(item, btn)\"\n >\n <div class=\"flex w-full items-center justify-between uppercase text-2xs\">\n @if (btn.icono) {\n <mat-icon [svgIcon]=\"btn.icono\" class=\"flex-none icon-xs\"\n ></mat-icon>\n }\n <span class=\"grow text-2xs\">{{ btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo)) }}</span>\n </div>\n </button>\n }\n }\n }\n}\n\n</ng-template>\n\n<ng-template #userMenu let-item=\"item\">\n <div class=\"mat-menu bg-white rounded mat-elevation-z8 shadow botonesContextual\">\n @for (btn of listaMenuCompleto; track btn) {\n <ng-container *ngTemplateOutlet=\"botonesContextual; context:{btn: btn, item: objSeleccionado, barraSuperior: false}\"></ng-container>\n }\n </div>\n</ng-template>\n\n\n<mat-menu #menuOpciones=\"matMenu\" xPosition=\"before\" yPosition=\"below\">\n @for (btn of listaMenuCompleto; track btn) {\n <ng-container\n *ngTemplateOutlet=\"botonesContextual; context:{btn: btn, item: objSeleccionado, barraSuperior: false}\"></ng-container>\n }\n</mat-menu>\n\n", styles: ["@charset \"UTF-8\";:root{--tabla-mantenimiento-seleccion-fondo: rgb(179, 217, 252);--tabla-mantenimiento-seleccion-texto: rgb(1, 84, 164);--mat-paginator-container-size: 30px}:root .table-mantenimiento .elemento-seleccionado{background-color:var(--tabla-mantenimiento-seleccion-fondo)!important;color:var(--tabla-mantenimiento-seleccion-texto)!important;border-color:var(--tabla-mantenimiento-seleccion-texto)!important}.jvs-tabla-mantenimiento{width:inherit;display:flex;flex-direction:column}.jvs-tabla-mantenimiento .contenedor-botones>*:first-child{@apply rounded-l;}.jvs-tabla-mantenimiento .contenedor-botones>*:last-child{@apply rounded-r;}.jvs-tabla-mantenimiento tr.regTooltip>td:first-child div:first-child:before,.jvs-tabla-mantenimiento tr.regTooltip>th:first-child div:first-child:before{content:\"\\26a0\\fe0f \";color:red;margin-right:4px;font-size:12px}.jvs-tabla-mantenimiento tr.regTooltip>td:first-child:not(:has(div)):before,.jvs-tabla-mantenimiento tr.regTooltip>th:first-child:not(:has(div)):before{content:\"\\26a0\\fe0f \";color:red;margin-right:4px;font-size:12px}.jvs-tabla-mantenimiento .mat-mdc-menu-content:not(:empty){@apply flex flex-col items-start;padding:0!important}.jvs-tabla-mantenimiento .mat-mdc-menu-item{line-height:24px!important;height:24px!important;min-height:24px!important}.jvs-tabla-mantenimiento .mat-mdc-menu-panel{min-height:auto!important}.jvs-tabla-mantenimiento .mat-mdc-table .mat-mdc-cell,.jvs-tabla-mantenimiento .mat-mdc-table .mat-mdc-header-cell .mat-mdc-footer-cell{white-space:unset}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-table-sticky-border-elem-right{border-left:1px solid #e0e0e0}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-table-sticky-border-elem-left{border-right:1px solid #e0e0e0}.jvs-tabla-mantenimiento .table-mantenimiento tr.regAnulado .mat-mdc-cell{color:unset!important}.jvs-tabla-mantenimiento .table-mantenimiento .bg-primary-activo .numeracionFila{@apply rounded-full bg-primary-contrast text-primary mx-1 p-1 w-6 h-6;}.jvs-tabla-mantenimiento .table-mantenimiento th .form-input{@apply w-auto;}.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell:not(.celda-numeracion-fila),.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-cell:not(.celda-numeracion-fila),.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-footer-cell:not(.celda-numeracion-fila){padding:.05rem .25rem}.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell,.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-cell,.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-footer-cell{border-width:1px;border-style:solid}.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell:first-of-type:not(.celda-numeracion-fila),.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell:last-of-type:not(.celda-numeracion-fila),.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-cell:first-of-type:not(.celda-numeracion-fila),.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-cell:last-of-type:not(.celda-numeracion-fila),.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-footer-cell:first-of-type:not(.celda-numeracion-fila),.jvs-tabla-mantenimiento .table-mantenimiento td.mat-mdc-footer-cell:last-of-type:not(.celda-numeracion-fila){padding:0 .25rem}.jvs-tabla-mantenimiento .table-mantenimiento .student-element-detail{overflow:hidden;display:flex;align-items:center;justify-content:center}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-header-row{height:25px!important;color:rgb(var(--color-primary))!important;background-color:rgb(var(--color-primary-contrast))!important}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-header-cell{padding:5px;font-size:10px;line-height:10px;font-weight:700!important;color:inherit}.jvs-tabla-mantenimiento .table-mantenimiento .mdc-data-table__row:not(.mdc-data-table__row--selected):not(.elemento-seleccionado):hover,.jvs-tabla-mantenimiento .table-mantenimiento .mdc-data-table__row:not(.mdc-data-table__row--selected):not(.elemento-seleccionado):focus{background-color:rgba(var(--color-primary-contrast),.04)}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-row .mat-mdc-cell,.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-footer-row .mat-mdc-cell{font-size:10px}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-row .mat-mdc-footer-cell:empty,.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-footer-row .mat-mdc-footer-cell:empty{border-width:0!important}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-cell{@apply leading-tight;}.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell{border-color:#d4d0d0;@apply text-center uppercase;}.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell .mat-sort-header-container{@apply flex items-center justify-between w-full;}.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell .mat-sort-header-container .mat-sort-header-content{@apply inline w-full text-center;}.jvs-tabla-mantenimiento .table-mantenimiento th.mat-mdc-header-cell .mat-sort-header-container .mat-sort-header-arrow{@apply flex-none;}.jvs-tabla-mantenimiento .table-mantenimiento .mat-mdc-sort-header-content{width:100%;text-align:center;display:unset;align-items:center}.compact-search-menu{min-width:200px!important;overflow:hidden}.compact-search-menu input:focus{@apply border-primary;}\n"] }]
|
|
1938
|
+
}], ctorParameters: () => [{ type: i1$2.Overlay }, { type: i0.ViewContainerRef }, { type: TablaMantenimientoService }, { type: i0.ChangeDetectorRef }], propDecorators: { id: [{
|
|
1737
1939
|
type: HostBinding
|
|
1738
1940
|
}], dataSuscription: [{
|
|
1739
1941
|
type: Input
|
|
@@ -1808,9 +2010,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.18", ngImpo
|
|
|
1808
2010
|
}], rows: [{
|
|
1809
2011
|
type: ViewChildren,
|
|
1810
2012
|
args: [MatRow, { read: ElementRef }]
|
|
1811
|
-
}], rowFooter: [{
|
|
1812
|
-
type: ViewChild,
|
|
1813
|
-
args: [MatFooterRow, { read: ElementRef }]
|
|
1814
2013
|
}], userMenu: [{
|
|
1815
2014
|
type: ViewChild,
|
|
1816
2015
|
args: ['userMenu']
|