@jvsoft/components 0.0.13-alpha.3 → 1.0.0-alpha.10
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/dialog-flotante/README.md +169 -0
- package/dialog-flotante/dialog-flotante.component.d.ts +13 -22
- package/fesm2022/jvsoft-components-dialog-flotante.mjs +49 -82
- package/fesm2022/jvsoft-components-dialog-flotante.mjs.map +1 -1
- package/fesm2022/jvsoft-components-filtro-busqueda.mjs +660 -0
- package/fesm2022/jvsoft-components-filtro-busqueda.mjs.map +1 -0
- package/fesm2022/jvsoft-components-lista-arbol.mjs +121 -145
- package/fesm2022/jvsoft-components-lista-arbol.mjs.map +1 -1
- package/fesm2022/jvsoft-components-mat-suffix-search-button.mjs +4 -2
- package/fesm2022/jvsoft-components-mat-suffix-search-button.mjs.map +1 -1
- package/fesm2022/jvsoft-components-tabla-mantenimiento-components-progress-bar.mjs +1 -1
- package/fesm2022/jvsoft-components-tabla-mantenimiento-components-progress-bar.mjs.map +1 -1
- package/fesm2022/jvsoft-components-tabla-mantenimiento.mjs +107 -61
- package/fesm2022/jvsoft-components-tabla-mantenimiento.mjs.map +1 -1
- package/fesm2022/jvsoft-components.mjs +928 -301
- package/fesm2022/jvsoft-components.mjs.map +1 -1
- package/filtro-busqueda/README.md +156 -0
- package/filtro-busqueda/filtro-busqueda.component.d.ts +89 -0
- package/filtro-busqueda/filtro-busqueda.component.scss +98 -0
- package/filtro-busqueda/filtro-busqueda.service.d.ts +40 -0
- package/filtro-busqueda/index.d.ts +5 -0
- package/filtro-busqueda/interfaces/filtro-busqueda.interface.d.ts +86 -0
- package/filtro-busqueda/public-api.d.ts +3 -0
- package/index.d.ts +1 -0
- package/lista-arbol/README.md +268 -0
- package/lista-arbol/lista-arbol.component.d.ts +36 -37
- package/package.json +17 -14
- package/src/styles/base-jvsoft-components.css +6 -4
- package/src/styles/base.scss +1 -0
- package/tabla-mantenimiento/interfaces/global/columnas-tabla.d.ts +9 -10
- package/tabla-mantenimiento/interfaces/global/otros.d.ts +1 -0
- package/tabla-mantenimiento/tabla-mantenimiento-column-defs/column-type/column-type.module.d.ts +2 -1
- package/tabla-mantenimiento/tabla-mantenimiento.component.d.ts +15 -8
- package/tabla-mantenimiento/tabla-mantenimiento.component.scss +14 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import {
|
|
2
|
+
import { input, booleanAttribute, output, computed, Component, EventEmitter, HostListener, Output, Input, Directive, ViewChild, Optional, inject, Pipe, NgModule, ContentChildren, ViewChildren, Injectable, signal, ElementRef, HostBinding, effect, untracked, InjectionToken } from '@angular/core';
|
|
3
3
|
import * as i3 from '@angular/material/dialog';
|
|
4
4
|
import { MatDialogModule } from '@angular/material/dialog';
|
|
5
5
|
import * as i4 from '@angular/material/icon';
|
|
@@ -8,118 +8,120 @@ import * as i1 from '@angular/common';
|
|
|
8
8
|
import { CommonModule, DecimalPipe, NgIf, NgForOf } from '@angular/common';
|
|
9
9
|
import { CdkDrag, CdkDragHandle } from '@angular/cdk/drag-drop';
|
|
10
10
|
import * as i5 from '@angular/material/core';
|
|
11
|
-
import { MatRipple, MatRippleModule } from '@angular/material/core';
|
|
11
|
+
import { MatRipple, MatRippleModule, MatOptionModule } from '@angular/material/core';
|
|
12
12
|
import * as i6 from '@angular/material/divider';
|
|
13
13
|
import { MatDivider, MatDividerModule } from '@angular/material/divider';
|
|
14
14
|
import { __decorate } from 'tslib';
|
|
15
15
|
import { trigger, state, transition, style, animate } from '@angular/animations';
|
|
16
16
|
import { TemplatePortal } from '@angular/cdk/portal';
|
|
17
|
-
import * as
|
|
18
|
-
import { Validators, FormControl, FormGroup, ReactiveFormsModule, FormsModule } from '@angular/forms';
|
|
17
|
+
import * as i2$1 from '@angular/forms';
|
|
18
|
+
import { Validators, FormControl, FormGroup, ReactiveFormsModule, FormsModule, FormBuilder } from '@angular/forms';
|
|
19
19
|
import * as i14 from '@angular/material/badge';
|
|
20
20
|
import { MatBadgeModule } from '@angular/material/badge';
|
|
21
21
|
import * as i5$1 from '@angular/material/checkbox';
|
|
22
22
|
import { MatCheckboxModule } from '@angular/material/checkbox';
|
|
23
|
-
import * as i2$
|
|
24
|
-
import { MatMenuModule, MatMenu } from '@angular/material/menu';
|
|
23
|
+
import * as i2$2 from '@angular/material/menu';
|
|
24
|
+
import { MatMenuModule, MatMenuTrigger, MatMenu } from '@angular/material/menu';
|
|
25
25
|
import * as i9 from '@angular/material/paginator';
|
|
26
26
|
import { MatPaginatorModule, MatPaginator, MAT_PAGINATOR_DEFAULT_OPTIONS } from '@angular/material/paginator';
|
|
27
27
|
import * as i3$1 from '@angular/material/sort';
|
|
28
28
|
import { MatSortModule, MatSort } from '@angular/material/sort';
|
|
29
29
|
import * as i2 from '@angular/material/table';
|
|
30
30
|
import { MatColumnDef, MatTable, MatTableModule, MatTableDataSource, MatFooterRow, MatRow } from '@angular/material/table';
|
|
31
|
-
import * as i4$
|
|
31
|
+
import * as i4$2 from '@angular/material/tooltip';
|
|
32
32
|
import { MatTooltipModule } from '@angular/material/tooltip';
|
|
33
33
|
import { untilDestroyed, UntilDestroy } from '@ngneat/until-destroy';
|
|
34
34
|
import moment from 'moment';
|
|
35
|
-
import { Subject, takeUntil, startWith, of, fromEvent } from 'rxjs';
|
|
36
|
-
import { filter, map, take } from 'rxjs/operators';
|
|
35
|
+
import { Subject, takeUntil, startWith, of, fromEvent, BehaviorSubject } from 'rxjs';
|
|
36
|
+
import { filter, map, take, switchMap, debounceTime, takeUntil as takeUntil$1, distinctUntilChanged } from 'rxjs/operators';
|
|
37
37
|
import shortHash from 'shorthash2';
|
|
38
|
+
import * as i4$1 from '@jvsoft/utils';
|
|
39
|
+
import { JvsPopoverDirective, JvsPopoverListenerDirective, DataModel as DataModel$1, generateRandomString, dataEnLista, tipoValorFuncion as tipoValorFuncion$1, getUniqueValues, establecerQuitarRequired, mostrarValorEnBusqueda, getFormValidationErrors } from '@jvsoft/utils';
|
|
38
40
|
import * as i1$1 from '@angular/platform-browser';
|
|
39
41
|
import { DomSanitizer } from '@angular/platform-browser';
|
|
40
42
|
import * as XLSX from 'xlsx';
|
|
41
43
|
import { Router, ActivatedRoute, NavigationEnd } from '@angular/router';
|
|
42
|
-
import * as i2$
|
|
44
|
+
import * as i2$3 from '@angular/cdk/overlay';
|
|
43
45
|
import * as i3$2 from '@angular/material/tree';
|
|
44
46
|
import { MatTreeModule } from '@angular/material/tree';
|
|
45
47
|
import { NestedTreeControl } from '@angular/cdk/tree';
|
|
46
|
-
import {
|
|
48
|
+
import { toObservable, takeUntilDestroyed } from '@angular/core/rxjs-interop';
|
|
49
|
+
import * as i3$3 from '@angular/material/autocomplete';
|
|
50
|
+
import { MatAutocompleteModule } from '@angular/material/autocomplete';
|
|
51
|
+
import * as i4$3 from '@angular/material/datepicker';
|
|
52
|
+
import { MatDatepickerModule } from '@angular/material/datepicker';
|
|
53
|
+
import * as i5$2 from '@angular/material/form-field';
|
|
54
|
+
import { MatFormFieldModule } from '@angular/material/form-field';
|
|
55
|
+
import { MatInputModule } from '@angular/material/input';
|
|
56
|
+
import { MatRadioModule } from '@angular/material/radio';
|
|
57
|
+
import { MatSelectModule } from '@angular/material/select';
|
|
58
|
+
import * as i8 from '@angular/material/tabs';
|
|
59
|
+
import { MatTabsModule } from '@angular/material/tabs';
|
|
60
|
+
import { TextFieldModule } from '@angular/cdk/text-field';
|
|
61
|
+
import { ToastrService } from 'ngx-toastr';
|
|
47
62
|
|
|
48
63
|
class DialogFlotanteComponent {
|
|
49
|
-
cssClases = {};
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
}
|
|
61
|
-
set sinBarraDeAccion(val) {
|
|
62
|
-
this._sinBarraDeAccion = val == '';
|
|
63
|
-
}
|
|
64
|
+
cssClases = input({});
|
|
65
|
+
sinTitulo = input(false, { transform: booleanAttribute });
|
|
66
|
+
sinBarraDeAccion = input(false, { transform: booleanAttribute });
|
|
67
|
+
btnCerrarBarra = input(false, { transform: booleanAttribute });
|
|
68
|
+
iconoTitulo = input(undefined);
|
|
69
|
+
matDialogRefActual = input(undefined);
|
|
70
|
+
// Inputs crudos para botones (string | boolean | object)
|
|
71
|
+
btnGuardarInput = input(undefined, { alias: 'btnGuardar' });
|
|
72
|
+
btnCerrarInput = input(undefined, { alias: 'btnCerrar' });
|
|
73
|
+
btnGuardarClick = output();
|
|
74
|
+
btnCerrarClick = output();
|
|
64
75
|
defaultBtnCerrar = { label: 'CERRAR', class: 'text-gray-700 border-gray-700' };
|
|
65
|
-
_btnCerrar = this.defaultBtnCerrar;
|
|
66
|
-
get btnCerrar() {
|
|
67
|
-
return this._btnCerrar;
|
|
68
|
-
}
|
|
69
|
-
set btnCerrar(val) {
|
|
70
|
-
if (val == null || val === '') {
|
|
71
|
-
this._btnCerrar = this.defaultBtnCerrar;
|
|
72
|
-
}
|
|
73
|
-
else {
|
|
74
|
-
this._btnCerrar = (typeof val === 'string' && val !== '') ? { ...this.defaultBtnCerrar, label: val } :
|
|
75
|
-
(typeof val === 'boolean' && val) ? this.defaultBtnCerrar :
|
|
76
|
-
val ?? this.defaultBtnCerrar;
|
|
77
|
-
}
|
|
78
|
-
}
|
|
79
|
-
_btnCerrarBarra = true;
|
|
80
|
-
get btnCerrarBarra() {
|
|
81
|
-
return this._btnCerrarBarra;
|
|
82
|
-
}
|
|
83
|
-
set btnCerrarBarra(val) {
|
|
84
|
-
this._btnCerrarBarra = val || true;
|
|
85
|
-
}
|
|
86
76
|
defaultBtnGuardar = {
|
|
87
77
|
label: 'GUARDAR', class: 'text-blue-700 border-blue-700', icono: 'roundSave'
|
|
88
78
|
};
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
79
|
+
// Computed signals para normalizar la configuración de botones
|
|
80
|
+
btnCerrar = computed(() => {
|
|
81
|
+
const val = this.btnCerrarInput();
|
|
82
|
+
// Si es false, null o undefined -> NO MOSTRAR
|
|
83
|
+
if (val === false || val === null || val === undefined)
|
|
84
|
+
return undefined;
|
|
85
|
+
// Si es string vacío (atributo presente sin valor) o true -> MOSTRAR DEFAULT
|
|
86
|
+
if (val === '' || val === true)
|
|
87
|
+
return this.defaultBtnCerrar;
|
|
88
|
+
// Si es string con valor -> MOSTRAR DEFAULT CON LABEL
|
|
89
|
+
if (typeof val === 'string')
|
|
90
|
+
return { ...this.defaultBtnCerrar, label: val };
|
|
91
|
+
// Si es objeto -> USAR EL OBJETO
|
|
92
|
+
return val;
|
|
93
|
+
});
|
|
94
|
+
btnGuardar = computed(() => {
|
|
95
|
+
const val = this.btnGuardarInput();
|
|
96
|
+
// Si es false, null o undefined -> NO MOSTRAR
|
|
97
|
+
if (val === false || val === null || val === undefined)
|
|
98
|
+
return undefined;
|
|
99
|
+
// Si es string vacío (atributo presente sin valor) o true -> MOSTRAR DEFAULT
|
|
100
|
+
if (val === '' || val === true)
|
|
101
|
+
return this.defaultBtnGuardar;
|
|
102
|
+
// Si es string con valor -> MOSTRAR DEFAULT CON LABEL
|
|
103
|
+
if (typeof val === 'string')
|
|
104
|
+
return { ...this.defaultBtnGuardar, label: val };
|
|
105
|
+
// Si es objeto -> USAR EL OBJETO
|
|
106
|
+
return val;
|
|
107
|
+
});
|
|
107
108
|
guardarDialogo() {
|
|
108
109
|
this.btnGuardarClick.emit(true);
|
|
109
110
|
}
|
|
110
111
|
cerrarDialogo() {
|
|
111
112
|
this.btnCerrarClick.emit(true);
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
113
|
+
const ref = this.matDialogRefActual();
|
|
114
|
+
if (ref) {
|
|
115
|
+
if (ref.componentInstance?.validarCerrarDialog) {
|
|
116
|
+
ref.componentInstance?.validarCerrarDialog();
|
|
115
117
|
}
|
|
116
118
|
else {
|
|
117
|
-
|
|
119
|
+
ref.close('Cerrado GDLG');
|
|
118
120
|
}
|
|
119
121
|
}
|
|
120
122
|
}
|
|
121
123
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DialogFlotanteComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
122
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
|
|
124
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "19.2.14", type: DialogFlotanteComponent, isStandalone: true, selector: "[jvsDialogFlotante]", inputs: { cssClases: { classPropertyName: "cssClases", publicName: "cssClases", isSignal: true, isRequired: false, transformFunction: null }, sinTitulo: { classPropertyName: "sinTitulo", publicName: "sinTitulo", isSignal: true, isRequired: false, transformFunction: null }, sinBarraDeAccion: { classPropertyName: "sinBarraDeAccion", publicName: "sinBarraDeAccion", isSignal: true, isRequired: false, transformFunction: null }, btnCerrarBarra: { classPropertyName: "btnCerrarBarra", publicName: "btnCerrarBarra", isSignal: true, isRequired: false, transformFunction: null }, iconoTitulo: { classPropertyName: "iconoTitulo", publicName: "iconoTitulo", isSignal: true, isRequired: false, transformFunction: null }, matDialogRefActual: { classPropertyName: "matDialogRefActual", publicName: "matDialogRefActual", isSignal: true, isRequired: false, transformFunction: null }, btnGuardarInput: { classPropertyName: "btnGuardarInput", publicName: "btnGuardar", isSignal: true, isRequired: false, transformFunction: null }, btnCerrarInput: { classPropertyName: "btnCerrarInput", publicName: "btnCerrar", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { btnGuardarClick: "btnGuardarClick", btnCerrarClick: "btnCerrarClick" }, host: { classAttribute: "jvs-dialog-flotante" }, ngImport: i0, template: "<ng-container *ngIf=\"sinTitulo(); else conTitulo\">\n <ng-container [ngTemplateOutlet]=\"parteComun\"></ng-container>\n</ng-container>\n\n<ng-template #conTitulo>\n <div cdkDrag class=\"block h-full\" cdkDragRootElement=\".cdk-overlay-pane\" cdkDragBoundary=\"body\">\n <div class=\"flex-auto flex items-center justify-between hover:cursor-move gap-1\"\n [ngClass]=\"cssClases()['titulo'] ?? 'bg-primary text-primary-contrast'\"\n mat-dialog-title cdkDragHandle>\n\n <mat-icon *ngIf=\"iconoTitulo()\" class=\"flex-none icon-xs\" [svgIcon]=\"iconoTitulo()!\"></mat-icon>\n <ng-content select=\"[tituloImagen]\"></ng-content>\n <h5 class=\"flex-1 m-0\">\n <ng-content select=\"[titulo]\"></ng-content>\n </h5>\n <ng-content select=\"[selectTitulo]\"></ng-content>\n\n <ng-container *ngIf=\"btnCerrar() || btnCerrarBarra()\">\n <button matRipple class=\"flex items-center justify-center ml-2 h-6 w-6 bg-red-700 rounded-md text-white\"\n type=\"button\" [mat-dialog-close]=\"!matDialogRefActual()\"\n (click)=\"matDialogRefActual() ? cerrarDialogo() : null\">\n <mat-icon svgIcon=\"roundClose\"></mat-icon>\n </button>\n </ng-container>\n </div>\n\n <mat-divider class=\"flex-auto bg-primary\"></mat-divider>\n <ng-container [ngTemplateOutlet]=\"parteComun\"></ng-container>\n </div>\n</ng-template>\n\n<ng-template #parteComun>\n <mat-dialog-content class=\"flex-1\">\n <div class=\"contenedor-cuerpo\">\n <ng-content select=\"[cuerpo]\"></ng-content>\n </div>\n </mat-dialog-content>\n\n <mat-dialog-actions class=\"flex-auto flex items-center justify-between gap-1 pt-0 mt-0\" *ngIf=\"!sinBarraDeAccion()\">\n <div class=\"flex items-start justify-start gap-1\">\n <ng-content select=\"[pieIzquierda]\"></ng-content>\n </div>\n <div class=\"flex items-center justify-center gap-1\">\n <ng-content select=\"[pieCentro]\"></ng-content>\n </div>\n <div class=\"flex items-end justify-end gap-1\">\n <ng-content select=\"[pieDerecha]\"></ng-content>\n\n <!-- Bot\u00F3n Guardar -->\n <button matRipple *ngIf=\"btnGuardar()\" type=\"submit\"\n class=\"boton-dialog-flotante\" [ngClass]=\"btnGuardar()!.class\"\n [class]=\"cssClases()['btnGuardar']\" (click)=\"guardarDialogo()\">\n <mat-icon class=\"icon-xs\" [svgIcon]=\"btnGuardar()?.icono ?? ''\"></mat-icon>\n <span>{{ btnGuardar()!.label }}</span>\n </button>\n\n <!-- Bot\u00F3n Cerrar -->\n <button matRipple *ngIf=\"btnCerrar()\" type=\"button\"\n class=\"boton-dialog-flotante\" [ngClass]=\"btnCerrar()!.class\"\n [mat-dialog-close]=\"!matDialogRefActual()\" (click)=\"matDialogRefActual() ? cerrarDialogo() : null\">\n <mat-icon class=\"icon-xs\" svgIcon=\"roundClose\"></mat-icon>\n <span>{{ btnCerrar()!.label }}</span>\n </button>\n </div>\n </mat-dialog-actions>\n</ng-template>\n", styles: [".jvs-dialog-flotante{max-width:98vw}.jvs-dialog-flotante .mat-mdc-dialog-title .mat-mdc-checkbox .mdc-form-field{color:unset}.jvs-dialog-flotante .mat-mdc-dialog-title .mat-mdc-checkbox .mdc-checkbox__native-control:enabled:focus:focus:not(:checked):not(:indeterminate)~.mdc-checkbox__background{border-color:var(--color-prnpx tailwindcss init --fullimary-contrast)!important}.jvs-dialog-flotante fieldset{@apply w-full sm:w-auto rounded-sm bg-transparent pt-0 pb-1 px-1 border;}.jvs-dialog-flotante fieldset legend{@apply px-2 font-bold border-0 bg-transparent;width:auto}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatDialogModule }, { kind: "directive", type: i3.MatDialogClose, selector: "[mat-dialog-close], [matDialogClose]", inputs: ["aria-label", "type", "mat-dialog-close", "matDialogClose"], exportAs: ["matDialogClose"] }, { kind: "directive", type: i3.MatDialogTitle, selector: "[mat-dialog-title], [matDialogTitle]", inputs: ["id"], exportAs: ["matDialogTitle"] }, { kind: "directive", type: i3.MatDialogActions, selector: "[mat-dialog-actions], mat-dialog-actions, [matDialogActions]", inputs: ["align"] }, { kind: "directive", type: i3.MatDialogContent, selector: "[mat-dialog-content], mat-dialog-content, [matDialogContent]" }, { kind: "directive", type: CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer", "cdkDragScale"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { kind: "directive", type: CdkDragHandle, selector: "[cdkDragHandle]", inputs: ["cdkDragHandleDisabled"] }, { kind: "directive", type: MatRipple, selector: "[mat-ripple], [matRipple]", inputs: ["matRippleColor", "matRippleUnbounded", "matRippleCentered", "matRippleRadius", "matRippleAnimation", "matRippleDisabled", "matRippleTrigger"], exportAs: ["matRipple"] }, { kind: "component", type: MatDivider, selector: "mat-divider", inputs: ["vertical", "inset"] }] });
|
|
123
125
|
}
|
|
124
126
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DialogFlotanteComponent, decorators: [{
|
|
125
127
|
type: Component,
|
|
@@ -133,28 +135,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImpo
|
|
|
133
135
|
MatDivider,
|
|
134
136
|
], host: {
|
|
135
137
|
class: 'jvs-dialog-flotante',
|
|
136
|
-
}, template: "<ng-container *ngIf=\"sinTitulo; else conTitulo\">\n <ng-container [ngTemplateOutlet]=\"parteComun\"></ng-container>\n</ng-container>\n\n<ng-template #conTitulo>\n <div cdkDrag class=\"block h-full\" cdkDragRootElement=\".cdk-overlay-pane\" cdkDragBoundary=\"body\">\n <div class=\"flex-auto flex items-center justify-between hover:cursor-move gap-1\"\n [ngClass]=\"cssClases['titulo'] ?? 'bg-primary text-primary-contrast'\"\n mat-dialog-title cdkDragHandle>\n\n <mat-icon *ngIf=\"iconoTitulo\" class=\"flex-none icon-xs\" [svgIcon]=\"iconoTitulo
|
|
137
|
-
}]
|
|
138
|
-
type: Input
|
|
139
|
-
}], sinTitulo: [{
|
|
140
|
-
type: Input
|
|
141
|
-
}], sinBarraDeAccion: [{
|
|
142
|
-
type: Input
|
|
143
|
-
}], btnCerrar: [{
|
|
144
|
-
type: Input
|
|
145
|
-
}], btnCerrarBarra: [{
|
|
146
|
-
type: Input
|
|
147
|
-
}], btnGuardar: [{
|
|
148
|
-
type: Input
|
|
149
|
-
}], iconoTitulo: [{
|
|
150
|
-
type: Input
|
|
151
|
-
}], matDialogRefActual: [{
|
|
152
|
-
type: Input
|
|
153
|
-
}], btnGuardarClick: [{
|
|
154
|
-
type: Output
|
|
155
|
-
}], btnCerrarClick: [{
|
|
156
|
-
type: Output
|
|
157
|
-
}] } });
|
|
138
|
+
}, template: "<ng-container *ngIf=\"sinTitulo(); else conTitulo\">\n <ng-container [ngTemplateOutlet]=\"parteComun\"></ng-container>\n</ng-container>\n\n<ng-template #conTitulo>\n <div cdkDrag class=\"block h-full\" cdkDragRootElement=\".cdk-overlay-pane\" cdkDragBoundary=\"body\">\n <div class=\"flex-auto flex items-center justify-between hover:cursor-move gap-1\"\n [ngClass]=\"cssClases()['titulo'] ?? 'bg-primary text-primary-contrast'\"\n mat-dialog-title cdkDragHandle>\n\n <mat-icon *ngIf=\"iconoTitulo()\" class=\"flex-none icon-xs\" [svgIcon]=\"iconoTitulo()!\"></mat-icon>\n <ng-content select=\"[tituloImagen]\"></ng-content>\n <h5 class=\"flex-1 m-0\">\n <ng-content select=\"[titulo]\"></ng-content>\n </h5>\n <ng-content select=\"[selectTitulo]\"></ng-content>\n\n <ng-container *ngIf=\"btnCerrar() || btnCerrarBarra()\">\n <button matRipple class=\"flex items-center justify-center ml-2 h-6 w-6 bg-red-700 rounded-md text-white\"\n type=\"button\" [mat-dialog-close]=\"!matDialogRefActual()\"\n (click)=\"matDialogRefActual() ? cerrarDialogo() : null\">\n <mat-icon svgIcon=\"roundClose\"></mat-icon>\n </button>\n </ng-container>\n </div>\n\n <mat-divider class=\"flex-auto bg-primary\"></mat-divider>\n <ng-container [ngTemplateOutlet]=\"parteComun\"></ng-container>\n </div>\n</ng-template>\n\n<ng-template #parteComun>\n <mat-dialog-content class=\"flex-1\">\n <div class=\"contenedor-cuerpo\">\n <ng-content select=\"[cuerpo]\"></ng-content>\n </div>\n </mat-dialog-content>\n\n <mat-dialog-actions class=\"flex-auto flex items-center justify-between gap-1 pt-0 mt-0\" *ngIf=\"!sinBarraDeAccion()\">\n <div class=\"flex items-start justify-start gap-1\">\n <ng-content select=\"[pieIzquierda]\"></ng-content>\n </div>\n <div class=\"flex items-center justify-center gap-1\">\n <ng-content select=\"[pieCentro]\"></ng-content>\n </div>\n <div class=\"flex items-end justify-end gap-1\">\n <ng-content select=\"[pieDerecha]\"></ng-content>\n\n <!-- Bot\u00F3n Guardar -->\n <button matRipple *ngIf=\"btnGuardar()\" type=\"submit\"\n class=\"boton-dialog-flotante\" [ngClass]=\"btnGuardar()!.class\"\n [class]=\"cssClases()['btnGuardar']\" (click)=\"guardarDialogo()\">\n <mat-icon class=\"icon-xs\" [svgIcon]=\"btnGuardar()?.icono ?? ''\"></mat-icon>\n <span>{{ btnGuardar()!.label }}</span>\n </button>\n\n <!-- Bot\u00F3n Cerrar -->\n <button matRipple *ngIf=\"btnCerrar()\" type=\"button\"\n class=\"boton-dialog-flotante\" [ngClass]=\"btnCerrar()!.class\"\n [mat-dialog-close]=\"!matDialogRefActual()\" (click)=\"matDialogRefActual() ? cerrarDialogo() : null\">\n <mat-icon class=\"icon-xs\" svgIcon=\"roundClose\"></mat-icon>\n <span>{{ btnCerrar()!.label }}</span>\n </button>\n </div>\n </mat-dialog-actions>\n</ng-template>\n", styles: [".jvs-dialog-flotante{max-width:98vw}.jvs-dialog-flotante .mat-mdc-dialog-title .mat-mdc-checkbox .mdc-form-field{color:unset}.jvs-dialog-flotante .mat-mdc-dialog-title .mat-mdc-checkbox .mdc-checkbox__native-control:enabled:focus:focus:not(:checked):not(:indeterminate)~.mdc-checkbox__background{border-color:var(--color-prnpx tailwindcss init --fullimary-contrast)!important}.jvs-dialog-flotante fieldset{@apply w-full sm:w-auto rounded-sm bg-transparent pt-0 pb-1 px-1 border;}.jvs-dialog-flotante fieldset legend{@apply px-2 font-bold border-0 bg-transparent;width:auto}\n"] }]
|
|
139
|
+
}] });
|
|
158
140
|
|
|
159
141
|
function buscarEnArray(coleccion, idBuscar, dato) {
|
|
160
142
|
if (!Array.isArray(coleccion) || coleccion.length === 0)
|
|
@@ -485,11 +467,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImpo
|
|
|
485
467
|
class ColumnTypeNumberComponent extends ColumnTypeComponent {
|
|
486
468
|
column = {};
|
|
487
469
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: ColumnTypeNumberComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
488
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: ColumnTypeNumberComponent, isStandalone: false, selector: "jvs-column-type-number", inputs: { column: "column" }, usesInheritance: true, ngImport: i0, template: "\n<ng-template #cellTemplate let-row=\"row\">\n\t\t\t\t<span *ngIf=\"column.property
|
|
470
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: ColumnTypeNumberComponent, isStandalone: false, selector: "jvs-column-type-number", inputs: { column: "column" }, usesInheritance: true, ngImport: i0, template: "\n<ng-template #cellTemplate let-row=\"row\">\n\t\t\t\t<span *ngIf=\"column.property\" class=\"!text-indigo-900 font-semibold\"\n [jvsPopover]=\"(column.popover?.template || column.popover?.content?.(row)) ?? null\"\n [context]=\"row\"\n [trigger]=\"column.popover?.trigger || 'hover'\"\n [position]=\"column.popover?.position || 'bottom'\"\n [customClass]=\"column.popover?.customClass || ''\">\n\t\t\t\t\t{{ row[column.property] | number: (column.format ? column.format : '1.0-2') }}\n\t\t\t\t</span>\n</ng-template>\n\n<ng-container matColumnDef=\"{{ column.property }}\">\n <!-- Definici\u00F3n del encabezado de la columna -->\n <th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"uppercase text-center\" mat-header-cell mat-sort-header\n [disabled]=\"column.sort === false\">\n <span [innerHTML]=\"column.label\">{{ column.label }} </span>\n </th>\n\n <!-- Cuerpo de la celda, definido por los hijos -->\n <td *matCellDef=\"let row\" [ngClass]=\"column.cssClasses\" mat-cell (click)=\"accionClick(row, $event)\">\n\n <ng-container [ngTemplateOutlet]=\"cellTemplate\" [ngTemplateOutletContext]=\"{row}\"></ng-container>\n\n </td>\n\n <th *matFooterCellDef [ngClass]=\"column.cssFooterClasses\" mat-footer-cell>\n {{ column.transformarFooter ? column.transformarFooter() : '' }}\n </th>\n</ng-container>\n", dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { 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: "component", type: i3$1.MatSortHeader, selector: "[mat-sort-header]", inputs: ["mat-sort-header", "arrowPosition", "start", "disabled", "sortActionDescription", "disableClear"], exportAs: ["matSortHeader"] }, { kind: "directive", type: i4$1.JvsPopoverDirective, selector: "[jvsPopover]", inputs: ["jvsPopover", "context", "trigger", "position", "customClass"] }, { kind: "pipe", type: i1.DecimalPipe, name: "number" }] });
|
|
489
471
|
}
|
|
490
472
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: ColumnTypeNumberComponent, decorators: [{
|
|
491
473
|
type: Component,
|
|
492
|
-
args: [{ selector: 'jvs-column-type-number', standalone: false, template: "\n<ng-template #cellTemplate let-row=\"row\">\n\t\t\t\t<span *ngIf=\"column.property
|
|
474
|
+
args: [{ selector: 'jvs-column-type-number', standalone: false, template: "\n<ng-template #cellTemplate let-row=\"row\">\n\t\t\t\t<span *ngIf=\"column.property\" class=\"!text-indigo-900 font-semibold\"\n [jvsPopover]=\"(column.popover?.template || column.popover?.content?.(row)) ?? null\"\n [context]=\"row\"\n [trigger]=\"column.popover?.trigger || 'hover'\"\n [position]=\"column.popover?.position || 'bottom'\"\n [customClass]=\"column.popover?.customClass || ''\">\n\t\t\t\t\t{{ row[column.property] | number: (column.format ? column.format : '1.0-2') }}\n\t\t\t\t</span>\n</ng-template>\n\n<ng-container matColumnDef=\"{{ column.property }}\">\n <!-- Definici\u00F3n del encabezado de la columna -->\n <th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"uppercase text-center\" mat-header-cell mat-sort-header\n [disabled]=\"column.sort === false\">\n <span [innerHTML]=\"column.label\">{{ column.label }} </span>\n </th>\n\n <!-- Cuerpo de la celda, definido por los hijos -->\n <td *matCellDef=\"let row\" [ngClass]=\"column.cssClasses\" mat-cell (click)=\"accionClick(row, $event)\">\n\n <ng-container [ngTemplateOutlet]=\"cellTemplate\" [ngTemplateOutletContext]=\"{row}\"></ng-container>\n\n </td>\n\n <th *matFooterCellDef [ngClass]=\"column.cssFooterClasses\" mat-footer-cell>\n {{ column.transformarFooter ? column.transformarFooter() : '' }}\n </th>\n</ng-container>\n" }]
|
|
493
475
|
}], propDecorators: { column: [{
|
|
494
476
|
type: Input,
|
|
495
477
|
args: [{ required: true }]
|
|
@@ -498,11 +480,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImpo
|
|
|
498
480
|
class ColumnTypeDateComponent extends ColumnTypeComponent {
|
|
499
481
|
column = {};
|
|
500
482
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: ColumnTypeDateComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
501
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: ColumnTypeDateComponent, isStandalone: false, selector: "jvs-column-type-date", inputs: { column: "column" }, usesInheritance: true, ngImport: i0, template: "<ng-template #cellTemplate let-row=\"row\">\n {{ row[column.property] | date: (column.format ? column.format : 'dd/MM/yyyy') }}\n</ng-template>\n\n<ng-container matColumnDef=\"{{ column.property }}\">\n <!-- Definici\u00F3n del encabezado de la columna -->\n <th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"uppercase text-center\" mat-header-cell mat-sort-header\n [disabled]=\"column.sort === false\">\n <span [innerHTML]=\"column.label
|
|
483
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: ColumnTypeDateComponent, isStandalone: false, selector: "jvs-column-type-date", inputs: { column: "column" }, usesInheritance: true, ngImport: i0, template: "<ng-template #cellTemplate let-row=\"row\">\n <span [jvsPopover]=\"(column.popover?.template || column.popover?.content?.(row)) ?? null\"\n [context]=\"row\"\n [trigger]=\"column.popover?.trigger || 'hover'\"\n [position]=\"column.popover?.position || 'bottom'\"\n [customClass]=\"column.popover?.customClass || ''\"\n *ngIf=\"column.property && row[column.property]\">\n {{ row[column.property] | date: (column.format ? column.format : 'dd/MM/yyyy') }}\n </span>\n</ng-template>\n\n<ng-container matColumnDef=\"{{ column.property }}\">\n <!-- Definici\u00F3n del encabezado de la columna -->\n <th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"uppercase text-center\" mat-header-cell mat-sort-header\n [disabled]=\"column.sort === false\">\n <span [innerHTML]=\"column.label\">{{ column.label }} </span>\n </th>\n\n <!-- Cuerpo de la celda, definido por los hijos -->\n <td *matCellDef=\"let row\" [ngClass]=\"column.cssClasses\" mat-cell (click)=\"accionClick(row, $event)\">\n\n <ng-container [ngTemplateOutlet]=\"cellTemplate\" [ngTemplateOutletContext]=\"{row}\"></ng-container>\n\n </td>\n\n <th *matFooterCellDef [ngClass]=\"column.cssFooterClasses\" mat-footer-cell>\n {{ column.transformarFooter ? column.transformarFooter() : '' }}\n </th>\n</ng-container>\n", dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { 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: "component", type: i3$1.MatSortHeader, selector: "[mat-sort-header]", inputs: ["mat-sort-header", "arrowPosition", "start", "disabled", "sortActionDescription", "disableClear"], exportAs: ["matSortHeader"] }, { kind: "directive", type: i4$1.JvsPopoverDirective, selector: "[jvsPopover]", inputs: ["jvsPopover", "context", "trigger", "position", "customClass"] }, { kind: "pipe", type: i1.DatePipe, name: "date" }] });
|
|
502
484
|
}
|
|
503
485
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: ColumnTypeDateComponent, decorators: [{
|
|
504
486
|
type: Component,
|
|
505
|
-
args: [{ selector: 'jvs-column-type-date', standalone: false, template: "<ng-template #cellTemplate let-row=\"row\">\n {{ row[column.property] | date: (column.format ? column.format : 'dd/MM/yyyy') }}\n</ng-template>\n\n<ng-container matColumnDef=\"{{ column.property }}\">\n <!-- Definici\u00F3n del encabezado de la columna -->\n <th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"uppercase text-center\" mat-header-cell mat-sort-header\n [disabled]=\"column.sort === false\">\n <span [innerHTML]=\"column.label
|
|
487
|
+
args: [{ selector: 'jvs-column-type-date', standalone: false, template: "<ng-template #cellTemplate let-row=\"row\">\n <span [jvsPopover]=\"(column.popover?.template || column.popover?.content?.(row)) ?? null\"\n [context]=\"row\"\n [trigger]=\"column.popover?.trigger || 'hover'\"\n [position]=\"column.popover?.position || 'bottom'\"\n [customClass]=\"column.popover?.customClass || ''\"\n *ngIf=\"column.property && row[column.property]\">\n {{ row[column.property] | date: (column.format ? column.format : 'dd/MM/yyyy') }}\n </span>\n</ng-template>\n\n<ng-container matColumnDef=\"{{ column.property }}\">\n <!-- Definici\u00F3n del encabezado de la columna -->\n <th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"uppercase text-center\" mat-header-cell mat-sort-header\n [disabled]=\"column.sort === false\">\n <span [innerHTML]=\"column.label\">{{ column.label }} </span>\n </th>\n\n <!-- Cuerpo de la celda, definido por los hijos -->\n <td *matCellDef=\"let row\" [ngClass]=\"column.cssClasses\" mat-cell (click)=\"accionClick(row, $event)\">\n\n <ng-container [ngTemplateOutlet]=\"cellTemplate\" [ngTemplateOutletContext]=\"{row}\"></ng-container>\n\n </td>\n\n <th *matFooterCellDef [ngClass]=\"column.cssFooterClasses\" mat-footer-cell>\n {{ column.transformarFooter ? column.transformarFooter() : '' }}\n </th>\n</ng-container>\n" }]
|
|
506
488
|
}], propDecorators: { column: [{
|
|
507
489
|
type: Input,
|
|
508
490
|
args: [{ required: true }]
|
|
@@ -529,11 +511,11 @@ class ColumnTypeSinoComponent extends ColumnTypeComponent {
|
|
|
529
511
|
// iconRegistry.addSvgIconLiteral('noIcon', sanitizer.bypassSecurityTrustHtml(NO_ICON));
|
|
530
512
|
}
|
|
531
513
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: ColumnTypeSinoComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
532
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: ColumnTypeSinoComponent, isStandalone: false, selector: "jvs-column-type-sino", inputs: { column: "column" }, usesInheritance: true, ngImport: i0, template: "<ng-template #cellTemplate let-row=\"row\">\n <mat-icon *ngIf=\"[column.yesValue, 1, true].includes(row[column.property])\"\n
|
|
514
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: ColumnTypeSinoComponent, isStandalone: false, selector: "jvs-column-type-sino", inputs: { column: "column" }, usesInheritance: true, ngImport: i0, template: "<ng-template #cellTemplate let-row=\"row\">\n <div class=\"flex items-center justify-center\"\n [jvsPopover]=\"(column.popover?.template || column.popover?.content?.(row)) ?? null\"\n [context]=\"row\"\n [trigger]=\"column.popover?.trigger || 'hover'\"\n [position]=\"column.popover?.position || 'bottom'\"\n [customClass]=\"column.popover?.customClass || ''\">\n <mat-icon *ngIf=\"[column.yesValue, 1, true].includes(row[column.property])\"\n [svgIcon]=\"column.yesIcon ?? 'yes_no:yes'\" class=\"icon-sm\"\n [matTooltip]=\"column.yesTooltip ?? undefined\"\n ></mat-icon>\n <mat-icon *ngIf=\"[column.noValue, 0, false].includes(row[column.property])\" [svgIcon]=\"column.noIcon ?? 'yes_no:no'\"\n class=\"icon-sm\"\n [matTooltip]=\"column.noTooltip ?? undefined\"\n ></mat-icon>\n <span class=\"cdk-visually-hidden\">{{ row[column.property] }}</span>\n </div>\n</ng-template>\n\n<ng-container matColumnDef=\"{{ column.property }}\">\n <!-- Definici\u00F3n del encabezado de la columna -->\n <th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"uppercase text-center\" mat-header-cell mat-sort-header\n [disabled]=\"column.sort === false\">\n <span [innerHTML]=\"column.label\">{{ column.label }} </span>\n </th>\n\n <!-- Cuerpo de la celda, definido por los hijos -->\n <td *matCellDef=\"let row\" [ngClass]=\"column.cssClasses\" mat-cell (click)=\"accionClick(row, $event)\">\n\n <ng-container [ngTemplateOutlet]=\"cellTemplate\" [ngTemplateOutletContext]=\"{row}\"></ng-container>\n\n </td>\n\n <th *matFooterCellDef [ngClass]=\"column.cssFooterClasses\" mat-footer-cell>\n {{ column.transformarFooter ? column.transformarFooter() : '' }}\n </th>\n</ng-container>\n", dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { 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: "component", type: i3$1.MatSortHeader, selector: "[mat-sort-header]", inputs: ["mat-sort-header", "arrowPosition", "start", "disabled", "sortActionDescription", "disableClear"], exportAs: ["matSortHeader"] }, { kind: "directive", type: i4$2.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "component", type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "directive", type: i4$1.JvsPopoverDirective, selector: "[jvsPopover]", inputs: ["jvsPopover", "context", "trigger", "position", "customClass"] }] });
|
|
533
515
|
}
|
|
534
516
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: ColumnTypeSinoComponent, decorators: [{
|
|
535
517
|
type: Component,
|
|
536
|
-
args: [{ selector: 'jvs-column-type-sino', standalone: false, template: "<ng-template #cellTemplate let-row=\"row\">\n <mat-icon *ngIf=\"[column.yesValue, 1, true].includes(row[column.property])\"\n
|
|
518
|
+
args: [{ selector: 'jvs-column-type-sino', standalone: false, template: "<ng-template #cellTemplate let-row=\"row\">\n <div class=\"flex items-center justify-center\"\n [jvsPopover]=\"(column.popover?.template || column.popover?.content?.(row)) ?? null\"\n [context]=\"row\"\n [trigger]=\"column.popover?.trigger || 'hover'\"\n [position]=\"column.popover?.position || 'bottom'\"\n [customClass]=\"column.popover?.customClass || ''\">\n <mat-icon *ngIf=\"[column.yesValue, 1, true].includes(row[column.property])\"\n [svgIcon]=\"column.yesIcon ?? 'yes_no:yes'\" class=\"icon-sm\"\n [matTooltip]=\"column.yesTooltip ?? undefined\"\n ></mat-icon>\n <mat-icon *ngIf=\"[column.noValue, 0, false].includes(row[column.property])\" [svgIcon]=\"column.noIcon ?? 'yes_no:no'\"\n class=\"icon-sm\"\n [matTooltip]=\"column.noTooltip ?? undefined\"\n ></mat-icon>\n <span class=\"cdk-visually-hidden\">{{ row[column.property] }}</span>\n </div>\n</ng-template>\n\n<ng-container matColumnDef=\"{{ column.property }}\">\n <!-- Definici\u00F3n del encabezado de la columna -->\n <th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"uppercase text-center\" mat-header-cell mat-sort-header\n [disabled]=\"column.sort === false\">\n <span [innerHTML]=\"column.label\">{{ column.label }} </span>\n </th>\n\n <!-- Cuerpo de la celda, definido por los hijos -->\n <td *matCellDef=\"let row\" [ngClass]=\"column.cssClasses\" mat-cell (click)=\"accionClick(row, $event)\">\n\n <ng-container [ngTemplateOutlet]=\"cellTemplate\" [ngTemplateOutletContext]=\"{row}\"></ng-container>\n\n </td>\n\n <th *matFooterCellDef [ngClass]=\"column.cssFooterClasses\" mat-footer-cell>\n {{ column.transformarFooter ? column.transformarFooter() : '' }}\n </th>\n</ng-container>\n" }]
|
|
537
519
|
}], ctorParameters: () => [], propDecorators: { column: [{
|
|
538
520
|
type: Input,
|
|
539
521
|
args: [{ required: true }]
|
|
@@ -597,7 +579,7 @@ class ProgressBarComponent {
|
|
|
597
579
|
}
|
|
598
580
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: ProgressBarComponent, decorators: [{
|
|
599
581
|
type: Component,
|
|
600
|
-
args: [{ selector: 'jvs-progress-bar', imports: [
|
|
582
|
+
args: [{ selector: 'jvs-progress-bar', standalone: true, imports: [
|
|
601
583
|
CommonModule,
|
|
602
584
|
DecimalPipe
|
|
603
585
|
], host: {
|
|
@@ -620,11 +602,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImpo
|
|
|
620
602
|
class ColumnTypeProgressbarComponent extends ColumnTypeComponent {
|
|
621
603
|
column = {};
|
|
622
604
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: ColumnTypeProgressbarComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
623
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: ColumnTypeProgressbarComponent, isStandalone: false, selector: "jvs-column-type-progressbar", inputs: { column: "column" }, usesInheritance: true, ngImport: i0, template: "<ng-template #cellTemplate let-row=\"row\">\n <jvs-progress-bar\n [textoCentrado]=\"!!column.progressbar.textoCentrado\"\n [porcentaje]=\"column.progressbar.porcentaje(row)\"\n [coloresValor]=\"column.progressbar.coloresValor\"\n [formatoNumero]=\"column.progressbar.formatoNumero\"\n [textoMostrar]=\"column.progressbar.textoMostrar ? column.progressbar.textoMostrar(row) : ''\"\n ></jvs-progress-bar>\n</ng-template>\n\n<ng-container matColumnDef=\"{{ column.property }}\">\n <!-- Definici\u00F3n del encabezado de la columna -->\n <th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"uppercase text-center\" mat-header-cell mat-sort-header\n [disabled]=\"column.sort === false\">\n <span [innerHTML]=\"column.label
|
|
605
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: ColumnTypeProgressbarComponent, isStandalone: false, selector: "jvs-column-type-progressbar", inputs: { column: "column" }, usesInheritance: true, ngImport: i0, template: "<ng-template #cellTemplate let-row=\"row\">\n <jvs-progress-bar\n [textoCentrado]=\"!!column.progressbar.textoCentrado\"\n [porcentaje]=\"column.progressbar.porcentaje(row)\"\n [coloresValor]=\"column.progressbar.coloresValor\"\n [formatoNumero]=\"column.progressbar.formatoNumero\"\n [textoMostrar]=\"column.progressbar.textoMostrar ? column.progressbar.textoMostrar(row) : ''\"\n [jvsPopover]=\"(column.popover?.template || column.popover?.content?.(row)) ?? null\"\n [context]=\"row\"\n [trigger]=\"column.popover?.trigger || 'hover'\"\n [position]=\"column.popover?.position || 'bottom'\"\n [customClass]=\"column.popover?.customClass || ''\"\n ></jvs-progress-bar>\n</ng-template>\n\n<ng-container matColumnDef=\"{{ column.property }}\">\n <!-- Definici\u00F3n del encabezado de la columna -->\n <th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"uppercase text-center\" mat-header-cell mat-sort-header\n [disabled]=\"column.sort === false\">\n <span [innerHTML]=\"column.label\">{{ column.label }} </span>\n </th>\n\n <!-- Cuerpo de la celda, definido por los hijos -->\n <td *matCellDef=\"let row\" [ngClass]=\"column.cssClasses\" mat-cell (click)=\"accionClick(row, $event)\">\n\n <ng-container [ngTemplateOutlet]=\"cellTemplate\" [ngTemplateOutletContext]=\"{row}\"></ng-container>\n\n </td>\n\n <th *matFooterCellDef [ngClass]=\"column.cssFooterClasses\" mat-footer-cell>\n {{ column.transformarFooter ? column.transformarFooter() : '' }}\n </th>\n</ng-container>\n", dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { 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: "component", type: i3$1.MatSortHeader, selector: "[mat-sort-header]", inputs: ["mat-sort-header", "arrowPosition", "start", "disabled", "sortActionDescription", "disableClear"], exportAs: ["matSortHeader"] }, { kind: "component", type: ProgressBarComponent, selector: "jvs-progress-bar", inputs: ["objThis", "porcentaje", "textoCentrado", "textoMostrar", "formatoNumero", "coloresValor"] }, { kind: "directive", type: i4$1.JvsPopoverDirective, selector: "[jvsPopover]", inputs: ["jvsPopover", "context", "trigger", "position", "customClass"] }] });
|
|
624
606
|
}
|
|
625
607
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: ColumnTypeProgressbarComponent, decorators: [{
|
|
626
608
|
type: Component,
|
|
627
|
-
args: [{ selector: 'jvs-column-type-progressbar', standalone: false, template: "<ng-template #cellTemplate let-row=\"row\">\n <jvs-progress-bar\n [textoCentrado]=\"!!column.progressbar.textoCentrado\"\n [porcentaje]=\"column.progressbar.porcentaje(row)\"\n [coloresValor]=\"column.progressbar.coloresValor\"\n [formatoNumero]=\"column.progressbar.formatoNumero\"\n [textoMostrar]=\"column.progressbar.textoMostrar ? column.progressbar.textoMostrar(row) : ''\"\n ></jvs-progress-bar>\n</ng-template>\n\n<ng-container matColumnDef=\"{{ column.property }}\">\n <!-- Definici\u00F3n del encabezado de la columna -->\n <th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"uppercase text-center\" mat-header-cell mat-sort-header\n [disabled]=\"column.sort === false\">\n <span [innerHTML]=\"column.label
|
|
609
|
+
args: [{ selector: 'jvs-column-type-progressbar', standalone: false, template: "<ng-template #cellTemplate let-row=\"row\">\n <jvs-progress-bar\n [textoCentrado]=\"!!column.progressbar.textoCentrado\"\n [porcentaje]=\"column.progressbar.porcentaje(row)\"\n [coloresValor]=\"column.progressbar.coloresValor\"\n [formatoNumero]=\"column.progressbar.formatoNumero\"\n [textoMostrar]=\"column.progressbar.textoMostrar ? column.progressbar.textoMostrar(row) : ''\"\n [jvsPopover]=\"(column.popover?.template || column.popover?.content?.(row)) ?? null\"\n [context]=\"row\"\n [trigger]=\"column.popover?.trigger || 'hover'\"\n [position]=\"column.popover?.position || 'bottom'\"\n [customClass]=\"column.popover?.customClass || ''\"\n ></jvs-progress-bar>\n</ng-template>\n\n<ng-container matColumnDef=\"{{ column.property }}\">\n <!-- Definici\u00F3n del encabezado de la columna -->\n <th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"uppercase text-center\" mat-header-cell mat-sort-header\n [disabled]=\"column.sort === false\">\n <span [innerHTML]=\"column.label\">{{ column.label }} </span>\n </th>\n\n <!-- Cuerpo de la celda, definido por los hijos -->\n <td *matCellDef=\"let row\" [ngClass]=\"column.cssClasses\" mat-cell (click)=\"accionClick(row, $event)\">\n\n <ng-container [ngTemplateOutlet]=\"cellTemplate\" [ngTemplateOutletContext]=\"{row}\"></ng-container>\n\n </td>\n\n <th *matFooterCellDef [ngClass]=\"column.cssFooterClasses\" mat-footer-cell>\n {{ column.transformarFooter ? column.transformarFooter() : '' }}\n </th>\n</ng-container>\n" }]
|
|
628
610
|
}], propDecorators: { column: [{
|
|
629
611
|
type: Input,
|
|
630
612
|
args: [{ required: true }]
|
|
@@ -643,7 +625,10 @@ class NoSanitizePipe {
|
|
|
643
625
|
}
|
|
644
626
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: NoSanitizePipe, decorators: [{
|
|
645
627
|
type: Pipe,
|
|
646
|
-
args: [{
|
|
628
|
+
args: [{
|
|
629
|
+
name: 'noSanitize',
|
|
630
|
+
standalone: true
|
|
631
|
+
}]
|
|
647
632
|
}], ctorParameters: () => [{ type: i1$1.DomSanitizer }] });
|
|
648
633
|
|
|
649
634
|
class ZeroFillPipe {
|
|
@@ -661,6 +646,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImpo
|
|
|
661
646
|
type: Pipe,
|
|
662
647
|
args: [{
|
|
663
648
|
name: 'zeroFill',
|
|
649
|
+
standalone: true
|
|
664
650
|
}]
|
|
665
651
|
}] });
|
|
666
652
|
function zeroFill(value, digitos, ...args) {
|
|
@@ -672,11 +658,11 @@ function zeroFill(value, digitos, ...args) {
|
|
|
672
658
|
class ColumnTypeTextComponent extends ColumnTypeComponent {
|
|
673
659
|
column = {}; // 🟢 Solución
|
|
674
660
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: ColumnTypeTextComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
675
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: ColumnTypeTextComponent, isStandalone: false, selector: "jvs-column-type-text", inputs: { column: "column" }, usesInheritance: true, ngImport: i0, template: "<ng-template #cellTemplate let-row=\"row\">\n <div *ngIf=\"column.innerHTML; else sinInnerHTML\" [class]=\"column.text?.cssContenedor\" [ngStyle]=\"column.text?.cssStyle\" class=\"hover:!max-h-max\"\n [innerHTML]=\"column.innerHTML(row) | noSanitize\">\n </div>\n <ng-template #sinInnerHTML>\n <ng-container *ngIf=\"column.text && column.text?.separador else campoTextNormal\">\n <div [class]=\"column.text?.cssContenedor\">\n <ng-container\n *ngFor=\"let itm of ((column.transformar ? column.transformar(row) : row[column.property]) ?? '').split(column.text.separador)\">\n <ng-template *ngIf=\"column.property\" [ngTemplateOutlet]=\"tipoDatoString\"\n [ngTemplateOutletContext]=\"{ fila: column, tipo: 'text', value: itm, class: column.textCss, row: row }\"></ng-template>\n </ng-container>\n </div>\n </ng-container>\n <ng-template #campoTextNormal>\n <ng-template *ngIf=\"column.property\" [ngTemplateOutlet]=\"tipoDatoString\"\n [ngTemplateOutletContext]=\"{ fila: column, tipo: 'text', value: (column.transformar ? column.transformar(row) : row[column.property]), class: column.textCss, row: row }\"></ng-template>\n </ng-template>\n </ng-template>\n</ng-template>\n\n<ng-container matColumnDef=\"{{ column.property }}\">\n <!-- Definici\u00F3n del encabezado de la columna -->\n <th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"uppercase text-center\" mat-header-cell mat-sort-header\n [disabled]=\"column.sort === false\">\n <span [innerHTML]=\"column.label
|
|
661
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: ColumnTypeTextComponent, isStandalone: false, selector: "jvs-column-type-text", inputs: { column: "column" }, usesInheritance: true, ngImport: i0, template: "<ng-template #cellTemplate let-row=\"row\">\n <div *ngIf=\"column.innerHTML; else sinInnerHTML\" [class]=\"column.text?.cssContenedor\" [ngStyle]=\"column.text?.cssStyle\" class=\"hover:!max-h-max\"\n [innerHTML]=\"column.innerHTML(row) | noSanitize\"\n jvsPopoverListener [trigger]=\"column.popover?.trigger || 'hover'\">\n </div>\n <ng-template #sinInnerHTML>\n <ng-container *ngIf=\"column.text && column.text?.separador else campoTextNormal\">\n <div [class]=\"column.text?.cssContenedor\">\n <ng-container\n *ngFor=\"let itm of ((column.transformar ? column.transformar(row) : row[column.property]) ?? '').split(column.text.separador)\">\n <ng-template *ngIf=\"column.property\" [ngTemplateOutlet]=\"tipoDatoString\"\n [ngTemplateOutletContext]=\"{ fila: column, tipo: 'text', value: itm, class: column.textCss, row: row }\"></ng-template>\n </ng-container>\n </div>\n </ng-container>\n <ng-template #campoTextNormal>\n <ng-template *ngIf=\"column.property\" [ngTemplateOutlet]=\"tipoDatoString\"\n [ngTemplateOutletContext]=\"{ fila: column, tipo: 'text', value: (column.transformar ? column.transformar(row) : row[column.property]), class: column.textCss, row: row }\"></ng-template>\n </ng-template>\n </ng-template>\n</ng-template>\n\n<ng-container matColumnDef=\"{{ column.property }}\">\n <!-- Definici\u00F3n del encabezado de la columna -->\n <th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"uppercase text-center\" mat-header-cell mat-sort-header\n [disabled]=\"column.sort === false\">\n <span [innerHTML]=\"column.label\">{{ column.label }} </span>\n </th>\n\n <!-- Cuerpo de la celda, definido por los hijos -->\n <td *matCellDef=\"let row\" [ngClass]=\"column.cssClasses\" mat-cell (click)=\"accionClick(row, $event)\">\n\n <ng-container [ngTemplateOutlet]=\"cellTemplate\" [ngTemplateOutletContext]=\"{row}\"></ng-container>\n\n </td>\n\n <th *matFooterCellDef [ngClass]=\"column.cssFooterClasses\" mat-footer-cell>\n {{ column.transformarFooter ? column.transformarFooter() : '' }}\n </th>\n</ng-container>\n\n\n<!--<ng-container matColumnDef=\"{{ column.property }}\">\n<th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"uppercase text-center\" mat-header-cell mat-sort-header\n [disabled]=\"column.sort === false\">\n <span [innerHTML]=\"column.label ?? ''\">{{ column.label }} </span>\n</th>\n<ng-container *ngIf=\"column.innerHTML; else sinInnerHTML\">\n <td *matCellDef=\"let row\" [ngClass]=\"column.cssClasses\" mat-cell (click)=\"accionClick(column, row, $event)\">\n <div [class]=\"column.text?.cssContenedor\" [ngStyle]=\"column.text?.cssStyle\" class=\"hover:!max-h-max\"\n [innerHTML]=\"column.innerHTML(row) | noSanitize\">\n\n </div>\n </td>\n</ng-container>\n<ng-template #sinInnerHTML>\n <td *matCellDef=\"let row\" [ngClass]=\"column.cssClasses\" mat-cell>\n <ng-container *ngIf=\"column.text && column.text?.separador else campoTextNormal\">\n <div [class]=\"column.text?.cssContenedor\">\n <ng-container\n *ngFor=\"let itm of ((column.transformar ? column.transformar(row) : row[column.property]) ?? '').split(column.text.separador)\">\n <ng-template *ngIf=\"column.property\" [ngTemplateOutlet]=\"tipoDatoString\"\n [ngTemplateOutletContext]=\"{ fila: column, tipo: 'text', value: itm, class: column.textCss, row: row }\"></ng-template>\n </ng-container>\n </div>\n </ng-container>\n <ng-template #campoTextNormal>\n <ng-template *ngIf=\"column.property\" [ngTemplateOutlet]=\"tipoDatoString\"\n [ngTemplateOutletContext]=\"{ fila: column, tipo: 'text', value: (column.transformar ? column.transformar(row) : row[column.property]), class: column.textCss, row: row }\"></ng-template>\n </ng-template>\n </td>\n</ng-template>\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<ng-template #tipoDatoString let-row=\"row\" let-fila=\"fila\" let-tipo=\"tipo\" let-value=\"value\" let-format=\"format\"\n let-clase=\"class\">\n <ng-container [ngSwitch]=\"tipo\">\n <ng-container *ngSwitchCase=\"'text'\"><span [ngClass]=\"clase\" *ngIf=\"value\"\n (click)=\"accionClick(row, $event)\"\n [jvsPopover]=\"(column.popover?.template || column.popover?.content?.(row)) ?? null\"\n [context]=\"row\"\n [trigger]=\"column.popover?.trigger || 'hover'\"\n [position]=\"column.popover?.position || 'bottom'\"\n [customClass]=\"column.popover?.customClass || ''\">\n <span *ngIf=\"!fila.zeroFill\">{{ value }}</span>\n <span *ngIf=\"fila.zeroFill\">{{ value | zeroFill: fila.zeroFill }}</span>\n </span></ng-container>\n <ng-container *ngSwitchCase=\"'date'\"><span [ngClass]=\"clase\" *ngIf=\"value\"\n (click)=\"accionClick(row, $event)\">{{ value | date: (format || 'dd/MM/yyyy') }}</span></ng-container>\n <ng-container *ngSwitchCase=\"'number'\"><span [ngClass]=\"clase\" *ngIf=\"value\"\n (click)=\"accionClick(row, $event)\">{{ value | number: (format || '0.0-2') }}</span></ng-container>\n <ng-container *ngSwitchCase=\"'money'\"><span [ngClass]=\"clase\"\n [class.text-sky-700]=\"(value * 1) >= 0\" [class.text-red-700]=\"(value * 1) < 0\"\n *ngIf=\"value\" (click)=\"accionClick(row, $event)\">{{ value | number: (format || '1.2-2') }}</span>\n </ng-container>\n\n <!--\t\t<span [ngClass]=\"class\" *ngSwitchCase=\"'date'\">{{ value | date: (format || 'dd/MM/yyyy') }}</span>-->\n <!--\t\t<span [ngClass]=\"class\" *ngSwitchCase=\"'number'\">{{ value | number: (format || '0.0-2') }}</span>-->\n </ng-container>\n</ng-template>\n", dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "directive", type: i1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { 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: "component", type: i3$1.MatSortHeader, selector: "[mat-sort-header]", inputs: ["mat-sort-header", "arrowPosition", "start", "disabled", "sortActionDescription", "disableClear"], exportAs: ["matSortHeader"] }, { kind: "directive", type: i4$1.JvsPopoverDirective, selector: "[jvsPopover]", inputs: ["jvsPopover", "context", "trigger", "position", "customClass"] }, { kind: "directive", type: i4$1.JvsPopoverListenerDirective, selector: "[jvsPopoverListener]", inputs: ["trigger"] }, { kind: "pipe", type: i1.DecimalPipe, name: "number" }, { kind: "pipe", type: i1.DatePipe, name: "date" }, { kind: "pipe", type: NoSanitizePipe, name: "noSanitize" }, { kind: "pipe", type: ZeroFillPipe, name: "zeroFill" }] });
|
|
676
662
|
}
|
|
677
663
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: ColumnTypeTextComponent, decorators: [{
|
|
678
664
|
type: Component,
|
|
679
|
-
args: [{ selector: 'jvs-column-type-text', standalone: false, template: "<ng-template #cellTemplate let-row=\"row\">\n <div *ngIf=\"column.innerHTML; else sinInnerHTML\" [class]=\"column.text?.cssContenedor\" [ngStyle]=\"column.text?.cssStyle\" class=\"hover:!max-h-max\"\n [innerHTML]=\"column.innerHTML(row) | noSanitize\">\n </div>\n <ng-template #sinInnerHTML>\n <ng-container *ngIf=\"column.text && column.text?.separador else campoTextNormal\">\n <div [class]=\"column.text?.cssContenedor\">\n <ng-container\n *ngFor=\"let itm of ((column.transformar ? column.transformar(row) : row[column.property]) ?? '').split(column.text.separador)\">\n <ng-template *ngIf=\"column.property\" [ngTemplateOutlet]=\"tipoDatoString\"\n [ngTemplateOutletContext]=\"{ fila: column, tipo: 'text', value: itm, class: column.textCss, row: row }\"></ng-template>\n </ng-container>\n </div>\n </ng-container>\n <ng-template #campoTextNormal>\n <ng-template *ngIf=\"column.property\" [ngTemplateOutlet]=\"tipoDatoString\"\n [ngTemplateOutletContext]=\"{ fila: column, tipo: 'text', value: (column.transformar ? column.transformar(row) : row[column.property]), class: column.textCss, row: row }\"></ng-template>\n </ng-template>\n </ng-template>\n</ng-template>\n\n<ng-container matColumnDef=\"{{ column.property }}\">\n <!-- Definici\u00F3n del encabezado de la columna -->\n <th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"uppercase text-center\" mat-header-cell mat-sort-header\n [disabled]=\"column.sort === false\">\n <span [innerHTML]=\"column.label
|
|
665
|
+
args: [{ selector: 'jvs-column-type-text', standalone: false, template: "<ng-template #cellTemplate let-row=\"row\">\n <div *ngIf=\"column.innerHTML; else sinInnerHTML\" [class]=\"column.text?.cssContenedor\" [ngStyle]=\"column.text?.cssStyle\" class=\"hover:!max-h-max\"\n [innerHTML]=\"column.innerHTML(row) | noSanitize\"\n jvsPopoverListener [trigger]=\"column.popover?.trigger || 'hover'\">\n </div>\n <ng-template #sinInnerHTML>\n <ng-container *ngIf=\"column.text && column.text?.separador else campoTextNormal\">\n <div [class]=\"column.text?.cssContenedor\">\n <ng-container\n *ngFor=\"let itm of ((column.transformar ? column.transformar(row) : row[column.property]) ?? '').split(column.text.separador)\">\n <ng-template *ngIf=\"column.property\" [ngTemplateOutlet]=\"tipoDatoString\"\n [ngTemplateOutletContext]=\"{ fila: column, tipo: 'text', value: itm, class: column.textCss, row: row }\"></ng-template>\n </ng-container>\n </div>\n </ng-container>\n <ng-template #campoTextNormal>\n <ng-template *ngIf=\"column.property\" [ngTemplateOutlet]=\"tipoDatoString\"\n [ngTemplateOutletContext]=\"{ fila: column, tipo: 'text', value: (column.transformar ? column.transformar(row) : row[column.property]), class: column.textCss, row: row }\"></ng-template>\n </ng-template>\n </ng-template>\n</ng-template>\n\n<ng-container matColumnDef=\"{{ column.property }}\">\n <!-- Definici\u00F3n del encabezado de la columna -->\n <th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"uppercase text-center\" mat-header-cell mat-sort-header\n [disabled]=\"column.sort === false\">\n <span [innerHTML]=\"column.label\">{{ column.label }} </span>\n </th>\n\n <!-- Cuerpo de la celda, definido por los hijos -->\n <td *matCellDef=\"let row\" [ngClass]=\"column.cssClasses\" mat-cell (click)=\"accionClick(row, $event)\">\n\n <ng-container [ngTemplateOutlet]=\"cellTemplate\" [ngTemplateOutletContext]=\"{row}\"></ng-container>\n\n </td>\n\n <th *matFooterCellDef [ngClass]=\"column.cssFooterClasses\" mat-footer-cell>\n {{ column.transformarFooter ? column.transformarFooter() : '' }}\n </th>\n</ng-container>\n\n\n<!--<ng-container matColumnDef=\"{{ column.property }}\">\n<th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"uppercase text-center\" mat-header-cell mat-sort-header\n [disabled]=\"column.sort === false\">\n <span [innerHTML]=\"column.label ?? ''\">{{ column.label }} </span>\n</th>\n<ng-container *ngIf=\"column.innerHTML; else sinInnerHTML\">\n <td *matCellDef=\"let row\" [ngClass]=\"column.cssClasses\" mat-cell (click)=\"accionClick(column, row, $event)\">\n <div [class]=\"column.text?.cssContenedor\" [ngStyle]=\"column.text?.cssStyle\" class=\"hover:!max-h-max\"\n [innerHTML]=\"column.innerHTML(row) | noSanitize\">\n\n </div>\n </td>\n</ng-container>\n<ng-template #sinInnerHTML>\n <td *matCellDef=\"let row\" [ngClass]=\"column.cssClasses\" mat-cell>\n <ng-container *ngIf=\"column.text && column.text?.separador else campoTextNormal\">\n <div [class]=\"column.text?.cssContenedor\">\n <ng-container\n *ngFor=\"let itm of ((column.transformar ? column.transformar(row) : row[column.property]) ?? '').split(column.text.separador)\">\n <ng-template *ngIf=\"column.property\" [ngTemplateOutlet]=\"tipoDatoString\"\n [ngTemplateOutletContext]=\"{ fila: column, tipo: 'text', value: itm, class: column.textCss, row: row }\"></ng-template>\n </ng-container>\n </div>\n </ng-container>\n <ng-template #campoTextNormal>\n <ng-template *ngIf=\"column.property\" [ngTemplateOutlet]=\"tipoDatoString\"\n [ngTemplateOutletContext]=\"{ fila: column, tipo: 'text', value: (column.transformar ? column.transformar(row) : row[column.property]), class: column.textCss, row: row }\"></ng-template>\n </ng-template>\n </td>\n</ng-template>\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<ng-template #tipoDatoString let-row=\"row\" let-fila=\"fila\" let-tipo=\"tipo\" let-value=\"value\" let-format=\"format\"\n let-clase=\"class\">\n <ng-container [ngSwitch]=\"tipo\">\n <ng-container *ngSwitchCase=\"'text'\"><span [ngClass]=\"clase\" *ngIf=\"value\"\n (click)=\"accionClick(row, $event)\"\n [jvsPopover]=\"(column.popover?.template || column.popover?.content?.(row)) ?? null\"\n [context]=\"row\"\n [trigger]=\"column.popover?.trigger || 'hover'\"\n [position]=\"column.popover?.position || 'bottom'\"\n [customClass]=\"column.popover?.customClass || ''\">\n <span *ngIf=\"!fila.zeroFill\">{{ value }}</span>\n <span *ngIf=\"fila.zeroFill\">{{ value | zeroFill: fila.zeroFill }}</span>\n </span></ng-container>\n <ng-container *ngSwitchCase=\"'date'\"><span [ngClass]=\"clase\" *ngIf=\"value\"\n (click)=\"accionClick(row, $event)\">{{ value | date: (format || 'dd/MM/yyyy') }}</span></ng-container>\n <ng-container *ngSwitchCase=\"'number'\"><span [ngClass]=\"clase\" *ngIf=\"value\"\n (click)=\"accionClick(row, $event)\">{{ value | number: (format || '0.0-2') }}</span></ng-container>\n <ng-container *ngSwitchCase=\"'money'\"><span [ngClass]=\"clase\"\n [class.text-sky-700]=\"(value * 1) >= 0\" [class.text-red-700]=\"(value * 1) < 0\"\n *ngIf=\"value\" (click)=\"accionClick(row, $event)\">{{ value | number: (format || '1.2-2') }}</span>\n </ng-container>\n\n <!--\t\t<span [ngClass]=\"class\" *ngSwitchCase=\"'date'\">{{ value | date: (format || 'dd/MM/yyyy') }}</span>-->\n <!--\t\t<span [ngClass]=\"class\" *ngSwitchCase=\"'number'\">{{ value | number: (format || '0.0-2') }}</span>-->\n </ng-container>\n</ng-template>\n" }]
|
|
680
666
|
}], propDecorators: { column: [{
|
|
681
667
|
type: Input,
|
|
682
668
|
args: [{ required: true }]
|
|
@@ -688,11 +674,11 @@ class ColumnTypeMoneyComponent extends ColumnTypeComponent {
|
|
|
688
674
|
return (this.column.transformar ? this.column.transformar(row) : row[this.column.property]);
|
|
689
675
|
}
|
|
690
676
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: ColumnTypeMoneyComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
691
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: ColumnTypeMoneyComponent, isStandalone: false, selector: "jvs-column-type-money", inputs: { column: "column" }, usesInheritance: true, ngImport: i0, template: "<ng-template #cellTemplate let-row=\"row\">\n <span [ngClass]=\"column.textCss\"\n [class.text-sky-700]=\"(value(row)) >= 0\" [class.text-red-700]=\"(value(row)) < 0\"\n *ngIf=\"value(row)\"\n (click)=\"accionClick(row, $event)\">{{ value(row) | number: (column.format || '1.2-2') }}</span>\n</ng-template>\n<ng-template #columnFooterTemplate let-row=\"row\">\n\t\t<span *ngIf=\"column.transformarFooter\"\n [class.text-sky-700]=\"column.transformarFooter() >= 0\"\n [class.text-red-700]=\"column.transformarFooter() < 0\"\n >\n\t\t\t\t\t<span>{{ column.transformarFooter() | currency: column.simboloMoneda ?? 'S/' }}</span>\n\t\t\t\t</span>\n</ng-template>\n\n<!--<jvs-column-type [column]=\"column\" [cellTemplate]=\"cellTemplate\" [columnFooterTemplate]=\"columnFooterTemplate\"></jvs-column-type>-->\n\n<ng-container matColumnDef=\"{{ column.property }}\">\n <!-- Definici\u00F3n del encabezado de la columna -->\n <th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"uppercase text-center\" mat-header-cell mat-sort-header\n [disabled]=\"column.sort === false\">\n <span [innerHTML]=\"column.label
|
|
677
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: ColumnTypeMoneyComponent, isStandalone: false, selector: "jvs-column-type-money", inputs: { column: "column" }, usesInheritance: true, ngImport: i0, template: "<ng-template #cellTemplate let-row=\"row\">\n <span [ngClass]=\"column.textCss\"\n [class.text-sky-700]=\"(value(row)) >= 0\" [class.text-red-700]=\"(value(row)) < 0\"\n *ngIf=\"value(row)\"\n [jvsPopover]=\"(column.popover?.template || column.popover?.content?.(row)) ?? null\"\n [context]=\"row\"\n [trigger]=\"column.popover?.trigger || 'hover'\"\n [position]=\"column.popover?.position || 'bottom'\"\n [customClass]=\"column.popover?.customClass || ''\"\n (click)=\"accionClick(row, $event)\">{{ value(row) | number: (column.format || '1.2-2') }}</span>\n</ng-template>\n<ng-template #columnFooterTemplate let-row=\"row\">\n\t\t<span *ngIf=\"column.transformarFooter\"\n [class.text-sky-700]=\"column.transformarFooter() >= 0\"\n [class.text-red-700]=\"column.transformarFooter() < 0\"\n >\n\t\t\t\t\t<span>{{ column.transformarFooter() | currency: column.simboloMoneda ?? 'S/' }}</span>\n\t\t\t\t</span>\n</ng-template>\n\n<!--<jvs-column-type [column]=\"column\" [cellTemplate]=\"cellTemplate\" [columnFooterTemplate]=\"columnFooterTemplate\"></jvs-column-type>-->\n\n<ng-container matColumnDef=\"{{ column.property }}\">\n <!-- Definici\u00F3n del encabezado de la columna -->\n <th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"uppercase text-center\" mat-header-cell mat-sort-header\n [disabled]=\"column.sort === false\">\n <span [innerHTML]=\"column.label\">{{ column.label }} </span>\n </th>\n\n <!-- Cuerpo de la celda, definido por los hijos -->\n <td *matCellDef=\"let row\" [ngClass]=\"column.cssClasses\" mat-cell (click)=\"accionClick(row, $event)\">\n\n <ng-container [ngTemplateOutlet]=\"cellTemplate\" [ngTemplateOutletContext]=\"{row}\"></ng-container>\n\n </td>\n\n <th *matFooterCellDef [ngClass]=\"column.cssFooterClasses\" mat-footer-cell>\n\t\t<span *ngIf=\"column.transformarFooter\"\n [class.text-sky-700]=\"column.transformarFooter() >= 0\"\n [class.text-red-700]=\"column.transformarFooter() < 0\"\n >\n\t\t\t\t\t<span>{{ column.transformarFooter() | currency: column.simboloMoneda ?? 'S/' }}</span>\n\t\t\t\t</span>\n </th>\n</ng-container>\n", dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { 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: "component", type: i3$1.MatSortHeader, selector: "[mat-sort-header]", inputs: ["mat-sort-header", "arrowPosition", "start", "disabled", "sortActionDescription", "disableClear"], exportAs: ["matSortHeader"] }, { kind: "directive", type: i4$1.JvsPopoverDirective, selector: "[jvsPopover]", inputs: ["jvsPopover", "context", "trigger", "position", "customClass"] }, { kind: "pipe", type: i1.DecimalPipe, name: "number" }, { kind: "pipe", type: i1.CurrencyPipe, name: "currency" }] });
|
|
692
678
|
}
|
|
693
679
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: ColumnTypeMoneyComponent, decorators: [{
|
|
694
680
|
type: Component,
|
|
695
|
-
args: [{ selector: 'jvs-column-type-money', standalone: false, template: "<ng-template #cellTemplate let-row=\"row\">\n <span [ngClass]=\"column.textCss\"\n [class.text-sky-700]=\"(value(row)) >= 0\" [class.text-red-700]=\"(value(row)) < 0\"\n *ngIf=\"value(row)\"\n (click)=\"accionClick(row, $event)\">{{ value(row) | number: (column.format || '1.2-2') }}</span>\n</ng-template>\n<ng-template #columnFooterTemplate let-row=\"row\">\n\t\t<span *ngIf=\"column.transformarFooter\"\n [class.text-sky-700]=\"column.transformarFooter() >= 0\"\n [class.text-red-700]=\"column.transformarFooter() < 0\"\n >\n\t\t\t\t\t<span>{{ column.transformarFooter() | currency: column.simboloMoneda ?? 'S/' }}</span>\n\t\t\t\t</span>\n</ng-template>\n\n<!--<jvs-column-type [column]=\"column\" [cellTemplate]=\"cellTemplate\" [columnFooterTemplate]=\"columnFooterTemplate\"></jvs-column-type>-->\n\n<ng-container matColumnDef=\"{{ column.property }}\">\n <!-- Definici\u00F3n del encabezado de la columna -->\n <th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"uppercase text-center\" mat-header-cell mat-sort-header\n [disabled]=\"column.sort === false\">\n <span [innerHTML]=\"column.label
|
|
681
|
+
args: [{ selector: 'jvs-column-type-money', standalone: false, template: "<ng-template #cellTemplate let-row=\"row\">\n <span [ngClass]=\"column.textCss\"\n [class.text-sky-700]=\"(value(row)) >= 0\" [class.text-red-700]=\"(value(row)) < 0\"\n *ngIf=\"value(row)\"\n [jvsPopover]=\"(column.popover?.template || column.popover?.content?.(row)) ?? null\"\n [context]=\"row\"\n [trigger]=\"column.popover?.trigger || 'hover'\"\n [position]=\"column.popover?.position || 'bottom'\"\n [customClass]=\"column.popover?.customClass || ''\"\n (click)=\"accionClick(row, $event)\">{{ value(row) | number: (column.format || '1.2-2') }}</span>\n</ng-template>\n<ng-template #columnFooterTemplate let-row=\"row\">\n\t\t<span *ngIf=\"column.transformarFooter\"\n [class.text-sky-700]=\"column.transformarFooter() >= 0\"\n [class.text-red-700]=\"column.transformarFooter() < 0\"\n >\n\t\t\t\t\t<span>{{ column.transformarFooter() | currency: column.simboloMoneda ?? 'S/' }}</span>\n\t\t\t\t</span>\n</ng-template>\n\n<!--<jvs-column-type [column]=\"column\" [cellTemplate]=\"cellTemplate\" [columnFooterTemplate]=\"columnFooterTemplate\"></jvs-column-type>-->\n\n<ng-container matColumnDef=\"{{ column.property }}\">\n <!-- Definici\u00F3n del encabezado de la columna -->\n <th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"uppercase text-center\" mat-header-cell mat-sort-header\n [disabled]=\"column.sort === false\">\n <span [innerHTML]=\"column.label\">{{ column.label }} </span>\n </th>\n\n <!-- Cuerpo de la celda, definido por los hijos -->\n <td *matCellDef=\"let row\" [ngClass]=\"column.cssClasses\" mat-cell (click)=\"accionClick(row, $event)\">\n\n <ng-container [ngTemplateOutlet]=\"cellTemplate\" [ngTemplateOutletContext]=\"{row}\"></ng-container>\n\n </td>\n\n <th *matFooterCellDef [ngClass]=\"column.cssFooterClasses\" mat-footer-cell>\n\t\t<span *ngIf=\"column.transformarFooter\"\n [class.text-sky-700]=\"column.transformarFooter() >= 0\"\n [class.text-red-700]=\"column.transformarFooter() < 0\"\n >\n\t\t\t\t\t<span>{{ column.transformarFooter() | currency: column.simboloMoneda ?? 'S/' }}</span>\n\t\t\t\t</span>\n </th>\n</ng-container>\n" }]
|
|
696
682
|
}], propDecorators: { column: [{
|
|
697
683
|
type: Input,
|
|
698
684
|
args: [{ required: true }]
|
|
@@ -707,11 +693,11 @@ class ColumnTypeIconsComponent extends ColumnTypeComponent {
|
|
|
707
693
|
return columna.items;
|
|
708
694
|
}
|
|
709
695
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: ColumnTypeIconsComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
710
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: ColumnTypeIconsComponent, isStandalone: false, selector: "jvs-column-type-icons", inputs: { column: "column" }, usesInheritance: true, ngImport: i0, template: "<ng-template #cellTemplate let-row=\"row\">\n <div class=\"flex items-center justify-center\" [ngClass]=\"{ '-space-x-1': !column.iconsDef
|
|
696
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: ColumnTypeIconsComponent, isStandalone: false, selector: "jvs-column-type-icons", inputs: { column: "column" }, usesInheritance: true, ngImport: i0, template: "<ng-template #cellTemplate let-row=\"row\">\n <div class=\"flex items-center justify-center\" [ngClass]=\"{ '-space-x-1': !column.iconsDef.soloIcono }\"\n [jvsPopover]=\"(column.popover?.template || column.popover?.content?.(row)) ?? null\"\n [context]=\"row\"\n [trigger]=\"column.popover?.trigger || 'hover'\"\n [position]=\"column.popover?.position || 'bottom'\"\n [customClass]=\"column.popover?.customClass || ''\">\n <ng-container *ngFor=\"let icon of obtenerItems(column.iconsDef, row)\">\n <ng-container *ngIf=\"!column.iconsDef.soloIcono; else soloIcono\">\n <button matRipple type=\"button\" *ngIf=\"!icon.esVisible || icon.esVisible(row)\"\n (click)=\"icon.click ? icon.click(row) : false; $event.stopPropagation()\"\n class=\"flex items-center justify-center p-1 rounded border shadow-sm hover:shadow-lg\"\n [ngClass]=\"icon.contentCss\"\n [matTooltip]=\"icon.toolTip ?? row[icon.toolTipField ?? '_field_']\"\n [matTooltipDisabled]=\"!icon.toolTip && !icon.toolTipField\"\n >\n <ng-container [ngTemplateOutlet]=\"iconoConTamanio\"\n [ngTemplateOutletContext]=\"{icon: icon.icon, iconClass: icon.cssClass, size: (icon.iconSize ?? column.iconsDef?.iconSize)}\"></ng-container>\n </button>\n </ng-container>\n <ng-template #soloIcono>\n <div *ngIf=\"!icon.esVisible || icon.esVisible(row)\" [ngClass]=\"icon.contentCss\"\n class=\"flex items-center\"\n [matTooltip]=\"icon.toolTip ?? row[icon.toolTipField ?? '_field_']\"\n [matTooltipDisabled]=\"!icon.toolTip && !icon.toolTipField\"\n >\n <ng-container [ngTemplateOutlet]=\"iconoConTamanio\"\n [ngTemplateOutletContext]=\"{icon: icon.icon, iconClass: icon.cssClass, size: (icon.iconSize ?? column.iconsDef?.iconSize)}\"></ng-container>\n </div>\n </ng-template>\n </ng-container>\n </div>\n</ng-template>\n\n<ng-container matColumnDef=\"{{ column.property }}\">\n <!-- Definici\u00F3n del encabezado de la columna -->\n <th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"uppercase text-center\" mat-header-cell mat-sort-header\n [disabled]=\"column.sort === false\">\n <span [innerHTML]=\"column.label\">{{ column.label }} </span>\n </th>\n\n <!-- Cuerpo de la celda, definido por los hijos -->\n <td *matCellDef=\"let row\" [ngClass]=\"column.cssClasses\" mat-cell (click)=\"accionClick(row, $event)\">\n\n <ng-container [ngTemplateOutlet]=\"cellTemplate\" [ngTemplateOutletContext]=\"{row}\"></ng-container>\n\n </td>\n\n <th *matFooterCellDef [ngClass]=\"column.cssFooterClasses\" mat-footer-cell>\n {{ column.transformarFooter ? column.transformarFooter() : '' }}\n </th>\n</ng-container>\n\n\n<ng-template #iconoConTamanio let-icon=\"icon\" let-iconClass=\"iconClass\" let-size=\"size\">\n <mat-icon *ngIf=\"size\" [svgIcon]=\"icon\" [ngClass]=\"iconClass\" [inline]=\"true\"\n [style.font-size]=\"size\"\n [style.height]=\"size\"\n [style.width]=\"size\"\n ></mat-icon>\n <mat-icon *ngIf=\"!size\" [svgIcon]=\"icon\" [ngClass]=\"iconClass\"></mat-icon>\n</ng-template>\n", dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { 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: "component", type: i3$1.MatSortHeader, selector: "[mat-sort-header]", inputs: ["mat-sort-header", "arrowPosition", "start", "disabled", "sortActionDescription", "disableClear"], exportAs: ["matSortHeader"] }, { kind: "directive", type: i4$2.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "directive", type: i5.MatRipple, selector: "[mat-ripple], [matRipple]", inputs: ["matRippleColor", "matRippleUnbounded", "matRippleCentered", "matRippleRadius", "matRippleAnimation", "matRippleDisabled", "matRippleTrigger"], exportAs: ["matRipple"] }, { kind: "component", type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "directive", type: i4$1.JvsPopoverDirective, selector: "[jvsPopover]", inputs: ["jvsPopover", "context", "trigger", "position", "customClass"] }] });
|
|
711
697
|
}
|
|
712
698
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: ColumnTypeIconsComponent, decorators: [{
|
|
713
699
|
type: Component,
|
|
714
|
-
args: [{ selector: 'jvs-column-type-icons', standalone: false, template: "<ng-template #cellTemplate let-row=\"row\">\n <div class=\"flex items-center justify-center\" [ngClass]=\"{ '-space-x-1': !column.iconsDef
|
|
700
|
+
args: [{ selector: 'jvs-column-type-icons', standalone: false, template: "<ng-template #cellTemplate let-row=\"row\">\n <div class=\"flex items-center justify-center\" [ngClass]=\"{ '-space-x-1': !column.iconsDef.soloIcono }\"\n [jvsPopover]=\"(column.popover?.template || column.popover?.content?.(row)) ?? null\"\n [context]=\"row\"\n [trigger]=\"column.popover?.trigger || 'hover'\"\n [position]=\"column.popover?.position || 'bottom'\"\n [customClass]=\"column.popover?.customClass || ''\">\n <ng-container *ngFor=\"let icon of obtenerItems(column.iconsDef, row)\">\n <ng-container *ngIf=\"!column.iconsDef.soloIcono; else soloIcono\">\n <button matRipple type=\"button\" *ngIf=\"!icon.esVisible || icon.esVisible(row)\"\n (click)=\"icon.click ? icon.click(row) : false; $event.stopPropagation()\"\n class=\"flex items-center justify-center p-1 rounded border shadow-sm hover:shadow-lg\"\n [ngClass]=\"icon.contentCss\"\n [matTooltip]=\"icon.toolTip ?? row[icon.toolTipField ?? '_field_']\"\n [matTooltipDisabled]=\"!icon.toolTip && !icon.toolTipField\"\n >\n <ng-container [ngTemplateOutlet]=\"iconoConTamanio\"\n [ngTemplateOutletContext]=\"{icon: icon.icon, iconClass: icon.cssClass, size: (icon.iconSize ?? column.iconsDef?.iconSize)}\"></ng-container>\n </button>\n </ng-container>\n <ng-template #soloIcono>\n <div *ngIf=\"!icon.esVisible || icon.esVisible(row)\" [ngClass]=\"icon.contentCss\"\n class=\"flex items-center\"\n [matTooltip]=\"icon.toolTip ?? row[icon.toolTipField ?? '_field_']\"\n [matTooltipDisabled]=\"!icon.toolTip && !icon.toolTipField\"\n >\n <ng-container [ngTemplateOutlet]=\"iconoConTamanio\"\n [ngTemplateOutletContext]=\"{icon: icon.icon, iconClass: icon.cssClass, size: (icon.iconSize ?? column.iconsDef?.iconSize)}\"></ng-container>\n </div>\n </ng-template>\n </ng-container>\n </div>\n</ng-template>\n\n<ng-container matColumnDef=\"{{ column.property }}\">\n <!-- Definici\u00F3n del encabezado de la columna -->\n <th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"uppercase text-center\" mat-header-cell mat-sort-header\n [disabled]=\"column.sort === false\">\n <span [innerHTML]=\"column.label\">{{ column.label }} </span>\n </th>\n\n <!-- Cuerpo de la celda, definido por los hijos -->\n <td *matCellDef=\"let row\" [ngClass]=\"column.cssClasses\" mat-cell (click)=\"accionClick(row, $event)\">\n\n <ng-container [ngTemplateOutlet]=\"cellTemplate\" [ngTemplateOutletContext]=\"{row}\"></ng-container>\n\n </td>\n\n <th *matFooterCellDef [ngClass]=\"column.cssFooterClasses\" mat-footer-cell>\n {{ column.transformarFooter ? column.transformarFooter() : '' }}\n </th>\n</ng-container>\n\n\n<ng-template #iconoConTamanio let-icon=\"icon\" let-iconClass=\"iconClass\" let-size=\"size\">\n <mat-icon *ngIf=\"size\" [svgIcon]=\"icon\" [ngClass]=\"iconClass\" [inline]=\"true\"\n [style.font-size]=\"size\"\n [style.height]=\"size\"\n [style.width]=\"size\"\n ></mat-icon>\n <mat-icon *ngIf=\"!size\" [svgIcon]=\"icon\" [ngClass]=\"iconClass\"></mat-icon>\n</ng-template>\n" }]
|
|
715
701
|
}], propDecorators: { column: [{
|
|
716
702
|
type: Input,
|
|
717
703
|
args: [{ required: true }]
|
|
@@ -734,7 +720,9 @@ class ColumnTypeModule {
|
|
|
734
720
|
ZeroFillPipe,
|
|
735
721
|
MatRipple,
|
|
736
722
|
MatIcon,
|
|
737
|
-
ProgressBarComponent
|
|
723
|
+
ProgressBarComponent,
|
|
724
|
+
JvsPopoverDirective,
|
|
725
|
+
JvsPopoverListenerDirective], exports: [ColumnTypeTextComponent,
|
|
738
726
|
ColumnTypeMoneyComponent,
|
|
739
727
|
ColumnTypeNumberComponent,
|
|
740
728
|
ColumnTypeDateComponent,
|
|
@@ -771,6 +759,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImpo
|
|
|
771
759
|
MatRipple,
|
|
772
760
|
MatIcon,
|
|
773
761
|
ProgressBarComponent,
|
|
762
|
+
JvsPopoverDirective,
|
|
763
|
+
JvsPopoverListenerDirective
|
|
774
764
|
],
|
|
775
765
|
exports: [
|
|
776
766
|
ColumnTypeTextComponent,
|
|
@@ -813,7 +803,7 @@ class TablaMantenimientoColumnDefsComponent {
|
|
|
813
803
|
return column.property;
|
|
814
804
|
}
|
|
815
805
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: TablaMantenimientoColumnDefsComponent, deps: [{ token: i2.MatTable, optional: true }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
816
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", 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<ng-container *ngFor=\"let column of colDetalle; trackBy: trackByProperty\">\n\n <ng-container *ngIf=\"column.type === 'expandir'\" [matColumnDef]=\"column.property\">\n\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 <button type=\"button\" class=\"boton-circular text-primary-contrast bg-primary mat-elevation-z2\" matRipple\n *ngIf=\"column.click\"\n (click)=\"column.click(row); row.isExpanded = !row.isExpanded; $event.stopPropagation()\"\n matTooltip=\"Expandir / Contraer\">\n <mat-icon class=\"icon-xs\" [svgIcon]=\"(row.isExpanded ? 'roundExpandLess' : 'roundExpandMore')\"></mat-icon>\n </button>\n <button type=\"button\" class=\"boton-circular text-primary-contrast bg-primary mat-elevation-z2\" matRipple\n *ngIf=\"!column.click\"\n (click)=\"row.isExpanded = !row.isExpanded; $event.stopPropagation()\"\n matTooltip=\"Expandir / Contraer\">\n <mat-icon class=\"icon-xs\" [svgIcon]=\"(row.isExpanded ? 'roundExpandLess' : 'roundExpandMore')\"></mat-icon>\n </button>\n </td>\n <td *matFooterCellDef [ngClass]=\"column.cssFooterClasses\" mat-footer-cell></td>\n\n </ng-container>\n <ng-container *ngIf=\"column.type === 'checkbox'\" [matColumnDef]=\"column.property\">\n\n <th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"w-4 text-center\" mat-header-cell>\n <mat-checkbox *ngIf=\"chkLista\"\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 </th>\n <td *matCellDef=\"let row\" class=\"w-4 text-center\" mat-cell>\n <mat-checkbox *ngIf=\"chkLista\"\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\n </ng-container>\n <ng-container *ngIf=\"column.type === 'estiloEstablecido'\" [matColumnDef]=\"column.property\">\n\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\n </ng-container>\n\n <jvs-column-type-text *ngIf=\"column.type == 'text'\" [column]=\"column\"></jvs-column-type-text>\n <jvs-column-type-money *ngIf=\"column.type == 'money'\" [column]=\"column\"></jvs-column-type-money>\n <jvs-column-type-number *ngIf=\"column.type == 'number'\" [column]=\"column\"></jvs-column-type-number>\n <jvs-column-type-date *ngIf=\"column.type == 'date'\" [column]=\"column\"></jvs-column-type-date>\n <jvs-column-type-icons *ngIf=\"column.type == 'icons'\" [column]=\"column\"></jvs-column-type-icons>\n <jvs-column-type-sino *ngIf=\"column.type == 'yes_no'\" [column]=\"column\"></jvs-column-type-sino>\n <jvs-column-type-progressbar *ngIf=\"column.type == 'progress'\" [column]=\"column\"></jvs-column-type-progressbar>\n\n\n\n</ng-container>\n", styles: [""], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: MatCheckboxModule }, { kind: "component", type: i5$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: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatRippleModule }, { kind: "directive", type: i5.MatRipple, selector: "[mat-ripple], [matRipple]", inputs: ["matRippleColor", "matRippleUnbounded", "matRippleCentered", "matRippleRadius", "matRippleAnimation", "matRippleDisabled", "matRippleTrigger"], exportAs: ["matRipple"] }, { kind: "ngmodule", type: MatSortModule }, { kind: "component", type: i3$1.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$
|
|
806
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", 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<ng-container *ngFor=\"let column of colDetalle; trackBy: trackByProperty\">\n\n <ng-container *ngIf=\"column.type === 'expandir'\" [matColumnDef]=\"column.property\">\n\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 <button type=\"button\" class=\"boton-circular text-primary-contrast bg-primary mat-elevation-z2\" matRipple\n *ngIf=\"column.click\"\n (click)=\"column.click(row); row.isExpanded = !row.isExpanded; $event.stopPropagation()\"\n matTooltip=\"Expandir / Contraer\">\n <mat-icon class=\"icon-xs\" [svgIcon]=\"(row.isExpanded ? 'roundExpandLess' : 'roundExpandMore')\"></mat-icon>\n </button>\n <button type=\"button\" class=\"boton-circular text-primary-contrast bg-primary mat-elevation-z2\" matRipple\n *ngIf=\"!column.click\"\n (click)=\"row.isExpanded = !row.isExpanded; $event.stopPropagation()\"\n matTooltip=\"Expandir / Contraer\">\n <mat-icon class=\"icon-xs\" [svgIcon]=\"(row.isExpanded ? 'roundExpandLess' : 'roundExpandMore')\"></mat-icon>\n </button>\n </td>\n <td *matFooterCellDef [ngClass]=\"column.cssFooterClasses\" mat-footer-cell></td>\n\n </ng-container>\n <ng-container *ngIf=\"column.type === 'checkbox'\" [matColumnDef]=\"column.property\">\n\n <th *matHeaderCellDef [ngClass]=\"column.cssClassesTH\" class=\"w-4 text-center\" mat-header-cell>\n <mat-checkbox *ngIf=\"chkLista\"\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 </th>\n <td *matCellDef=\"let row\" class=\"w-4 text-center\" mat-cell>\n <mat-checkbox *ngIf=\"chkLista\"\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\n </ng-container>\n <ng-container *ngIf=\"column.type === 'estiloEstablecido'\" [matColumnDef]=\"column.property\">\n\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\n </ng-container>\n\n <jvs-column-type-text *ngIf=\"column.type == 'text'\" [column]=\"column\"></jvs-column-type-text>\n <jvs-column-type-money *ngIf=\"column.type == 'money'\" [column]=\"column\"></jvs-column-type-money>\n <jvs-column-type-number *ngIf=\"column.type == 'number'\" [column]=\"column\"></jvs-column-type-number>\n <jvs-column-type-date *ngIf=\"column.type == 'date'\" [column]=\"column\"></jvs-column-type-date>\n <jvs-column-type-icons *ngIf=\"column.type == 'icons'\" [column]=\"column\"></jvs-column-type-icons>\n <jvs-column-type-sino *ngIf=\"column.type == 'yes_no'\" [column]=\"column\"></jvs-column-type-sino>\n <jvs-column-type-progressbar *ngIf=\"column.type == 'progress'\" [column]=\"column\"></jvs-column-type-progressbar>\n\n\n\n</ng-container>\n", styles: [""], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: MatCheckboxModule }, { kind: "component", type: i5$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: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatRippleModule }, { kind: "directive", type: i5.MatRipple, selector: "[mat-ripple], [matRipple]", inputs: ["matRippleColor", "matRippleUnbounded", "matRippleCentered", "matRippleRadius", "matRippleAnimation", "matRippleDisabled", "matRippleTrigger"], exportAs: ["matRipple"] }, { kind: "ngmodule", type: MatSortModule }, { kind: "component", type: i3$1.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$2.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i2$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2$1.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"] }] });
|
|
817
807
|
}
|
|
818
808
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: TablaMantenimientoColumnDefsComponent, decorators: [{
|
|
819
809
|
type: Component,
|
|
@@ -865,7 +855,7 @@ class TablaMantenimientoMenuComponent {
|
|
|
865
855
|
ngOnInit() {
|
|
866
856
|
}
|
|
867
857
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: TablaMantenimientoMenuComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
868
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: TablaMantenimientoMenuComponent, isStandalone: true, selector: "jvs-tabla-mantenimiento-menu", inputs: { objThis: "objThis", nombreColeccion: "nombreColeccion", item: "item", derechosActuales: "derechosActuales", subItems: "subItems", botonTemplate: "botonTemplate" }, outputs: { opcionSelecionada: "opcionSelecionada" }, viewQueries: [{ propertyName: "menu", first: true, predicate: ["menu"], descendants: true, static: true }], ngImport: i0, template: "<mat-menu #menu=\"matMenu\">\n <div class=\"mat-menu bg-white rounded mat-elevation-z8 shadow botonesContextual w-full\">\n <ng-container *ngFor=\"let btn of subItems\">\n <ng-container *ngTemplateOutlet=\"botonTemplate; context:{btn: btn, item: item, barraSuperior: false}\"></ng-container>\n </ng-container>\n </div>\n</mat-menu>\n", styles: [""], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "ngmodule", type: MatMenuModule }, { kind: "component", type: i2$
|
|
858
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: TablaMantenimientoMenuComponent, isStandalone: true, selector: "jvs-tabla-mantenimiento-menu", inputs: { objThis: "objThis", nombreColeccion: "nombreColeccion", item: "item", derechosActuales: "derechosActuales", subItems: "subItems", botonTemplate: "botonTemplate" }, outputs: { opcionSelecionada: "opcionSelecionada" }, viewQueries: [{ propertyName: "menu", first: true, predicate: ["menu"], descendants: true, static: true }], ngImport: i0, template: "<mat-menu #menu=\"matMenu\">\n <div class=\"mat-menu bg-white rounded mat-elevation-z8 shadow botonesContextual w-full\">\n <ng-container *ngFor=\"let btn of subItems\">\n <ng-container *ngTemplateOutlet=\"botonTemplate; context:{btn: btn, item: item, barraSuperior: false}\"></ng-container>\n </ng-container>\n </div>\n</mat-menu>\n", styles: [""], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "ngmodule", type: MatMenuModule }, { kind: "component", type: i2$2.MatMenu, selector: "mat-menu", inputs: ["backdropClass", "aria-label", "aria-labelledby", "aria-describedby", "xPosition", "yPosition", "overlapTrigger", "hasBackdrop", "class", "classList"], outputs: ["closed", "close"], exportAs: ["matMenu"] }] });
|
|
869
859
|
}
|
|
870
860
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: TablaMantenimientoMenuComponent, decorators: [{
|
|
871
861
|
type: Component,
|
|
@@ -1002,8 +992,8 @@ let TablaMantenimientoComponent = class TablaMantenimientoComponent {
|
|
|
1002
992
|
dataSuscription;
|
|
1003
993
|
objThis;
|
|
1004
994
|
nombreColeccion;
|
|
1005
|
-
|
|
1006
|
-
|
|
995
|
+
busquedaValor = input('', { alias: 'ctrlBusquedaValue' });
|
|
996
|
+
busquedaPlaceholder = input('Buscar...', { alias: 'ctrlBusquedaPlaceholder' });
|
|
1007
997
|
filtroCampos = true;
|
|
1008
998
|
paginador = true;
|
|
1009
999
|
esTabla = true;
|
|
@@ -1034,6 +1024,8 @@ let TablaMantenimientoComponent = class TablaMantenimientoComponent {
|
|
|
1034
1024
|
paginator;
|
|
1035
1025
|
sort;
|
|
1036
1026
|
exportarExcel = true;
|
|
1027
|
+
busquedaCompacta = input(false);
|
|
1028
|
+
alturaFull = input(false);
|
|
1037
1029
|
// MIO
|
|
1038
1030
|
pageSize = 25;
|
|
1039
1031
|
pageSizeOptions = [5, 10, 25, 50, 100, 500, 1000];
|
|
@@ -1061,12 +1053,15 @@ let TablaMantenimientoComponent = class TablaMantenimientoComponent {
|
|
|
1061
1053
|
mouseEvent$;
|
|
1062
1054
|
overlayRef;
|
|
1063
1055
|
userMenu;
|
|
1056
|
+
compactSearchMenuTrigger;
|
|
1064
1057
|
// FILTRO BUSQUEDA
|
|
1065
1058
|
opcFiltroActual = {};
|
|
1066
1059
|
capitalizarTexto = capitalizarTexto;
|
|
1067
1060
|
_seleccionado = {};
|
|
1068
1061
|
cCampoBusqueda = new FormControl('');
|
|
1069
1062
|
chkLista = new DataModel();
|
|
1063
|
+
bDireccionOrden = signal(1);
|
|
1064
|
+
mostrarBotonOrden = input(false);
|
|
1070
1065
|
constructor(fb, overlay, viewContainerRef, tablaMantenimientoService, cdRef) {
|
|
1071
1066
|
this.fb = fb;
|
|
1072
1067
|
this.overlay = overlay;
|
|
@@ -1075,16 +1070,14 @@ let TablaMantenimientoComponent = class TablaMantenimientoComponent {
|
|
|
1075
1070
|
this.cdRef = cdRef;
|
|
1076
1071
|
// this._seleccionado[this.nombreColeccion] = null;
|
|
1077
1072
|
}
|
|
1078
|
-
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
|
|
1082
|
-
|
|
1083
|
-
|
|
1084
|
-
val = 'simple';
|
|
1073
|
+
busquedaTipo = input('simple', {
|
|
1074
|
+
alias: 'ctrlBusqueda',
|
|
1075
|
+
transform: (val) => {
|
|
1076
|
+
if (val === '')
|
|
1077
|
+
return 'simple';
|
|
1078
|
+
return val;
|
|
1085
1079
|
}
|
|
1086
|
-
|
|
1087
|
-
}
|
|
1080
|
+
});
|
|
1088
1081
|
// @Input() leyenda;
|
|
1089
1082
|
_leyenda = undefined;
|
|
1090
1083
|
get leyenda() {
|
|
@@ -1270,27 +1263,39 @@ let TablaMantenimientoComponent = class TablaMantenimientoComponent {
|
|
|
1270
1263
|
return this.columnasTabla && this.columnasTabla.length > 0 && this.columnasTabla.find(col => col.type === 'checkbox') || false;
|
|
1271
1264
|
}
|
|
1272
1265
|
get buscarItemSeleccionado() {
|
|
1266
|
+
if (!this.dataSource?.data || !Array.isArray(this.dataSource.data)) {
|
|
1267
|
+
return null;
|
|
1268
|
+
}
|
|
1273
1269
|
const dRet = this.dataSource.data.find(itm => this._seleccionado === this.propiedadSeleccion(itm));
|
|
1274
1270
|
return dRet ?? null;
|
|
1275
1271
|
}
|
|
1276
1272
|
get objSeleccionado() {
|
|
1277
|
-
return this.buscarItemSeleccionado
|
|
1273
|
+
return this.buscarItemSeleccionado ?? this.objThis?.['seleccionados']?.[this.nombreColeccion];
|
|
1278
1274
|
}
|
|
1279
1275
|
set objSeleccionado(val) {
|
|
1280
1276
|
// if (val) {
|
|
1281
1277
|
this.seleccionarItem(val, true);
|
|
1282
1278
|
// }
|
|
1283
|
-
/*
|
|
1284
|
-
this.objThis = {};
|
|
1285
|
-
}
|
|
1279
|
+
/*if (this.objThis) {
|
|
1286
1280
|
if (!this.objThis['seleccionados']) {
|
|
1287
1281
|
this.objThis['seleccionados'] = {};
|
|
1288
1282
|
}
|
|
1289
|
-
this.objThis['seleccionados'][this.nombreColeccion] = val
|
|
1283
|
+
this.objThis['seleccionados'][this.nombreColeccion] = val;
|
|
1284
|
+
}*/
|
|
1290
1285
|
}
|
|
1291
1286
|
get idsSeleccionado() {
|
|
1292
1287
|
return this.chkLista.generarLista();
|
|
1293
1288
|
}
|
|
1289
|
+
get itemsSeleccionados() {
|
|
1290
|
+
const checkbox = this.tieneCheckbox;
|
|
1291
|
+
if (!checkbox || !this.dataSource?.data) {
|
|
1292
|
+
return [];
|
|
1293
|
+
}
|
|
1294
|
+
return this.dataSource.data.filter(item => {
|
|
1295
|
+
const id = this.chkLista.generarId(item, (checkbox.chkField ?? checkbox.property), checkbox.chkFieldSeparador);
|
|
1296
|
+
return !!this.chkLista.getState(id);
|
|
1297
|
+
});
|
|
1298
|
+
}
|
|
1294
1299
|
idTablaValor(data) {
|
|
1295
1300
|
if (data) {
|
|
1296
1301
|
if (this.idTabla.length < 1) {
|
|
@@ -1339,9 +1344,9 @@ let TablaMantenimientoComponent = class TablaMantenimientoComponent {
|
|
|
1339
1344
|
}
|
|
1340
1345
|
else {
|
|
1341
1346
|
console.log('eLSE ID TABLA');
|
|
1342
|
-
const dataStr = res.find((itm) => shortHash(JSON.stringify({
|
|
1347
|
+
const dataStr = Array.isArray(res) ? res.find((itm) => shortHash(JSON.stringify({
|
|
1343
1348
|
...itm, claseFinal: undefined
|
|
1344
|
-
})) == shortHash(JSON.stringify({ ...this.objSeleccionado, claseFinal: undefined })));
|
|
1349
|
+
})) == shortHash(JSON.stringify({ ...this.objSeleccionado, claseFinal: undefined }))) : null;
|
|
1345
1350
|
if (dataStr) {
|
|
1346
1351
|
this.objSeleccionado = dataStr;
|
|
1347
1352
|
}
|
|
@@ -1368,13 +1373,13 @@ let TablaMantenimientoComponent = class TablaMantenimientoComponent {
|
|
|
1368
1373
|
}
|
|
1369
1374
|
});
|
|
1370
1375
|
// console.log(a);
|
|
1371
|
-
if (this.
|
|
1372
|
-
this.cCampoBusqueda.setValue(this.
|
|
1376
|
+
if (this.busquedaValor()) {
|
|
1377
|
+
this.cCampoBusqueda.setValue(this.busquedaValor());
|
|
1373
1378
|
}
|
|
1374
1379
|
this.table.renderRows(); // 🔹 Refrescar la tabla
|
|
1375
1380
|
}
|
|
1376
1381
|
ngOnChanges(changes) {
|
|
1377
|
-
if (changes['botonesCRUD'] || changes['
|
|
1382
|
+
if (changes['botonesCRUD'] || changes['busquedaTipo']) {
|
|
1378
1383
|
this.actualizarCrud();
|
|
1379
1384
|
}
|
|
1380
1385
|
if (changes['botonesMenu']) {
|
|
@@ -1442,7 +1447,7 @@ let TablaMantenimientoComponent = class TablaMantenimientoComponent {
|
|
|
1442
1447
|
}
|
|
1443
1448
|
}
|
|
1444
1449
|
}
|
|
1445
|
-
if (this.
|
|
1450
|
+
if (this.busquedaTipo() === 'simple') {
|
|
1446
1451
|
this.cCampoBusqueda.valueChanges.pipe(untilDestroyed(this)).subscribe(value => this.onFilterChange(value ?? ''));
|
|
1447
1452
|
}
|
|
1448
1453
|
if (this.botonesCRUD === '-') {
|
|
@@ -1499,7 +1504,7 @@ let TablaMantenimientoComponent = class TablaMantenimientoComponent {
|
|
|
1499
1504
|
column.visible = !column.visible;
|
|
1500
1505
|
}
|
|
1501
1506
|
cargarData(retorno = false) {
|
|
1502
|
-
if (this.
|
|
1507
|
+
if (this.busquedaTipo() && this.busquedaTipo() == 'simple') {
|
|
1503
1508
|
if (!retorno) {
|
|
1504
1509
|
this.dataSource.paginator = this.paginator;
|
|
1505
1510
|
this.dataSource.sort = this.sort;
|
|
@@ -1513,8 +1518,9 @@ let TablaMantenimientoComponent = class TablaMantenimientoComponent {
|
|
|
1513
1518
|
iPaginacion: 1,
|
|
1514
1519
|
iPageSize: this.paginator?.pageSize ? this.paginator?.pageSize : this.paginacion.pageCurrent?.pageSize,
|
|
1515
1520
|
iPageNumber: (this.paginator?.pageIndex ? this.paginator?.pageIndex : 0) + 1,
|
|
1521
|
+
bDireccionOrden: this.bDireccionOrden(),
|
|
1516
1522
|
};
|
|
1517
|
-
if (this.
|
|
1523
|
+
if (this.busquedaTipo() && this.busquedaTipo() == 'query') {
|
|
1518
1524
|
dPag['cCampoBusqueda'] = this.cCampoBusqueda.value;
|
|
1519
1525
|
}
|
|
1520
1526
|
if (retorno) {
|
|
@@ -1523,8 +1529,20 @@ let TablaMantenimientoComponent = class TablaMantenimientoComponent {
|
|
|
1523
1529
|
this.resultados.emit(dPag);
|
|
1524
1530
|
this.opcBusqueda.emit(dPag);
|
|
1525
1531
|
}
|
|
1532
|
+
toggleDireccionOrden() {
|
|
1533
|
+
this.bDireccionOrden.update((v) => v === 0 ? 1 : 0);
|
|
1534
|
+
this.emitirResultados();
|
|
1535
|
+
// if (this.busquedaTipo() === 'query') {
|
|
1536
|
+
// this.cargarData();
|
|
1537
|
+
// } else {
|
|
1538
|
+
// this.emitirAccionRecargar();
|
|
1539
|
+
// }
|
|
1540
|
+
}
|
|
1526
1541
|
// FIN FILTRO BUSQUEDA INTEGRAR
|
|
1527
1542
|
setData(data) {
|
|
1543
|
+
if (!Array.isArray(data)) {
|
|
1544
|
+
data = [];
|
|
1545
|
+
}
|
|
1528
1546
|
this.dataSource = new MatTableDataSource(data);
|
|
1529
1547
|
this.dataSource.sortingDataAccessor = (item, property) => {
|
|
1530
1548
|
const dColumn = buscarEnArray(this.columnasTabla, 'property', property);
|
|
@@ -1556,6 +1574,9 @@ let TablaMantenimientoComponent = class TablaMantenimientoComponent {
|
|
|
1556
1574
|
if (data && data[0] && data[0]['iPageNumber']) {
|
|
1557
1575
|
this.paginacion.pageIndex = (data && data[0] && data[0]['iPageNumber']) ? data[0]['iPageNumber'] : 0;
|
|
1558
1576
|
}
|
|
1577
|
+
if (data && data[0] && 'bDireccionOrden' in data[0]) {
|
|
1578
|
+
this.bDireccionOrden.set(data[0]['bDireccionOrden']);
|
|
1579
|
+
}
|
|
1559
1580
|
this.paginacion.pageLength = (data && data[0] && data[0]['iTotalRegistros']) ? data[0]['iTotalRegistros'] : data.length;
|
|
1560
1581
|
if (data && data[0] && !data[0]['iTotalRegistros']) {
|
|
1561
1582
|
this.dataSource.paginator = this.paginator;
|
|
@@ -1596,13 +1617,12 @@ let TablaMantenimientoComponent = class TablaMantenimientoComponent {
|
|
|
1596
1617
|
this._seleccionado = this._seleccionado === idItem ? null : idItem;
|
|
1597
1618
|
}
|
|
1598
1619
|
this.selectionModelChange.emit(this.objSeleccionado);
|
|
1599
|
-
/*if (
|
|
1600
|
-
this.objThis
|
|
1601
|
-
|
|
1602
|
-
|
|
1603
|
-
this.objThis['seleccionados'] =
|
|
1604
|
-
}
|
|
1605
|
-
this.objThis['seleccionados'][this.nombreColeccion] = this._seleccionado;*/
|
|
1620
|
+
/*if (this.objThis) {
|
|
1621
|
+
if (!this.objThis['seleccionados']) {
|
|
1622
|
+
this.objThis['seleccionados'] = {};
|
|
1623
|
+
}
|
|
1624
|
+
this.objThis['seleccionados'][this.nombreColeccion] = this.objSeleccionado;
|
|
1625
|
+
}*/
|
|
1606
1626
|
}
|
|
1607
1627
|
opcMenu(item, objMenu, modal = null, retorno = false) {
|
|
1608
1628
|
// console.log(this.buscarItemSeleccionado);
|
|
@@ -1694,6 +1714,7 @@ let TablaMantenimientoComponent = class TablaMantenimientoComponent {
|
|
|
1694
1714
|
if (this.tieneCheckbox) {
|
|
1695
1715
|
// itmsSeleccionados = this.formulariosGlobalesService.generarLista(this.nombreColeccion);
|
|
1696
1716
|
opAdic['idsSeleccionados'] = this.idsSeleccionado;
|
|
1717
|
+
opAdic['itemsSeleccionados'] = this.itemsSeleccionados;
|
|
1697
1718
|
}
|
|
1698
1719
|
// opAdic['refTabla'] = this;
|
|
1699
1720
|
objMenu = { ...objMenu, ...opAdic };
|
|
@@ -1742,6 +1763,12 @@ let TablaMantenimientoComponent = class TablaMantenimientoComponent {
|
|
|
1742
1763
|
this.overlayRef = undefined;
|
|
1743
1764
|
}
|
|
1744
1765
|
}
|
|
1766
|
+
ejecutarBusquedaCompacta() {
|
|
1767
|
+
if (this.busquedaTipo() === 'query') {
|
|
1768
|
+
this.cargarData();
|
|
1769
|
+
}
|
|
1770
|
+
this.compactSearchMenuTrigger.closeMenu();
|
|
1771
|
+
}
|
|
1745
1772
|
emitirAccionRecargar() {
|
|
1746
1773
|
if (!this.idTabla) {
|
|
1747
1774
|
this.objSeleccionado = null;
|
|
@@ -1750,10 +1777,10 @@ let TablaMantenimientoComponent = class TablaMantenimientoComponent {
|
|
|
1750
1777
|
// this.accionRecargar.emit({ ...this.opcFiltroActual, ...{seleccionado: this.objSeleccionado}});
|
|
1751
1778
|
}
|
|
1752
1779
|
tipoValorFuncion = tipoValorFuncion;
|
|
1753
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: TablaMantenimientoComponent, deps: [{ token:
|
|
1754
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
|
|
1780
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: TablaMantenimientoComponent, deps: [{ token: i2$1.FormBuilder }, { token: i2$3.Overlay }, { token: i0.ViewContainerRef }, { token: TablaMantenimientoService }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
1781
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "19.2.14", 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: [
|
|
1755
1782
|
{ provide: MAT_PAGINATOR_DEFAULT_OPTIONS, useValue: { formFieldAppearance: 'outline' } }
|
|
1756
|
-
], 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: "rows", predicate: MatRow, descendants: true, read: ElementRef }], usesOnChanges: true, ngImport: i0, template: "<div class=\"flex flex-col h-fit\">\n <div class=\"grow 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\">\n <div class=\"flex-1 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 <div class=\"flex items-center flex-wrap mr-1 h-full\" *ngIf=\"leyenda\">\n <span class=\"font-bold\" [class]=\"leyenda.class\">{{ leyenda.text }}</span>\n </div>\n <div class=\"hidden flex-1 sm:flex items-center flex-wrap gap-1\">\n <div *ngIf=\"(botonesMenuFinal.izquierda ?? []).length > 0 \" class=\" flex items-center flex-wrap contenedor-botones\">\n <ng-container *ngFor=\"let btn of botonesMenu.izquierda; let idx = index;\">\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.izquierda?.length}}\"></ng-container>\n </ng-container>\n </div>\n\n <div *ngIf=\"(botonesMenuFinal.crud ?? []).length > 0\" class=\" flex items-center flex-wrap contenedor-botones\">\n <ng-container *ngFor=\"let btn of botonesMenu.crud; let idx = index;\">\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.crud?.length}}\"></ng-container>\n </ng-container>\n </div>\n\n <div *ngIf=\"(botonesMenuFinal.principal ?? []).length > 0\" class=\" flex items-center flex-wrap contenedor-botones\">\n <ng-container *ngFor=\"let btn of botonesMenu.principal; let idx = index;\">\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.principal?.length}}\"></ng-container>\n </ng-container>\n </div>\n\n <div *ngIf=\"(botonesMenuFinal.derecha ?? []).length > 0\" class=\"flex-auto flex items-center justify-end contenedor-botones\">\n <ng-container *ngFor=\"let btn of botonesMenu.derecha; let idx = index;\">\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.derecha?.length}}\"></ng-container>\n </ng-container>\n </div>\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 <div *ngIf=\"ctrlBusqueda\" 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]=\"ctrlBusquedaPlaceholder\"\n (keyup.enter)=\"ctrlBusqueda == 'query' ? cargarData() : false;\"\n type=\"search\">\n </div>\n <div class=\"flex-none flex items-center justify-end border-l-2\">\n <ng-content select=\"[botonesFiltro]\"></ng-content>\n <button matRipple *ngIf=\"isRecargarUsed || ctrlBusqueda == 'query'\"\n class=\"flex items-center justify-center text-2xs leading-none rounded-full p-1 text-green-700\"\n matTooltip=\"Actualizar datos\"\n (click)=\"(ctrlBusqueda == 'query' ? cargarData() : emitirAccionRecargar())\"\n type=\"button\">\n <mat-icon svgIcon=\"roundRefresh\" class=\"icon-xs\"></mat-icon>\n\n </button>\n <button matRipple [matMenuTriggerFor]=\"columnFilterMenu\" *ngIf=\"filtroCampos\"\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 </div>\n </div>\n\n <div *ngIf=\"(botonesMenuFinal.secundario ?? []).length > 0\" 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 <ng-container *ngFor=\"let btn of botonesMenu.secundario; let idx = index;\">\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.secundario?.length}}\"></ng-container>\n </ng-container>\n </div>\n </div>\n </div>\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=\"flex-1 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 <ng-container *ngIf=\"esTabla && paginador\">\n {{ (this.paginator?.pageIndex == 0 ? i + 1 : 1 + i + (this.paginator?.pageIndex ?? 1) * (this.paginator?.pageSize ?? 1)) }}\n </ng-container>\n <ng-container *ngIf=\"!paginador\">\n {{ (i + 1) }}\n </ng-container>\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 <ng-container *ngIf=\"!!filaExtraHeader\">\n <tr mat-row *matRowDef=\"let row; columns: ['filaExtraHeader']\" class=\"student-detail-row\"\n [style.height.px]=\"0\"\n ></tr>\n\n <ng-container matColumnDef=\"filaExtraHeader\">\n <td mat-cell *matCellDef=\"let row; let i = dataIndex\" [attr.colspan]=\"visibleColumns.length\">\n\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 <ng-container *ngIf=\"filaExtraHeader.template\"\n [ngTemplateOutlet]=\"filaExtraHeader.template\"\n [ngTemplateOutletContext]=\"{ row: row }\"></ng-container>\n </div>\n\n </td>\n </ng-container>\n </ng-container>\n <ng-container *ngIf=\"filaFooter\">\n <tr *matFooterRowDef=\"visibleColumns\" mat-footer-row\n [style.height.px]=\"0\"\n [id]=\"nombreColeccion + '_filaFooter'\"\n ></tr>\n </ng-container>\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 <ng-container *ngIf=\"filaExtraTemplate\">\n <tr mat-row *matRowDef=\"let row; columns: ['expandedDetail']\" class=\"student-detail-row h-0\"></tr>\n\n <ng-container matColumnDef=\"expandedDetail\">\n <td mat-cell *matCellDef=\"let row\" [attr.colspan]=\"visibleColumns.length\">\n\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\n </td>\n </ng-container>\n </ng-container>\n </table>\n\n <ng-container *ngIf=\"componenteCargadoTotalmente\">\n <div *ngIf=\"(noData | async) && esTabla\" class=\"flex-1 text-center text-secondary font-medium\">\n No se encontraron datos\n </div>\n </ng-container>\n </div>\n <ng-content select=\"[appendTable]\"></ng-content>\n <div class=\"flex-1 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 <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 <div *ngIf=\"esTabla && paginador\" 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 </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 <ng-container *ngFor=\"let column of columnasTabla\">\n <button (click)=\"toggleColumnVisibility(column, $event)\" *ngIf=\"!tipoValorFuncion(column.noMostrarEnLista, false)\"\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 </ng-container>\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 <ng-container *ngIf=\"barraSuperior; else noBarraSuperior\">\n\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 <ng-container *ngIf=\"btn.subItems && btn.subItems.length > 0\">\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\n *ngIf=\"(!btn.esVisible || btn.esVisible(item, this)) && subItemsActivos(btn, item)\"\n [class]=\"(btn.class?btn.class:'')\"\n\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\n [matBadge]=\"btn.badge\"\n matBadgeSize=\"small\"\n >\n <mat-icon class=\"icon-xs\" [class.mr-0.5]=\"!(btn.soloIcono ?? tipoValorFuncion(soloIconos))\" *ngIf=\"btn.icono\" [svgIcon]=\"btn.icono\" ></mat-icon>\n <span class=\"whitespace-nowrap\" *ngIf=\"!(btn.soloIcono ?? tipoValorFuncion(soloIconos))\">{{ btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo)) }}</span>\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 </ng-container>\n <ng-container *ngIf=\"!btn.subItems || btn.subItems.length == 0\">\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\n *ngIf=\"!btn.esVisible || btn.esVisible(item, this)\"\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\n [matBadge]=\"btn.badge\"\n matBadgeSize=\"small\"\n >\n <mat-icon class=\"icon-xs\" [class.mr-0.5]=\"!(btn.soloIcono ?? tipoValorFuncion(soloIconos))\" *ngIf=\"btn.icono\" [svgIcon]=\"btn.icono\"></mat-icon>\n <span class=\"whitespace-nowrap\" *ngIf=\"!(btn.soloIcono ?? tipoValorFuncion(soloIconos))\">{{ btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo)) }}</span>\n </button>\n\n </ng-container>\n\n </ng-container>\n <ng-template #noBarraSuperior>\n\n <ng-container *ngIf=\"btn.subItems && btn.subItems.length > 0\">\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 *ngIf=\"!btn.noContextual && (!btn.esVisible || btn.esVisible(item, this))\"\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 <mat-icon *ngIf=\"btn.icono\" [svgIcon]=\"btn.icono\"\n class=\"flex-none icon-xs\"\n ></mat-icon>\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 </ng-container>\n <ng-container *ngIf=\"!btn.subItems || btn.subItems.length == 0\">\n <ng-container *ngIf=\"btn.tipo == '-#SEPARADOR#-'; else itemsNormales\">\n <mat-divider></mat-divider>\n </ng-container>\n <ng-template #itemsNormales>\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 *ngIf=\"!btn.noContextual && (!btn.esVisible || btn.esVisible(item, this))\"\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 <mat-icon *ngIf=\"btn.icono\" [svgIcon]=\"btn.icono\" class=\"flex-none icon-xs\"\n ></mat-icon>\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 </ng-template>\n\n </ng-container>\n\n </ng-template>\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 <ng-container *ngFor=\"let btn of listaMenuCompleto\">\n <ng-container *ngTemplateOutlet=\"botonesContextual; context:{btn: btn, item: objSeleccionado, barraSuperior: false}\"></ng-container>\n </ng-container>\n </div>\n</ng-template>\n\n\n<mat-menu #menuOpciones=\"matMenu\" xPosition=\"before\" yPosition=\"below\">\n <ng-container *ngFor=\"let btn of listaMenuCompleto\">\n <ng-container\n *ngTemplateOutlet=\"botonesContextual; context:{btn: btn, item: objSeleccionado, barraSuperior: false}\"></ng-container>\n </ng-container>\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}.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-container{max-height:600px!important}.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,.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: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: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}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }, { 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: i5$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: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatMenuModule }, { kind: "component", type: i2$1.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: i2$1.MatMenuItem, selector: "[mat-menu-item]", inputs: ["role", "disabled", "disableRipple"], exportAs: ["matMenuItem"] }, { kind: "directive", type: i2$1.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.MatRipple, selector: "[mat-ripple], [matRipple]", inputs: ["matRippleColor", "matRippleUnbounded", "matRippleCentered", "matRippleRadius", "matRippleAnimation", "matRippleDisabled", "matRippleTrigger"], exportAs: ["matRipple"] }, { kind: "ngmodule", type: MatSortModule }, { kind: "directive", type: i3$1.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"] }], animations: [
|
|
1783
|
+
], 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 <div class=\"flex items-center flex-wrap mr-1 h-full\" *ngIf=\"leyenda\">\n <span class=\"font-bold\" [class]=\"leyenda.class\">{{ leyenda.text }}</span>\n </div>\n <div class=\"hidden flex-1 sm:flex items-center flex-wrap gap-1\">\n <div *ngIf=\"(botonesMenuFinal.izquierda ?? []).length > 0 \" class=\" flex items-center flex-wrap contenedor-botones\">\n <ng-container *ngFor=\"let btn of botonesMenu.izquierda; let idx = index;\">\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.izquierda?.length}}\"></ng-container>\n </ng-container>\n </div>\n\n <div *ngIf=\"(botonesMenuFinal.crud ?? []).length > 0\" class=\" flex items-center flex-wrap contenedor-botones\">\n <ng-container *ngFor=\"let btn of botonesMenu.crud; let idx = index;\">\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.crud?.length}}\"></ng-container>\n </ng-container>\n </div>\n\n <div *ngIf=\"(botonesMenuFinal.principal ?? []).length > 0\" class=\" flex items-center flex-wrap contenedor-botones\">\n <ng-container *ngFor=\"let btn of botonesMenu.principal; let idx = index;\">\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.principal?.length}}\"></ng-container>\n </ng-container>\n </div>\n\n <div *ngIf=\"(botonesMenuFinal.derecha ?? []).length > 0\" class=\"flex-auto flex items-center justify-end contenedor-botones\">\n <ng-container *ngFor=\"let btn of botonesMenu.derecha; let idx = index;\">\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.derecha?.length}}\"></ng-container>\n </ng-container>\n </div>\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 <div *ngIf=\"busquedaTipo() && !busquedaCompacta()\" 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 <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 <button matRipple *ngIf=\"busquedaTipo() && busquedaCompacta()\"\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 <button matRipple *ngIf=\"isRecargarUsed || busquedaTipo() == 'query'\"\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\n </button>\n <button matRipple *ngIf=\"mostrarBotonOrden()\"\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 <button matRipple [matMenuTriggerFor]=\"columnFilterMenu\" *ngIf=\"filtroCampos\"\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 </div>\n </div>\n\n <div *ngIf=\"(botonesMenuFinal.secundario ?? []).length > 0\" 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 <ng-container *ngFor=\"let btn of botonesMenu.secundario; let idx = index;\">\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.secundario?.length}}\"></ng-container>\n </ng-container>\n </div>\n </div>\n </div>\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 <ng-container *ngIf=\"esTabla && paginador\">\n {{ (this.paginator?.pageIndex == 0 ? i + 1 : 1 + i + (this.paginator?.pageIndex ?? 1) * (this.paginator?.pageSize ?? 1)) }}\n </ng-container>\n <ng-container *ngIf=\"!paginador\">\n {{ (i + 1) }}\n </ng-container>\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 <ng-container *ngIf=\"!!filaExtraHeader\">\n <tr mat-row *matRowDef=\"let row; columns: ['filaExtraHeader']\" class=\"student-detail-row\"\n [style.height.px]=\"0\"\n ></tr>\n\n <ng-container matColumnDef=\"filaExtraHeader\">\n <td mat-cell *matCellDef=\"let row; let i = dataIndex\" [attr.colspan]=\"visibleColumns.length\">\n\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 <ng-container *ngIf=\"filaExtraHeader.template\"\n [ngTemplateOutlet]=\"filaExtraHeader.template\"\n [ngTemplateOutletContext]=\"{ row: row }\"></ng-container>\n </div>\n\n </td>\n </ng-container>\n </ng-container>\n <ng-container *ngIf=\"filaFooter\">\n <tr *matFooterRowDef=\"visibleColumns\" mat-footer-row\n [style.height.px]=\"0\"\n [id]=\"nombreColeccion + '_filaFooter'\"\n ></tr>\n </ng-container>\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 <ng-container *ngIf=\"filaExtraTemplate\">\n <tr mat-row *matRowDef=\"let row; columns: ['expandedDetail']\" class=\"student-detail-row h-0\"></tr>\n\n <ng-container matColumnDef=\"expandedDetail\">\n <td mat-cell *matCellDef=\"let row\" [attr.colspan]=\"visibleColumns.length\">\n\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\n </td>\n </ng-container>\n </ng-container>\n </table>\n\n <ng-container *ngIf=\"componenteCargadoTotalmente\">\n <div *ngIf=\"(noData | async) && esTabla\" class=\"flex-1 text-center text-secondary font-medium\">\n No se encontraron datos\n </div>\n </ng-container>\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 <div *ngIf=\"(botonesMenuFinal.inferior ?? []).length > 0\" class=\"flex items-center contenedor-botones\">\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 *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 <div *ngIf=\"esTabla && paginador\" 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 </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 <ng-container *ngFor=\"let column of columnasTabla\">\n <button (click)=\"toggleColumnVisibility(column, $event)\" *ngIf=\"!tipoValorFuncion(column.noMostrarEnLista, false)\"\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 </ng-container>\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 <ng-container *ngIf=\"barraSuperior; else noBarraSuperior\">\n\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 <ng-container *ngIf=\"btn.subItems && btn.subItems.length > 0\">\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\n *ngIf=\"(!btn.esVisible || btn.esVisible(item, this)) && subItemsActivos(btn, item)\"\n [class]=\"(btn.class?btn.class:'')\"\n\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\n [matBadge]=\"btn.badge\"\n matBadgeSize=\"small\"\n >\n <mat-icon class=\"icon-xs\" [class.mr-0.5]=\"!(btn.soloIcono ?? tipoValorFuncion(soloIconos))\" *ngIf=\"btn.icono\" [svgIcon]=\"btn.icono\" ></mat-icon>\n <span class=\"whitespace-nowrap\" *ngIf=\"!(btn.soloIcono ?? tipoValorFuncion(soloIconos))\">{{ btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo)) }}</span>\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 </ng-container>\n <ng-container *ngIf=\"!btn.subItems || btn.subItems.length == 0\">\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\n *ngIf=\"!btn.esVisible || btn.esVisible(item, this)\"\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\n [matBadge]=\"btn.badge\"\n matBadgeSize=\"small\"\n >\n <mat-icon class=\"icon-xs\" [class.mr-0.5]=\"!(btn.soloIcono ?? tipoValorFuncion(soloIconos))\" *ngIf=\"btn.icono\" [svgIcon]=\"btn.icono\"></mat-icon>\n <span class=\"whitespace-nowrap\" *ngIf=\"!(btn.soloIcono ?? tipoValorFuncion(soloIconos))\">{{ btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo)) }}</span>\n </button>\n\n </ng-container>\n\n </ng-container>\n <ng-template #noBarraSuperior>\n\n <ng-container *ngIf=\"btn.subItems && btn.subItems.length > 0\">\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 *ngIf=\"!btn.noContextual && (!btn.esVisible || btn.esVisible(item, this))\"\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 <mat-icon *ngIf=\"btn.icono\" [svgIcon]=\"btn.icono\"\n class=\"flex-none icon-xs\"\n ></mat-icon>\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 </ng-container>\n <ng-container *ngIf=\"!btn.subItems || btn.subItems.length == 0\">\n <ng-container *ngIf=\"btn.tipo == '-#SEPARADOR#-'; else itemsNormales\">\n <mat-divider></mat-divider>\n </ng-container>\n <ng-template #itemsNormales>\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 *ngIf=\"!btn.noContextual && (!btn.esVisible || btn.esVisible(item, this))\"\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 <mat-icon *ngIf=\"btn.icono\" [svgIcon]=\"btn.icono\" class=\"flex-none icon-xs\"\n ></mat-icon>\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 </ng-template>\n\n </ng-container>\n\n </ng-template>\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 <ng-container *ngFor=\"let btn of listaMenuCompleto\">\n <ng-container *ngTemplateOutlet=\"botonesContextual; context:{btn: btn, item: objSeleccionado, barraSuperior: false}\"></ng-container>\n </ng-container>\n </div>\n</ng-template>\n\n\n<mat-menu #menuOpciones=\"matMenu\" xPosition=\"before\" yPosition=\"below\">\n <ng-container *ngFor=\"let btn of listaMenuCompleto\">\n <ng-container\n *ngTemplateOutlet=\"botonesContextual; context:{btn: btn, item: objSeleccionado, barraSuperior: false}\"></ng-container>\n </ng-container>\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,.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: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: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.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2$1.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: i2$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: MatCheckboxModule }, { kind: "component", type: i5$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: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatMenuModule }, { kind: "component", type: i2$2.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: i2$2.MatMenuItem, selector: "[mat-menu-item]", inputs: ["role", "disabled", "disableRipple"], exportAs: ["matMenuItem"] }, { kind: "directive", type: i2$2.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.MatRipple, selector: "[mat-ripple], [matRipple]", inputs: ["matRippleColor", "matRippleUnbounded", "matRippleCentered", "matRippleRadius", "matRippleAnimation", "matRippleDisabled", "matRippleTrigger"], exportAs: ["matRipple"] }, { kind: "ngmodule", type: MatSortModule }, { kind: "directive", type: i3$1.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$2.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i2$1.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"] }], animations: [
|
|
1757
1784
|
trigger('detailExpand', [
|
|
1758
1785
|
state('collapsed', style({ height: '0px', minHeight: '0' })),
|
|
1759
1786
|
state('expanded', style({ height: '*' })),
|
|
@@ -1785,6 +1812,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImpo
|
|
|
1785
1812
|
MatDividerModule,
|
|
1786
1813
|
MatIconModule,
|
|
1787
1814
|
MatMenuModule,
|
|
1815
|
+
MatMenuTrigger,
|
|
1788
1816
|
MatPaginatorModule,
|
|
1789
1817
|
MatRippleModule,
|
|
1790
1818
|
MatSortModule,
|
|
@@ -1797,6 +1825,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImpo
|
|
|
1797
1825
|
MatRowKeyboardSelectionDirective,
|
|
1798
1826
|
], host: {
|
|
1799
1827
|
class: 'jvs-tabla-mantenimiento',
|
|
1828
|
+
'[class.h-full]': 'alturaFull()',
|
|
1800
1829
|
}, animations: [
|
|
1801
1830
|
trigger('detailExpand', [
|
|
1802
1831
|
state('collapsed', style({ height: '0px', minHeight: '0' })),
|
|
@@ -1817,8 +1846,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImpo
|
|
|
1817
1846
|
]),
|
|
1818
1847
|
], providers: [
|
|
1819
1848
|
{ provide: MAT_PAGINATOR_DEFAULT_OPTIONS, useValue: { formFieldAppearance: 'outline' } }
|
|
1820
|
-
], template: "<div class=\"flex flex-col h-fit\">\n <div class=\"grow 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\">\n <div class=\"flex-1 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 <div class=\"flex items-center flex-wrap mr-1 h-full\" *ngIf=\"leyenda\">\n <span class=\"font-bold\" [class]=\"leyenda.class\">{{ leyenda.text }}</span>\n </div>\n <div class=\"hidden flex-1 sm:flex items-center flex-wrap gap-1\">\n <div *ngIf=\"(botonesMenuFinal.izquierda ?? []).length > 0 \" class=\" flex items-center flex-wrap contenedor-botones\">\n <ng-container *ngFor=\"let btn of botonesMenu.izquierda; let idx = index;\">\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.izquierda?.length}}\"></ng-container>\n </ng-container>\n </div>\n\n <div *ngIf=\"(botonesMenuFinal.crud ?? []).length > 0\" class=\" flex items-center flex-wrap contenedor-botones\">\n <ng-container *ngFor=\"let btn of botonesMenu.crud; let idx = index;\">\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.crud?.length}}\"></ng-container>\n </ng-container>\n </div>\n\n <div *ngIf=\"(botonesMenuFinal.principal ?? []).length > 0\" class=\" flex items-center flex-wrap contenedor-botones\">\n <ng-container *ngFor=\"let btn of botonesMenu.principal; let idx = index;\">\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.principal?.length}}\"></ng-container>\n </ng-container>\n </div>\n\n <div *ngIf=\"(botonesMenuFinal.derecha ?? []).length > 0\" class=\"flex-auto flex items-center justify-end contenedor-botones\">\n <ng-container *ngFor=\"let btn of botonesMenu.derecha; let idx = index;\">\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.derecha?.length}}\"></ng-container>\n </ng-container>\n </div>\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 <div *ngIf=\"ctrlBusqueda\" 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]=\"ctrlBusquedaPlaceholder\"\n (keyup.enter)=\"ctrlBusqueda == 'query' ? cargarData() : false;\"\n type=\"search\">\n </div>\n <div class=\"flex-none flex items-center justify-end border-l-2\">\n <ng-content select=\"[botonesFiltro]\"></ng-content>\n <button matRipple *ngIf=\"isRecargarUsed || ctrlBusqueda == 'query'\"\n class=\"flex items-center justify-center text-2xs leading-none rounded-full p-1 text-green-700\"\n matTooltip=\"Actualizar datos\"\n (click)=\"(ctrlBusqueda == 'query' ? cargarData() : emitirAccionRecargar())\"\n type=\"button\">\n <mat-icon svgIcon=\"roundRefresh\" class=\"icon-xs\"></mat-icon>\n\n </button>\n <button matRipple [matMenuTriggerFor]=\"columnFilterMenu\" *ngIf=\"filtroCampos\"\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 </div>\n </div>\n\n <div *ngIf=\"(botonesMenuFinal.secundario ?? []).length > 0\" 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 <ng-container *ngFor=\"let btn of botonesMenu.secundario; let idx = index;\">\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.secundario?.length}}\"></ng-container>\n </ng-container>\n </div>\n </div>\n </div>\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=\"flex-1 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 <ng-container *ngIf=\"esTabla && paginador\">\n {{ (this.paginator?.pageIndex == 0 ? i + 1 : 1 + i + (this.paginator?.pageIndex ?? 1) * (this.paginator?.pageSize ?? 1)) }}\n </ng-container>\n <ng-container *ngIf=\"!paginador\">\n {{ (i + 1) }}\n </ng-container>\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 <ng-container *ngIf=\"!!filaExtraHeader\">\n <tr mat-row *matRowDef=\"let row; columns: ['filaExtraHeader']\" class=\"student-detail-row\"\n [style.height.px]=\"0\"\n ></tr>\n\n <ng-container matColumnDef=\"filaExtraHeader\">\n <td mat-cell *matCellDef=\"let row; let i = dataIndex\" [attr.colspan]=\"visibleColumns.length\">\n\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 <ng-container *ngIf=\"filaExtraHeader.template\"\n [ngTemplateOutlet]=\"filaExtraHeader.template\"\n [ngTemplateOutletContext]=\"{ row: row }\"></ng-container>\n </div>\n\n </td>\n </ng-container>\n </ng-container>\n <ng-container *ngIf=\"filaFooter\">\n <tr *matFooterRowDef=\"visibleColumns\" mat-footer-row\n [style.height.px]=\"0\"\n [id]=\"nombreColeccion + '_filaFooter'\"\n ></tr>\n </ng-container>\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 <ng-container *ngIf=\"filaExtraTemplate\">\n <tr mat-row *matRowDef=\"let row; columns: ['expandedDetail']\" class=\"student-detail-row h-0\"></tr>\n\n <ng-container matColumnDef=\"expandedDetail\">\n <td mat-cell *matCellDef=\"let row\" [attr.colspan]=\"visibleColumns.length\">\n\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\n </td>\n </ng-container>\n </ng-container>\n </table>\n\n <ng-container *ngIf=\"componenteCargadoTotalmente\">\n <div *ngIf=\"(noData | async) && esTabla\" class=\"flex-1 text-center text-secondary font-medium\">\n No se encontraron datos\n </div>\n </ng-container>\n </div>\n <ng-content select=\"[appendTable]\"></ng-content>\n <div class=\"flex-1 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 <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 <div *ngIf=\"esTabla && paginador\" 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 </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 <ng-container *ngFor=\"let column of columnasTabla\">\n <button (click)=\"toggleColumnVisibility(column, $event)\" *ngIf=\"!tipoValorFuncion(column.noMostrarEnLista, false)\"\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 </ng-container>\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 <ng-container *ngIf=\"barraSuperior; else noBarraSuperior\">\n\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 <ng-container *ngIf=\"btn.subItems && btn.subItems.length > 0\">\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\n *ngIf=\"(!btn.esVisible || btn.esVisible(item, this)) && subItemsActivos(btn, item)\"\n [class]=\"(btn.class?btn.class:'')\"\n\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\n [matBadge]=\"btn.badge\"\n matBadgeSize=\"small\"\n >\n <mat-icon class=\"icon-xs\" [class.mr-0.5]=\"!(btn.soloIcono ?? tipoValorFuncion(soloIconos))\" *ngIf=\"btn.icono\" [svgIcon]=\"btn.icono\" ></mat-icon>\n <span class=\"whitespace-nowrap\" *ngIf=\"!(btn.soloIcono ?? tipoValorFuncion(soloIconos))\">{{ btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo)) }}</span>\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 </ng-container>\n <ng-container *ngIf=\"!btn.subItems || btn.subItems.length == 0\">\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\n *ngIf=\"!btn.esVisible || btn.esVisible(item, this)\"\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\n [matBadge]=\"btn.badge\"\n matBadgeSize=\"small\"\n >\n <mat-icon class=\"icon-xs\" [class.mr-0.5]=\"!(btn.soloIcono ?? tipoValorFuncion(soloIconos))\" *ngIf=\"btn.icono\" [svgIcon]=\"btn.icono\"></mat-icon>\n <span class=\"whitespace-nowrap\" *ngIf=\"!(btn.soloIcono ?? tipoValorFuncion(soloIconos))\">{{ btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo)) }}</span>\n </button>\n\n </ng-container>\n\n </ng-container>\n <ng-template #noBarraSuperior>\n\n <ng-container *ngIf=\"btn.subItems && btn.subItems.length > 0\">\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 *ngIf=\"!btn.noContextual && (!btn.esVisible || btn.esVisible(item, this))\"\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 <mat-icon *ngIf=\"btn.icono\" [svgIcon]=\"btn.icono\"\n class=\"flex-none icon-xs\"\n ></mat-icon>\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 </ng-container>\n <ng-container *ngIf=\"!btn.subItems || btn.subItems.length == 0\">\n <ng-container *ngIf=\"btn.tipo == '-#SEPARADOR#-'; else itemsNormales\">\n <mat-divider></mat-divider>\n </ng-container>\n <ng-template #itemsNormales>\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 *ngIf=\"!btn.noContextual && (!btn.esVisible || btn.esVisible(item, this))\"\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 <mat-icon *ngIf=\"btn.icono\" [svgIcon]=\"btn.icono\" class=\"flex-none icon-xs\"\n ></mat-icon>\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 </ng-template>\n\n </ng-container>\n\n </ng-template>\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 <ng-container *ngFor=\"let btn of listaMenuCompleto\">\n <ng-container *ngTemplateOutlet=\"botonesContextual; context:{btn: btn, item: objSeleccionado, barraSuperior: false}\"></ng-container>\n </ng-container>\n </div>\n</ng-template>\n\n\n<mat-menu #menuOpciones=\"matMenu\" xPosition=\"before\" yPosition=\"below\">\n <ng-container *ngFor=\"let btn of listaMenuCompleto\">\n <ng-container\n *ngTemplateOutlet=\"botonesContextual; context:{btn: btn, item: objSeleccionado, barraSuperior: false}\"></ng-container>\n </ng-container>\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}.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-container{max-height:600px!important}.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,.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: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: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}\n"] }]
|
|
1821
|
-
}], ctorParameters: () => [{ type:
|
|
1849
|
+
], 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 <div class=\"flex items-center flex-wrap mr-1 h-full\" *ngIf=\"leyenda\">\n <span class=\"font-bold\" [class]=\"leyenda.class\">{{ leyenda.text }}</span>\n </div>\n <div class=\"hidden flex-1 sm:flex items-center flex-wrap gap-1\">\n <div *ngIf=\"(botonesMenuFinal.izquierda ?? []).length > 0 \" class=\" flex items-center flex-wrap contenedor-botones\">\n <ng-container *ngFor=\"let btn of botonesMenu.izquierda; let idx = index;\">\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.izquierda?.length}}\"></ng-container>\n </ng-container>\n </div>\n\n <div *ngIf=\"(botonesMenuFinal.crud ?? []).length > 0\" class=\" flex items-center flex-wrap contenedor-botones\">\n <ng-container *ngFor=\"let btn of botonesMenu.crud; let idx = index;\">\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.crud?.length}}\"></ng-container>\n </ng-container>\n </div>\n\n <div *ngIf=\"(botonesMenuFinal.principal ?? []).length > 0\" class=\" flex items-center flex-wrap contenedor-botones\">\n <ng-container *ngFor=\"let btn of botonesMenu.principal; let idx = index;\">\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.principal?.length}}\"></ng-container>\n </ng-container>\n </div>\n\n <div *ngIf=\"(botonesMenuFinal.derecha ?? []).length > 0\" class=\"flex-auto flex items-center justify-end contenedor-botones\">\n <ng-container *ngFor=\"let btn of botonesMenu.derecha; let idx = index;\">\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.derecha?.length}}\"></ng-container>\n </ng-container>\n </div>\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 <div *ngIf=\"busquedaTipo() && !busquedaCompacta()\" 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 <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 <button matRipple *ngIf=\"busquedaTipo() && busquedaCompacta()\"\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 <button matRipple *ngIf=\"isRecargarUsed || busquedaTipo() == 'query'\"\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\n </button>\n <button matRipple *ngIf=\"mostrarBotonOrden()\"\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 <button matRipple [matMenuTriggerFor]=\"columnFilterMenu\" *ngIf=\"filtroCampos\"\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 </div>\n </div>\n\n <div *ngIf=\"(botonesMenuFinal.secundario ?? []).length > 0\" 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 <ng-container *ngFor=\"let btn of botonesMenu.secundario; let idx = index;\">\n <ng-container *ngTemplateOutlet=\"botonesSuperiores; context:{btn: btn, idx: {inicio: idx, fin: botonesMenu.secundario?.length}}\"></ng-container>\n </ng-container>\n </div>\n </div>\n </div>\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 <ng-container *ngIf=\"esTabla && paginador\">\n {{ (this.paginator?.pageIndex == 0 ? i + 1 : 1 + i + (this.paginator?.pageIndex ?? 1) * (this.paginator?.pageSize ?? 1)) }}\n </ng-container>\n <ng-container *ngIf=\"!paginador\">\n {{ (i + 1) }}\n </ng-container>\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 <ng-container *ngIf=\"!!filaExtraHeader\">\n <tr mat-row *matRowDef=\"let row; columns: ['filaExtraHeader']\" class=\"student-detail-row\"\n [style.height.px]=\"0\"\n ></tr>\n\n <ng-container matColumnDef=\"filaExtraHeader\">\n <td mat-cell *matCellDef=\"let row; let i = dataIndex\" [attr.colspan]=\"visibleColumns.length\">\n\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 <ng-container *ngIf=\"filaExtraHeader.template\"\n [ngTemplateOutlet]=\"filaExtraHeader.template\"\n [ngTemplateOutletContext]=\"{ row: row }\"></ng-container>\n </div>\n\n </td>\n </ng-container>\n </ng-container>\n <ng-container *ngIf=\"filaFooter\">\n <tr *matFooterRowDef=\"visibleColumns\" mat-footer-row\n [style.height.px]=\"0\"\n [id]=\"nombreColeccion + '_filaFooter'\"\n ></tr>\n </ng-container>\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 <ng-container *ngIf=\"filaExtraTemplate\">\n <tr mat-row *matRowDef=\"let row; columns: ['expandedDetail']\" class=\"student-detail-row h-0\"></tr>\n\n <ng-container matColumnDef=\"expandedDetail\">\n <td mat-cell *matCellDef=\"let row\" [attr.colspan]=\"visibleColumns.length\">\n\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\n </td>\n </ng-container>\n </ng-container>\n </table>\n\n <ng-container *ngIf=\"componenteCargadoTotalmente\">\n <div *ngIf=\"(noData | async) && esTabla\" class=\"flex-1 text-center text-secondary font-medium\">\n No se encontraron datos\n </div>\n </ng-container>\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 <div *ngIf=\"(botonesMenuFinal.inferior ?? []).length > 0\" class=\"flex items-center contenedor-botones\">\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 *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 <div *ngIf=\"esTabla && paginador\" 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 </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 <ng-container *ngFor=\"let column of columnasTabla\">\n <button (click)=\"toggleColumnVisibility(column, $event)\" *ngIf=\"!tipoValorFuncion(column.noMostrarEnLista, false)\"\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 </ng-container>\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 <ng-container *ngIf=\"barraSuperior; else noBarraSuperior\">\n\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 <ng-container *ngIf=\"btn.subItems && btn.subItems.length > 0\">\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\n *ngIf=\"(!btn.esVisible || btn.esVisible(item, this)) && subItemsActivos(btn, item)\"\n [class]=\"(btn.class?btn.class:'')\"\n\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\n [matBadge]=\"btn.badge\"\n matBadgeSize=\"small\"\n >\n <mat-icon class=\"icon-xs\" [class.mr-0.5]=\"!(btn.soloIcono ?? tipoValorFuncion(soloIconos))\" *ngIf=\"btn.icono\" [svgIcon]=\"btn.icono\" ></mat-icon>\n <span class=\"whitespace-nowrap\" *ngIf=\"!(btn.soloIcono ?? tipoValorFuncion(soloIconos))\">{{ btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo)) }}</span>\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 </ng-container>\n <ng-container *ngIf=\"!btn.subItems || btn.subItems.length == 0\">\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\n *ngIf=\"!btn.esVisible || btn.esVisible(item, this)\"\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\n [matBadge]=\"btn.badge\"\n matBadgeSize=\"small\"\n >\n <mat-icon class=\"icon-xs\" [class.mr-0.5]=\"!(btn.soloIcono ?? tipoValorFuncion(soloIconos))\" *ngIf=\"btn.icono\" [svgIcon]=\"btn.icono\"></mat-icon>\n <span class=\"whitespace-nowrap\" *ngIf=\"!(btn.soloIcono ?? tipoValorFuncion(soloIconos))\">{{ btn.label ? btn.label : ( (derechosActuales && derechosActuales[btn.cDerechoCodigo ?? btn.tipo]) ? derechosActuales[btn.cDerechoCodigo ?? btn.tipo]['cDerechoNombre'] : capitalizarTexto(btn.tipo)) }}</span>\n </button>\n\n </ng-container>\n\n </ng-container>\n <ng-template #noBarraSuperior>\n\n <ng-container *ngIf=\"btn.subItems && btn.subItems.length > 0\">\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 *ngIf=\"!btn.noContextual && (!btn.esVisible || btn.esVisible(item, this))\"\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 <mat-icon *ngIf=\"btn.icono\" [svgIcon]=\"btn.icono\"\n class=\"flex-none icon-xs\"\n ></mat-icon>\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 </ng-container>\n <ng-container *ngIf=\"!btn.subItems || btn.subItems.length == 0\">\n <ng-container *ngIf=\"btn.tipo == '-#SEPARADOR#-'; else itemsNormales\">\n <mat-divider></mat-divider>\n </ng-container>\n <ng-template #itemsNormales>\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 *ngIf=\"!btn.noContextual && (!btn.esVisible || btn.esVisible(item, this))\"\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 <mat-icon *ngIf=\"btn.icono\" [svgIcon]=\"btn.icono\" class=\"flex-none icon-xs\"\n ></mat-icon>\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 </ng-template>\n\n </ng-container>\n\n </ng-template>\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 <ng-container *ngFor=\"let btn of listaMenuCompleto\">\n <ng-container *ngTemplateOutlet=\"botonesContextual; context:{btn: btn, item: objSeleccionado, barraSuperior: false}\"></ng-container>\n </ng-container>\n </div>\n</ng-template>\n\n\n<mat-menu #menuOpciones=\"matMenu\" xPosition=\"before\" yPosition=\"below\">\n <ng-container *ngFor=\"let btn of listaMenuCompleto\">\n <ng-container\n *ngTemplateOutlet=\"botonesContextual; context:{btn: btn, item: objSeleccionado, barraSuperior: false}\"></ng-container>\n </ng-container>\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,.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: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: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"] }]
|
|
1850
|
+
}], ctorParameters: () => [{ type: i2$1.FormBuilder }, { type: i2$3.Overlay }, { type: i0.ViewContainerRef }, { type: TablaMantenimientoService }, { type: i0.ChangeDetectorRef }], propDecorators: { id: [{
|
|
1822
1851
|
type: HostBinding
|
|
1823
1852
|
}], dataSuscription: [{
|
|
1824
1853
|
type: Input
|
|
@@ -1828,10 +1857,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImpo
|
|
|
1828
1857
|
}], nombreColeccion: [{
|
|
1829
1858
|
type: Input,
|
|
1830
1859
|
args: [{ required: true }]
|
|
1831
|
-
}], ctrlBusquedaValue: [{
|
|
1832
|
-
type: Input
|
|
1833
|
-
}], ctrlBusquedaPlaceholder: [{
|
|
1834
|
-
type: Input
|
|
1835
1860
|
}], filtroCampos: [{
|
|
1836
1861
|
type: Input
|
|
1837
1862
|
}], paginador: [{
|
|
@@ -1903,8 +1928,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImpo
|
|
|
1903
1928
|
}], userMenu: [{
|
|
1904
1929
|
type: ViewChild,
|
|
1905
1930
|
args: ['userMenu']
|
|
1906
|
-
}],
|
|
1907
|
-
type:
|
|
1931
|
+
}], compactSearchMenuTrigger: [{
|
|
1932
|
+
type: ViewChild,
|
|
1933
|
+
args: ['compactSearchMenuTrigger', { read: MatMenuTrigger }]
|
|
1908
1934
|
}], leyenda: [{
|
|
1909
1935
|
type: Input
|
|
1910
1936
|
}], idTabla: [{
|
|
@@ -1953,6 +1979,8 @@ class MatSuffixSearchButtonComponent {
|
|
|
1953
1979
|
return this.fControl;
|
|
1954
1980
|
}
|
|
1955
1981
|
emitirClick() {
|
|
1982
|
+
if (this.control.disabled)
|
|
1983
|
+
return;
|
|
1956
1984
|
if (this.control.value) {
|
|
1957
1985
|
this.control.reset();
|
|
1958
1986
|
this.eventLimpiar.emit(true);
|
|
@@ -1962,7 +1990,7 @@ class MatSuffixSearchButtonComponent {
|
|
|
1962
1990
|
}
|
|
1963
1991
|
}
|
|
1964
1992
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: MatSuffixSearchButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1965
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
|
|
1993
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.14", type: MatSuffixSearchButtonComponent, isStandalone: true, selector: "div[matSuffix][matSuffixSearchButton]", inputs: { fControl: "fControl" }, outputs: { eventLimpiar: "eventLimpiar", eventBuscar: "eventBuscar" }, host: { classAttribute: "flex items-center justify-start" }, ngImport: i0, template: "@if (!control.disabled) {\n <button matRipple type=\"button\" class=\"boton-circular-gris\"\n (click)=\"emitirClick(); $event.preventDefault();\"\n >\n <mat-icon [svgIcon]=\"(control.value ? 'roundCancel' : 'roundSearch')\" class=\"icon-xs\"></mat-icon>\n </button>\n}\n", dependencies: [{ kind: "directive", type: MatRipple, selector: "[mat-ripple], [matRipple]", inputs: ["matRippleColor", "matRippleUnbounded", "matRippleCentered", "matRippleRadius", "matRippleAnimation", "matRippleDisabled", "matRippleTrigger"], exportAs: ["matRipple"] }, { kind: "component", type: MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }] });
|
|
1966
1994
|
}
|
|
1967
1995
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: MatSuffixSearchButtonComponent, decorators: [{
|
|
1968
1996
|
type: Component,
|
|
@@ -1971,7 +1999,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImpo
|
|
|
1971
1999
|
MatIcon
|
|
1972
2000
|
], host: {
|
|
1973
2001
|
class: 'flex items-center justify-start',
|
|
1974
|
-
}, template: "<button matRipple type=\"button\" class=\"boton-circular-gris\"\n
|
|
2002
|
+
}, template: "@if (!control.disabled) {\n <button matRipple type=\"button\" class=\"boton-circular-gris\"\n (click)=\"emitirClick(); $event.preventDefault();\"\n >\n <mat-icon [svgIcon]=\"(control.value ? 'roundCancel' : 'roundSearch')\" class=\"icon-xs\"></mat-icon>\n </button>\n}\n" }]
|
|
1975
2003
|
}], propDecorators: { fControl: [{
|
|
1976
2004
|
type: Input,
|
|
1977
2005
|
args: [{ required: true }]
|
|
@@ -2036,7 +2064,7 @@ class MenuComponent {
|
|
|
2036
2064
|
});
|
|
2037
2065
|
}
|
|
2038
2066
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: MenuComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
2039
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: MenuComponent, isStandalone: true, selector: "jvs-menu", inputs: { cssBoton: "cssBoton", title: "title", disabled: "disabled", itemSeleccion: "itemSeleccion", menu: "menu" }, outputs: { action: "action" }, viewQueries: [{ propertyName: "matmenus", predicate: MatMenu, descendants: true }], ngImport: i0, template: "<ng-container *ngIf=\"yet\">\n <button matRipple [matMenuTriggerFor]=\"matmenus.first\"\n [disabled]=\"disabled\"\n type=\"button\" [class]=\"cssBoton ?? 'boton-circular boton-circular-red border-0'\"\n (click)=\"$event.preventDefault(); $event.stopImmediatePropagation()\"\n [matTooltip]=\"title\"\n >\n <ng-content></ng-content>\n </button>\n</ng-container>\n\n<!--<pre class=\"text-indigo-900\">{{_submenus | json}}</pre>-->\n<ng-container *ngFor=\"let menu of _submenus\">\n <!--<pre class=\"text-red-700\">{{menu | json}}</pre>-->\n <mat-menu xPosition=\"before\" yPosition=\"below\" class=\"max-w-none\">\n <ng-container *ngFor=\"let item of menu\">\n <!--<pre *ngIf=\"menu$\" class=\"text-orange-700\">{{item | json}}</pre>-->\n <!--<span>{{ [item.label, item.idxOpcionCalc!=-1 , yet , (!item.esVisible || item.esVisible({itemMenu: item, archivo: itemSeleccion})), [!item.esVisible , (item.esVisible ? item.esVisible({itemMenu: item, archivo: itemSeleccion}) : 'NO HAY')]] | json }}</span>-->\n <button mat-menu-item *ngIf=\"item.idxOpcionCalc!=-1 && yet && (!item.esVisible || item.esVisible({itemMenu: item, archivo: itemSeleccion}))\"\n class=\"flex items-center justify-items-center uppercase w-full rounded-none px-2 \"\n [matMenuTriggerFor]=\"getMenu(item.idxOpcionCalc)\">\n <mat-icon *ngIf=\"item.icono\"\n class=\"flex-none flex items-center justify-center !text-red-700 !mr-1 icon-2xs\"\n [svgIcon]=\"item.icono ?? 'fa5sFileSignature'\"\n ></mat-icon>\n <span class=\"grow text-2xs\" [innerHTML]=\"item.label\">{{item.label}}</span>\n </button>\n <button mat-menu-item *ngIf=\"item.idxOpcionCalc==-1 && (!item.esVisible || item.esVisible(item))\" (click)=\"onClick(item.valorSeleccion)\"\n class=\"flex items-center justify-items-center uppercase w-full rounded-none px-2 \"\n >\n <mat-icon *ngIf=\"item.icono\"\n class=\"flex-none flex items-center justify-center !text-red-700 !mr-1 icon-2xs\"\n [svgIcon]=\"item.icono ?? 'fa5sFileSignature'\"\n ></mat-icon>\n <span class=\"grow text-2xs\" [innerHTML]=\"item.label\">{{item.label}} </span>\n </button>\n\n </ng-container>\n </mat-menu>\n</ng-container>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: MatMenuModule }, { kind: "component", type: i2$
|
|
2067
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: MenuComponent, isStandalone: true, selector: "jvs-menu", inputs: { cssBoton: "cssBoton", title: "title", disabled: "disabled", itemSeleccion: "itemSeleccion", menu: "menu" }, outputs: { action: "action" }, viewQueries: [{ propertyName: "matmenus", predicate: MatMenu, descendants: true }], ngImport: i0, template: "<ng-container *ngIf=\"yet\">\n <button matRipple [matMenuTriggerFor]=\"matmenus.first\"\n [disabled]=\"disabled\"\n type=\"button\" [class]=\"cssBoton ?? 'boton-circular boton-circular-red border-0'\"\n (click)=\"$event.preventDefault(); $event.stopImmediatePropagation()\"\n [matTooltip]=\"title\"\n >\n <ng-content></ng-content>\n </button>\n</ng-container>\n\n<!--<pre class=\"text-indigo-900\">{{_submenus | json}}</pre>-->\n<ng-container *ngFor=\"let menu of _submenus\">\n <!--<pre class=\"text-red-700\">{{menu | json}}</pre>-->\n <mat-menu xPosition=\"before\" yPosition=\"below\" class=\"max-w-none\">\n <ng-container *ngFor=\"let item of menu\">\n <!--<pre *ngIf=\"menu$\" class=\"text-orange-700\">{{item | json}}</pre>-->\n <!--<span>{{ [item.label, item.idxOpcionCalc!=-1 , yet , (!item.esVisible || item.esVisible({itemMenu: item, archivo: itemSeleccion})), [!item.esVisible , (item.esVisible ? item.esVisible({itemMenu: item, archivo: itemSeleccion}) : 'NO HAY')]] | json }}</span>-->\n <button mat-menu-item *ngIf=\"item.idxOpcionCalc!=-1 && yet && (!item.esVisible || item.esVisible({itemMenu: item, archivo: itemSeleccion}))\"\n class=\"flex items-center justify-items-center uppercase w-full rounded-none px-2 \"\n [matMenuTriggerFor]=\"getMenu(item.idxOpcionCalc)\">\n <mat-icon *ngIf=\"item.icono\"\n class=\"flex-none flex items-center justify-center !text-red-700 !mr-1 icon-2xs\"\n [svgIcon]=\"item.icono ?? 'fa5sFileSignature'\"\n ></mat-icon>\n <span class=\"grow text-2xs\" [innerHTML]=\"item.label\">{{item.label}}</span>\n </button>\n <button mat-menu-item *ngIf=\"item.idxOpcionCalc==-1 && (!item.esVisible || item.esVisible(item))\" (click)=\"onClick(item.valorSeleccion)\"\n class=\"flex items-center justify-items-center uppercase w-full rounded-none px-2 \"\n >\n <mat-icon *ngIf=\"item.icono\"\n class=\"flex-none flex items-center justify-center !text-red-700 !mr-1 icon-2xs\"\n [svgIcon]=\"item.icono ?? 'fa5sFileSignature'\"\n ></mat-icon>\n <span class=\"grow text-2xs\" [innerHTML]=\"item.label\">{{item.label}} </span>\n </button>\n\n </ng-container>\n </mat-menu>\n</ng-container>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: MatMenuModule }, { kind: "component", type: i2$2.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: i2$2.MatMenuItem, selector: "[mat-menu-item]", inputs: ["role", "disabled", "disableRipple"], exportAs: ["matMenuItem"] }, { kind: "directive", type: i2$2.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: MatIconModule }, { kind: "component", type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatRippleModule }, { kind: "directive", type: i5.MatRipple, selector: "[mat-ripple], [matRipple]", inputs: ["matRippleColor", "matRippleUnbounded", "matRippleCentered", "matRippleRadius", "matRippleAnimation", "matRippleDisabled", "matRippleTrigger"], exportAs: ["matRipple"] }, { kind: "ngmodule", type: MatTooltipModule }, { kind: "directive", type: i4$2.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }] });
|
|
2040
2068
|
}
|
|
2041
2069
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: MenuComponent, decorators: [{
|
|
2042
2070
|
type: Component,
|
|
@@ -2094,77 +2122,94 @@ function generarArbol(params) {
|
|
|
2094
2122
|
}
|
|
2095
2123
|
|
|
2096
2124
|
class ListaArbolComponent {
|
|
2097
|
-
|
|
2098
|
-
|
|
2099
|
-
|
|
2100
|
-
|
|
2101
|
-
|
|
2102
|
-
|
|
2103
|
-
|
|
2104
|
-
|
|
2105
|
-
|
|
2106
|
-
|
|
2107
|
-
|
|
2108
|
-
|
|
2109
|
-
|
|
2110
|
-
|
|
2111
|
-
|
|
2112
|
-
|
|
2113
|
-
|
|
2114
|
-
|
|
2115
|
-
|
|
2116
|
-
|
|
2117
|
-
|
|
2118
|
-
|
|
2119
|
-
|
|
2120
|
-
|
|
2121
|
-
|
|
2122
|
-
|
|
2123
|
-
|
|
2124
|
-
|
|
2125
|
-
|
|
2126
|
-
if (Array.isArray(val)) {
|
|
2127
|
-
this._idTabla = val;
|
|
2128
|
-
}
|
|
2129
|
-
else {
|
|
2130
|
-
this._idTabla.push(val);
|
|
2125
|
+
// Inputs
|
|
2126
|
+
listaSuscription = input.required();
|
|
2127
|
+
nombreColeccion = input.required();
|
|
2128
|
+
checkbox = input(false);
|
|
2129
|
+
expandirRecursivo = input(false);
|
|
2130
|
+
checkboxSeleccionados = input([]);
|
|
2131
|
+
campoId = input.required();
|
|
2132
|
+
campoIdPadre = input.required();
|
|
2133
|
+
campoStr = input(''); // Optional - can use templateTxtData instead
|
|
2134
|
+
campoOrden = input();
|
|
2135
|
+
strHijoContainer = input('hijos');
|
|
2136
|
+
menuContextual = input();
|
|
2137
|
+
classSeleccionado = input(['bg-primary-activo', 'text-primary', 'dark:!bg-primary-dark-activo']);
|
|
2138
|
+
classAnulado = input(['line-through', 'text-red', 'italic']);
|
|
2139
|
+
campoAnulado = input();
|
|
2140
|
+
templateTxtData = input();
|
|
2141
|
+
condicionMostrar = input();
|
|
2142
|
+
condicionesClaseFila = input(() => []);
|
|
2143
|
+
// idTabla input with transform to support both string and string[]
|
|
2144
|
+
idTabla = input.required({
|
|
2145
|
+
transform: (val) => {
|
|
2146
|
+
if (Array.isArray(val)) {
|
|
2147
|
+
this._idTabla.set(val);
|
|
2148
|
+
return val;
|
|
2149
|
+
}
|
|
2150
|
+
else {
|
|
2151
|
+
this._idTabla.update(current => [...current, val]);
|
|
2152
|
+
return [val];
|
|
2153
|
+
}
|
|
2131
2154
|
}
|
|
2132
|
-
}
|
|
2133
|
-
|
|
2134
|
-
|
|
2135
|
-
|
|
2136
|
-
|
|
2137
|
-
|
|
2138
|
-
|
|
2139
|
-
|
|
2140
|
-
|
|
2141
|
-
|
|
2142
|
-
|
|
2155
|
+
});
|
|
2156
|
+
// selectionModel input for backward compatibility
|
|
2157
|
+
selectionModel = input();
|
|
2158
|
+
// Outputs
|
|
2159
|
+
selectionModelChange = output();
|
|
2160
|
+
seleccionado = output();
|
|
2161
|
+
listaCheck = output();
|
|
2162
|
+
listaCheckObj = output();
|
|
2163
|
+
// Internal state as signals
|
|
2164
|
+
_idTabla = signal([]);
|
|
2165
|
+
_seleccionado = signal(null);
|
|
2166
|
+
listaMuestraArbol = signal([]);
|
|
2167
|
+
listaOriginal = signal([]);
|
|
2143
2168
|
chkLista = new DataModel$1();
|
|
2144
|
-
|
|
2145
|
-
|
|
2146
|
-
|
|
2147
|
-
|
|
2148
|
-
|
|
2149
|
-
|
|
2169
|
+
// Computed values
|
|
2170
|
+
idTablaValue = computed(() => this._idTabla());
|
|
2171
|
+
buscarItemSeleccionado = computed(() => {
|
|
2172
|
+
const selId = this._seleccionado();
|
|
2173
|
+
const lista = this.listaOriginal();
|
|
2174
|
+
if (!selId)
|
|
2175
|
+
return null;
|
|
2176
|
+
return lista.find(itm => selId === this.propiedadSeleccion(itm)) ?? null;
|
|
2177
|
+
});
|
|
2178
|
+
objSeleccionado = computed(() => this.buscarItemSeleccionado());
|
|
2179
|
+
treeControl = new NestedTreeControl((node) => node[this.strHijoContainer()]);
|
|
2180
|
+
// Convert signal to observable for proper subscription management
|
|
2181
|
+
listaSuscription$ = toObservable(this.listaSuscription);
|
|
2182
|
+
constructor() {
|
|
2183
|
+
// Watch selectionModel input for backward compatibility
|
|
2184
|
+
effect(() => {
|
|
2185
|
+
const selModel = this.selectionModel();
|
|
2186
|
+
if (selModel) {
|
|
2187
|
+
untracked(() => this.seleccionarItem(selModel, true));
|
|
2188
|
+
}
|
|
2189
|
+
});
|
|
2190
|
+
// Setup subscription with automatic cleanup using switchMap
|
|
2191
|
+
// switchMap automatically unsubscribes from previous observable when a new one arrives
|
|
2192
|
+
this.listaSuscription$
|
|
2193
|
+
.pipe(switchMap(obs => obs), takeUntilDestroyed())
|
|
2194
|
+
.subscribe(res => {
|
|
2150
2195
|
if (res) {
|
|
2151
|
-
this.listaOriginal
|
|
2196
|
+
this.listaOriginal.set(res);
|
|
2152
2197
|
const listaAs = generarArbol({
|
|
2153
2198
|
lista: res,
|
|
2154
|
-
campoId: this.campoId,
|
|
2155
|
-
campoIdPadre: this.campoIdPadre,
|
|
2199
|
+
campoId: this.campoId(),
|
|
2200
|
+
campoIdPadre: this.campoIdPadre(),
|
|
2156
2201
|
idPadre: null,
|
|
2157
|
-
strChildren: this.strHijoContainer,
|
|
2158
|
-
campoOrden: this.campoOrden
|
|
2202
|
+
strChildren: this.strHijoContainer(),
|
|
2203
|
+
campoOrden: this.campoOrden(),
|
|
2204
|
+
});
|
|
2205
|
+
// Use untracked to avoid unnecessary re-renders
|
|
2206
|
+
untracked(() => {
|
|
2207
|
+
this.listaMuestraArbol.set(listaAs);
|
|
2159
2208
|
});
|
|
2160
|
-
this.
|
|
2161
|
-
|
|
2162
|
-
this.
|
|
2163
|
-
|
|
2164
|
-
if (this.checkbox) {
|
|
2165
|
-
this.chkLista.agregarControles(res, this.campoId);
|
|
2166
|
-
this.checkboxSeleccionados.forEach((chkSel) => {
|
|
2167
|
-
this.chkLista.setState(chkSel[this.campoId], true);
|
|
2209
|
+
if (this.checkbox()) {
|
|
2210
|
+
this.chkLista.agregarControles(res, this.campoId());
|
|
2211
|
+
this.checkboxSeleccionados().forEach((chkSel) => {
|
|
2212
|
+
this.chkLista.setState(chkSel[this.campoId()], true);
|
|
2168
2213
|
});
|
|
2169
2214
|
this.emitirModeloCheck();
|
|
2170
2215
|
}
|
|
@@ -2173,47 +2218,50 @@ class ListaArbolComponent {
|
|
|
2173
2218
|
}
|
|
2174
2219
|
idTablaValor(data) {
|
|
2175
2220
|
if (data) {
|
|
2176
|
-
|
|
2221
|
+
const idTablaVal = this._idTabla();
|
|
2222
|
+
if (idTablaVal.length < 1) {
|
|
2177
2223
|
return shortHash(JSON.stringify({ data, claseFinal: undefined }));
|
|
2178
2224
|
}
|
|
2179
|
-
return
|
|
2225
|
+
return idTablaVal.map(d => data[d]).join('-');
|
|
2180
2226
|
}
|
|
2181
2227
|
return '';
|
|
2182
2228
|
}
|
|
2183
2229
|
propiedadSeleccion(item) {
|
|
2184
|
-
return `${this.nombreColeccion}_${this.idTablaValor(item)}`;
|
|
2230
|
+
return `${this.nombreColeccion()}_${this.idTablaValor(item)}`;
|
|
2185
2231
|
}
|
|
2186
2232
|
esSeleccionActual(item) {
|
|
2187
|
-
return this._seleccionado === this.propiedadSeleccion(item);
|
|
2233
|
+
return this._seleccionado() === this.propiedadSeleccion(item);
|
|
2188
2234
|
}
|
|
2189
2235
|
seleccionarItem(item, forzado = false) {
|
|
2190
2236
|
const idItem = this.propiedadSeleccion(item);
|
|
2191
2237
|
if (forzado) {
|
|
2192
|
-
this._seleccionado
|
|
2238
|
+
this._seleccionado.set(idItem);
|
|
2193
2239
|
}
|
|
2194
2240
|
else {
|
|
2195
|
-
this._seleccionado
|
|
2241
|
+
this._seleccionado.update(current => current === idItem ? null : idItem);
|
|
2196
2242
|
}
|
|
2197
|
-
this.
|
|
2198
|
-
this.
|
|
2243
|
+
const objSel = this.objSeleccionado();
|
|
2244
|
+
this.selectionModelChange.emit(objSel);
|
|
2245
|
+
this.seleccionado.emit(objSel);
|
|
2199
2246
|
}
|
|
2200
|
-
hasChild = (_, node) =>
|
|
2247
|
+
hasChild = (_, node) => {
|
|
2248
|
+
const strHijo = this.strHijoContainer();
|
|
2249
|
+
return !!node[strHijo] && node[strHijo].length > 0;
|
|
2250
|
+
};
|
|
2201
2251
|
opcMenu(v) {
|
|
2202
|
-
|
|
2203
|
-
|
|
2204
|
-
const opAdic = { seccion: this.nombreColeccion };
|
|
2205
|
-
opAdic['itemSeleccionado'] = this.objSeleccionado;
|
|
2206
|
-
// v = {...v, ...opAdic};
|
|
2207
|
-
// this.seleccionado.emit(v);
|
|
2252
|
+
const opAdic = { seccion: this.nombreColeccion() };
|
|
2253
|
+
opAdic['itemSeleccionado'] = this.objSeleccionado();
|
|
2208
2254
|
}
|
|
2209
2255
|
emitirModeloCheck() {
|
|
2210
2256
|
this.listaCheck.emit(this.chkLista.generarLista());
|
|
2211
2257
|
this.listaCheckObj.emit(this.chkLista.generarLista('object'));
|
|
2212
2258
|
}
|
|
2213
2259
|
cambiarPadre(checkActual, estado) {
|
|
2214
|
-
const parentId = checkActual[this.campoIdPadre];
|
|
2260
|
+
const parentId = checkActual[this.campoIdPadre()];
|
|
2215
2261
|
if (parentId) {
|
|
2216
|
-
|
|
2262
|
+
// Fix: buscar en listaOriginal en lugar de listaMuestraArbol
|
|
2263
|
+
const listaOrig = this.listaOriginal();
|
|
2264
|
+
const padreAct = listaOrig.find((itm) => itm[this.campoId()] === parentId);
|
|
2217
2265
|
if (padreAct) {
|
|
2218
2266
|
this.chkLista.setState(parentId, this.hijosActivos('checked', padreAct) || this.hijosActivos('indeterminate', padreAct));
|
|
2219
2267
|
this.cambiarPadre(padreAct, estado);
|
|
@@ -2227,14 +2275,14 @@ class ListaArbolComponent {
|
|
|
2227
2275
|
});
|
|
2228
2276
|
}
|
|
2229
2277
|
this.cambiarPadre(checkActual, estado);
|
|
2230
|
-
this.chkLista.setState(checkActual[this.campoId], estado);
|
|
2278
|
+
this.chkLista.setState(checkActual[this.campoId()], estado);
|
|
2231
2279
|
}
|
|
2232
2280
|
hijosActivos(tipo, checkActual) {
|
|
2233
2281
|
let totalHijos = 0;
|
|
2234
2282
|
let cantActivo = 0;
|
|
2235
2283
|
if (this.hasChild(0, checkActual)) {
|
|
2236
2284
|
(this.treeControl.getChildren(checkActual) ?? []).forEach((vas) => {
|
|
2237
|
-
if (this.chkLista.getState(vas[this.campoId] + '')) {
|
|
2285
|
+
if (this.chkLista.getState(vas[this.campoId()] + '')) {
|
|
2238
2286
|
cantActivo++;
|
|
2239
2287
|
}
|
|
2240
2288
|
totalHijos++;
|
|
@@ -2242,29 +2290,30 @@ class ListaArbolComponent {
|
|
|
2242
2290
|
}
|
|
2243
2291
|
switch (tipo) {
|
|
2244
2292
|
case 'checked':
|
|
2245
|
-
return (cantActivo
|
|
2293
|
+
return (cantActivo === totalHijos);
|
|
2246
2294
|
case 'indeterminate':
|
|
2247
|
-
|
|
2248
|
-
|
|
2249
|
-
}
|
|
2250
|
-
return ((cantActivo > 0) && (cantActivo != totalHijos));
|
|
2295
|
+
// Fix: remover efecto secundario
|
|
2296
|
+
return ((cantActivo > 0) && (cantActivo !== totalHijos));
|
|
2251
2297
|
}
|
|
2252
2298
|
return false;
|
|
2253
2299
|
}
|
|
2254
2300
|
classFila(item) {
|
|
2255
2301
|
let claseFinal = [];
|
|
2256
|
-
|
|
2257
|
-
|
|
2302
|
+
const campoAnul = this.campoAnulado();
|
|
2303
|
+
if (campoAnul && (item[campoAnul] === 1)) {
|
|
2304
|
+
claseFinal = claseFinal.concat(this.classAnulado());
|
|
2258
2305
|
}
|
|
2259
|
-
|
|
2260
|
-
|
|
2306
|
+
const objSel = this.objSeleccionado();
|
|
2307
|
+
if (objSel === item || this.esSeleccionActual(item)) {
|
|
2308
|
+
claseFinal = claseFinal.concat(this.classSeleccionado());
|
|
2261
2309
|
}
|
|
2262
|
-
|
|
2263
|
-
|
|
2310
|
+
const condClases = this.condicionesClaseFila();
|
|
2311
|
+
claseFinal = claseFinal.concat(condClases(item));
|
|
2312
|
+
// Fix: no mutar el objeto original
|
|
2264
2313
|
return claseFinal;
|
|
2265
2314
|
}
|
|
2266
2315
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: ListaArbolComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
2267
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
|
|
2316
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "19.2.14", type: ListaArbolComponent, isStandalone: true, selector: "jvs-lista-arbol", inputs: { listaSuscription: { classPropertyName: "listaSuscription", publicName: "listaSuscription", isSignal: true, isRequired: true, transformFunction: null }, nombreColeccion: { classPropertyName: "nombreColeccion", publicName: "nombreColeccion", isSignal: true, isRequired: true, transformFunction: null }, checkbox: { classPropertyName: "checkbox", publicName: "checkbox", isSignal: true, isRequired: false, transformFunction: null }, expandirRecursivo: { classPropertyName: "expandirRecursivo", publicName: "expandirRecursivo", isSignal: true, isRequired: false, transformFunction: null }, checkboxSeleccionados: { classPropertyName: "checkboxSeleccionados", publicName: "checkboxSeleccionados", isSignal: true, isRequired: false, transformFunction: null }, campoId: { classPropertyName: "campoId", publicName: "campoId", isSignal: true, isRequired: true, transformFunction: null }, campoIdPadre: { classPropertyName: "campoIdPadre", publicName: "campoIdPadre", isSignal: true, isRequired: true, transformFunction: null }, campoStr: { classPropertyName: "campoStr", publicName: "campoStr", isSignal: true, isRequired: false, transformFunction: null }, campoOrden: { classPropertyName: "campoOrden", publicName: "campoOrden", isSignal: true, isRequired: false, transformFunction: null }, strHijoContainer: { classPropertyName: "strHijoContainer", publicName: "strHijoContainer", isSignal: true, isRequired: false, transformFunction: null }, menuContextual: { classPropertyName: "menuContextual", publicName: "menuContextual", isSignal: true, isRequired: false, transformFunction: null }, classSeleccionado: { classPropertyName: "classSeleccionado", publicName: "classSeleccionado", isSignal: true, isRequired: false, transformFunction: null }, classAnulado: { classPropertyName: "classAnulado", publicName: "classAnulado", isSignal: true, isRequired: false, transformFunction: null }, campoAnulado: { classPropertyName: "campoAnulado", publicName: "campoAnulado", isSignal: true, isRequired: false, transformFunction: null }, templateTxtData: { classPropertyName: "templateTxtData", publicName: "templateTxtData", isSignal: true, isRequired: false, transformFunction: null }, condicionMostrar: { classPropertyName: "condicionMostrar", publicName: "condicionMostrar", isSignal: true, isRequired: false, transformFunction: null }, condicionesClaseFila: { classPropertyName: "condicionesClaseFila", publicName: "condicionesClaseFila", isSignal: true, isRequired: false, transformFunction: null }, idTabla: { classPropertyName: "idTabla", publicName: "idTabla", isSignal: true, isRequired: true, transformFunction: null }, selectionModel: { classPropertyName: "selectionModel", publicName: "selectionModel", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { selectionModelChange: "selectionModelChange", seleccionado: "seleccionado", listaCheck: "listaCheck", listaCheckObj: "listaCheckObj" }, ngImport: i0, template: "<mat-tree [dataSource]=\"listaMuestraArbol()\" [treeControl]=\"treeControl\">\n <mat-nested-tree-node *matTreeNodeDef=\"let node; when: hasChild\">\n <div class=\"flex flex-col trans-ease-out cursor-pointer\" matTreeNodeToggle\n [matTreeNodeToggleRecursive]=\"expandirRecursivo()\">\n <ng-container [ngTemplateOutlet]=\"liDat\"\n [ngTemplateOutletContext]=\"{ node: node, nested: true }\"></ng-container>\n <div class=\"pl-4\" [class.hidden]=\"!treeControl.isExpanded(node)\">\n <ng-container matTreeNodeOutlet></ng-container>\n </div>\n </div>\n </mat-nested-tree-node>\n\n <!-- Cambiar mat-tree-node plano por mat-nested-tree-node sin hijos -->\n <mat-nested-tree-node *matTreeNodeDef=\"let node\">\n <div class=\"flex flex-col trans-ease-out\">\n <ng-container [ngTemplateOutlet]=\"liDat\"\n [ngTemplateOutletContext]=\"{ node: node, nested: false }\"></ng-container>\n </div>\n </mat-nested-tree-node>\n</mat-tree>\n\n<ng-template #liDat let-node=\"node\" let-nested=\"nested\">\n <div class=\"flex items-center gap-0 text-sm trans-ease-out cursor-pointer p-0 w-full\"\n (contextmenu)=\"menuContextual()?.abrirMenuContextual($event, node); $event.preventDefault();\"\n (click)=\"seleccionarItem(node); opcMenu({ seccion: nombreColeccion(), tipo: 'ver', item: node }); menuContextual()?.cerrarMenuContextual(); (nested === false) && $event.stopPropagation();\"\n [ngClass]=\"classFila(node)\">\n <mat-icon *ngIf=\"!nested\"></mat-icon>\n <mat-icon *ngIf=\"nested\"\n [svgIcon]=\"treeControl.isExpanded(node) ? 'roundExpandMore' : 'roundChevronRight'\"></mat-icon>\n\n <mat-checkbox *ngIf=\"checkbox()\"\n [(ngModel)]=\"chkLista.modelosChk[node[campoId()]]\"\n [ngModelOptions]=\"{ standalone: true }\"\n (click)=\"$event.stopPropagation()\"\n (change)=\"cambiarCheck(node, $event.checked); emitirModeloCheck()\"\n [indeterminate]=\"hasChild(0, node) && hijosActivos('indeterminate', node)\"\n [checked]=\"hasChild(0, node) ? hijosActivos('checked', node) : chkLista.modelosChk[node[campoId()]]\">\n </mat-checkbox>\n\n <span *ngIf=\"!templateTxtData()\" class=\"w-full\">{{ node[campoStr()] }}</span>\n <ng-container *ngIf=\"templateTxtData()\" [ngTemplateOutlet]=\"templateTxtData()!\"\n [ngTemplateOutletContext]=\"{ data: node, treeControl }\"></ng-container>\n </div>\n</ng-template>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: MatTreeModule }, { kind: "directive", type: i3$2.MatNestedTreeNode, selector: "mat-nested-tree-node", inputs: ["matNestedTreeNode", "disabled", "tabIndex"], outputs: ["activation", "expandedChange"], exportAs: ["matNestedTreeNode"] }, { kind: "directive", type: i3$2.MatTreeNodeDef, selector: "[matTreeNodeDef]", inputs: ["matTreeNodeDefWhen", "matTreeNode"] }, { kind: "directive", type: i3$2.MatTreeNodeToggle, selector: "[matTreeNodeToggle]", inputs: ["matTreeNodeToggleRecursive"] }, { kind: "component", type: i3$2.MatTree, selector: "mat-tree", exportAs: ["matTree"] }, { kind: "directive", type: i3$2.MatTreeNodeOutlet, selector: "[matTreeNodeOutlet]" }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatCheckboxModule }, { kind: "component", type: i5$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"] }] });
|
|
2268
2317
|
}
|
|
2269
2318
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: ListaArbolComponent, decorators: [{
|
|
2270
2319
|
type: Component,
|
|
@@ -2274,55 +2323,633 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImpo
|
|
|
2274
2323
|
MatTreeModule,
|
|
2275
2324
|
MatIconModule,
|
|
2276
2325
|
MatCheckboxModule,
|
|
2277
|
-
], template: "<mat-tree [dataSource]=\"listaMuestraArbol\" [treeControl]=\"treeControl\">\n <mat-nested-tree-node *matTreeNodeDef=\"let node; when: hasChild\">\n <div class=\"flex flex-col trans-ease-out cursor-pointer\" matTreeNodeToggle\n [matTreeNodeToggleRecursive]=\"expandirRecursivo\">\n <ng-container [ngTemplateOutlet]=\"liDat\"\n [ngTemplateOutletContext]=\"{ node: node, nested: true }\"></ng-container>\n <div class=\"pl-4\" [class.
|
|
2278
|
-
}],
|
|
2279
|
-
|
|
2280
|
-
|
|
2281
|
-
|
|
2282
|
-
|
|
2283
|
-
|
|
2284
|
-
|
|
2285
|
-
|
|
2286
|
-
|
|
2287
|
-
|
|
2288
|
-
|
|
2289
|
-
|
|
2290
|
-
|
|
2291
|
-
|
|
2292
|
-
|
|
2293
|
-
|
|
2294
|
-
|
|
2295
|
-
|
|
2296
|
-
|
|
2297
|
-
|
|
2298
|
-
|
|
2299
|
-
|
|
2300
|
-
|
|
2301
|
-
|
|
2302
|
-
|
|
2303
|
-
|
|
2304
|
-
|
|
2305
|
-
|
|
2306
|
-
|
|
2307
|
-
|
|
2308
|
-
|
|
2309
|
-
|
|
2310
|
-
|
|
2311
|
-
|
|
2312
|
-
|
|
2313
|
-
|
|
2314
|
-
|
|
2315
|
-
|
|
2316
|
-
|
|
2317
|
-
|
|
2318
|
-
|
|
2319
|
-
|
|
2320
|
-
|
|
2321
|
-
|
|
2322
|
-
|
|
2323
|
-
|
|
2324
|
-
|
|
2325
|
-
|
|
2326
|
+
], template: "<mat-tree [dataSource]=\"listaMuestraArbol()\" [treeControl]=\"treeControl\">\n <mat-nested-tree-node *matTreeNodeDef=\"let node; when: hasChild\">\n <div class=\"flex flex-col trans-ease-out cursor-pointer\" matTreeNodeToggle\n [matTreeNodeToggleRecursive]=\"expandirRecursivo()\">\n <ng-container [ngTemplateOutlet]=\"liDat\"\n [ngTemplateOutletContext]=\"{ node: node, nested: true }\"></ng-container>\n <div class=\"pl-4\" [class.hidden]=\"!treeControl.isExpanded(node)\">\n <ng-container matTreeNodeOutlet></ng-container>\n </div>\n </div>\n </mat-nested-tree-node>\n\n <!-- Cambiar mat-tree-node plano por mat-nested-tree-node sin hijos -->\n <mat-nested-tree-node *matTreeNodeDef=\"let node\">\n <div class=\"flex flex-col trans-ease-out\">\n <ng-container [ngTemplateOutlet]=\"liDat\"\n [ngTemplateOutletContext]=\"{ node: node, nested: false }\"></ng-container>\n </div>\n </mat-nested-tree-node>\n</mat-tree>\n\n<ng-template #liDat let-node=\"node\" let-nested=\"nested\">\n <div class=\"flex items-center gap-0 text-sm trans-ease-out cursor-pointer p-0 w-full\"\n (contextmenu)=\"menuContextual()?.abrirMenuContextual($event, node); $event.preventDefault();\"\n (click)=\"seleccionarItem(node); opcMenu({ seccion: nombreColeccion(), tipo: 'ver', item: node }); menuContextual()?.cerrarMenuContextual(); (nested === false) && $event.stopPropagation();\"\n [ngClass]=\"classFila(node)\">\n <mat-icon *ngIf=\"!nested\"></mat-icon>\n <mat-icon *ngIf=\"nested\"\n [svgIcon]=\"treeControl.isExpanded(node) ? 'roundExpandMore' : 'roundChevronRight'\"></mat-icon>\n\n <mat-checkbox *ngIf=\"checkbox()\"\n [(ngModel)]=\"chkLista.modelosChk[node[campoId()]]\"\n [ngModelOptions]=\"{ standalone: true }\"\n (click)=\"$event.stopPropagation()\"\n (change)=\"cambiarCheck(node, $event.checked); emitirModeloCheck()\"\n [indeterminate]=\"hasChild(0, node) && hijosActivos('indeterminate', node)\"\n [checked]=\"hasChild(0, node) ? hijosActivos('checked', node) : chkLista.modelosChk[node[campoId()]]\">\n </mat-checkbox>\n\n <span *ngIf=\"!templateTxtData()\" class=\"w-full\">{{ node[campoStr()] }}</span>\n <ng-container *ngIf=\"templateTxtData()\" [ngTemplateOutlet]=\"templateTxtData()!\"\n [ngTemplateOutletContext]=\"{ data: node, treeControl }\"></ng-container>\n </div>\n</ng-template>\n" }]
|
|
2327
|
+
}], ctorParameters: () => [] });
|
|
2328
|
+
|
|
2329
|
+
class FiltroBusquedaService {
|
|
2330
|
+
// Estado centralizado con Signals (Angular 19+)
|
|
2331
|
+
_filtrosActivos = signal(new Map());
|
|
2332
|
+
_dataServidorActivos = signal(new Map());
|
|
2333
|
+
// Interfaz de sólo lectura expuesta
|
|
2334
|
+
filtrosActivos = this._filtrosActivos.asReadonly();
|
|
2335
|
+
dataServidorActivos = this._dataServidorActivos.asReadonly();
|
|
2336
|
+
/**
|
|
2337
|
+
* Establece un valor para un filtro reactivo
|
|
2338
|
+
*/
|
|
2339
|
+
setValue(nombreFiltro, val) {
|
|
2340
|
+
this._filtrosActivos.update(map => {
|
|
2341
|
+
const nextMap = new Map(map);
|
|
2342
|
+
nextMap.set(nombreFiltro, val);
|
|
2343
|
+
return nextMap;
|
|
2344
|
+
});
|
|
2345
|
+
}
|
|
2346
|
+
/**
|
|
2347
|
+
* @deprecated Usa `getFiltroSignal(nombreFiltro)` en componentes modernos.
|
|
2348
|
+
* Retorna el snapshot sincrónico actual (para componentes legacy).
|
|
2349
|
+
*/
|
|
2350
|
+
getValue(nombreFiltro) {
|
|
2351
|
+
return this._filtrosActivos().get(nombreFiltro);
|
|
2352
|
+
}
|
|
2353
|
+
/**
|
|
2354
|
+
* Actualiza la metadata del servidor (Signals).
|
|
2355
|
+
*/
|
|
2356
|
+
setDataServidorSuscripcion(nombreFiltro, campo, data) {
|
|
2357
|
+
this._dataServidorActivos.update(map => {
|
|
2358
|
+
const nextMap = new Map(map);
|
|
2359
|
+
let filterMap = nextMap.get(nombreFiltro) || new Map();
|
|
2360
|
+
const nextFilterMap = new Map(filterMap);
|
|
2361
|
+
nextFilterMap.set(campo, data);
|
|
2362
|
+
nextMap.set(nombreFiltro, nextFilterMap);
|
|
2363
|
+
return nextMap;
|
|
2364
|
+
});
|
|
2365
|
+
}
|
|
2366
|
+
/**
|
|
2367
|
+
* @deprecated Usa `getDataServidorSignal(nombreFiltro, campo)` en componentes modernos.
|
|
2368
|
+
* Retorna el snapshot sincrónico actual de metadata (para componentes legacy).
|
|
2369
|
+
*/
|
|
2370
|
+
getDataServidorSuscripcion(nombreFiltro, campo) {
|
|
2371
|
+
return this._dataServidorActivos().get(nombreFiltro)?.get(campo);
|
|
2372
|
+
}
|
|
2373
|
+
// --- Opciones Signal (Angular 19+) ---
|
|
2374
|
+
/**
|
|
2375
|
+
* Crea y devuelve un Signal reactivo continuo para observar los valores aplicados de un filtro particular.
|
|
2376
|
+
* @param nombreFiltro Nombre del filtro que se desea escuchar
|
|
2377
|
+
* @param defaultValue Valor de respaldo seguro si aún no se ha inicializado el filtro.
|
|
2378
|
+
*/
|
|
2379
|
+
getFiltroSignal(nombreFiltro, defaultValue) {
|
|
2380
|
+
return computed(() => {
|
|
2381
|
+
const value = this._filtrosActivos().get(nombreFiltro);
|
|
2382
|
+
return (value ?? defaultValue);
|
|
2383
|
+
});
|
|
2384
|
+
}
|
|
2385
|
+
/**
|
|
2386
|
+
* Crea y devuelve un Signal reactivo continuo para escuchar la metadata/catálogo recibida del backend para un campo.
|
|
2387
|
+
* @param nombreFiltro Nombre de la colección del filtro principal
|
|
2388
|
+
* @param campo Campo específico (ej: id_usuario, categoria) del que se espera escuchar la lista u objeto servidor
|
|
2389
|
+
* @param defaultValue Valor de respaldo seguro si aún no hay data del servidor.
|
|
2390
|
+
*/
|
|
2391
|
+
getDataServidorSignal(nombreFiltro, campo, defaultValue) {
|
|
2392
|
+
return computed(() => {
|
|
2393
|
+
const value = this._dataServidorActivos().get(nombreFiltro)?.get(campo);
|
|
2394
|
+
return (value ?? defaultValue);
|
|
2395
|
+
});
|
|
2396
|
+
}
|
|
2397
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: FiltroBusquedaService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
2398
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: FiltroBusquedaService, providedIn: 'root' });
|
|
2399
|
+
}
|
|
2400
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: FiltroBusquedaService, decorators: [{
|
|
2401
|
+
type: Injectable,
|
|
2402
|
+
args: [{
|
|
2403
|
+
providedIn: 'root',
|
|
2404
|
+
}]
|
|
2405
|
+
}] });
|
|
2406
|
+
|
|
2407
|
+
const QUERY_SERVICE_TOKEN = new InjectionToken('QUERY_SERVICE_TOKEN');
|
|
2408
|
+
class FiltroBusquedaComponent {
|
|
2409
|
+
fb = inject(FormBuilder);
|
|
2410
|
+
toastr = inject(ToastrService);
|
|
2411
|
+
filtroBusquedaService = inject(FiltroBusquedaService);
|
|
2412
|
+
queryService = inject(QUERY_SERVICE_TOKEN, { optional: true });
|
|
2413
|
+
opciones = input([]);
|
|
2414
|
+
nombreColeccionInput = input(generateRandomString(10), { alias: 'nombreColeccion' });
|
|
2415
|
+
prefijoConsulta = input('grl');
|
|
2416
|
+
busquedaAutomatica = input(false);
|
|
2417
|
+
opciones$ = input();
|
|
2418
|
+
modificarOpciones$ = input();
|
|
2419
|
+
defaultTab = input(0);
|
|
2420
|
+
/**
|
|
2421
|
+
* @deprecated Paradigma Zero-Output: Inyecta FiltroBusquedaService y usa `getFiltroSignal('nombreColeccion')` para estado en tiempo real, esto evita renderizados innecesarios del padre.
|
|
2422
|
+
*/
|
|
2423
|
+
dataFiltro = output();
|
|
2424
|
+
/**
|
|
2425
|
+
* @deprecated Su payload de diccionario crudo desaparecerá pronto (Mejora 2). Migra al nuevo evento `(buscar)` que emite la interfaz `FiltroResultante`.
|
|
2426
|
+
* Se mantiene temporalmente para componentes legacy.
|
|
2427
|
+
*/
|
|
2428
|
+
resultados = output();
|
|
2429
|
+
/**
|
|
2430
|
+
* Evento principal explícito de búsqueda (Click en Filtrar). Emite el objeto con metadata y labels.
|
|
2431
|
+
*/
|
|
2432
|
+
buscar = output();
|
|
2433
|
+
/**
|
|
2434
|
+
* @deprecated Paradigma Zero-Output: Maneja la finalización de carga a través de los Signals internos del servicio o asume inmediatez de la arquitectura nueva.
|
|
2435
|
+
*/
|
|
2436
|
+
cargaCompleta = output();
|
|
2437
|
+
tabActual = signal(0);
|
|
2438
|
+
dataOpcionesNuevo = signal([]);
|
|
2439
|
+
isCargaCompleta = signal(false);
|
|
2440
|
+
frmFiltroBusqueda = this.fb.group({
|
|
2441
|
+
opcion: [0],
|
|
2442
|
+
opciones: this.fb.array([]),
|
|
2443
|
+
});
|
|
2444
|
+
get opcionesTabs() {
|
|
2445
|
+
return this.frmFiltroBusqueda.get('opciones');
|
|
2446
|
+
}
|
|
2447
|
+
get frmGroupSeleccionado() {
|
|
2448
|
+
return this.opcionesTabs.at(this.tabActual()) || this.fb.group({});
|
|
2449
|
+
}
|
|
2450
|
+
getControl(nombre) {
|
|
2451
|
+
return this.frmGroupSeleccionado.get(nombre);
|
|
2452
|
+
}
|
|
2453
|
+
getControlRaiz(nombre) {
|
|
2454
|
+
return this.frmFiltroBusqueda.get(nombre);
|
|
2455
|
+
}
|
|
2456
|
+
getAutocompleteLabel(controlData, value) {
|
|
2457
|
+
if (!value)
|
|
2458
|
+
return '';
|
|
2459
|
+
const config = controlData.autocomplete;
|
|
2460
|
+
if (!config)
|
|
2461
|
+
return '';
|
|
2462
|
+
const list = this.dataServidorSuscripcion[config.data]?.getValue() || [];
|
|
2463
|
+
const item = dataEnLista(list, config.campoValor || controlData.campo, value);
|
|
2464
|
+
if (item) {
|
|
2465
|
+
return this.campoTextEval(controlData, item);
|
|
2466
|
+
}
|
|
2467
|
+
// Fallback search in the filtered results if not in the main list
|
|
2468
|
+
const filteredList = this.filtrados[controlData.campo] || [];
|
|
2469
|
+
const filteredItem = dataEnLista(filteredList, config.campoValor || controlData.campo, value);
|
|
2470
|
+
if (filteredItem) {
|
|
2471
|
+
return this.campoTextEval(controlData, filteredItem);
|
|
2472
|
+
}
|
|
2473
|
+
return value?.toString() || '';
|
|
2474
|
+
}
|
|
2475
|
+
dataServidor = {};
|
|
2476
|
+
dataServidorSuscripcion = {};
|
|
2477
|
+
filtrados = {};
|
|
2478
|
+
inputParaEnviarAutocomplete = new Subject();
|
|
2479
|
+
destroy$ = new Subject();
|
|
2480
|
+
sufixTemporal = '_temporal';
|
|
2481
|
+
tipoValorFuncion = tipoValorFuncion$1;
|
|
2482
|
+
fechaActual = moment().toDate();
|
|
2483
|
+
constructor() {
|
|
2484
|
+
this.inputParaEnviarAutocomplete.pipe(debounceTime(500), takeUntil$1(this.destroy$)).subscribe((param) => {
|
|
2485
|
+
this.queryService?.cargar(this, [param.reqQuery], param.reqData, false, this.prefijoConsulta()).then((dRet) => {
|
|
2486
|
+
if (dRet) {
|
|
2487
|
+
this.filtrados[param.controlData.campo] = dRet[param.reqQuery];
|
|
2488
|
+
this.filtroBusquedaService.setDataServidorSuscripcion(this.nombreColeccionInput(), param.controlData.campo, dRet[param.reqQuery]);
|
|
2489
|
+
}
|
|
2490
|
+
});
|
|
2491
|
+
});
|
|
2492
|
+
}
|
|
2493
|
+
ngOnInit() {
|
|
2494
|
+
this.tabActual.set(this.defaultTab());
|
|
2495
|
+
this.frmFiltroBusqueda.get('opcion')?.setValue(this.tabActual());
|
|
2496
|
+
if (this.opciones().length > 0) {
|
|
2497
|
+
this.initOpciones(this.opciones());
|
|
2498
|
+
}
|
|
2499
|
+
this.opciones$()?.pipe(takeUntil$1(this.destroy$)).subscribe(val => {
|
|
2500
|
+
if (val)
|
|
2501
|
+
this.initOpciones(val);
|
|
2502
|
+
});
|
|
2503
|
+
this.modificarOpciones$()?.pipe(takeUntil$1(this.destroy$)).subscribe(val => {
|
|
2504
|
+
if (val) {
|
|
2505
|
+
Object.keys(val).forEach(x => {
|
|
2506
|
+
const ev = val[x];
|
|
2507
|
+
this.actualizarEnFormArray(x, ev.value ?? ev['val'], { disabled: ev.disabled });
|
|
2508
|
+
});
|
|
2509
|
+
}
|
|
2510
|
+
});
|
|
2511
|
+
this.frmFiltroBusqueda.valueChanges.pipe(distinctUntilChanged(), takeUntil$1(this.destroy$)).subscribe(() => {
|
|
2512
|
+
this.actualizarEstadoService();
|
|
2513
|
+
});
|
|
2514
|
+
this.frmFiltroBusqueda.get('opcion')?.valueChanges.pipe(distinctUntilChanged(), takeUntil$1(this.destroy$)).subscribe((val) => {
|
|
2515
|
+
if (val !== null) {
|
|
2516
|
+
this.tabActual.set(val);
|
|
2517
|
+
this.cargarDatosFiltroNuevo(val);
|
|
2518
|
+
}
|
|
2519
|
+
});
|
|
2520
|
+
}
|
|
2521
|
+
initOpciones(val) {
|
|
2522
|
+
const nOpc = this.reorganizarOpcionesNuevas(val);
|
|
2523
|
+
this.dataOpcionesNuevo.set(nOpc);
|
|
2524
|
+
this.cargarDatosFiltroNuevo();
|
|
2525
|
+
}
|
|
2526
|
+
reorganizarOpcionesNuevas(val) {
|
|
2527
|
+
return val.filter(tab => !tab.esVisible || tipoValorFuncion$1(tab.esVisible, true, tab)).map(tab => ({
|
|
2528
|
+
label: tab.label,
|
|
2529
|
+
campos: tab.campos || []
|
|
2530
|
+
}));
|
|
2531
|
+
}
|
|
2532
|
+
async cargarDatosFiltroNuevo(idTab) {
|
|
2533
|
+
const tabIdx = idTab !== undefined ? idTab : this.tabActual();
|
|
2534
|
+
const currentTab = this.dataOpcionesNuevo()[tabIdx];
|
|
2535
|
+
if (!currentTab)
|
|
2536
|
+
return;
|
|
2537
|
+
let llamadasJuntas = [[], [], [], [], []];
|
|
2538
|
+
let llamadasJuntasParams = [{}, {}, {}, {}, {}];
|
|
2539
|
+
const camposDisabled = [];
|
|
2540
|
+
const camposRequired = [];
|
|
2541
|
+
const procesarCampos = (campos, grupoFrm, agrupado = false) => {
|
|
2542
|
+
campos.forEach((campo) => {
|
|
2543
|
+
let val = campo;
|
|
2544
|
+
if (val.modificadorDatos)
|
|
2545
|
+
val = val.modificadorDatos(val);
|
|
2546
|
+
if (val.disabled)
|
|
2547
|
+
camposDisabled.push(val.campo);
|
|
2548
|
+
if (val.required)
|
|
2549
|
+
camposRequired.push(val.campo);
|
|
2550
|
+
if (val.dateRange) {
|
|
2551
|
+
const [fIni, fFin] = val.dateRange.campo;
|
|
2552
|
+
grupoFrm[fIni] = val.dateRange.value?.[0] === '*fechaActual*' ? this.fechaActual : (val.dateRange.value?.[0] || '');
|
|
2553
|
+
grupoFrm[fFin] = val.dateRange.value?.[1] === '*fechaActual*' ? this.fechaActual : (val.dateRange.value?.[1] || '');
|
|
2554
|
+
}
|
|
2555
|
+
else if (val.autocomplete) {
|
|
2556
|
+
grupoFrm[val.campo + this.sufixTemporal] = val.value || '';
|
|
2557
|
+
grupoFrm[val.campo] = val.value || '';
|
|
2558
|
+
}
|
|
2559
|
+
else if (val.controlAgrupado) {
|
|
2560
|
+
grupoFrm[val.campo] = val.value || '';
|
|
2561
|
+
procesarCampos(val.controlAgrupado, grupoFrm, true);
|
|
2562
|
+
}
|
|
2563
|
+
else {
|
|
2564
|
+
grupoFrm[val.campo] = val.value === '*fechaActual*' ? this.fechaActual : (val.value || '');
|
|
2565
|
+
}
|
|
2566
|
+
if (val.select || val.autocomplete) {
|
|
2567
|
+
const config = (val.select || val.autocomplete);
|
|
2568
|
+
if (agrupado)
|
|
2569
|
+
config.ordenPeticion = 3;
|
|
2570
|
+
if (config.customData) {
|
|
2571
|
+
this.setCustomData(config.data, config.customData);
|
|
2572
|
+
}
|
|
2573
|
+
else {
|
|
2574
|
+
const level = config.ordenPeticion || 0;
|
|
2575
|
+
if (config.data)
|
|
2576
|
+
llamadasJuntas[level].push(config.data);
|
|
2577
|
+
if (val.reqParams?.fields) {
|
|
2578
|
+
val.reqParams.fields.forEach(f => {
|
|
2579
|
+
if (grupoFrm[f] && !['*primero*', '*deUsuario*'].includes(grupoFrm[f])) {
|
|
2580
|
+
llamadasJuntasParams[level][f] = grupoFrm[f];
|
|
2581
|
+
}
|
|
2582
|
+
});
|
|
2583
|
+
}
|
|
2584
|
+
if (val.reqParams?.params) {
|
|
2585
|
+
llamadasJuntasParams[level] = { ...llamadasJuntasParams[level], ...val.reqParams.params };
|
|
2586
|
+
}
|
|
2587
|
+
}
|
|
2588
|
+
}
|
|
2589
|
+
});
|
|
2590
|
+
};
|
|
2591
|
+
const targetOpciones = idTab !== undefined ? [this.dataOpcionesNuevo()[idTab]] : this.dataOpcionesNuevo();
|
|
2592
|
+
targetOpciones.forEach(tab => {
|
|
2593
|
+
const grupoFrm = {};
|
|
2594
|
+
procesarCampos(tab.campos, grupoFrm);
|
|
2595
|
+
const group = this.fb.group(grupoFrm);
|
|
2596
|
+
if (idTab === undefined) {
|
|
2597
|
+
this.opcionesTabs.push(group);
|
|
2598
|
+
}
|
|
2599
|
+
else {
|
|
2600
|
+
this.opcionesTabs.setControl(idTab, group);
|
|
2601
|
+
}
|
|
2602
|
+
});
|
|
2603
|
+
getUniqueValues(camposDisabled).forEach(c => this.actualizarEnFormArray(c, undefined, { disabled: true }));
|
|
2604
|
+
establecerQuitarRequired(this.frmGroupSeleccionado, getUniqueValues(camposRequired));
|
|
2605
|
+
const cargaNivel = async (idx) => {
|
|
2606
|
+
const types = getUniqueValues(llamadasJuntas[idx]);
|
|
2607
|
+
if (types.length === 0)
|
|
2608
|
+
return;
|
|
2609
|
+
const dRet = await this.queryService?.cargar(this, types, llamadasJuntasParams[idx], false, this.prefijoConsulta());
|
|
2610
|
+
if (dRet) {
|
|
2611
|
+
this.procesarRetornoDatos(idx, dRet, llamadasJuntasParams);
|
|
2612
|
+
}
|
|
2613
|
+
};
|
|
2614
|
+
await cargaNivel(0);
|
|
2615
|
+
await cargaNivel(1);
|
|
2616
|
+
await cargaNivel(2);
|
|
2617
|
+
await cargaNivel(3);
|
|
2618
|
+
await cargaNivel(4);
|
|
2619
|
+
this.isCargaCompleta.set(true);
|
|
2620
|
+
this.actualizarEstadoService();
|
|
2621
|
+
this.cargaCompleta.emit(true);
|
|
2622
|
+
}
|
|
2623
|
+
actualizarEstadoService() {
|
|
2624
|
+
if (this.isCargaCompleta()) {
|
|
2625
|
+
const res = this.getFiltroResultante();
|
|
2626
|
+
this.filtroBusquedaService.setValue(this.nombreColeccionInput(), res);
|
|
2627
|
+
this.dataFiltro.emit(res.datosFiltro);
|
|
2628
|
+
}
|
|
2629
|
+
}
|
|
2630
|
+
setCustomData(key, data) {
|
|
2631
|
+
if (!this.dataServidorSuscripcion[key]) {
|
|
2632
|
+
this.dataServidorSuscripcion[key] = new BehaviorSubject(null);
|
|
2633
|
+
}
|
|
2634
|
+
this.dataServidorSuscripcion[key].next(data);
|
|
2635
|
+
}
|
|
2636
|
+
procesarRetornoDatos(idxLevel, data, paramsRef) {
|
|
2637
|
+
const tabCampos = this.dataOpcionesNuevo()[this.tabActual()].campos;
|
|
2638
|
+
const affected = tabCampos.filter(c => {
|
|
2639
|
+
const config = c.select || c.autocomplete;
|
|
2640
|
+
return config && (config.ordenPeticion || 0) === idxLevel;
|
|
2641
|
+
});
|
|
2642
|
+
affected.forEach(campo => {
|
|
2643
|
+
const config = (campo.select || campo.autocomplete);
|
|
2644
|
+
const res = data[config.data];
|
|
2645
|
+
if (!this.dataServidorSuscripcion[config.data]) {
|
|
2646
|
+
this.dataServidorSuscripcion[config.data] = new BehaviorSubject(null);
|
|
2647
|
+
}
|
|
2648
|
+
this.dataServidorSuscripcion[config.data].next(res);
|
|
2649
|
+
this.filtroBusquedaService.setDataServidorSuscripcion(this.nombreColeccionInput(), campo.campo, res);
|
|
2650
|
+
if (campo.value === '*primero*' && res?.length > 0) {
|
|
2651
|
+
const firstVal = config.campoValor === '*objeto*' ? res[0] : res[0][config.campoValor || campo.campo];
|
|
2652
|
+
this.actualizarEnFormArray(campo.campo, firstVal);
|
|
2653
|
+
paramsRef.forEach((p, i) => {
|
|
2654
|
+
if (i > idxLevel && p[campo.campo] === '')
|
|
2655
|
+
p[campo.campo] = firstVal;
|
|
2656
|
+
});
|
|
2657
|
+
}
|
|
2658
|
+
if (campo.autocomplete) {
|
|
2659
|
+
this.filtrados[campo.campo] = res;
|
|
2660
|
+
}
|
|
2661
|
+
if (campo.change) {
|
|
2662
|
+
this.cambiarSeleccionNuevo(campo);
|
|
2663
|
+
}
|
|
2664
|
+
});
|
|
2665
|
+
}
|
|
2666
|
+
getFiltroResultante() {
|
|
2667
|
+
const rawForm = this.frmGroupSeleccionado.getRawValue();
|
|
2668
|
+
const datosFiltro = { opcion: this.tabActual() };
|
|
2669
|
+
const datosFiltroConLabel = [];
|
|
2670
|
+
const resumenItems = [];
|
|
2671
|
+
const campos = this.dataOpcionesNuevo()[this.tabActual()]?.campos || [];
|
|
2672
|
+
const procesarMetadatos = (campo) => {
|
|
2673
|
+
const meta = { campo: campo.campo, label: campo.label || '', value: null };
|
|
2674
|
+
if (campo.dateRange) {
|
|
2675
|
+
const [fIni, fFin] = campo.dateRange.campo;
|
|
2676
|
+
datosFiltro[fIni] = rawForm[fIni] ? moment(rawForm[fIni]).format('YYYYMMDD') : '';
|
|
2677
|
+
datosFiltro[fFin] = rawForm[fFin] ? moment(rawForm[fFin]).format('YYYYMMDD') : '';
|
|
2678
|
+
if (rawForm[fIni] && rawForm[fFin]) {
|
|
2679
|
+
meta.value = `${moment(rawForm[fIni]).format('DD/MM/YYYY')} - ${moment(rawForm[fFin]).format('DD/MM/YYYY')}`;
|
|
2680
|
+
resumenItems.push(`${meta.label}: ${meta.value}`);
|
|
2681
|
+
}
|
|
2682
|
+
}
|
|
2683
|
+
else if (campo.control === 'date') {
|
|
2684
|
+
const val = rawForm[campo.campo];
|
|
2685
|
+
datosFiltro[campo.campo] = val ? moment(val).format('YYYYMMDD') : '';
|
|
2686
|
+
meta.value = val ? moment(val).format('DD/MM/YYYY') : '';
|
|
2687
|
+
if (meta.value)
|
|
2688
|
+
resumenItems.push(`${meta.label}: ${meta.value}`);
|
|
2689
|
+
}
|
|
2690
|
+
else if (campo.control === 'checkbox') {
|
|
2691
|
+
datosFiltro[campo.campo] = rawForm[campo.campo];
|
|
2692
|
+
meta.value = rawForm[campo.campo];
|
|
2693
|
+
if (meta.value)
|
|
2694
|
+
resumenItems.push(`${meta.label}`);
|
|
2695
|
+
}
|
|
2696
|
+
else {
|
|
2697
|
+
const val = rawForm[campo.campo];
|
|
2698
|
+
datosFiltro[campo.campo] = val;
|
|
2699
|
+
meta.value = val;
|
|
2700
|
+
if (campo.select || campo.autocomplete) {
|
|
2701
|
+
const config = (campo.select || campo.autocomplete);
|
|
2702
|
+
const list = this.dataServidorSuscripcion[config.data]?.getValue() || [];
|
|
2703
|
+
const item = config.campoValor === '*objeto*' ? val : dataEnLista(list, config.campoValor || campo.campo, val);
|
|
2704
|
+
if (item) {
|
|
2705
|
+
meta.list = list;
|
|
2706
|
+
meta.valueObject = item;
|
|
2707
|
+
meta.valueString = this.campoTextEval(campo, item);
|
|
2708
|
+
resumenItems.push(`${meta.label}: ${meta.valueString}`);
|
|
2709
|
+
}
|
|
2710
|
+
}
|
|
2711
|
+
else if (val !== null && val !== undefined && val !== '') {
|
|
2712
|
+
resumenItems.push(`${meta.label}: ${val}`);
|
|
2713
|
+
}
|
|
2714
|
+
}
|
|
2715
|
+
datosFiltroConLabel.push(meta);
|
|
2716
|
+
};
|
|
2717
|
+
campos.forEach(c => {
|
|
2718
|
+
if (c.controlAgrupado) {
|
|
2719
|
+
c.controlAgrupado.forEach(sub => procesarMetadatos(sub));
|
|
2720
|
+
}
|
|
2721
|
+
else {
|
|
2722
|
+
procesarMetadatos(c);
|
|
2723
|
+
}
|
|
2724
|
+
});
|
|
2725
|
+
const labelResumen = resumenItems.join(' | ');
|
|
2726
|
+
return { datosFiltro, datosFiltroConLabel, labelResumen };
|
|
2727
|
+
}
|
|
2728
|
+
mostrarValorEnBusqueda = mostrarValorEnBusqueda;
|
|
2729
|
+
campoValorEval(campoFiltro, itemSelect) {
|
|
2730
|
+
if (campoFiltro.select || campoFiltro.autocomplete) {
|
|
2731
|
+
const selectOrAutocomplete = campoFiltro.select ? campoFiltro.select : campoFiltro.autocomplete;
|
|
2732
|
+
if (selectOrAutocomplete?.campoValor === '*objeto*') {
|
|
2733
|
+
return itemSelect;
|
|
2734
|
+
}
|
|
2735
|
+
if (campoFiltro.campo === '*objeto*') {
|
|
2736
|
+
return itemSelect;
|
|
2737
|
+
}
|
|
2738
|
+
if (selectOrAutocomplete && itemSelect[selectOrAutocomplete.campoValor] !== undefined) {
|
|
2739
|
+
return itemSelect[selectOrAutocomplete.campoValor];
|
|
2740
|
+
}
|
|
2741
|
+
}
|
|
2742
|
+
return itemSelect[campoFiltro.campo];
|
|
2743
|
+
}
|
|
2744
|
+
campoTextEval(campoFiltro, itemSelect) {
|
|
2745
|
+
if (campoFiltro.select || campoFiltro.autocomplete) {
|
|
2746
|
+
const selectOrAutocomplete = (campoFiltro.select || campoFiltro.autocomplete);
|
|
2747
|
+
if (selectOrAutocomplete.optionText) {
|
|
2748
|
+
return selectOrAutocomplete.optionText(itemSelect);
|
|
2749
|
+
}
|
|
2750
|
+
if (selectOrAutocomplete.camposText) {
|
|
2751
|
+
return selectOrAutocomplete.camposText.map(c => itemSelect[c]).join(' ');
|
|
2752
|
+
}
|
|
2753
|
+
return itemSelect[campoFiltro.campo];
|
|
2754
|
+
}
|
|
2755
|
+
return '';
|
|
2756
|
+
}
|
|
2757
|
+
concatenarCadenasArray(array, objData) {
|
|
2758
|
+
if (typeof array === 'string') {
|
|
2759
|
+
return objData[array];
|
|
2760
|
+
}
|
|
2761
|
+
const nTxtArray = [];
|
|
2762
|
+
array.forEach(campo => {
|
|
2763
|
+
if (campo.charAt(0) === '*') {
|
|
2764
|
+
nTxtArray.push(campo.replace('*', ''));
|
|
2765
|
+
}
|
|
2766
|
+
else {
|
|
2767
|
+
nTxtArray.push(objData[campo]);
|
|
2768
|
+
}
|
|
2769
|
+
});
|
|
2770
|
+
return nTxtArray.join(' ');
|
|
2771
|
+
}
|
|
2772
|
+
filtrarData() {
|
|
2773
|
+
if (this.frmGroupSeleccionado.invalid) {
|
|
2774
|
+
const errors = getFormValidationErrors(this.frmGroupSeleccionado);
|
|
2775
|
+
const labels = errors.map(e => {
|
|
2776
|
+
const found = this.dataOpcionesNuevo()[this.tabActual()].campos.find(c => c.campo === e.control);
|
|
2777
|
+
return found?.label || e.control;
|
|
2778
|
+
});
|
|
2779
|
+
this.toastr.error(`Campos requeridos:<br>${labels.join(', ')}`, undefined, { enableHtml: true });
|
|
2780
|
+
return;
|
|
2781
|
+
}
|
|
2782
|
+
this.actualizarEstadoService();
|
|
2783
|
+
const res = this.getFiltroResultante();
|
|
2784
|
+
// Soporte temporal a usos actuales
|
|
2785
|
+
this.resultados.emit(res.datosFiltro);
|
|
2786
|
+
// Nueva mejora 2 (Emisión completa)
|
|
2787
|
+
this.buscar.emit(res);
|
|
2788
|
+
}
|
|
2789
|
+
actualizarEnFormArray(name, value, extra) {
|
|
2790
|
+
this.opcionesTabs.controls.forEach((control) => {
|
|
2791
|
+
const fc = control.get(name);
|
|
2792
|
+
if (fc) {
|
|
2793
|
+
if (value !== undefined)
|
|
2794
|
+
fc.setValue(value, { emitEvent: false });
|
|
2795
|
+
if (extra?.disabled === true)
|
|
2796
|
+
fc.disable();
|
|
2797
|
+
if (extra?.disabled === false)
|
|
2798
|
+
fc.enable();
|
|
2799
|
+
fc.updateValueAndValidity();
|
|
2800
|
+
}
|
|
2801
|
+
});
|
|
2802
|
+
}
|
|
2803
|
+
accionPosteriorCambioAutocomplete(controlData, valControl) {
|
|
2804
|
+
const list = this.dataServidorSuscripcion[controlData.autocomplete?.data]?.getValue() || [];
|
|
2805
|
+
this.filtrados[controlData.campo] = list.filter((algo) => {
|
|
2806
|
+
let nTextVerif = this.concatenarCadenasArray(controlData.autocomplete?.camposText, algo);
|
|
2807
|
+
if (controlData.autocomplete?.searchFields) {
|
|
2808
|
+
const nTextVerifExtra = this.concatenarCadenasArray(controlData.autocomplete.searchFields, algo);
|
|
2809
|
+
nTextVerif = nTextVerif.concat(nTextVerifExtra);
|
|
2810
|
+
}
|
|
2811
|
+
const textBuscar = valControl && typeof valControl === 'string' ? valControl.toLowerCase() : null;
|
|
2812
|
+
if (nTextVerif) {
|
|
2813
|
+
return nTextVerif.toLowerCase().includes(textBuscar) ? algo : null;
|
|
2814
|
+
}
|
|
2815
|
+
return null;
|
|
2816
|
+
});
|
|
2817
|
+
}
|
|
2818
|
+
cambiarNuevo(campo, val) {
|
|
2819
|
+
if (campo.autocomplete) {
|
|
2820
|
+
const valControl = this.frmGroupSeleccionado.get(campo.campo + this.sufixTemporal)?.value;
|
|
2821
|
+
if (!valControl) {
|
|
2822
|
+
this.filtrados[campo.campo] = this.dataServidorSuscripcion[campo.autocomplete.data]?.getValue() || [];
|
|
2823
|
+
}
|
|
2824
|
+
else {
|
|
2825
|
+
const config = campo.autocomplete;
|
|
2826
|
+
if (config.campotxtBuscar && val && val.length > (config.campotxtBuscarLength || 3)) {
|
|
2827
|
+
const reqQuery = config.data;
|
|
2828
|
+
let reqData = {};
|
|
2829
|
+
if (campo.reqParams?.fields) {
|
|
2830
|
+
campo.reqParams.fields.forEach(f => {
|
|
2831
|
+
const ctrl = this.buscarControl(f);
|
|
2832
|
+
reqData[ctrl?.aliasCampoEnviar || f] = this.frmGroupSeleccionado.get(f)?.value;
|
|
2833
|
+
});
|
|
2834
|
+
}
|
|
2835
|
+
reqData[config.campotxtBuscar || campo.campo] = val;
|
|
2836
|
+
if (campo.reqParams?.params)
|
|
2837
|
+
Object.assign(reqData, campo.reqParams.params);
|
|
2838
|
+
this.inputParaEnviarAutocomplete.next({ reqQuery, reqData, controlData: campo });
|
|
2839
|
+
}
|
|
2840
|
+
else {
|
|
2841
|
+
this.accionPosteriorCambioAutocomplete(campo, valControl);
|
|
2842
|
+
}
|
|
2843
|
+
}
|
|
2844
|
+
}
|
|
2845
|
+
}
|
|
2846
|
+
cambiarSeleccionNuevo(campo, event) {
|
|
2847
|
+
const val = event?.option?.value ?? event?.value ?? (event?.target ? event.target.value : event);
|
|
2848
|
+
if (val !== undefined) {
|
|
2849
|
+
this.actualizarEnFormArray(campo.campo, val);
|
|
2850
|
+
if (campo.autocomplete) {
|
|
2851
|
+
const config = campo.autocomplete;
|
|
2852
|
+
const list = this.dataServidorSuscripcion[config.data]?.getValue() || [];
|
|
2853
|
+
const item = config.campoValor === '*objeto*' ? val : dataEnLista(list, config.campoValor || campo.campo, val);
|
|
2854
|
+
if (item) {
|
|
2855
|
+
const text = this.campoTextEval(campo, item);
|
|
2856
|
+
this.actualizarEnFormArray(campo.campo + this.sufixTemporal, text);
|
|
2857
|
+
}
|
|
2858
|
+
}
|
|
2859
|
+
const groupedMatch = this.dataOpcionesNuevo()[this.tabActual()].campos
|
|
2860
|
+
.filter(c => c.controlAgrupado)
|
|
2861
|
+
.find(c => c.controlAgrupado?.some(sub => sub.campo === campo.campo));
|
|
2862
|
+
if (groupedMatch)
|
|
2863
|
+
this.frmGroupSeleccionado.get(groupedMatch.campo)?.setValue(val);
|
|
2864
|
+
}
|
|
2865
|
+
if (campo.change?.filterFields) {
|
|
2866
|
+
campo.change.filterFields.forEach(target => {
|
|
2867
|
+
const targetMeta = this.buscarControl(target);
|
|
2868
|
+
if (targetMeta) {
|
|
2869
|
+
const params = this.generarParams(targetMeta, campo);
|
|
2870
|
+
this.actualizarEnFormArray(target, null);
|
|
2871
|
+
this.actualizarEnFormArray(target + this.sufixTemporal, null);
|
|
2872
|
+
this.dataServidorSuscripcion[target]?.next(null);
|
|
2873
|
+
const config = (targetMeta.select || targetMeta.autocomplete);
|
|
2874
|
+
if (config?.data) {
|
|
2875
|
+
this.queryService?.cargar(this, [config.data], params, false, this.prefijoConsulta()).then(d => {
|
|
2876
|
+
if (d) {
|
|
2877
|
+
const res = d[config.data];
|
|
2878
|
+
this.actualizarEnFormArray(target, targetMeta.value || null);
|
|
2879
|
+
this.actualizarEnFormArray(target + this.sufixTemporal, targetMeta.value || null);
|
|
2880
|
+
if (!this.dataServidorSuscripcion[config.data]) {
|
|
2881
|
+
this.dataServidorSuscripcion[config.data] = new BehaviorSubject(null);
|
|
2882
|
+
}
|
|
2883
|
+
this.dataServidorSuscripcion[config.data].next(res);
|
|
2884
|
+
this.filtrados[target] = res;
|
|
2885
|
+
}
|
|
2886
|
+
});
|
|
2887
|
+
}
|
|
2888
|
+
}
|
|
2889
|
+
});
|
|
2890
|
+
}
|
|
2891
|
+
else if (campo.change?.filter) {
|
|
2892
|
+
setTimeout(() => this.filtrarData(), 1);
|
|
2893
|
+
}
|
|
2894
|
+
}
|
|
2895
|
+
buscarControl(campo) {
|
|
2896
|
+
const rootCampos = this.dataOpcionesNuevo()[this.tabActual()].campos;
|
|
2897
|
+
let found = rootCampos.find(c => c.campo === campo);
|
|
2898
|
+
if (!found) {
|
|
2899
|
+
found = rootCampos.filter(c => c.controlAgrupado).flatMap(c => c.controlAgrupado).find(c => c.campo === campo);
|
|
2900
|
+
}
|
|
2901
|
+
return found;
|
|
2902
|
+
}
|
|
2903
|
+
generarParams(meta, trigger) {
|
|
2904
|
+
const params = {};
|
|
2905
|
+
if (meta.reqParams?.fields) {
|
|
2906
|
+
meta.reqParams.fields.forEach(f => {
|
|
2907
|
+
const ctrl = this.buscarControl(f);
|
|
2908
|
+
params[ctrl?.aliasCampoEnviar || f] = this.frmGroupSeleccionado.get(f)?.value;
|
|
2909
|
+
});
|
|
2910
|
+
}
|
|
2911
|
+
else {
|
|
2912
|
+
params[meta.aliasCampoEnviar || trigger.campo || meta.campo] = this.frmGroupSeleccionado.get(trigger.campo || meta.campo)?.value;
|
|
2913
|
+
}
|
|
2914
|
+
if (meta.reqParams?.params)
|
|
2915
|
+
Object.assign(params, meta.reqParams.params);
|
|
2916
|
+
return params;
|
|
2917
|
+
}
|
|
2918
|
+
limpiarAutocomplete(campo, event) {
|
|
2919
|
+
this.actualizarEnFormArray(campo.campo, '');
|
|
2920
|
+
this.actualizarEnFormArray(campo.campo + this.sufixTemporal, '');
|
|
2921
|
+
this.cambiarSeleccionNuevo(campo, { option: { value: '' } });
|
|
2922
|
+
event.preventDefault();
|
|
2923
|
+
}
|
|
2924
|
+
ngOnDestroy() {
|
|
2925
|
+
this.destroy$.next();
|
|
2926
|
+
this.destroy$.complete();
|
|
2927
|
+
}
|
|
2928
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: FiltroBusquedaComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
2929
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.14", type: FiltroBusquedaComponent, isStandalone: true, selector: "jvs-filtro-busqueda", inputs: { opciones: { classPropertyName: "opciones", publicName: "opciones", isSignal: true, isRequired: false, transformFunction: null }, nombreColeccionInput: { classPropertyName: "nombreColeccionInput", publicName: "nombreColeccion", isSignal: true, isRequired: false, transformFunction: null }, prefijoConsulta: { classPropertyName: "prefijoConsulta", publicName: "prefijoConsulta", isSignal: true, isRequired: false, transformFunction: null }, busquedaAutomatica: { classPropertyName: "busquedaAutomatica", publicName: "busquedaAutomatica", isSignal: true, isRequired: false, transformFunction: null }, opciones$: { classPropertyName: "opciones$", publicName: "opciones$", isSignal: true, isRequired: false, transformFunction: null }, modificarOpciones$: { classPropertyName: "modificarOpciones$", publicName: "modificarOpciones$", isSignal: true, isRequired: false, transformFunction: null }, defaultTab: { classPropertyName: "defaultTab", publicName: "defaultTab", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { dataFiltro: "dataFiltro", resultados: "resultados", buscar: "buscar", cargaCompleta: "cargaCompleta" }, host: { classAttribute: "jvsFiltroBusqueda" }, ngImport: i0, template: "@if (isCargaCompleta()) {\n <div class=\"filtroBusqueda w-full\">\n <div class=\"border-none p-0 flex flex-col\">\n\n @if (dataOpcionesNuevo().length === 1) {\n <div class=\"flex-1 flex items-end max-sm:flex-col flex-wrap gap-2\">\n <ng-container [ngTemplateOutlet]=\"verOpcionesT\"></ng-container>\n </div>\n } @else if (dataOpcionesNuevo().length > 1) {\n <div class=\"flex-1 flex flex-col flex-wrap gap-2 border\">\n <mat-tab-group\n [selectedIndex]=\"tabActual()\"\n (selectedIndexChange)=\"getControlRaiz('opcion').setValue($event)\"\n class=\"flex-1 flex flex-wrap\"\n [mat-stretch-tabs]=\"false\"\n dynamicHeight\n mat-align-tabs=\"start\"\n >\n @for (item of dataOpcionesNuevo(); track $index) {\n <mat-tab [aria-label]=\"(tabActual() === $index) ? 'primary' : ''\">\n <ng-template mat-tab-label>\n @if (tabActual() === $index) {\n <mat-icon class=\"icon-xs\" svgIcon=\"roundVerified\"></mat-icon>\n }\n {{ item.label }}\n </ng-template>\n\n <div class=\"mx-2 mt-0 pt-0 flex flex-col items-end sm:flex-row flex-wrap gap-2\">\n <ng-container [ngTemplateOutlet]=\"verOpcionesT\"></ng-container>\n </div>\n </mat-tab>\n }\n </mat-tab-group>\n </div>\n }\n </div>\n </div>\n}\n\n<ng-template #verOpcionesT>\n @for (campo of dataOpcionesNuevo()[tabActual()]?.campos; track campo.campo) {\n <ng-container [ngTemplateOutletContext]=\"{controlData: campo}\" [ngTemplateOutlet]=\"controlesFormularioNuevo\"></ng-container>\n }\n <ng-container [ngTemplateOutlet]=\"botonFiltrar\"></ng-container>\n</ng-template>\n\n<ng-template #botonFiltrar>\n <button (click)=\"filtrarData()\"\n class=\"flex items-center justify-center bg-primary text-primary-contrast font-bold uppercase text-xs px-2 py-1 rounded shadow-md hover:shadow-lg outline-none focus:outline-none mr-1 mb-1 ease-linear transition-all duration-150\"\n matRipple type=\"button\"\n [disabled]=\"!isCargaCompleta()\"\n >\n <mat-icon class=\"icon-xs\" svgIcon=\"roundFilterAlt\"></mat-icon> \n <span>Filtrar</span>\n </button>\n</ng-template>\n\n<ng-template #controlesFormularioNuevo let-controlData=\"controlData\">\n @switch (controlData.control) {\n @case ('controlAgrupado') {\n <ng-container [ngTemplateOutletContext]=\"{template: inputControlAgrupado, controlData: controlData}\" [ngTemplateOutlet]=\"contenedorInput\"></ng-container>\n }\n @case ('select') {\n <ng-container [ngTemplateOutletContext]=\"{template: inputSelect, controlData: controlData}\" [ngTemplateOutlet]=\"contenedorInput\"></ng-container>\n }\n @case ('autocomplete') {\n <ng-container [ngTemplateOutletContext]=\"{template: inputAutocomplete, controlData: controlData}\" [ngTemplateOutlet]=\"contenedorInput\"></ng-container>\n }\n @case ('date') {\n <ng-container [ngTemplateOutletContext]=\"{template: inputDate, controlData: controlData}\" [ngTemplateOutlet]=\"contenedorInput\"></ng-container>\n }\n @case ('date_range') {\n <ng-container [ngTemplateOutletContext]=\"{template: inputDateRange, controlData: controlData}\" [ngTemplateOutlet]=\"contenedorInput\"></ng-container>\n }\n @case ('checkbox') {\n <ng-container [ngTemplateOutletContext]=\"{template: inputCheckBox, controlData: controlData}\" [ngTemplateOutlet]=\"contenedorInput\"></ng-container>\n }\n @default {\n @if (controlData.control === 'text' || controlData.control === 'number') {\n <ng-container [ngTemplateOutletContext]=\"{template: inputTextNumber, controlData: controlData}\" [ngTemplateOutlet]=\"contenedorInput\"></ng-container>\n }\n }\n }\n</ng-template>\n\n<ng-template #contenedorInput let-template=\"template\" let-controlData=\"controlData\">\n <fieldset [class.flex-auto]=\"!controlData.cssClass\" [class]=\"controlData.cssClass\" class=\"appearance-none contenedorCampo relative\">\n <legend>\n <label [for]=\"controlData.campo\">{{ controlData.label }}@if(controlData.required){<span class=\"text-red-700 font-bold\"> *</span>}</label>\n </legend>\n <ng-container [ngTemplateOutletContext]=\"{controlData: controlData}\" [ngTemplateOutlet]=\"template\"></ng-container>\n </fieldset>\n</ng-template>\n\n<ng-template #inputSelect let-controlData=\"controlData\">\n <select [formControl]=\"getControl(controlData.campo)\"\n (change)=\"cambiarSeleccionNuevo(controlData, $event);\"\n [class]=\"controlData.select?.cssClass?.class\"\n [id]=\"controlData.campo\"\n [required]=\"controlData.required\"\n [class.border-b-red-700]=\"getControl(controlData.campo).invalid\"\n >\n @if (controlData.select?.textoCuandoNulo) {\n <option value=\"\">{{ controlData.select?.textoCuandoNulo }}</option>\n }\n @for (itemSelect of dataServidorSuscripcion[controlData.select?.data!] | async; track $index) {\n <option [class]=\"controlData.select?.cssClass?.option\" [value]=\"campoValorEval(controlData, itemSelect)\">\n {{ campoTextEval(controlData, itemSelect) }}\n </option>\n }\n </select>\n</ng-template>\n\n<ng-template #inputControlAgrupado let-controlData=\"controlData\">\n <div class=\"flex items-center campos-container\">\n @for (sub of controlData.controlAgrupado; track sub.campo) {\n @switch (sub.control) {\n @case ('select') {\n <ng-container [ngTemplateOutletContext]=\"{controlData: sub}\" [ngTemplateOutlet]=\"inputSelect\"></ng-container>\n }\n @case ('autocomplete') {\n <ng-container [ngTemplateOutletContext]=\"{controlData: sub}\" [ngTemplateOutlet]=\"inputAutocomplete\"></ng-container>\n }\n @case ('date') {\n <ng-container [ngTemplateOutletContext]=\"{controlData: sub}\" [ngTemplateOutlet]=\"inputDate\"></ng-container>\n }\n @case ('date_range') {\n <ng-container [ngTemplateOutletContext]=\"{controlData: sub}\" [ngTemplateOutlet]=\"inputDateRange\"></ng-container>\n }\n @case ('checkbox') {\n <ng-container [ngTemplateOutletContext]=\"{controlData: sub}\" [ngTemplateOutlet]=\"inputCheckBox\"></ng-container>\n }\n @default {\n @if (sub.control === 'text' || sub.control === 'number') {\n <ng-container [ngTemplateOutletContext]=\"{controlData: sub}\" [ngTemplateOutlet]=\"inputTextNumber\"></ng-container>\n }\n }\n }\n }\n </div>\n</ng-template>\n\n<ng-template #inputAutocomplete let-controlData=\"controlData\">\n <div class=\"flex items-center formcontrol-container\">\n <input [formControl]=\"getControl(controlData.campo + sufixTemporal)\"\n (input)=\"cambiarNuevo(controlData, $any($event.target).value)\"\n [matAutocomplete]=\"auto\"\n autocomplete=\"off\"\n [id]=\"controlData.campo\"\n placeholder=\"{{ controlData.autocomplete?.textoCuandoNulo ?? controlData.label }}\"\n [required]=\"controlData.required\"\n [class.border-b-red-700]=\"getControl(controlData.campo).invalid\"\n >\n <mat-autocomplete #auto=\"matAutocomplete\"\n (optionSelected)=\"cambiarSeleccionNuevo(controlData, $event)\"\n [panelWidth]=\"'auto'\"\n [displayWith]=\"getAutocompleteLabel.bind(this, controlData)\"\n >\n @for (itemSelect of filtrados[controlData.campo]; track $index) {\n <mat-option [class]=\"controlData.autocomplete?.cssClass?.option\" [value]=\"campoValorEval(controlData, itemSelect)\">\n @if (controlData.autocomplete?.optionInnerHtml) {\n <div [innerHTML]=\"controlData.autocomplete?.optionInnerHtml!(itemSelect)\"></div>\n } @else {\n {{ campoTextEval(controlData, itemSelect) }}\n }\n </mat-option>\n }\n </mat-autocomplete>\n\n <div class=\"flex items-center justify-start\">\n <button (click)=\"limpiarAutocomplete(controlData, $event)\" class=\"boton-circular-gris\"\n matRipple\n type=\"button\"\n >\n <mat-icon [svgIcon]=\"(getControl(controlData.campo).value ? 'roundCancel' : 'roundSearch')\" class=\"icon-2xs\"></mat-icon>\n </button>\n </div>\n </div>\n</ng-template>\n\n<ng-template #inputTextNumber let-controlData=\"controlData\">\n <input (keyup.enter)=\"controlData.keyUpEnter ? filtrarData() : null\"\n [formControl]=\"getControl(controlData.campo)\"\n [type]=\"controlData.control\"\n autocomplete=\"off\"\n [id]=\"controlData.campo\"\n placeholder=\"{{ controlData.label }}\"\n [required]=\"controlData.required\"\n [class.border-b-red-700]=\"getControl(controlData.campo).invalid\"\n >\n</ng-template>\n\n<ng-template #inputDate let-controlData=\"controlData\">\n <div class=\"flex items-center date-container\">\n <input (keyup.enter)=\"controlData.keyUpEnter ? filtrarData() : null\"\n [formControl]=\"getControl(controlData.campo)\"\n (dateChange)=\"cambiarSeleccionNuevo(controlData, $event)\"\n [matDatepicker]=\"i\"\n autocomplete=\"off\"\n [id]=\"controlData.campo\"\n placeholder=\"{{ controlData.label }}\"\n type=\"text\"\n [required]=\"controlData.required\"\n [class.border-b-red-700]=\"getControl(controlData.campo).invalid\"\n >\n <mat-datepicker-toggle [for]=\"i\" class=\"icon-xs\" matSuffix></mat-datepicker-toggle>\n <mat-datepicker #i></mat-datepicker>\n </div>\n</ng-template>\n\n<ng-template #inputDateRange let-controlData=\"controlData\">\n <div class=\"flex items-center daterange-container\">\n <mat-date-range-input [rangePicker]=\"i\">\n <input [formControl]=\"getControl(controlData.dateRange?.campo![0])\" matStartDate placeholder=\"Desde\">\n <input [formControl]=\"getControl(controlData.dateRange?.campo![1])\" matEndDate placeholder=\"Hasta\">\n </mat-date-range-input>\n <mat-datepicker-toggle [for]=\"i\" class=\"icon-xs\"></mat-datepicker-toggle>\n <mat-date-range-picker #i></mat-date-range-picker>\n </div>\n</ng-template>\n\n<ng-template #inputCheckBox let-controlData=\"controlData\">\n <input [formControl]=\"getControl(controlData.campo)\"\n [id]=\"controlData.campo\"\n [required]=\"controlData.required\"\n [class.border-b-red-700]=\"getControl(controlData.campo).invalid\"\n type=\"checkbox\"\n (change)=\"cambiarSeleccionNuevo(controlData, $event)\"\n >\n</ng-template>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2$1.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i2$1.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i2$1.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: i2$1.CheckboxControlValueAccessor, selector: "input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]" }, { kind: "directive", type: i2$1.SelectControlValueAccessor, selector: "select:not([multiple])[formControlName],select:not([multiple])[formControl],select:not([multiple])[ngModel]", inputs: ["compareWith"] }, { kind: "directive", type: i2$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2$1.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { kind: "directive", type: i2$1.CheckboxRequiredValidator, selector: "input[type=checkbox][required][formControlName],input[type=checkbox][required][formControl],input[type=checkbox][required][ngModel]" }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i2$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "ngmodule", type: MatAutocompleteModule }, { kind: "component", type: i3$3.MatAutocomplete, selector: "mat-autocomplete", inputs: ["aria-label", "aria-labelledby", "displayWith", "autoActiveFirstOption", "autoSelectActiveOption", "requireSelection", "panelWidth", "disableRipple", "class", "hideSingleSelectionIndicator"], outputs: ["optionSelected", "opened", "closed", "optionActivated"], exportAs: ["matAutocomplete"] }, { kind: "component", type: i3$3.MatOption, selector: "mat-option", inputs: ["value", "id", "disabled"], outputs: ["onSelectionChange"], exportAs: ["matOption"] }, { kind: "directive", type: i3$3.MatAutocompleteTrigger, selector: "input[matAutocomplete], textarea[matAutocomplete]", inputs: ["matAutocomplete", "matAutocompletePosition", "matAutocompleteConnectedTo", "autocomplete", "matAutocompleteDisabled"], exportAs: ["matAutocompleteTrigger"] }, { kind: "ngmodule", type: MatCheckboxModule }, { kind: "ngmodule", type: MatDatepickerModule }, { kind: "component", type: i4$3.MatDatepicker, selector: "mat-datepicker", exportAs: ["matDatepicker"] }, { kind: "directive", type: i4$3.MatDatepickerInput, selector: "input[matDatepicker]", inputs: ["matDatepicker", "min", "max", "matDatepickerFilter"], exportAs: ["matDatepickerInput"] }, { kind: "component", type: i4$3.MatDatepickerToggle, selector: "mat-datepicker-toggle", inputs: ["for", "tabIndex", "aria-label", "disabled", "disableRipple"], exportAs: ["matDatepickerToggle"] }, { kind: "component", type: i4$3.MatDateRangeInput, selector: "mat-date-range-input", inputs: ["rangePicker", "required", "dateFilter", "min", "max", "disabled", "separator", "comparisonStart", "comparisonEnd"], exportAs: ["matDateRangeInput"] }, { kind: "directive", type: i4$3.MatStartDate, selector: "input[matStartDate]", outputs: ["dateChange", "dateInput"] }, { kind: "directive", type: i4$3.MatEndDate, selector: "input[matEndDate]", outputs: ["dateChange", "dateInput"] }, { kind: "component", type: i4$3.MatDateRangePicker, selector: "mat-date-range-picker", exportAs: ["matDateRangePicker"] }, { kind: "ngmodule", type: MatFormFieldModule }, { kind: "directive", type: i5$2.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatInputModule }, { kind: "ngmodule", type: MatOptionModule }, { kind: "ngmodule", type: MatRadioModule }, { kind: "ngmodule", type: MatRippleModule }, { kind: "directive", type: i5.MatRipple, selector: "[mat-ripple], [matRipple]", inputs: ["matRippleColor", "matRippleUnbounded", "matRippleCentered", "matRippleRadius", "matRippleAnimation", "matRippleDisabled", "matRippleTrigger"], exportAs: ["matRipple"] }, { kind: "ngmodule", type: MatSelectModule }, { kind: "ngmodule", type: MatTabsModule }, { kind: "directive", type: i8.MatTabLabel, selector: "[mat-tab-label], [matTabLabel]" }, { kind: "component", type: i8.MatTab, selector: "mat-tab", inputs: ["disabled", "label", "aria-label", "aria-labelledby", "labelClass", "bodyClass", "id"], exportAs: ["matTab"] }, { kind: "component", type: i8.MatTabGroup, selector: "mat-tab-group", inputs: ["color", "fitInkBarToContent", "mat-stretch-tabs", "mat-align-tabs", "dynamicHeight", "selectedIndex", "headerPosition", "animationDuration", "contentTabIndex", "disablePagination", "disableRipple", "preserveContent", "backgroundColor", "aria-label", "aria-labelledby"], outputs: ["selectedIndexChange", "focusChange", "animationDone", "selectedTabChange"], exportAs: ["matTabGroup"] }, { kind: "ngmodule", type: TextFieldModule }] });
|
|
2930
|
+
}
|
|
2931
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: FiltroBusquedaComponent, decorators: [{
|
|
2932
|
+
type: Component,
|
|
2933
|
+
args: [{ selector: 'jvs-filtro-busqueda', standalone: true, imports: [
|
|
2934
|
+
CommonModule,
|
|
2935
|
+
FormsModule,
|
|
2936
|
+
ReactiveFormsModule,
|
|
2937
|
+
MatAutocompleteModule,
|
|
2938
|
+
MatCheckboxModule,
|
|
2939
|
+
MatDatepickerModule,
|
|
2940
|
+
MatFormFieldModule,
|
|
2941
|
+
MatIconModule,
|
|
2942
|
+
MatInputModule,
|
|
2943
|
+
MatOptionModule,
|
|
2944
|
+
MatRadioModule,
|
|
2945
|
+
MatRippleModule,
|
|
2946
|
+
MatSelectModule,
|
|
2947
|
+
MatTabsModule,
|
|
2948
|
+
TextFieldModule,
|
|
2949
|
+
], host: {
|
|
2950
|
+
class: 'jvsFiltroBusqueda',
|
|
2951
|
+
}, template: "@if (isCargaCompleta()) {\n <div class=\"filtroBusqueda w-full\">\n <div class=\"border-none p-0 flex flex-col\">\n\n @if (dataOpcionesNuevo().length === 1) {\n <div class=\"flex-1 flex items-end max-sm:flex-col flex-wrap gap-2\">\n <ng-container [ngTemplateOutlet]=\"verOpcionesT\"></ng-container>\n </div>\n } @else if (dataOpcionesNuevo().length > 1) {\n <div class=\"flex-1 flex flex-col flex-wrap gap-2 border\">\n <mat-tab-group\n [selectedIndex]=\"tabActual()\"\n (selectedIndexChange)=\"getControlRaiz('opcion').setValue($event)\"\n class=\"flex-1 flex flex-wrap\"\n [mat-stretch-tabs]=\"false\"\n dynamicHeight\n mat-align-tabs=\"start\"\n >\n @for (item of dataOpcionesNuevo(); track $index) {\n <mat-tab [aria-label]=\"(tabActual() === $index) ? 'primary' : ''\">\n <ng-template mat-tab-label>\n @if (tabActual() === $index) {\n <mat-icon class=\"icon-xs\" svgIcon=\"roundVerified\"></mat-icon>\n }\n {{ item.label }}\n </ng-template>\n\n <div class=\"mx-2 mt-0 pt-0 flex flex-col items-end sm:flex-row flex-wrap gap-2\">\n <ng-container [ngTemplateOutlet]=\"verOpcionesT\"></ng-container>\n </div>\n </mat-tab>\n }\n </mat-tab-group>\n </div>\n }\n </div>\n </div>\n}\n\n<ng-template #verOpcionesT>\n @for (campo of dataOpcionesNuevo()[tabActual()]?.campos; track campo.campo) {\n <ng-container [ngTemplateOutletContext]=\"{controlData: campo}\" [ngTemplateOutlet]=\"controlesFormularioNuevo\"></ng-container>\n }\n <ng-container [ngTemplateOutlet]=\"botonFiltrar\"></ng-container>\n</ng-template>\n\n<ng-template #botonFiltrar>\n <button (click)=\"filtrarData()\"\n class=\"flex items-center justify-center bg-primary text-primary-contrast font-bold uppercase text-xs px-2 py-1 rounded shadow-md hover:shadow-lg outline-none focus:outline-none mr-1 mb-1 ease-linear transition-all duration-150\"\n matRipple type=\"button\"\n [disabled]=\"!isCargaCompleta()\"\n >\n <mat-icon class=\"icon-xs\" svgIcon=\"roundFilterAlt\"></mat-icon> \n <span>Filtrar</span>\n </button>\n</ng-template>\n\n<ng-template #controlesFormularioNuevo let-controlData=\"controlData\">\n @switch (controlData.control) {\n @case ('controlAgrupado') {\n <ng-container [ngTemplateOutletContext]=\"{template: inputControlAgrupado, controlData: controlData}\" [ngTemplateOutlet]=\"contenedorInput\"></ng-container>\n }\n @case ('select') {\n <ng-container [ngTemplateOutletContext]=\"{template: inputSelect, controlData: controlData}\" [ngTemplateOutlet]=\"contenedorInput\"></ng-container>\n }\n @case ('autocomplete') {\n <ng-container [ngTemplateOutletContext]=\"{template: inputAutocomplete, controlData: controlData}\" [ngTemplateOutlet]=\"contenedorInput\"></ng-container>\n }\n @case ('date') {\n <ng-container [ngTemplateOutletContext]=\"{template: inputDate, controlData: controlData}\" [ngTemplateOutlet]=\"contenedorInput\"></ng-container>\n }\n @case ('date_range') {\n <ng-container [ngTemplateOutletContext]=\"{template: inputDateRange, controlData: controlData}\" [ngTemplateOutlet]=\"contenedorInput\"></ng-container>\n }\n @case ('checkbox') {\n <ng-container [ngTemplateOutletContext]=\"{template: inputCheckBox, controlData: controlData}\" [ngTemplateOutlet]=\"contenedorInput\"></ng-container>\n }\n @default {\n @if (controlData.control === 'text' || controlData.control === 'number') {\n <ng-container [ngTemplateOutletContext]=\"{template: inputTextNumber, controlData: controlData}\" [ngTemplateOutlet]=\"contenedorInput\"></ng-container>\n }\n }\n }\n</ng-template>\n\n<ng-template #contenedorInput let-template=\"template\" let-controlData=\"controlData\">\n <fieldset [class.flex-auto]=\"!controlData.cssClass\" [class]=\"controlData.cssClass\" class=\"appearance-none contenedorCampo relative\">\n <legend>\n <label [for]=\"controlData.campo\">{{ controlData.label }}@if(controlData.required){<span class=\"text-red-700 font-bold\"> *</span>}</label>\n </legend>\n <ng-container [ngTemplateOutletContext]=\"{controlData: controlData}\" [ngTemplateOutlet]=\"template\"></ng-container>\n </fieldset>\n</ng-template>\n\n<ng-template #inputSelect let-controlData=\"controlData\">\n <select [formControl]=\"getControl(controlData.campo)\"\n (change)=\"cambiarSeleccionNuevo(controlData, $event);\"\n [class]=\"controlData.select?.cssClass?.class\"\n [id]=\"controlData.campo\"\n [required]=\"controlData.required\"\n [class.border-b-red-700]=\"getControl(controlData.campo).invalid\"\n >\n @if (controlData.select?.textoCuandoNulo) {\n <option value=\"\">{{ controlData.select?.textoCuandoNulo }}</option>\n }\n @for (itemSelect of dataServidorSuscripcion[controlData.select?.data!] | async; track $index) {\n <option [class]=\"controlData.select?.cssClass?.option\" [value]=\"campoValorEval(controlData, itemSelect)\">\n {{ campoTextEval(controlData, itemSelect) }}\n </option>\n }\n </select>\n</ng-template>\n\n<ng-template #inputControlAgrupado let-controlData=\"controlData\">\n <div class=\"flex items-center campos-container\">\n @for (sub of controlData.controlAgrupado; track sub.campo) {\n @switch (sub.control) {\n @case ('select') {\n <ng-container [ngTemplateOutletContext]=\"{controlData: sub}\" [ngTemplateOutlet]=\"inputSelect\"></ng-container>\n }\n @case ('autocomplete') {\n <ng-container [ngTemplateOutletContext]=\"{controlData: sub}\" [ngTemplateOutlet]=\"inputAutocomplete\"></ng-container>\n }\n @case ('date') {\n <ng-container [ngTemplateOutletContext]=\"{controlData: sub}\" [ngTemplateOutlet]=\"inputDate\"></ng-container>\n }\n @case ('date_range') {\n <ng-container [ngTemplateOutletContext]=\"{controlData: sub}\" [ngTemplateOutlet]=\"inputDateRange\"></ng-container>\n }\n @case ('checkbox') {\n <ng-container [ngTemplateOutletContext]=\"{controlData: sub}\" [ngTemplateOutlet]=\"inputCheckBox\"></ng-container>\n }\n @default {\n @if (sub.control === 'text' || sub.control === 'number') {\n <ng-container [ngTemplateOutletContext]=\"{controlData: sub}\" [ngTemplateOutlet]=\"inputTextNumber\"></ng-container>\n }\n }\n }\n }\n </div>\n</ng-template>\n\n<ng-template #inputAutocomplete let-controlData=\"controlData\">\n <div class=\"flex items-center formcontrol-container\">\n <input [formControl]=\"getControl(controlData.campo + sufixTemporal)\"\n (input)=\"cambiarNuevo(controlData, $any($event.target).value)\"\n [matAutocomplete]=\"auto\"\n autocomplete=\"off\"\n [id]=\"controlData.campo\"\n placeholder=\"{{ controlData.autocomplete?.textoCuandoNulo ?? controlData.label }}\"\n [required]=\"controlData.required\"\n [class.border-b-red-700]=\"getControl(controlData.campo).invalid\"\n >\n <mat-autocomplete #auto=\"matAutocomplete\"\n (optionSelected)=\"cambiarSeleccionNuevo(controlData, $event)\"\n [panelWidth]=\"'auto'\"\n [displayWith]=\"getAutocompleteLabel.bind(this, controlData)\"\n >\n @for (itemSelect of filtrados[controlData.campo]; track $index) {\n <mat-option [class]=\"controlData.autocomplete?.cssClass?.option\" [value]=\"campoValorEval(controlData, itemSelect)\">\n @if (controlData.autocomplete?.optionInnerHtml) {\n <div [innerHTML]=\"controlData.autocomplete?.optionInnerHtml!(itemSelect)\"></div>\n } @else {\n {{ campoTextEval(controlData, itemSelect) }}\n }\n </mat-option>\n }\n </mat-autocomplete>\n\n <div class=\"flex items-center justify-start\">\n <button (click)=\"limpiarAutocomplete(controlData, $event)\" class=\"boton-circular-gris\"\n matRipple\n type=\"button\"\n >\n <mat-icon [svgIcon]=\"(getControl(controlData.campo).value ? 'roundCancel' : 'roundSearch')\" class=\"icon-2xs\"></mat-icon>\n </button>\n </div>\n </div>\n</ng-template>\n\n<ng-template #inputTextNumber let-controlData=\"controlData\">\n <input (keyup.enter)=\"controlData.keyUpEnter ? filtrarData() : null\"\n [formControl]=\"getControl(controlData.campo)\"\n [type]=\"controlData.control\"\n autocomplete=\"off\"\n [id]=\"controlData.campo\"\n placeholder=\"{{ controlData.label }}\"\n [required]=\"controlData.required\"\n [class.border-b-red-700]=\"getControl(controlData.campo).invalid\"\n >\n</ng-template>\n\n<ng-template #inputDate let-controlData=\"controlData\">\n <div class=\"flex items-center date-container\">\n <input (keyup.enter)=\"controlData.keyUpEnter ? filtrarData() : null\"\n [formControl]=\"getControl(controlData.campo)\"\n (dateChange)=\"cambiarSeleccionNuevo(controlData, $event)\"\n [matDatepicker]=\"i\"\n autocomplete=\"off\"\n [id]=\"controlData.campo\"\n placeholder=\"{{ controlData.label }}\"\n type=\"text\"\n [required]=\"controlData.required\"\n [class.border-b-red-700]=\"getControl(controlData.campo).invalid\"\n >\n <mat-datepicker-toggle [for]=\"i\" class=\"icon-xs\" matSuffix></mat-datepicker-toggle>\n <mat-datepicker #i></mat-datepicker>\n </div>\n</ng-template>\n\n<ng-template #inputDateRange let-controlData=\"controlData\">\n <div class=\"flex items-center daterange-container\">\n <mat-date-range-input [rangePicker]=\"i\">\n <input [formControl]=\"getControl(controlData.dateRange?.campo![0])\" matStartDate placeholder=\"Desde\">\n <input [formControl]=\"getControl(controlData.dateRange?.campo![1])\" matEndDate placeholder=\"Hasta\">\n </mat-date-range-input>\n <mat-datepicker-toggle [for]=\"i\" class=\"icon-xs\"></mat-datepicker-toggle>\n <mat-date-range-picker #i></mat-date-range-picker>\n </div>\n</ng-template>\n\n<ng-template #inputCheckBox let-controlData=\"controlData\">\n <input [formControl]=\"getControl(controlData.campo)\"\n [id]=\"controlData.campo\"\n [required]=\"controlData.required\"\n [class.border-b-red-700]=\"getControl(controlData.campo).invalid\"\n type=\"checkbox\"\n (change)=\"cambiarSeleccionNuevo(controlData, $event)\"\n >\n</ng-template>\n" }]
|
|
2952
|
+
}], ctorParameters: () => [] });
|
|
2326
2953
|
|
|
2327
2954
|
// export {};
|
|
2328
2955
|
// import './src/styles.scss';
|
|
@@ -2331,5 +2958,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImpo
|
|
|
2331
2958
|
* Generated bundle index. Do not edit.
|
|
2332
2959
|
*/
|
|
2333
2960
|
|
|
2334
|
-
export { DialogFlotanteComponent, ListaArbolComponent, LucesNavidadComponent, MatSuffixSearchButtonComponent, MenuComponent, ProgressBarComponent, TablaMantenimientoComponent, TablaMantenimientoService };
|
|
2961
|
+
export { DialogFlotanteComponent, FiltroBusquedaComponent, FiltroBusquedaService, ListaArbolComponent, LucesNavidadComponent, MatSuffixSearchButtonComponent, MenuComponent, ProgressBarComponent, QUERY_SERVICE_TOKEN, TablaMantenimientoComponent, TablaMantenimientoService };
|
|
2335
2962
|
//# sourceMappingURL=jvsoft-components.mjs.map
|