keevo-components 1.8.1 → 1.8.21
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/esm2022/lib/api/components/table/table-dropdown-control.mjs +2 -0
- package/esm2022/lib/api/components/table/table.config.column.mjs +1 -1
- package/esm2022/lib/api/components/table/table.config.mjs +1 -1
- package/esm2022/lib/api/components/table/tabledit.config.mjs +2 -0
- package/esm2022/lib/api/components/table/tableedit.config.column.mjs +2 -0
- package/esm2022/lib/api/services/form.service.mjs +2 -1
- package/esm2022/lib/inputs/input-text-checkbox/input-text-checkbox.component.mjs +3 -3
- package/esm2022/lib/keevo-components.module.mjs +8 -4
- package/esm2022/lib/label/label.component.mjs +3 -3
- package/esm2022/lib/label/label.module.mjs +1 -1
- package/esm2022/lib/table-edit/table-edit.component.mjs +502 -0
- package/esm2022/lib/table-edit/table-edit.module.mjs +31 -0
- package/esm2022/public-api.mjs +5 -1
- package/fesm2022/keevo-components.mjs +529 -19
- package/fesm2022/keevo-components.mjs.map +1 -1
- package/lib/api/components/table/table-dropdown-control.d.ts +6 -0
- package/lib/api/components/table/table.config.d.ts +1 -0
- package/lib/api/components/table/tabledit.config.d.ts +6 -0
- package/lib/api/components/table/tableedit.config.column.d.ts +9 -0
- package/lib/api/services/form.service.d.ts +1 -0
- package/lib/keevo-components.module.d.ts +2 -1
- package/lib/table/table.component.d.ts +1 -1
- package/lib/table-edit/table-edit.component.d.ts +109 -0
- package/lib/table-edit/table-edit.module.d.ts +11 -0
- package/package.json +1 -1
- package/public-api.d.ts +4 -0
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { TableConfig } from "./table.config";
|
|
2
|
+
import { TableEditConfigColumn } from "./tableedit.config.column";
|
|
3
|
+
export default interface TableEditConfig extends TableConfig {
|
|
4
|
+
columns: TableEditConfigColumn[];
|
|
5
|
+
disableEditRowFunction?: (rowData: any, rowNode?: any) => boolean;
|
|
6
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import FieldDropDownControl from "./table-dropdown-control";
|
|
2
|
+
import { TableConfigColumn } from "./table.config.column";
|
|
3
|
+
export interface TableEditConfigColumn extends TableConfigColumn {
|
|
4
|
+
required?: boolean;
|
|
5
|
+
validator?: any;
|
|
6
|
+
mask?: string;
|
|
7
|
+
fieldControlType?: 'text' | 'switch' | 'dropdown' | 'multiselect' | 'number' | 'calendar' | 'mask';
|
|
8
|
+
fieldDropDownControl?: FieldDropDownControl;
|
|
9
|
+
}
|
|
@@ -15,8 +15,9 @@ import * as i13 from "./loader/kvloader.module";
|
|
|
15
15
|
import * as i14 from "./avatar/kv-avatar.module";
|
|
16
16
|
import * as i15 from "./carousel/kv-carousel.module";
|
|
17
17
|
import * as i16 from "./treetable/treetable.module";
|
|
18
|
+
import * as i17 from "./table-edit/table-edit.module";
|
|
18
19
|
export declare class KeevoComponentsModule {
|
|
19
20
|
static ɵfac: i0.ɵɵFactoryDeclaration<KeevoComponentsModule, never>;
|
|
20
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<KeevoComponentsModule, never, [typeof i1.KvInputsModule, typeof i2.KvButtonsModule, typeof i3.KvTableModule, typeof i4.KvtreeViewModule, typeof i5.KvChartModule, typeof i6.KvMenuModule, typeof i7.KvPickListModule, typeof i8.KVTreeTableModule, typeof i9.KvWorkspaceModule, typeof i10.OrgchartModule, typeof i11.KvLoginModule, typeof i12.KvPageFormModule, typeof i13.KvLoaderModule, typeof i14.KvAvatarModule, typeof i15.KvCarouselModule, typeof i16.TreetableModule], [typeof i1.KvInputsModule, typeof i2.KvButtonsModule, typeof i3.KvTableModule, typeof i4.KvtreeViewModule, typeof i5.KvChartModule, typeof i6.KvMenuModule, typeof i7.KvPickListModule, typeof i8.KVTreeTableModule, typeof i9.KvWorkspaceModule, typeof i10.OrgchartModule, typeof i11.KvLoginModule, typeof i12.KvPageFormModule, typeof i13.KvLoaderModule, typeof i14.KvAvatarModule, typeof i15.KvCarouselModule, typeof i16.TreetableModule]>;
|
|
21
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<KeevoComponentsModule, never, [typeof i1.KvInputsModule, typeof i2.KvButtonsModule, typeof i3.KvTableModule, typeof i4.KvtreeViewModule, typeof i5.KvChartModule, typeof i6.KvMenuModule, typeof i7.KvPickListModule, typeof i8.KVTreeTableModule, typeof i9.KvWorkspaceModule, typeof i10.OrgchartModule, typeof i11.KvLoginModule, typeof i12.KvPageFormModule, typeof i13.KvLoaderModule, typeof i14.KvAvatarModule, typeof i15.KvCarouselModule, typeof i16.TreetableModule], [typeof i1.KvInputsModule, typeof i2.KvButtonsModule, typeof i3.KvTableModule, typeof i4.KvtreeViewModule, typeof i5.KvChartModule, typeof i6.KvMenuModule, typeof i7.KvPickListModule, typeof i8.KVTreeTableModule, typeof i9.KvWorkspaceModule, typeof i10.OrgchartModule, typeof i11.KvLoginModule, typeof i12.KvPageFormModule, typeof i13.KvLoaderModule, typeof i14.KvAvatarModule, typeof i15.KvCarouselModule, typeof i16.TreetableModule, typeof i17.KvTableEditModule]>;
|
|
21
22
|
static ɵinj: i0.ɵɵInjectorDeclaration<KeevoComponentsModule>;
|
|
22
23
|
}
|
|
@@ -100,7 +100,7 @@ export declare class TableComponent implements OnInit {
|
|
|
100
100
|
addColumn(field: string): void;
|
|
101
101
|
dinamicColumnSet(e: any, col: any): void;
|
|
102
102
|
checkMenuFiltro(col: any): void;
|
|
103
|
-
sortByPosition(): (elem1: any, elem2: any) =>
|
|
103
|
+
sortByPosition(): (elem1: any, elem2: any) => 1 | 0 | -1;
|
|
104
104
|
callDisabled(action: KvMenuItem, data: any): boolean;
|
|
105
105
|
dinamicDisableColumn(col: TableConfigColumn): boolean;
|
|
106
106
|
checkHideColumns(): void;
|
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
import { EventEmitter, OnChanges, OnInit, SimpleChanges, TemplateRef } from '@angular/core';
|
|
2
|
+
import { MenuItemCommandEvent, SelectItem } from 'primeng/api';
|
|
3
|
+
import { CodigoFipePipe, CpfCnpjPipe, KvMenuItem, NotificationService, TableConfig, TableConfigColumn, TelefonePipe } from '../../public-api';
|
|
4
|
+
import { DatePipe, DecimalPipe } from '@angular/common';
|
|
5
|
+
import { Table } from 'primeng/table';
|
|
6
|
+
import TableEditConfig from '../api/components/table/tabledit.config';
|
|
7
|
+
import { TableEditConfigColumn } from '../api/components/table/tableedit.config.column';
|
|
8
|
+
import * as i0 from "@angular/core";
|
|
9
|
+
export declare class TableEditComponent implements OnInit, OnChanges {
|
|
10
|
+
private readonly datePipe;
|
|
11
|
+
private readonly decimalPipe;
|
|
12
|
+
private readonly codigoFipePipe;
|
|
13
|
+
private readonly cpfCnpjPipe;
|
|
14
|
+
private readonly telefonePipe;
|
|
15
|
+
private readonly notificationService;
|
|
16
|
+
config: TableEditConfig;
|
|
17
|
+
globalFilterFields: string[];
|
|
18
|
+
collapsed: boolean;
|
|
19
|
+
set setConfig(value: TableConfig);
|
|
20
|
+
dataSource: any[];
|
|
21
|
+
editMode: 'row' | 'cell';
|
|
22
|
+
selectedItems: any[];
|
|
23
|
+
totalRecords: number;
|
|
24
|
+
paginator: boolean;
|
|
25
|
+
rowsPerPageOptions: number[];
|
|
26
|
+
rows: number;
|
|
27
|
+
pageLinksOptions: number;
|
|
28
|
+
showFirstLastIcon: boolean;
|
|
29
|
+
tableSize: number;
|
|
30
|
+
applyStyle: Function;
|
|
31
|
+
acoesLinhaTabela: boolean;
|
|
32
|
+
filterColumnsBtn: boolean;
|
|
33
|
+
filtrosAvancados: boolean;
|
|
34
|
+
scrollHeight: string;
|
|
35
|
+
isTableScrollable: boolean;
|
|
36
|
+
rowTrackBy: Function;
|
|
37
|
+
responsiveLayout: boolean;
|
|
38
|
+
espacamentoPai: string;
|
|
39
|
+
espacamentoLateral: boolean;
|
|
40
|
+
tamanhoTotalTabela: number;
|
|
41
|
+
rightCollapse: boolean;
|
|
42
|
+
onFilter: EventEmitter<any>;
|
|
43
|
+
_templates: any;
|
|
44
|
+
tamanhoTela: number;
|
|
45
|
+
selectedSize: string;
|
|
46
|
+
selecteIems: any[];
|
|
47
|
+
menuItems: KvMenuItem[];
|
|
48
|
+
imgDefault: string;
|
|
49
|
+
isExpanded: boolean;
|
|
50
|
+
commandEvent: MenuItemCommandEvent;
|
|
51
|
+
statuses: SelectItem[];
|
|
52
|
+
clonedDataSource: {
|
|
53
|
+
[s: string]: any;
|
|
54
|
+
};
|
|
55
|
+
/** Emite evento de salvamento da linha */
|
|
56
|
+
onRowSave: EventEmitter<any>;
|
|
57
|
+
onActiveItem: EventEmitter<any>;
|
|
58
|
+
onActiveItemLote: EventEmitter<any>;
|
|
59
|
+
onPaginate: EventEmitter<any>;
|
|
60
|
+
onSelectionChange: EventEmitter<any>;
|
|
61
|
+
doubleClickEvent: EventEmitter<any>;
|
|
62
|
+
filterField: EventEmitter<any>;
|
|
63
|
+
onSwitchTableChange: EventEmitter<any>;
|
|
64
|
+
constructor(datePipe: DatePipe, decimalPipe: DecimalPipe, codigoFipePipe: CodigoFipePipe, cpfCnpjPipe: CpfCnpjPipe, telefonePipe: TelefonePipe, notificationService: NotificationService);
|
|
65
|
+
ngOnInit(): void;
|
|
66
|
+
isRowSelectable(event: any): boolean;
|
|
67
|
+
ngOnChanges(changes: SimpleChanges): void;
|
|
68
|
+
onRowEditInit(rowData: any): void;
|
|
69
|
+
onRowEditSave(rowData: any, index: any): void;
|
|
70
|
+
onRowEditCancel(product: any, index: number): void;
|
|
71
|
+
listarDrop(service: any, col: any, indtodos?: boolean): Promise<any>;
|
|
72
|
+
retornaDescricaoDrop(rowData: any[], col: TableEditConfigColumn): any;
|
|
73
|
+
onGlobalFilter(table: Table, event: Event): void;
|
|
74
|
+
onWindowResize(): void;
|
|
75
|
+
adjustTableSize(): void;
|
|
76
|
+
paginate($event: any): void;
|
|
77
|
+
isBooleanField(rowData: any, col: TableConfigColumn): boolean;
|
|
78
|
+
isChipField(col: TableConfigColumn): boolean;
|
|
79
|
+
isImageField(col: TableConfigColumn): boolean;
|
|
80
|
+
returnRowClass(rowData: any, col: TableConfigColumn): string;
|
|
81
|
+
transformValue(rowData: any, col: TableConfigColumn): any;
|
|
82
|
+
alignColunasHeader(col: any): string;
|
|
83
|
+
centralizarColunas(col: any): string;
|
|
84
|
+
alignColunas(col: any): string;
|
|
85
|
+
returnClassIcon(rowData: any, col: any): string;
|
|
86
|
+
returnTooltipIcon(rowData: any, col: any): string;
|
|
87
|
+
returnClassChip(rowData: any, col: any): string;
|
|
88
|
+
retornarRow(rowData: any, col: any, field: string): string;
|
|
89
|
+
selectionChange(value?: never[]): void;
|
|
90
|
+
formatarValor(valor: number): string;
|
|
91
|
+
loadImage(rowData: any, col: TableConfigColumn): string;
|
|
92
|
+
getCustomTemplate(templatename: string): TemplateRef<any>;
|
|
93
|
+
exibirCampo(field: any, rowData: any): any;
|
|
94
|
+
activeItem(rowData: any): void;
|
|
95
|
+
activeItemLote(rowData: any): void;
|
|
96
|
+
retornarCampo(action: KvMenuItem, rowData: any, field: string): string;
|
|
97
|
+
callDisabled(action: KvMenuItem, data: any): boolean;
|
|
98
|
+
criarMenusModal(data: any): void;
|
|
99
|
+
validaLinhaAcaoVazia(rowData: any): boolean;
|
|
100
|
+
doubleClick(e: any, rowData: any): void;
|
|
101
|
+
isDisabledCheckbox(rowData: any): boolean;
|
|
102
|
+
returnTooltipRow(rowData: any, col: any): any;
|
|
103
|
+
isSwitchField(col: TableConfigColumn): boolean;
|
|
104
|
+
onSwitchChange(estado: any, rowData: boolean, col: any): void;
|
|
105
|
+
isButtonDisable(action: any, rowData: any, commandEvent: any): any;
|
|
106
|
+
isDisableEditRowFunction(rowData: any): boolean | null;
|
|
107
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<TableEditComponent, never>;
|
|
108
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<TableEditComponent, "kv-table-edit", never, { "setConfig": { "alias": "config"; "required": false; }; "dataSource": { "alias": "dataSource"; "required": false; }; "editMode": { "alias": "editMode"; "required": false; }; "selectedItems": { "alias": "selectedItems"; "required": false; }; "totalRecords": { "alias": "totalRecords"; "required": false; }; "paginator": { "alias": "paginator"; "required": false; }; "rowsPerPageOptions": { "alias": "rowsPerPageOptions"; "required": false; }; "rows": { "alias": "rows"; "required": false; }; "pageLinksOptions": { "alias": "pageLinksOptions"; "required": false; }; "showFirstLastIcon": { "alias": "showFirstLastIcon"; "required": false; }; "tableSize": { "alias": "tableSize"; "required": false; }; "applyStyle": { "alias": "applyStyle"; "required": false; }; "acoesLinhaTabela": { "alias": "acoesLinhaTabela"; "required": false; }; "filterColumnsBtn": { "alias": "filterColumnsBtn"; "required": false; }; "filtrosAvancados": { "alias": "filtrosAvancados"; "required": false; }; "scrollHeight": { "alias": "scrollHeight"; "required": false; }; "isTableScrollable": { "alias": "isTableScrollable"; "required": false; }; "rowTrackBy": { "alias": "rowTrackBy"; "required": false; }; "responsiveLayout": { "alias": "responsiveLayout"; "required": false; }; "espacamentoPai": { "alias": "espacamentoPai"; "required": false; }; "espacamentoLateral": { "alias": "espacamentoLateral"; "required": false; }; "tamanhoTotalTabela": { "alias": "tamanhoTotalTabela"; "required": false; }; "rightCollapse": { "alias": "rightCollapse"; "required": false; }; "_templates": { "alias": "templates"; "required": false; }; }, { "onFilter": "onFilter"; "onRowSave": "onRowSave"; "onActiveItem": "onActiveItem"; "onActiveItemLote": "onActiveItemLote"; "onPaginate": "onPaginate"; "onSelectionChange": "onSelectionChange"; "doubleClickEvent": "doubleClickEvent"; "filterField": "filterField"; "onSwitchTableChange": "onSwitchTableChange"; }, never, ["*"], false, never>;
|
|
109
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
import * as i1 from "./table-edit.component";
|
|
3
|
+
import * as i2 from "@angular/common";
|
|
4
|
+
import * as i3 from "../api/modules/primeng.module";
|
|
5
|
+
import * as i4 from "@angular/forms";
|
|
6
|
+
import * as i5 from "../inputs/kvinputs.module";
|
|
7
|
+
export declare class KvTableEditModule {
|
|
8
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<KvTableEditModule, never>;
|
|
9
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<KvTableEditModule, [typeof i1.TableEditComponent], [typeof i2.CommonModule, typeof i3.PrimeNgModule, typeof i4.FormsModule, typeof i5.KvInputsModule], [typeof i1.TableEditComponent]>;
|
|
10
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<KvTableEditModule>;
|
|
11
|
+
}
|
package/package.json
CHANGED
package/public-api.d.ts
CHANGED
|
@@ -90,6 +90,8 @@ export * from './lib/picklist/picklist.component';
|
|
|
90
90
|
/**
|
|
91
91
|
* Table
|
|
92
92
|
*/
|
|
93
|
+
export * from './lib/table-edit/table-edit.component';
|
|
94
|
+
export * from './lib/table-edit/table-edit.module';
|
|
93
95
|
export * from './lib/table/kvtable.module';
|
|
94
96
|
export * from './lib/table/table.component';
|
|
95
97
|
export * from './lib/api/components/table/action-item';
|
|
@@ -97,6 +99,8 @@ export * from './lib/api/components/table/kv-menuitem';
|
|
|
97
99
|
export * from './lib/api/components/table/table.config';
|
|
98
100
|
export * from './lib/api/components/table/table.config.column';
|
|
99
101
|
export * from './lib/api/components/table/table.paginate';
|
|
102
|
+
export * from './lib/api/components/table/tabledit.config';
|
|
103
|
+
export * from './lib/api/components/table/tableedit.config.column';
|
|
100
104
|
/**
|
|
101
105
|
* TreeTable
|
|
102
106
|
*/
|