sf-crud 12.0.1-beta2 → 12.0.1-beta21
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundles/sf-crud.umd.js +423 -47
- package/bundles/sf-crud.umd.js.map +1 -1
- package/esm2015/lib/components/control/control.component.js +76 -7
- package/esm2015/lib/components/registro/registro.component.js +125 -19
- package/esm2015/lib/components/registro-child/registro-child.component.js +137 -0
- package/esm2015/lib/components/tablero/tablero.component.js +3 -3
- package/esm2015/lib/sf-crud.module.js +28 -12
- package/esm2015/lib/shared/services/models/crud-config.model.js +1 -1
- package/esm2015/lib/shared/services/models/shema.model.js +1 -1
- package/esm2015/public-api.js +2 -1
- package/fesm2015/sf-crud.js +343 -32
- package/fesm2015/sf-crud.js.map +1 -1
- package/lib/components/control/control.component.d.ts +10 -1
- package/lib/components/registro/registro.component.d.ts +17 -7
- package/lib/components/registro-child/registro-child.component.d.ts +26 -0
- package/lib/components/tablero/tablero.component.d.ts +1 -1
- package/lib/sf-crud.module.d.ts +76 -73
- package/lib/shared/services/models/crud-config.model.d.ts +2 -0
- package/lib/shared/services/models/shema.model.d.ts +1 -0
- package/package.json +1 -1
- package/public-api.d.ts +1 -0
package/fesm2015/sf-crud.js
CHANGED
|
@@ -10,7 +10,7 @@ import * as i4 from 'primeng/toolbar';
|
|
|
10
10
|
import { ToolbarModule } from 'primeng/toolbar';
|
|
11
11
|
import * as i5 from 'primeng/table';
|
|
12
12
|
import { TableModule } from 'primeng/table';
|
|
13
|
-
import * as
|
|
13
|
+
import * as i6 from '@angular/common';
|
|
14
14
|
import * as i3$1 from 'primeng/api';
|
|
15
15
|
import { MessageService } from 'primeng/api';
|
|
16
16
|
import * as i8 from 'primeng/button';
|
|
@@ -21,19 +21,30 @@ import * as i10 from 'primeng/inputtext';
|
|
|
21
21
|
import { InputTextModule } from 'primeng/inputtext';
|
|
22
22
|
import * as i11 from 'primeng/tooltip';
|
|
23
23
|
import { TooltipModule } from 'primeng/tooltip';
|
|
24
|
+
import * as i1$1 from 'primeng/dynamicdialog';
|
|
25
|
+
import { DialogService, DynamicDialogConfig, DynamicDialogRef, DynamicDialogModule } from 'primeng/dynamicdialog';
|
|
24
26
|
import * as jsonpath from 'jsonpath';
|
|
25
|
-
import * as
|
|
27
|
+
import * as i3$3 from 'primeng/toast';
|
|
26
28
|
import { ToastModule } from 'primeng/toast';
|
|
27
|
-
import * as i2$1 from 'primeng/
|
|
29
|
+
import * as i2$1 from 'primeng/inputmask';
|
|
30
|
+
import { InputMaskModule } from 'primeng/inputmask';
|
|
31
|
+
import * as i3$2 from 'primeng/dropdown';
|
|
28
32
|
import { DropdownModule } from 'primeng/dropdown';
|
|
29
|
-
import * as i4$1 from '
|
|
33
|
+
import * as i4$1 from 'primeng/autocomplete';
|
|
34
|
+
import { AutoCompleteModule } from 'primeng/autocomplete';
|
|
35
|
+
import * as i5$1 from 'primeng/calendar';
|
|
36
|
+
import { CalendarModule } from 'primeng/calendar';
|
|
37
|
+
import * as i6$1 from 'primeng/inputnumber';
|
|
38
|
+
import { InputNumberModule } from 'primeng/inputnumber';
|
|
39
|
+
import * as i7 from 'primeng/fileupload';
|
|
40
|
+
import { FileUploadModule } from 'primeng/fileupload';
|
|
41
|
+
import * as i9$1 from '@angular/forms';
|
|
30
42
|
import { FormsModule } from '@angular/forms';
|
|
31
43
|
import { AccordionModule } from 'primeng/accordion';
|
|
32
|
-
import { AvatarModule } from 'primeng/avatar';
|
|
33
44
|
import { AvatarGroupModule } from 'primeng/avatargroup';
|
|
45
|
+
import { AvatarModule } from 'primeng/avatar';
|
|
34
46
|
import { BadgeModule } from 'primeng/badge';
|
|
35
47
|
import { BreadcrumbModule } from 'primeng/breadcrumb';
|
|
36
|
-
import { CalendarModule } from 'primeng/calendar';
|
|
37
48
|
import { CardModule } from 'primeng/card';
|
|
38
49
|
import { CarouselModule } from 'primeng/carousel';
|
|
39
50
|
import { CascadeSelectModule } from 'primeng/cascadeselect';
|
|
@@ -41,33 +52,30 @@ import { CheckboxModule } from 'primeng/checkbox';
|
|
|
41
52
|
import { ChipModule } from 'primeng/chip';
|
|
42
53
|
import { ChipsModule } from 'primeng/chips';
|
|
43
54
|
import { CodeHighlighterModule } from 'primeng/codehighlighter';
|
|
55
|
+
import { ColorPickerModule } from 'primeng/colorpicker';
|
|
44
56
|
import { ConfirmDialogModule } from 'primeng/confirmdialog';
|
|
45
57
|
import { ConfirmPopupModule } from 'primeng/confirmpopup';
|
|
46
|
-
import { ColorPickerModule } from 'primeng/colorpicker';
|
|
47
58
|
import { ContextMenuModule } from 'primeng/contextmenu';
|
|
48
59
|
import { DialogModule } from 'primeng/dialog';
|
|
49
60
|
import { DividerModule } from 'primeng/divider';
|
|
50
61
|
import { FieldsetModule } from 'primeng/fieldset';
|
|
51
|
-
import { FileUploadModule } from 'primeng/fileupload';
|
|
52
62
|
import { GalleriaModule } from 'primeng/galleria';
|
|
53
63
|
import { InplaceModule } from 'primeng/inplace';
|
|
54
|
-
import { InputNumberModule } from 'primeng/inputnumber';
|
|
55
|
-
import { InputMaskModule } from 'primeng/inputmask';
|
|
56
64
|
import { InputSwitchModule } from 'primeng/inputswitch';
|
|
57
65
|
import { InputTextareaModule } from 'primeng/inputtextarea';
|
|
58
66
|
import { KnobModule } from 'primeng/knob';
|
|
59
67
|
import { LightboxModule } from 'primeng/lightbox';
|
|
60
68
|
import { ListboxModule } from 'primeng/listbox';
|
|
61
69
|
import { MegaMenuModule } from 'primeng/megamenu';
|
|
62
|
-
import { MenuModule } from 'primeng/menu';
|
|
63
70
|
import { MenubarModule } from 'primeng/menubar';
|
|
64
|
-
import {
|
|
71
|
+
import { MenuModule } from 'primeng/menu';
|
|
65
72
|
import { MessageModule } from 'primeng/message';
|
|
73
|
+
import { MessagesModule } from 'primeng/messages';
|
|
66
74
|
import { MultiSelectModule } from 'primeng/multiselect';
|
|
67
75
|
import { OrganizationChartModule } from 'primeng/organizationchart';
|
|
68
76
|
import { OverlayPanelModule } from 'primeng/overlaypanel';
|
|
69
|
-
import { PanelModule } from 'primeng/panel';
|
|
70
77
|
import { PanelMenuModule } from 'primeng/panelmenu';
|
|
78
|
+
import { PanelModule } from 'primeng/panel';
|
|
71
79
|
import { PasswordModule } from 'primeng/password';
|
|
72
80
|
import { ProgressBarModule } from 'primeng/progressbar';
|
|
73
81
|
import { RadioButtonModule } from 'primeng/radiobutton';
|
|
@@ -230,7 +238,7 @@ class TableroComponent {
|
|
|
230
238
|
this.btn.update = this.opciones.find(x => x.label == 'Editar');
|
|
231
239
|
this.btn.delete = this.opciones.find(x => x.label == 'Eliminar');
|
|
232
240
|
}
|
|
233
|
-
redirect(
|
|
241
|
+
redirect(accion, data) {
|
|
234
242
|
var _a, _b;
|
|
235
243
|
switch (accion) {
|
|
236
244
|
case 'create':
|
|
@@ -251,7 +259,7 @@ class TableroComponent {
|
|
|
251
259
|
}
|
|
252
260
|
}
|
|
253
261
|
TableroComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: TableroComponent, deps: [{ token: GeneralService }, { token: i2.Router }], target: i0.ɵɵFactoryTarget.Component });
|
|
254
|
-
TableroComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: TableroComponent, selector: "sf-crudtablero", inputs: { opciones: "opciones", idEntidad: "idEntidad", idKatios: "idKatios" }, ngImport: i0, template: "<p-blockUI [blocked]=\"enProceso\">\r\n <i class=\"pi pi-cog pi-spin\" style=\"font-size: 50px\"></i>\r\n</p-blockUI>\r\n\r\n<div class=\"card\" *ngIf=\"!enProceso\">\r\n <p-toolbar styleClass=\"mb-4 gap-2\">\r\n <ng-template pTemplate=\"left\">\r\n <button *ngIf=\"btn.create\" pButton pRipple [label]=\"btn.create.label\" [icon]=\"btn.create.icon\"\r\n class=\"p-button-success mr-2\" (click)=\"redirect(
|
|
262
|
+
TableroComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: TableroComponent, selector: "sf-crudtablero", inputs: { opciones: "opciones", idEntidad: "idEntidad", idKatios: "idKatios" }, ngImport: i0, template: "<p-blockUI [blocked]=\"enProceso\">\r\n <i class=\"pi pi-cog pi-spin\" style=\"font-size: 50px\"></i>\r\n</p-blockUI>\r\n\r\n<div class=\"card\" *ngIf=\"!enProceso\">\r\n <p-toolbar styleClass=\"mb-4 gap-2\">\r\n <ng-template pTemplate=\"left\">\r\n <button *ngIf=\"btn.create\" pButton pRipple [label]=\"btn.create.label\" [icon]=\"btn.create.icon\"\r\n class=\"p-button-success mr-2\" (click)=\"redirect('create')\"></button>\r\n </ng-template>\r\n </p-toolbar>\r\n <p-table #dt [columns]=\"crudConfig.tablero.columns\" [value]=\"data\" [rowHover]=\"true\" [rows]=\"10\" [paginator]=\"true\"\r\n [globalFilterFields]=\"crudConfig.tablero?.filters || []\" [tableStyle]=\"{'min-width': '75rem'}\"\r\n currentPageReportTemplate=\"Registro {first} al {last} de {totalRecords} {{idEntidad}}\"\r\n [showCurrentPageReport]=\"true\">\r\n <ng-template pTemplate=\"caption\">\r\n <div class=\"flex align-items-center justify-content-between\">\r\n <h5 class=\"m-0\">{{idEntidad}}</h5>\r\n <span class=\"p-input-icon-left\">\r\n <i class=\"pi pi-search\"></i>\r\n <input pInputText type=\"text\" (input)=\"dt.filterGlobal($event.target.value, 'contains')\"\r\n placeholder=\"Buscar...\" />\r\n </span>\r\n </div>\r\n </ng-template>\r\n <ng-template pTemplate=\"header\" let-columns>\r\n <tr>\r\n <th *ngFor=\"let col of columns\">\r\n {{col.label}}\r\n </th>\r\n <th>Acci\u00F3n</th>\r\n </tr>\r\n </ng-template>\r\n <ng-template pTemplate=\"body\" let-rowData let-columns=\"columns\">\r\n <tr>\r\n <ng-container *ngFor=\"let col of columns\" [ngSwitch]=\"col.type\">\r\n <td *ngSwitchCase=\"'text'\">{{rowData[col.col]}}</td>\r\n <td *ngSwitchCase=\"'date:yyyy-mm-dd'\">{{rowData[col.col] | date: 'yyyy-MM-dd'}}</td>\r\n <td *ngSwitchCase=\"'currency:USD'\">{{rowData[col.col] | currency: 'USD'}}</td>\r\n </ng-container>\r\n <th>\r\n <button *ngIf=\"btn.read\" pButton pRipple [pTooltip]=\"btn.read.label\" [icon]=\"btn.read.icon\"\r\n class=\"p-button-rounded p-button-info mr-2\" (click)=\"redirect('read', rowData)\"></button>\r\n <button *ngIf=\"btn.update\" pButton pRipple [pTooltip]=\"btn.update.label\" [icon]=\"btn.update.icon\"\r\n class=\"p-button-rounded p-button-warning mr-2\" (click)=\"redirect('update', rowData)\"></button>\r\n <button *ngIf=\"btn.delete\" pButton pRipple [pTooltip]=\"btn.delete.label\" [icon]=\"btn.delete.icon\"\r\n class=\"p-button-rounded p-button-danger mr-2\" (click)=\"redirect('delete', rowData)\"></button>\r\n </th>\r\n </tr>\r\n </ng-template>\r\n </p-table>\r\n</div>", components: [{ type: i3.BlockUI, selector: "p-blockUI", inputs: ["target", "autoZIndex", "baseZIndex", "styleClass", "blocked"] }, { type: i4.Toolbar, selector: "p-toolbar", inputs: ["style", "styleClass"] }, { type: i5.Table, selector: "p-table", inputs: ["frozenColumns", "frozenValue", "style", "styleClass", "tableStyle", "tableStyleClass", "paginator", "pageLinks", "rowsPerPageOptions", "alwaysShowPaginator", "paginatorPosition", "paginatorDropdownAppendTo", "paginatorDropdownScrollHeight", "currentPageReportTemplate", "showCurrentPageReport", "showJumpToPageDropdown", "showFirstLastIcon", "showPageLinks", "defaultSortOrder", "sortMode", "resetPageOnSort", "selectionMode", "contextMenuSelection", "contextMenuSelectionMode", "dataKey", "metaKeySelection", "rowTrackBy", "lazy", "lazyLoadOnInit", "compareSelectionBy", "csvSeparator", "exportFilename", "filters", "globalFilterFields", "filterDelay", "filterLocale", "expandedRowKeys", "editingRowKeys", "rowExpandMode", "scrollable", "scrollDirection", "rowGroupMode", "scrollHeight", "virtualScroll", "virtualScrollDelay", "virtualRowHeight", "frozenWidth", "responsive", "contextMenu", "resizableColumns", "columnResizeMode", "reorderableColumns", "loading", "loadingIcon", "showLoader", "rowHover", "customSort", "showInitialSortBadge", "autoLayout", "exportFunction", "stateKey", "stateStorage", "editMode", "groupRowsBy", "minBufferPx", "maxBufferPx", "responsiveLayout", "breakpoint", "value", "columns", "first", "rows", "totalRecords", "sortField", "sortOrder", "multiSortMeta", "selection"], outputs: ["selectionChange", "contextMenuSelectionChange", "onRowSelect", "onRowUnselect", "onPage", "onSort", "onFilter", "onLazyLoad", "onRowExpand", "onRowCollapse", "onContextMenuSelect", "onColResize", "onColReorder", "onRowReorder", "onEditInit", "onEditComplete", "onEditCancel", "onHeaderCheckboxToggle", "sortFunction", "firstChange", "rowsChange", "onStateSave", "onStateRestore"] }], directives: [{ type: i6.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i3$1.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { type: i8.ButtonDirective, selector: "[pButton]", inputs: ["iconPos", "loadingIcon", "label", "icon", "loading"] }, { type: i9.Ripple, selector: "[pRipple]" }, { type: i10.InputText, selector: "[pInputText]" }, { type: i6.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i6.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i6.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { type: i11.Tooltip, selector: "[pTooltip]", inputs: ["tooltipPosition", "tooltipEvent", "appendTo", "positionStyle", "tooltipStyleClass", "tooltipZIndex", "escape", "showDelay", "hideDelay", "life", "positionTop", "positionLeft", "pTooltip", "tooltipDisabled", "tooltipOptions"] }], pipes: { "date": i6.DatePipe, "currency": i6.CurrencyPipe } });
|
|
255
263
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: TableroComponent, decorators: [{
|
|
256
264
|
type: Component,
|
|
257
265
|
args: [{
|
|
@@ -272,17 +280,47 @@ class ControlComponent {
|
|
|
272
280
|
this.control = new Shema();
|
|
273
281
|
this.label = '';
|
|
274
282
|
this.setValue = new EventEmitter();
|
|
283
|
+
this.sendNotification = new EventEmitter();
|
|
275
284
|
this.isLoading = false;
|
|
276
285
|
this.dataFromService = [];
|
|
286
|
+
this.uploadedFiles = [];
|
|
287
|
+
this.displayAdd = false;
|
|
277
288
|
}
|
|
278
289
|
ngOnInit() {
|
|
279
290
|
var _a;
|
|
280
|
-
if ((_a = this.control) === null || _a === void 0 ? void 0 : _a.config)
|
|
291
|
+
if (((_a = this.control) === null || _a === void 0 ? void 0 : _a.config) && this.control.subtype == 'dropdown')
|
|
281
292
|
this.loadDataFromService();
|
|
282
293
|
}
|
|
283
294
|
sendValue() {
|
|
284
295
|
this.setValue.emit(this.value);
|
|
285
296
|
}
|
|
297
|
+
sendValueFromObject(event) {
|
|
298
|
+
switch (typeof (this.control.config.optionValue)) {
|
|
299
|
+
case 'object':
|
|
300
|
+
this.control.config.optionValue.forEach((op) => op['value'] = event[op.key]);
|
|
301
|
+
this.setValue.emit(this.control.config.optionValue);
|
|
302
|
+
break;
|
|
303
|
+
default:
|
|
304
|
+
this.setValue.emit(event[this.control.config.optionValue]);
|
|
305
|
+
break;
|
|
306
|
+
}
|
|
307
|
+
}
|
|
308
|
+
validateValue(type) {
|
|
309
|
+
switch (type) {
|
|
310
|
+
case 'email':
|
|
311
|
+
let regex = new RegExp(/([\w\.\-_]+)?\w+@[\w-_]+(\.\w+){1,}/igm);
|
|
312
|
+
if (regex.test(this.value))
|
|
313
|
+
this.sendValue();
|
|
314
|
+
else {
|
|
315
|
+
this.value = null;
|
|
316
|
+
this.sendValue();
|
|
317
|
+
this.sendNotification.emit({ severity: 'warn', detail: 'El correo no es válido' });
|
|
318
|
+
}
|
|
319
|
+
break;
|
|
320
|
+
default:
|
|
321
|
+
break;
|
|
322
|
+
}
|
|
323
|
+
}
|
|
286
324
|
loadDataFromService() {
|
|
287
325
|
this.isLoading = true;
|
|
288
326
|
this.generalService.genericRequest(this.control.config.method, this.control.config.server, this.control.config.endpoint)
|
|
@@ -291,9 +329,38 @@ class ControlComponent {
|
|
|
291
329
|
this.isLoading = false;
|
|
292
330
|
});
|
|
293
331
|
}
|
|
332
|
+
loadDataFromControlBusquedaService(event) {
|
|
333
|
+
this.isLoading = true;
|
|
334
|
+
this.generalService.genericRequest(this.control.config.method, this.control.config.server, this.control.config.endpoint.replace('@query', (event === null || event === void 0 ? void 0 : event.query) || ''))
|
|
335
|
+
.then((res) => {
|
|
336
|
+
this.dataFromService = res.data;
|
|
337
|
+
this.isLoading = false;
|
|
338
|
+
});
|
|
339
|
+
}
|
|
340
|
+
onUpload(event) {
|
|
341
|
+
let file = event.files[0];
|
|
342
|
+
let formData = new FormData();
|
|
343
|
+
let path = 'Imagenes/CRUD/temp';
|
|
344
|
+
formData.append('uploadFile', file);
|
|
345
|
+
formData.append('Ruta', `/${path}`);
|
|
346
|
+
this.isLoading = true;
|
|
347
|
+
this.generalService.genericRequest(this.control.config.method, this.control.config.server, this.control.config.endpoint, formData)
|
|
348
|
+
.then(() => {
|
|
349
|
+
this.sendNotification.emit({ severity: 'info', detail: `Archivo cargado correctamente!` });
|
|
350
|
+
this.uploadedFiles.push(file);
|
|
351
|
+
this.isLoading = false;
|
|
352
|
+
this.value = `${this.generalService.jsonConfig.Server}${path}/${file.name}`;
|
|
353
|
+
this.sendValue();
|
|
354
|
+
})
|
|
355
|
+
.catch(err => {
|
|
356
|
+
console.log(err);
|
|
357
|
+
this.isLoading = false;
|
|
358
|
+
this.sendNotification.emit({ severity: 'error', detail: `Error al cargar el archivo!` });
|
|
359
|
+
});
|
|
360
|
+
}
|
|
294
361
|
}
|
|
295
362
|
ControlComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: ControlComponent, deps: [{ token: GeneralService }], target: i0.ɵɵFactoryTarget.Component });
|
|
296
|
-
ControlComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: ControlComponent, selector: "sf-control", inputs: { control: "control", label: "label", value: "value" }, outputs: { setValue: "setValue" }, ngImport: i0, template: "<ng-container [ngSwitch]=\"control.type\">\r\n <ng-container *ngSwitchCase=\"'string'\">\r\n <label>{{label}}</label>\r\n <ng-container [ngSwitch]=\"control.subtype\">\r\n <ng-container *ngSwitchCase=\"'input'\">\r\n <input pInputText type=\"text\" [(ngModel)]=\"value\" (focusout)=\"sendValue()\">\r\n </ng-container>\r\n <ng-container *ngSwitchCase=\"'password'\">\r\n <input pInputText type=\"password\" [(ngModel)]=\"value\" (focusout)=\"sendValue()\">\r\n </ng-container>\r\n <ng-container *ngSwitchCase=\"'enum'\">\r\n <p-dropdown [options]=\"control.enum\" [(ngModel)]=\"value\" (onChange)=\"sendValue()\"\r\n placeholder=\"Seleccione una opci\u00F3n\"></p-dropdown>\r\n </ng-container>\r\n <ng-container *ngSwitchCase=\"'dropdown'\">\r\n <p-dropdown [lazy]=\"isLoading\" [options]=\"dataFromService\" [(ngModel)]=\"value\" (onChange)=\"sendValue()\"\r\n [optionLabel]=\"control.config.optionLabel\" [optionValue]=\"control.config.optionValue\"\r\n placeholder=\"Seleccione una opci\u00F3n\"></p-dropdown>\r\n </ng-container>\r\n </ng-container>\r\n </ng-container>\r\n</ng-container>", components: [{ type: i2$1.Dropdown, selector: "p-dropdown", inputs: ["scrollHeight", "resetFilterOnHide", "dropdownIcon", "optionGroupChildren", "autoDisplayFirst", "emptyFilterMessage", "emptyMessage", "autoZIndex", "baseZIndex", "showTransitionOptions", "hideTransitionOptions", "filterMatchMode", "tooltip", "tooltipPosition", "tooltipPositionStyle", "autofocusFilter", "disabled", "options", "filterValue", "filter", "name", "style", "panelStyle", "styleClass", "panelStyleClass", "readonly", "required", "editable", "appendTo", "tabindex", "placeholder", "filterPlaceholder", "filterLocale", "inputId", "selectId", "dataKey", "filterBy", "autofocus", "optionLabel", "optionValue", "optionDisabled", "optionGroupLabel", "group", "showClear", "virtualScroll", "itemSize", "ariaFilterLabel", "ariaLabelledBy", "maxlength", "tooltipStyleClass"], outputs: ["onChange", "onFilter", "onFocus", "onBlur", "onClick", "onShow", "onHide"] }], directives: [{ type: i7.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i7.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { type: i4$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]" }, { type: i10.InputText, selector: "[pInputText]" }, { type: i4$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i4$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }] });
|
|
363
|
+
ControlComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: ControlComponent, selector: "sf-control", inputs: { control: "control", label: "label", value: "value", appendTo: "appendTo" }, outputs: { setValue: "setValue", sendNotification: "sendNotification" }, ngImport: i0, template: "<!-- <p-blockUI [blocked]=\"isLoading\" [target]=\"cc\">\r\n <i class=\"pi pi-cog pi-spin\" style=\"font-size: 50px\"></i>\r\n</p-blockUI> -->\r\n\r\n<ng-container [ngSwitch]=\"control.type\">\r\n <label>{{label}}</label>\r\n <ng-container *ngSwitchCase=\"'string'\">\r\n <ng-container [ngSwitch]=\"control.subtype\">\r\n <ng-container *ngSwitchCase=\"'input'\">\r\n <input pInputText type=\"text\" [(ngModel)]=\"value\" (focusout)=\"sendValue()\">\r\n </ng-container>\r\n <ng-container *ngSwitchCase=\"'password'\">\r\n <input pInputText type=\"password\" [(ngModel)]=\"value\" (focusout)=\"sendValue()\">\r\n </ng-container>\r\n <ng-container *ngSwitchCase=\"'email'\">\r\n <input pInputText type=\"text\" [(ngModel)]=\"value\" placeholder=\"email@example.com\"\r\n (focusout)=\"validateValue('email')\">\r\n </ng-container>\r\n <ng-container *ngSwitchCase=\"'phone'\">\r\n <p-inputMask mask=\"(999) 999-9999\" [(ngModel)]=\"value\" placeholder=\"(999) 999-9999\"\r\n (focusout)=\"sendValue()\"></p-inputMask>\r\n </ng-container>\r\n <ng-container *ngSwitchCase=\"'enum'\">\r\n <p-dropdown [options]=\"control.enum\" [(ngModel)]=\"value\" (onChange)=\"sendValue()\" [appendTo]=\"appendTo\"\r\n placeholder=\"Seleccione una opci\u00F3n\"></p-dropdown>\r\n </ng-container>\r\n <ng-container *ngSwitchCase=\"'dropdown'\">\r\n <p-dropdown [lazy]=\"isLoading\" [options]=\"dataFromService\" [(ngModel)]=\"value\" (onChange)=\"sendValue()\"\r\n [optionLabel]=\"control.config.optionLabel\" [optionValue]=\"control.config.optionValue\"\r\n [appendTo]=\"appendTo\" placeholder=\"Seleccione una opci\u00F3n\"></p-dropdown>\r\n </ng-container>\r\n <ng-container *ngSwitchCase=\"'autocomplete'\">\r\n <p-autoComplete [showEmptyMessage]=\"true\" [suggestions]=\"dataFromService\" [appendTo]=\"appendTo\"\r\n (completeMethod)=\"loadDataFromControlBusquedaService($event)\" [field]=\"control.field\"\r\n [minLength]=\"1\" (onSelect)=\"sendValueFromObject($event)\"></p-autoComplete>\r\n </ng-container>\r\n </ng-container>\r\n </ng-container>\r\n <ng-container *ngSwitchCase=\"'date'\">\r\n <ng-container [ngSwitch]=\"control.subtype\">\r\n <ng-container *ngSwitchCase=\"'calendar'\">\r\n <p-calendar [(ngModel)]=\"value\" (onSelect)=\"sendValue()\" [monthNavigator]=\"true\" [yearNavigator]=\"true\"\r\n yearRange=\"1900:2035\" [dateFormat]=\"control?.format || 'yy-mm-dd'\" [appendTo]=\"appendTo\"></p-calendar>\r\n </ng-container>\r\n </ng-container>\r\n </ng-container>\r\n <ng-container *ngSwitchCase=\"'numeric'\">\r\n <ng-container [ngSwitch]=\"control.subtype\">\r\n <ng-container *ngSwitchCase=\"'currency'\">\r\n <p-inputNumber [(ngModel)]=\"value\" mode=\"currency\" [minFractionDigits]=\"control?.minFractionDigits || 0\"\r\n [min]=\"control?.min || null\" [max]=\"control?.max || null\" (focusout)=\"sendValue()\"\r\n [currency]=\"control?.currency || 'USD'\"></p-inputNumber>\r\n </ng-container>\r\n <ng-container *ngSwitchCase=\"'decimal'\">\r\n <p-inputNumber [(ngModel)]=\"value\" mode=\"decimal\" (focusout)=\"sendValue()\" [min]=\"control?.min || null\"\r\n [max]=\"control?.max || null\" [minFractionDigits]=\"control?.minFractionDigits || 0\"></p-inputNumber>\r\n </ng-container>\r\n <ng-container *ngSwitchCase=\"'percentage'\">\r\n <p-inputNumber [(ngModel)]=\"value\" suffix=\" %\" (focusout)=\"sendValue()\" [min]=\"control?.min || null\"\r\n [max]=\"control?.max || null\" [minFractionDigits]=\"control?.minFractionDigits || 2\"></p-inputNumber>\r\n </ng-container>\r\n </ng-container>\r\n </ng-container>\r\n <ng-container *ngSwitchCase=\"'file'\">\r\n <ng-container [ngSwitch]=\"control.subtype\">\r\n <ng-container *ngSwitchCase=\"'filetmp'\">\r\n <p-fileUpload [accept]=\"control.config.accept\" [customUpload]=\"true\" (uploadHandler)=\"onUpload($event)\"\r\n [maxFileSize]=\"control.config?.maxFileSize || null\" fileLimit=\"1\">\r\n <ng-template pTemplate=\"content\">\r\n <ul *ngIf=\"uploadedFiles.length\">\r\n <li *ngFor=\"let file of uploadedFiles\">{{file.name}} - {{file.size}} bytes</li>\r\n </ul>\r\n </ng-template>\r\n </p-fileUpload>\r\n </ng-container>\r\n </ng-container>\r\n </ng-container>\r\n</ng-container>", components: [{ type: i2$1.InputMask, selector: "p-inputMask", inputs: ["type", "slotChar", "autoClear", "style", "inputId", "styleClass", "placeholder", "size", "maxlength", "tabindex", "title", "ariaLabel", "ariaRequired", "disabled", "readonly", "unmask", "name", "required", "characterPattern", "autoFocus", "autocomplete", "mask"], outputs: ["onComplete", "onFocus", "onBlur", "onInput", "onKeydown"] }, { type: i3$2.Dropdown, selector: "p-dropdown", inputs: ["scrollHeight", "filter", "name", "style", "panelStyle", "styleClass", "panelStyleClass", "readonly", "required", "editable", "appendTo", "tabindex", "placeholder", "filterPlaceholder", "filterLocale", "inputId", "selectId", "dataKey", "filterBy", "autofocus", "resetFilterOnHide", "dropdownIcon", "optionLabel", "optionValue", "optionDisabled", "optionGroupLabel", "optionGroupChildren", "autoDisplayFirst", "group", "showClear", "emptyFilterMessage", "emptyMessage", "virtualScroll", "itemSize", "autoZIndex", "baseZIndex", "showTransitionOptions", "hideTransitionOptions", "ariaFilterLabel", "ariaLabelledBy", "filterMatchMode", "maxlength", "tooltip", "tooltipPosition", "tooltipPositionStyle", "tooltipStyleClass", "autofocusFilter", "disabled", "options", "filterValue"], outputs: ["onChange", "onFilter", "onFocus", "onBlur", "onClick", "onShow", "onHide"] }, { type: i4$1.AutoComplete, selector: "p-autoComplete", inputs: ["minLength", "delay", "style", "panelStyle", "styleClass", "panelStyleClass", "inputStyle", "inputId", "inputStyleClass", "placeholder", "readonly", "disabled", "virtualScroll", "itemSize", "maxlength", "name", "required", "size", "appendTo", "autoHighlight", "forceSelection", "type", "autoZIndex", "baseZIndex", "ariaLabel", "ariaLabelledBy", "dropdownIcon", "unique", "group", "completeOnFocus", "field", "scrollHeight", "dropdown", "showEmptyMessage", "dropdownMode", "multiple", "tabindex", "dataKey", "emptyMessage", "showTransitionOptions", "hideTransitionOptions", "autofocus", "autocomplete", "optionGroupChildren", "optionGroupLabel", "suggestions"], outputs: ["completeMethod", "onSelect", "onUnselect", "onFocus", "onBlur", "onDropdownClick", "onClear", "onKeyUp", "onShow", "onHide"] }, { type: i5$1.Calendar, selector: "p-calendar", inputs: ["style", "styleClass", "inputStyle", "inputId", "name", "inputStyleClass", "placeholder", "ariaLabelledBy", "disabled", "dateFormat", "multipleSeparator", "rangeSeparator", "inline", "showOtherMonths", "selectOtherMonths", "showIcon", "icon", "appendTo", "readonlyInput", "shortYearCutoff", "monthNavigator", "yearNavigator", "hourFormat", "timeOnly", "stepHour", "stepMinute", "stepSecond", "showSeconds", "required", "showOnFocus", "showWeek", "dataType", "selectionMode", "maxDateCount", "showButtonBar", "todayButtonStyleClass", "clearButtonStyleClass", "autoZIndex", "baseZIndex", "panelStyleClass", "panelStyle", "keepInvalid", "hideOnDateTimeSelect", "numberOfMonths", "view", "touchUI", "timeSeparator", "focusTrap", "firstDayOfWeek", "showTransitionOptions", "hideTransitionOptions", "tabindex", "defaultDate", "minDate", "maxDate", "disabledDates", "disabledDays", "yearRange", "showTime", "locale"], outputs: ["onFocus", "onBlur", "onClose", "onSelect", "onInput", "onTodayClick", "onClearClick", "onMonthChange", "onYearChange", "onClickOutside", "onShow"] }, { type: i6$1.InputNumber, selector: "p-inputNumber", inputs: ["showButtons", "format", "buttonLayout", "inputId", "styleClass", "style", "placeholder", "size", "maxlength", "tabindex", "title", "ariaLabel", "ariaRequired", "name", "required", "autocomplete", "min", "max", "incrementButtonClass", "decrementButtonClass", "incrementButtonIcon", "decrementButtonIcon", "step", "inputStyle", "inputStyleClass", "locale", "localeMatcher", "mode", "currency", "currencyDisplay", "useGrouping", "minFractionDigits", "maxFractionDigits", "prefix", "suffix", "disabled"], outputs: ["onInput", "onFocus", "onBlur", "onKeyDown"] }, { type: i7.FileUpload, selector: "p-fileUpload", inputs: ["name", "url", "method", "multiple", "accept", "disabled", "auto", "withCredentials", "maxFileSize", "invalidFileSizeMessageSummary", "invalidFileSizeMessageDetail", "invalidFileTypeMessageSummary", "invalidFileTypeMessageDetail", "invalidFileLimitMessageDetail", "invalidFileLimitMessageSummary", "style", "styleClass", "previewWidth", "chooseLabel", "uploadLabel", "cancelLabel", "chooseIcon", "uploadIcon", "cancelIcon", "showUploadButton", "showCancelButton", "mode", "headers", "customUpload", "fileLimit", "files"], outputs: ["onBeforeUpload", "onSend", "onUpload", "onError", "onClear", "onRemove", "onSelect", "onProgress", "uploadHandler"] }], directives: [{ type: i6.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i6.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { type: i9$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]" }, { type: i10.InputText, selector: "[pInputText]" }, { type: i9$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i9$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: i3$1.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { type: i6.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i6.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }] });
|
|
297
364
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: ControlComponent, decorators: [{
|
|
298
365
|
type: Component,
|
|
299
366
|
args: [{
|
|
@@ -306,22 +373,154 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImpo
|
|
|
306
373
|
type: Input
|
|
307
374
|
}], value: [{
|
|
308
375
|
type: Input
|
|
376
|
+
}], appendTo: [{
|
|
377
|
+
type: Input
|
|
309
378
|
}], setValue: [{
|
|
310
379
|
type: Output
|
|
380
|
+
}], sendNotification: [{
|
|
381
|
+
type: Output
|
|
311
382
|
}] } });
|
|
312
383
|
|
|
384
|
+
class RegistroChildComponent {
|
|
385
|
+
constructor(ref, config, messageService) {
|
|
386
|
+
this.ref = ref;
|
|
387
|
+
this.config = config;
|
|
388
|
+
this.messageService = messageService;
|
|
389
|
+
this.esquema = new Shema();
|
|
390
|
+
}
|
|
391
|
+
ngOnInit() {
|
|
392
|
+
var _a;
|
|
393
|
+
this.uiEsquema = this.config.data.uiEsquema[0];
|
|
394
|
+
this.esquema = this.config.data.esquema;
|
|
395
|
+
this.data = (_a = this.config.data) === null || _a === void 0 ? void 0 : _a.data;
|
|
396
|
+
if (!this.data) {
|
|
397
|
+
this.data = this.createObject(this.esquema);
|
|
398
|
+
this.setValue(this.config.data.id, '$..id');
|
|
399
|
+
}
|
|
400
|
+
}
|
|
401
|
+
getControl(scope) {
|
|
402
|
+
return jsonpath.query(this.esquema, scope)[0];
|
|
403
|
+
}
|
|
404
|
+
getValue(scope) {
|
|
405
|
+
return jsonpath.query(this.data, scope.replace('.properties', ''))[0];
|
|
406
|
+
}
|
|
407
|
+
setValue(value, scope) {
|
|
408
|
+
switch (typeof (value)) {
|
|
409
|
+
case 'object':
|
|
410
|
+
value.forEach((val) => jsonpath.value(this.data, val.scope.replace('.properties', ''), val.value));
|
|
411
|
+
break;
|
|
412
|
+
default:
|
|
413
|
+
jsonpath.value(this.data, scope.replace('.properties', ''), value);
|
|
414
|
+
break;
|
|
415
|
+
}
|
|
416
|
+
}
|
|
417
|
+
createObject(esquema) {
|
|
418
|
+
let object = {};
|
|
419
|
+
switch (esquema.type) {
|
|
420
|
+
case 'numeric':
|
|
421
|
+
return (esquema === null || esquema === void 0 ? void 0 : esquema.default) || 0;
|
|
422
|
+
case 'string':
|
|
423
|
+
case 'date':
|
|
424
|
+
return (esquema === null || esquema === void 0 ? void 0 : esquema.default) ? this.setDefaultValue(esquema.default) : null;
|
|
425
|
+
case 'boolean':
|
|
426
|
+
return (esquema === null || esquema === void 0 ? void 0 : esquema.default) || false;
|
|
427
|
+
case 'file':
|
|
428
|
+
return null;
|
|
429
|
+
case 'array':
|
|
430
|
+
case 'object':
|
|
431
|
+
for (const key in esquema === null || esquema === void 0 ? void 0 : esquema.properties) {
|
|
432
|
+
Object.defineProperty(object, key, { value: this.createObject(esquema === null || esquema === void 0 ? void 0 : esquema.properties[key]), writable: true, enumerable: true, configurable: true });
|
|
433
|
+
}
|
|
434
|
+
break;
|
|
435
|
+
default:
|
|
436
|
+
break;
|
|
437
|
+
}
|
|
438
|
+
return object;
|
|
439
|
+
}
|
|
440
|
+
setDefaultValue(value) {
|
|
441
|
+
let data = null;
|
|
442
|
+
let uactivo;
|
|
443
|
+
switch (value) {
|
|
444
|
+
case '@uactivo':
|
|
445
|
+
uactivo = JSON.parse(localStorage.getItem('oSessionTFM') || '{}');
|
|
446
|
+
if (!uactivo)
|
|
447
|
+
console.log('Validar configuracion de sesion');
|
|
448
|
+
else
|
|
449
|
+
data = `${uactivo.UsuarioSistema.TDOC}-${uactivo.UsuarioSistema.NDOC}`;
|
|
450
|
+
break;
|
|
451
|
+
case '@tdocactivo':
|
|
452
|
+
uactivo = JSON.parse(sessionStorage.getItem('usrSesion') || '{}');
|
|
453
|
+
if (!uactivo)
|
|
454
|
+
console.log('Validar configuracion de sesion');
|
|
455
|
+
else
|
|
456
|
+
data = uactivo.UsuarioSistema.TDOC;
|
|
457
|
+
break;
|
|
458
|
+
case '@ndocactivo':
|
|
459
|
+
uactivo = JSON.parse(sessionStorage.getItem('usrSesion') || '{}');
|
|
460
|
+
if (!uactivo)
|
|
461
|
+
console.log('Validar configuracion de sesion');
|
|
462
|
+
else
|
|
463
|
+
data = uactivo.UsuarioSistema.NDOC;
|
|
464
|
+
break;
|
|
465
|
+
case '@hoy':
|
|
466
|
+
data = new Date();
|
|
467
|
+
break;
|
|
468
|
+
default:
|
|
469
|
+
data = value;
|
|
470
|
+
break;
|
|
471
|
+
}
|
|
472
|
+
return data;
|
|
473
|
+
}
|
|
474
|
+
submit() {
|
|
475
|
+
if (!this.validateData())
|
|
476
|
+
return;
|
|
477
|
+
this.ref.close(this.data);
|
|
478
|
+
}
|
|
479
|
+
cancel() {
|
|
480
|
+
this.ref.close();
|
|
481
|
+
}
|
|
482
|
+
validateData() {
|
|
483
|
+
if (this.esquema.validations.type == 'local')
|
|
484
|
+
return this.validateDataLocal();
|
|
485
|
+
return true;
|
|
486
|
+
}
|
|
487
|
+
validateDataLocal() {
|
|
488
|
+
let err = [];
|
|
489
|
+
this.esquema.validations.required.forEach((x) => {
|
|
490
|
+
if (!jsonpath.query(this.data, x.field)[0])
|
|
491
|
+
err.push(x.message);
|
|
492
|
+
});
|
|
493
|
+
if (err.length != 0)
|
|
494
|
+
this.messageService.add({ severity: 'warn', detail: err.join('. ') });
|
|
495
|
+
return err.length == 0;
|
|
496
|
+
}
|
|
497
|
+
}
|
|
498
|
+
RegistroChildComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: RegistroChildComponent, deps: [{ token: i1$1.DynamicDialogRef }, { token: i1$1.DynamicDialogConfig }, { token: i3$1.MessageService }], target: i0.ɵɵFactoryTarget.Component });
|
|
499
|
+
RegistroChildComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: RegistroChildComponent, selector: "lib-registro-child", providers: [MessageService], ngImport: i0, template: "<p-toast></p-toast>\n<div *ngFor=\"let element of uiEsquema.elements\" [class]=\"element?.class\">\n <ng-container [ngSwitch]=\"element.type\">\n <div *ngSwitchCase=\"'Label'\" [style]=\"element?.style\">\n {{element?.label}}\n </div>\n <ng-container *ngSwitchCase=\"'HorizontalLayout'\">\n <div *ngFor=\"let el of element.elements\" [class]=\"el?.class\" #a>\n <ng-container [ngSwitch]=\"el.type\">\n <sf-control *ngSwitchCase=\"'Control'\" [control]=\"getControl(el.scope)\" [label]=\"el.label\"\n [value]=\"getValue(el.scope)\" (setValue)=\"setValue($event, el.scope)\" \n (sendNotification)=\"sendNotification($event)\"></sf-control>\n </ng-container>\n </div>\n </ng-container>\n <ng-container *ngSwitchCase=\"'VerticalLayout'\">\n <div *ngFor=\"let el of element.elements\" [class]=\"el?.class\">\n <ng-container [ngSwitch]=\"el.type\" #b>\n <sf-control *ngSwitchCase=\"'Control'\" [control]=\"getControl(el.scope)\" [label]=\"el.label\"\n [value]=\"getValue(el.scope)\" (setValue)=\"setValue($event, el.scope)\" [appendTo]=\"b\"\n (sendNotification)=\"sendNotification($event)\"></sf-control>\n </ng-container>\n </div>\n </ng-container>\n <ng-container *ngSwitchCase=\"'Control'\" #c>\n <sf-control [control]=\"getControl(element.scope)\" [label]=\"element.label\" [appendTo]=\"c\"></sf-control>\n </ng-container>\n </ng-container>\n</div>\n<div class=\"card-footer mt-2\">\n <button pButton pRipple type=\"button\" label=\"Guardar\" (click)=\"submit()\" class=\"mr-2\"></button>\n <button pButton pRipple type=\"button\" label=\"Cancelar\" (click)=\"cancel()\" class=\"p-button-danger\"></button>\n</div>", components: [{ type: i3$3.Toast, selector: "p-toast", inputs: ["key", "autoZIndex", "baseZIndex", "style", "styleClass", "position", "preventOpenDuplicates", "preventDuplicates", "showTransformOptions", "hideTransformOptions", "showTransitionOptions", "hideTransitionOptions", "breakpoints"], outputs: ["onClose"] }, { type: ControlComponent, selector: "sf-control", inputs: ["control", "label", "value", "appendTo"], outputs: ["setValue", "sendNotification"] }], directives: [{ type: i6.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i6.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i6.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { type: i8.ButtonDirective, selector: "[pButton]", inputs: ["iconPos", "loadingIcon", "label", "icon", "loading"] }, { type: i9.Ripple, selector: "[pRipple]" }] });
|
|
500
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: RegistroChildComponent, decorators: [{
|
|
501
|
+
type: Component,
|
|
502
|
+
args: [{
|
|
503
|
+
selector: 'lib-registro-child',
|
|
504
|
+
templateUrl: './registro-child.component.html',
|
|
505
|
+
providers: [MessageService]
|
|
506
|
+
}]
|
|
507
|
+
}], ctorParameters: function () { return [{ type: i1$1.DynamicDialogRef }, { type: i1$1.DynamicDialogConfig }, { type: i3$1.MessageService }]; } });
|
|
508
|
+
|
|
313
509
|
class RegistroComponent {
|
|
314
|
-
constructor(generalService, router, messageSerice) {
|
|
510
|
+
constructor(generalService, router, messageSerice, dialogService) {
|
|
315
511
|
this.generalService = generalService;
|
|
316
512
|
this.router = router;
|
|
317
513
|
this.messageSerice = messageSerice;
|
|
514
|
+
this.dialogService = dialogService;
|
|
318
515
|
this.idKatios = '';
|
|
319
516
|
this.idEntidad = '';
|
|
320
517
|
this.trx = '';
|
|
321
518
|
this.id = '';
|
|
322
|
-
this.
|
|
519
|
+
this.sendData = new EventEmitter();
|
|
323
520
|
this.crudConfig = new CrudConfig();
|
|
521
|
+
this.enProceso = false;
|
|
324
522
|
this.configOperation = new Operations();
|
|
523
|
+
this.isLocal = false;
|
|
325
524
|
}
|
|
326
525
|
ngOnInit() {
|
|
327
526
|
this.loadConfigCrud();
|
|
@@ -332,6 +531,7 @@ class RegistroComponent {
|
|
|
332
531
|
this.generalService.getCrudByEntidad(this.idKatios, this.idEntidad)
|
|
333
532
|
.then(res => {
|
|
334
533
|
this.crudConfig = res;
|
|
534
|
+
console.log(this.crudConfig);
|
|
335
535
|
if (this.trx != 'c')
|
|
336
536
|
this.getInfoRegistro(this.crudConfig.registro);
|
|
337
537
|
else {
|
|
@@ -380,16 +580,29 @@ class RegistroComponent {
|
|
|
380
580
|
return jsonpath.query(this.data, scope.replace('.properties', ''))[0];
|
|
381
581
|
}
|
|
382
582
|
setValue(value, scope) {
|
|
383
|
-
|
|
583
|
+
switch (typeof (value)) {
|
|
584
|
+
case 'object':
|
|
585
|
+
value.forEach((val) => jsonpath.value(this.data, val.scope.replace('.properties', ''), val.value));
|
|
586
|
+
break;
|
|
587
|
+
default:
|
|
588
|
+
jsonpath.value(this.data, scope.replace('.properties', ''), value);
|
|
589
|
+
break;
|
|
590
|
+
}
|
|
384
591
|
}
|
|
385
592
|
createObject(esquema) {
|
|
386
593
|
let object = {};
|
|
387
594
|
switch (esquema.type) {
|
|
595
|
+
case 'numeric':
|
|
596
|
+
return (esquema === null || esquema === void 0 ? void 0 : esquema.default) || 0;
|
|
388
597
|
case 'string':
|
|
389
|
-
case '
|
|
390
|
-
return (esquema === null || esquema === void 0 ? void 0 : esquema.default)
|
|
598
|
+
case 'date':
|
|
599
|
+
return (esquema === null || esquema === void 0 ? void 0 : esquema.default) ? this.setDefaultValue(esquema.default) : null;
|
|
391
600
|
case 'boolean':
|
|
392
601
|
return (esquema === null || esquema === void 0 ? void 0 : esquema.default) || false;
|
|
602
|
+
case 'array':
|
|
603
|
+
return [];
|
|
604
|
+
case 'file':
|
|
605
|
+
return null;
|
|
393
606
|
case 'object':
|
|
394
607
|
for (const key in esquema === null || esquema === void 0 ? void 0 : esquema.properties) {
|
|
395
608
|
Object.defineProperty(object, key, { value: this.createObject(esquema === null || esquema === void 0 ? void 0 : esquema.properties[key]), writable: true, enumerable: true, configurable: true });
|
|
@@ -401,6 +614,7 @@ class RegistroComponent {
|
|
|
401
614
|
return object;
|
|
402
615
|
}
|
|
403
616
|
submit() {
|
|
617
|
+
console.log(this.data);
|
|
404
618
|
if (!this.validateData())
|
|
405
619
|
return;
|
|
406
620
|
this.enProceso = true;
|
|
@@ -427,26 +641,108 @@ class RegistroComponent {
|
|
|
427
641
|
return true;
|
|
428
642
|
}
|
|
429
643
|
validateDataLocal() {
|
|
644
|
+
var _a, _b;
|
|
430
645
|
let err = [];
|
|
431
|
-
this.configOperation.validations.required.forEach(x => {
|
|
646
|
+
(_a = this.configOperation.validations) === null || _a === void 0 ? void 0 : _a.required.forEach(x => {
|
|
432
647
|
if (!jsonpath.query(this.data, x.field)[0])
|
|
433
648
|
err.push(x.message);
|
|
434
649
|
});
|
|
650
|
+
(_b = this.configOperation.validations) === null || _b === void 0 ? void 0 : _b.operations.forEach();
|
|
435
651
|
if (err.length != 0)
|
|
436
652
|
this.messageSerice.add({ severity: 'warn', detail: err.join('. ') });
|
|
437
653
|
return err.length == 0;
|
|
438
654
|
}
|
|
655
|
+
setDefaultValue(value) {
|
|
656
|
+
let data = null;
|
|
657
|
+
let uactivo;
|
|
658
|
+
switch (value) {
|
|
659
|
+
case '@uactivo':
|
|
660
|
+
uactivo = JSON.parse(localStorage.getItem('oSessionTFM') || '{}');
|
|
661
|
+
if (!uactivo)
|
|
662
|
+
console.log('Validar configuracion de sesion');
|
|
663
|
+
else
|
|
664
|
+
data = `${uactivo.UsuarioSistema.TDOC}-${uactivo.UsuarioSistema.NDOC}`;
|
|
665
|
+
break;
|
|
666
|
+
case '@tdocactivo':
|
|
667
|
+
uactivo = JSON.parse(sessionStorage.getItem('usrSesion') || '{}');
|
|
668
|
+
if (!uactivo)
|
|
669
|
+
console.log('Validar configuracion de sesion');
|
|
670
|
+
else
|
|
671
|
+
data = uactivo.UsuarioSistema.TDOC;
|
|
672
|
+
break;
|
|
673
|
+
case '@ndocactivo':
|
|
674
|
+
uactivo = JSON.parse(sessionStorage.getItem('usrSesion') || '{}');
|
|
675
|
+
if (!uactivo)
|
|
676
|
+
console.log('Validar configuracion de sesion');
|
|
677
|
+
else
|
|
678
|
+
data = uactivo.UsuarioSistema.NDOC;
|
|
679
|
+
break;
|
|
680
|
+
case '@hoy':
|
|
681
|
+
data = new Date();
|
|
682
|
+
break;
|
|
683
|
+
default:
|
|
684
|
+
data = value;
|
|
685
|
+
break;
|
|
686
|
+
}
|
|
687
|
+
return data;
|
|
688
|
+
}
|
|
689
|
+
sendNotification(message) {
|
|
690
|
+
this.messageSerice.add(message);
|
|
691
|
+
}
|
|
692
|
+
addObjectArray(element) {
|
|
693
|
+
this.dialogRef = this.dialogService.open(RegistroChildComponent, {
|
|
694
|
+
header: `Detalle`,
|
|
695
|
+
width: '70%',
|
|
696
|
+
modal: true,
|
|
697
|
+
closable: false,
|
|
698
|
+
data: {
|
|
699
|
+
uiEsquema: Object.assign({}, element.elements),
|
|
700
|
+
esquema: this.getControl(element.scope),
|
|
701
|
+
id: this.getValue(element.scope).length + 1
|
|
702
|
+
}
|
|
703
|
+
});
|
|
704
|
+
this.dialogRef.onClose.subscribe((data) => {
|
|
705
|
+
if (data)
|
|
706
|
+
this.data[element.scope.replace('$..properties.', '')].push(data);
|
|
707
|
+
});
|
|
708
|
+
}
|
|
709
|
+
editRow(element, data) {
|
|
710
|
+
this.dialogRef = this.dialogService.open(RegistroChildComponent, {
|
|
711
|
+
header: `Detalle`,
|
|
712
|
+
width: '70%',
|
|
713
|
+
modal: true,
|
|
714
|
+
closable: false,
|
|
715
|
+
data: {
|
|
716
|
+
uiEsquema: Object.assign({}, element.elements),
|
|
717
|
+
esquema: this.getControl(element.scope),
|
|
718
|
+
data: Object.assign({}, data)
|
|
719
|
+
}
|
|
720
|
+
});
|
|
721
|
+
this.dialogRef.onClose.subscribe((data) => {
|
|
722
|
+
if (data)
|
|
723
|
+
this.data[element.scope.replace('$..properties.', '')][data.id - 1] = data;
|
|
724
|
+
});
|
|
725
|
+
}
|
|
726
|
+
deleteRow(element, index) {
|
|
727
|
+
this.data[element.scope.replace('$..properties.', '')].splice(index - 1, 1);
|
|
728
|
+
index = 1;
|
|
729
|
+
this.data[element.scope.replace('$..properties.', '')].forEach((el) => {
|
|
730
|
+
el.id = index;
|
|
731
|
+
index++;
|
|
732
|
+
});
|
|
733
|
+
}
|
|
439
734
|
}
|
|
440
|
-
RegistroComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: RegistroComponent, deps: [{ token: GeneralService }, { token: i2.Router }, { token: i3$1.MessageService }], target: i0.ɵɵFactoryTarget.Component });
|
|
441
|
-
RegistroComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: RegistroComponent, selector: "sf-registro", inputs: { idKatios: "idKatios", idEntidad: "idEntidad", trx: "trx", id: "id" }, providers: [MessageService], ngImport: i0, template: "<p-blockUI [blocked]=\"enProceso\">\r\n <i class=\"pi pi-cog pi-spin\" style=\"font-size: 50px\"></i>\r\n</p-blockUI>\r\n\r\n<p-toast></p-toast>\r\n\r\n<div class=\"card\" *ngIf=\"!enProceso\">\r\n <h5 class=\"card-header mb-2\" style=\"display: flex; justify-content: space-between;align-items: center;\">\r\n <span>{{idEntidad}} {{id != '' ? '-' + id : ''}}</span>\r\n <button pButton pRipple type=\"button\" icon=\"pi pi-arrow-left\" (click)=\"back()\"></button>\r\n </h5>\r\n <div *ngFor=\"let element of crudConfig.uiEsquema.elements\" [class]=\"element?.class\">\r\n <ng-container [ngSwitch]=\"element.type\">\r\n <div *ngSwitchCase=\"'Label'\" [style]=\"element?.style\">\r\n {{element?.label}}\r\n </div>\r\n <ng-container *ngSwitchCase=\"'HorizontalLayout'\">\r\n <div *ngFor=\"let el of element.elements\" [class]=\"el?.class\">\r\n <ng-container [ngSwitch]=\"el.type\"
|
|
735
|
+
RegistroComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: RegistroComponent, deps: [{ token: GeneralService }, { token: i2.Router }, { token: i3$1.MessageService }, { token: i1$1.DialogService }], target: i0.ɵɵFactoryTarget.Component });
|
|
736
|
+
RegistroComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: RegistroComponent, selector: "sf-registro", inputs: { idKatios: "idKatios", idEntidad: "idEntidad", trx: "trx", id: "id" }, outputs: { sendData: "sendData" }, providers: [MessageService, DialogService, DynamicDialogConfig, DynamicDialogRef], ngImport: i0, template: "<p-blockUI [blocked]=\"enProceso\">\r\n <i class=\"pi pi-cog pi-spin\" style=\"font-size: 50px\"></i>\r\n</p-blockUI>\r\n\r\n<p-toast></p-toast>\r\n\r\n<div class=\"card\" *ngIf=\"!enProceso\">\r\n <h5 class=\"card-header mb-2\" style=\"display: flex; justify-content: space-between;align-items: center;\">\r\n <span>{{crudConfig.registro?.label || idEntidad}} {{id != '' ? '-' + id : ''}}</span>\r\n <button pButton pRipple type=\"button\" icon=\"pi pi-arrow-left\" (click)=\"back()\"></button>\r\n </h5>\r\n <div *ngFor=\"let element of crudConfig.uiEsquema.elements\" [class]=\"element?.class\">\r\n <ng-container [ngSwitch]=\"element.type\">\r\n <div *ngSwitchCase=\"'Label'\" [style]=\"element?.style\">\r\n {{element?.label}}\r\n </div>\r\n <ng-container *ngSwitchCase=\"'HorizontalLayout'\">\r\n <div *ngFor=\"let el of element.elements\" [class]=\"el?.class\">\r\n <ng-container [ngSwitch]=\"el.type\">\r\n <sf-control *ngSwitchCase=\"'Control'\" [control]=\"getControl(el.scope)\" [label]=\"el.label\"\r\n [value]=\"getValue(el.scope)\" (setValue)=\"setValue($event, el.scope)\"\r\n (sendNotification)=\"sendNotification($event)\"></sf-control>\r\n </ng-container>\r\n </div>\r\n </ng-container>\r\n <ng-container *ngSwitchCase=\"'VerticalLayout'\">\r\n <div *ngFor=\"let el of element.elements\" [class]=\"el?.class\">\r\n <ng-container [ngSwitch]=\"el.type\">\r\n <sf-control *ngSwitchCase=\"'Control'\" [control]=\"getControl(el.scope)\" [label]=\"el.label\"\r\n [value]=\"getValue(el.scope)\" (setValue)=\"setValue($event, el.scope)\"\r\n (sendNotification)=\"sendNotification($event)\"></sf-control>\r\n <ng-container *ngSwitchCase=\"'Table'\">\r\n <p-table [value]=\"getValue(el.scope)\" [columns]=\"getControl(el.scope).config.columns\">\r\n <ng-template pTemplate=\"caption\">\r\n <div class=\"flex align-items-center justify-content-between\">\r\n <button pButton pRipple icon=\"pi pi-plus\" (click)=\"addObjectArray(el)\"\r\n class=\"p-button-success\"></button>\r\n </div>\r\n </ng-template>\r\n <ng-template pTemplate=\"header\" let-columns>\r\n <tr>\r\n <th *ngFor=\"let col of columns\">\r\n {{col.label}}\r\n </th>\r\n <ng-container *ngIf=\"trx == 'c' || trx == 'u'\">\r\n <th></th>\r\n </ng-container>\r\n </tr>\r\n </ng-template>\r\n <ng-template pTemplate=\"body\" let-rowData let-columns=\"columns\" let-rowIndex=\"rowIndex\">\r\n <tr>\r\n <ng-container *ngFor=\"let col of columns\" [ngSwitch]=\"col.type\">\r\n <ng-container *ngSwitchCase=\"'text'\">\r\n <td>{{rowData[col.col]}}</td>\r\n </ng-container>\r\n <ng-container *ngSwitchCase=\"'currency:USD'\">\r\n <td>{{rowData[col.col] | currency: 'USD'}}</td>\r\n </ng-container>\r\n </ng-container>\r\n <ng-container *ngIf=\"trx == 'c' || trx == 'u'\">\r\n <td>\r\n <!-- <button pButton pRipple type=\"button\" (click)=\"editRow(el, rowData)\" icon=\"pi pi-pencil\" class=\"p-button-rounded p-button-info mr-1\"></button> -->\r\n <button pButton pRipple type=\"button\" (click)=\"deleteRow(el, rowIndex)\" icon=\"pi pi-trash\" class=\"p-button-rounded p-button-danger\"></button>\r\n </td>\r\n </ng-container>\r\n </tr>\r\n </ng-template>\r\n </p-table>\r\n </ng-container>\r\n </ng-container>\r\n </div>\r\n </ng-container>\r\n <ng-container *ngSwitchCase=\"'Control'\">\r\n <sf-control [control]=\"getControl(element.scope)\" [label]=\"element.label\"></sf-control>\r\n </ng-container>\r\n </ng-container>\r\n </div>\r\n <div class=\"card-footer mt-2\" *ngIf=\"btnSubmit\">\r\n <button pButton pRipple type=\"button\" [icon]=\"btnSubmit.icon\" [label]=\"btnSubmit.label\"\r\n (click)=\"submit()\"></button>\r\n </div>\r\n</div>\r\n", components: [{ type: i3.BlockUI, selector: "p-blockUI", inputs: ["target", "autoZIndex", "baseZIndex", "styleClass", "blocked"] }, { type: i3$3.Toast, selector: "p-toast", inputs: ["key", "autoZIndex", "baseZIndex", "style", "styleClass", "position", "preventOpenDuplicates", "preventDuplicates", "showTransformOptions", "hideTransformOptions", "showTransitionOptions", "hideTransitionOptions", "breakpoints"], outputs: ["onClose"] }, { type: ControlComponent, selector: "sf-control", inputs: ["control", "label", "value", "appendTo"], outputs: ["setValue", "sendNotification"] }, { type: i5.Table, selector: "p-table", inputs: ["frozenColumns", "frozenValue", "style", "styleClass", "tableStyle", "tableStyleClass", "paginator", "pageLinks", "rowsPerPageOptions", "alwaysShowPaginator", "paginatorPosition", "paginatorDropdownAppendTo", "paginatorDropdownScrollHeight", "currentPageReportTemplate", "showCurrentPageReport", "showJumpToPageDropdown", "showFirstLastIcon", "showPageLinks", "defaultSortOrder", "sortMode", "resetPageOnSort", "selectionMode", "contextMenuSelection", "contextMenuSelectionMode", "dataKey", "metaKeySelection", "rowTrackBy", "lazy", "lazyLoadOnInit", "compareSelectionBy", "csvSeparator", "exportFilename", "filters", "globalFilterFields", "filterDelay", "filterLocale", "expandedRowKeys", "editingRowKeys", "rowExpandMode", "scrollable", "scrollDirection", "rowGroupMode", "scrollHeight", "virtualScroll", "virtualScrollDelay", "virtualRowHeight", "frozenWidth", "responsive", "contextMenu", "resizableColumns", "columnResizeMode", "reorderableColumns", "loading", "loadingIcon", "showLoader", "rowHover", "customSort", "showInitialSortBadge", "autoLayout", "exportFunction", "stateKey", "stateStorage", "editMode", "groupRowsBy", "minBufferPx", "maxBufferPx", "responsiveLayout", "breakpoint", "value", "columns", "first", "rows", "totalRecords", "sortField", "sortOrder", "multiSortMeta", "selection"], outputs: ["selectionChange", "contextMenuSelectionChange", "onRowSelect", "onRowUnselect", "onPage", "onSort", "onFilter", "onLazyLoad", "onRowExpand", "onRowCollapse", "onContextMenuSelect", "onColResize", "onColReorder", "onRowReorder", "onEditInit", "onEditComplete", "onEditCancel", "onHeaderCheckboxToggle", "sortFunction", "firstChange", "rowsChange", "onStateSave", "onStateRestore"] }], directives: [{ type: i6.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i8.ButtonDirective, selector: "[pButton]", inputs: ["iconPos", "loadingIcon", "label", "icon", "loading"] }, { type: i9.Ripple, selector: "[pRipple]" }, { type: i6.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i6.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i6.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { type: i3$1.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }], pipes: { "currency": i6.CurrencyPipe } });
|
|
442
737
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: RegistroComponent, decorators: [{
|
|
443
738
|
type: Component,
|
|
444
739
|
args: [{
|
|
445
740
|
selector: 'sf-registro',
|
|
446
741
|
templateUrl: './registro.component.html',
|
|
447
|
-
providers: [MessageService]
|
|
742
|
+
providers: [MessageService, DialogService, DynamicDialogConfig, DynamicDialogRef],
|
|
743
|
+
entryComponents: [RegistroComponent]
|
|
448
744
|
}]
|
|
449
|
-
}], ctorParameters: function () { return [{ type: GeneralService }, { type: i2.Router }, { type: i3$1.MessageService }]; }, propDecorators: { idKatios: [{
|
|
745
|
+
}], ctorParameters: function () { return [{ type: GeneralService }, { type: i2.Router }, { type: i3$1.MessageService }, { type: i1$1.DialogService }]; }, propDecorators: { idKatios: [{
|
|
450
746
|
type: Input
|
|
451
747
|
}], idEntidad: [{
|
|
452
748
|
type: Input
|
|
@@ -454,6 +750,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImpo
|
|
|
454
750
|
type: Input
|
|
455
751
|
}], id: [{
|
|
456
752
|
type: Input
|
|
753
|
+
}], sendData: [{
|
|
754
|
+
type: Output
|
|
457
755
|
}] } });
|
|
458
756
|
|
|
459
757
|
class SfCrudComponent {
|
|
@@ -486,7 +784,9 @@ SfCrudModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "1
|
|
|
486
784
|
SfCrudModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: SfCrudModule, declarations: [SfCrudComponent,
|
|
487
785
|
TableroComponent,
|
|
488
786
|
RegistroComponent,
|
|
489
|
-
ControlComponent
|
|
787
|
+
ControlComponent,
|
|
788
|
+
RegistroChildComponent], imports: [AccordionModule,
|
|
789
|
+
AutoCompleteModule,
|
|
490
790
|
AvatarGroupModule,
|
|
491
791
|
AvatarModule,
|
|
492
792
|
BadgeModule,
|
|
@@ -508,6 +808,7 @@ SfCrudModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "
|
|
|
508
808
|
DialogModule,
|
|
509
809
|
DividerModule,
|
|
510
810
|
DropdownModule,
|
|
811
|
+
DynamicDialogModule,
|
|
511
812
|
FieldsetModule,
|
|
512
813
|
FileUploadModule,
|
|
513
814
|
FormsModule,
|
|
@@ -559,9 +860,11 @@ SfCrudModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "
|
|
|
559
860
|
TooltipModule,
|
|
560
861
|
TreeModule], exports: [SfCrudComponent,
|
|
561
862
|
TableroComponent,
|
|
562
|
-
RegistroComponent
|
|
863
|
+
RegistroComponent,
|
|
864
|
+
ControlComponent] });
|
|
563
865
|
SfCrudModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: SfCrudModule, imports: [[
|
|
564
866
|
AccordionModule,
|
|
867
|
+
AutoCompleteModule,
|
|
565
868
|
AvatarGroupModule,
|
|
566
869
|
AvatarModule,
|
|
567
870
|
BadgeModule,
|
|
@@ -583,6 +886,7 @@ SfCrudModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "
|
|
|
583
886
|
DialogModule,
|
|
584
887
|
DividerModule,
|
|
585
888
|
DropdownModule,
|
|
889
|
+
DynamicDialogModule,
|
|
586
890
|
FieldsetModule,
|
|
587
891
|
FileUploadModule,
|
|
588
892
|
FormsModule,
|
|
@@ -641,10 +945,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImpo
|
|
|
641
945
|
SfCrudComponent,
|
|
642
946
|
TableroComponent,
|
|
643
947
|
RegistroComponent,
|
|
644
|
-
ControlComponent
|
|
948
|
+
ControlComponent,
|
|
949
|
+
RegistroChildComponent
|
|
645
950
|
],
|
|
646
951
|
imports: [
|
|
647
952
|
AccordionModule,
|
|
953
|
+
AutoCompleteModule,
|
|
648
954
|
AvatarGroupModule,
|
|
649
955
|
AvatarModule,
|
|
650
956
|
BadgeModule,
|
|
@@ -666,6 +972,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImpo
|
|
|
666
972
|
DialogModule,
|
|
667
973
|
DividerModule,
|
|
668
974
|
DropdownModule,
|
|
975
|
+
DynamicDialogModule,
|
|
669
976
|
FieldsetModule,
|
|
670
977
|
FileUploadModule,
|
|
671
978
|
FormsModule,
|
|
@@ -720,7 +1027,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImpo
|
|
|
720
1027
|
exports: [
|
|
721
1028
|
SfCrudComponent,
|
|
722
1029
|
TableroComponent,
|
|
723
|
-
RegistroComponent
|
|
1030
|
+
RegistroComponent,
|
|
1031
|
+
ControlComponent
|
|
1032
|
+
],
|
|
1033
|
+
entryComponents: [
|
|
1034
|
+
RegistroChildComponent
|
|
724
1035
|
]
|
|
725
1036
|
}]
|
|
726
1037
|
}] });
|
|
@@ -745,5 +1056,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImpo
|
|
|
745
1056
|
* Generated bundle index. Do not edit.
|
|
746
1057
|
*/
|
|
747
1058
|
|
|
748
|
-
export { RegistroComponent, SfCrudComponent, SfCrudModule, SfCrudService, TableroComponent };
|
|
1059
|
+
export { ControlComponent, RegistroComponent, SfCrudComponent, SfCrudModule, SfCrudService, TableroComponent };
|
|
749
1060
|
//# sourceMappingURL=sf-crud.js.map
|