@acorex/data-grid 5.1.6 → 5.1.7
Sign up to get free protection for your applications and to get access to all the features.
- package/acorex-data-grid.d.ts +5 -0
- package/esm2020/acorex-data-grid.mjs +5 -0
- package/esm2020/lib/data-grid/columns/check-column.component.mjs +117 -0
- package/esm2020/lib/data-grid/columns/column.component.mjs +164 -0
- package/esm2020/lib/data-grid/columns/command-column.component.mjs +115 -0
- package/esm2020/lib/data-grid/columns/date-column.component.mjs +111 -0
- package/esm2020/lib/data-grid/columns/row-number-column.component.mjs +37 -0
- package/esm2020/lib/data-grid/columns/selection-column.component.mjs +42 -0
- package/esm2020/lib/data-grid/columns/text-column.component.mjs +89 -0
- package/esm2020/lib/data-grid/datagrid.component.mjs +667 -0
- package/esm2020/lib/data-grid/datagrid.events.mjs +2 -0
- package/esm2020/lib/data-grid/datagrid.module.mjs +145 -0
- package/esm2020/lib/data-grid/filters/filter.component.mjs +39 -0
- package/esm2020/lib/data-grid/templates/cell-template.component.mjs +53 -0
- package/esm2020/lib/data-grid/templates/detail-template.component.mjs +46 -0
- package/esm2020/lib/data-grid/templates/row-template.component.mjs +43 -0
- package/esm2020/lib/data-lov/data-lov-popup/data-lov-popup.component.mjs +114 -0
- package/esm2020/lib/data-lov/data-lov.component.mjs +165 -0
- package/esm2020/lib/data-lov/data-lov.module.mjs +23 -0
- package/esm2020/public-api.mjs +18 -0
- package/fesm2015/acorex-data-grid.mjs +1881 -0
- package/fesm2015/acorex-data-grid.mjs.map +1 -0
- package/fesm2020/acorex-data-grid.mjs +1881 -0
- package/fesm2020/acorex-data-grid.mjs.map +1 -0
- package/lib/data-grid/columns/check-column.component.d.ts +37 -0
- package/lib/data-grid/columns/column.component.d.ts +32 -0
- package/lib/data-grid/columns/command-column.component.d.ts +27 -0
- package/lib/data-grid/columns/date-column.component.d.ts +32 -0
- package/lib/data-grid/columns/row-number-column.component.d.ts +10 -0
- package/lib/data-grid/columns/selection-column.component.d.ts +12 -0
- package/lib/data-grid/columns/text-column.component.d.ts +25 -0
- package/lib/data-grid/datagrid.component.d.ts +142 -0
- package/{src/lib/data-grid/datagrid.events.ts → lib/data-grid/datagrid.events.d.ts} +1 -4
- package/lib/data-grid/datagrid.module.d.ts +23 -0
- package/lib/data-grid/filters/filter.component.d.ts +5 -0
- package/lib/data-grid/templates/cell-template.component.d.ts +22 -0
- package/lib/data-grid/templates/detail-template.component.d.ts +21 -0
- package/lib/data-grid/templates/row-template.component.d.ts +20 -0
- package/lib/data-lov/data-lov-popup/data-lov-popup.component.d.ts +33 -0
- package/lib/data-lov/data-lov.component.d.ts +43 -0
- package/lib/data-lov/data-lov.module.d.ts +12 -0
- package/package.json +37 -17
- package/{src/public-api.ts → public-api.d.ts} +0 -3
- package/karma.conf.js +0 -32
- package/ng-package.json +0 -12
- package/src/lib/data-grid/columns/check-column.component.ts +0 -113
- package/src/lib/data-grid/columns/column.component.ts +0 -182
- package/src/lib/data-grid/columns/command-column.component.ts +0 -101
- package/src/lib/data-grid/columns/date-column.component.ts +0 -118
- package/src/lib/data-grid/columns/row-number-column.component.ts +0 -36
- package/src/lib/data-grid/columns/selection-column.component.ts +0 -39
- package/src/lib/data-grid/columns/text-column.component.ts +0 -92
- package/src/lib/data-grid/datagrid.component.html +0 -27
- package/src/lib/data-grid/datagrid.component.ts +0 -769
- package/src/lib/data-grid/datagrid.module.ts +0 -81
- package/src/lib/data-grid/filters/filter.component.ts +0 -21
- package/src/lib/data-grid/templates/cell-template.component.ts +0 -47
- package/src/lib/data-grid/templates/detail-template.component.ts +0 -43
- package/src/lib/data-grid/templates/row-template.component.ts +0 -41
- package/src/lib/data-lov/data-lov-popup/data-lov-popup.component.html +0 -16
- package/src/lib/data-lov/data-lov-popup/data-lov-popup.component.ts +0 -130
- package/src/lib/data-lov/data-lov.component.html +0 -61
- package/src/lib/data-lov/data-lov.component.ts +0 -184
- package/src/lib/data-lov/data-lov.module.ts +0 -16
- package/src/test.ts +0 -28
- package/tsconfig.lib.json +0 -23
- package/tsconfig.lib.prod.json +0 -6
- package/tsconfig.spec.json +0 -17
- package/tslint.json +0 -17
@@ -0,0 +1,142 @@
|
|
1
|
+
import { EventEmitter, ElementRef, ChangeDetectorRef } from '@angular/core';
|
2
|
+
import { AXDataSourceComponent } from '@acorex/components';
|
3
|
+
import { AXGridDataColumn } from './columns/column.component';
|
4
|
+
import { GridOptions, CellClickedEvent, RowClickedEvent, FirstDataRenderedEvent, GridSizeChangedEvent } from 'ag-grid-community';
|
5
|
+
import { AXGridCellEvent, AXGridRowEvent, AXGridRowSelectionEvent, AXGridRowParams } from './datagrid.events';
|
6
|
+
import { AXDataGridRowTemplateComponent } from './templates/row-template.component';
|
7
|
+
import { AXToolbarSearchComponent, AXToolbarComponent, AXDataEvent, AXValueEvent } from '@acorex/components';
|
8
|
+
import { AXDataGridDetailTemplateComponent } from './templates/detail-template.component';
|
9
|
+
import * as i0 from "@angular/core";
|
10
|
+
export declare class AXDataGridColumnsChangeEvent extends AXValueEvent<AXGridDataColumn[]> {
|
11
|
+
component: AXDataGridComponent;
|
12
|
+
}
|
13
|
+
export declare class AXDataGridCellEvent extends AXDataEvent<AXGridCellEvent> {
|
14
|
+
component: AXDataGridComponent;
|
15
|
+
}
|
16
|
+
export declare class AXDaagridRowClickEvent extends AXDataEvent<AXGridRowEvent> {
|
17
|
+
component: AXDataGridComponent;
|
18
|
+
}
|
19
|
+
export declare class AXDataGridSelectionChangeEvent extends AXDataEvent<AXGridRowSelectionEvent> {
|
20
|
+
component: AXDataGridComponent;
|
21
|
+
}
|
22
|
+
export declare class AXDataGridRowSelectionChangeEvent extends AXDataEvent<any> {
|
23
|
+
component: AXDataGridComponent;
|
24
|
+
selected: boolean;
|
25
|
+
}
|
26
|
+
export declare class AXDataGridComponent {
|
27
|
+
private ref;
|
28
|
+
private cdr;
|
29
|
+
private gridApi;
|
30
|
+
private dataSourceSuccessCallback;
|
31
|
+
localeText: any;
|
32
|
+
gridOptions: GridOptions;
|
33
|
+
columnDefs: any[];
|
34
|
+
rowModelType: string;
|
35
|
+
fullWidthCellRendererFramework: any;
|
36
|
+
fullWidthCellRendererParams: any;
|
37
|
+
frameworkComponents: any;
|
38
|
+
isFullWidthCell: Function;
|
39
|
+
internalHeight: string;
|
40
|
+
detailCellRenderer: any;
|
41
|
+
detailCellRendererParams: any;
|
42
|
+
detailRowHeight: number;
|
43
|
+
masterDetail: boolean;
|
44
|
+
treeData: boolean;
|
45
|
+
enabelSelect: boolean;
|
46
|
+
gridView: boolean;
|
47
|
+
groupSelectsChildren: boolean;
|
48
|
+
oldSelectionNodes: any[];
|
49
|
+
paginationAutoPageSize: boolean;
|
50
|
+
paginationPageSize: number;
|
51
|
+
cacheBlockSize: number;
|
52
|
+
remoteOperation: boolean;
|
53
|
+
rowMultiSelectWithClick: boolean;
|
54
|
+
suppressRowClickSelection: boolean;
|
55
|
+
suppressCellSelection: boolean;
|
56
|
+
sizeColumnsToFit: boolean;
|
57
|
+
showCheckBox: boolean;
|
58
|
+
floatingFilter: boolean;
|
59
|
+
autoGroupColumnDef: any;
|
60
|
+
selectionMode: 'single' | 'multiple';
|
61
|
+
pagination: boolean;
|
62
|
+
selectRow: any[];
|
63
|
+
rowGroupPanelShow: 'always' | 'never';
|
64
|
+
loadOnInit: boolean;
|
65
|
+
keyField: string;
|
66
|
+
hasChildField: string;
|
67
|
+
private _searchText;
|
68
|
+
get searchText(): string;
|
69
|
+
set searchText(v: string);
|
70
|
+
private _filter;
|
71
|
+
get filter(): any[];
|
72
|
+
set filter(v: any[]);
|
73
|
+
private _inlineColumns;
|
74
|
+
columnsChange: EventEmitter<AXDataGridColumnsChangeEvent>;
|
75
|
+
private _columns;
|
76
|
+
get columns(): AXGridDataColumn[];
|
77
|
+
set columns(val: AXGridDataColumn[]);
|
78
|
+
defaultColDef: any;
|
79
|
+
rowHeight: any;
|
80
|
+
searchInput: AXToolbarSearchComponent;
|
81
|
+
toolbar: AXToolbarComponent;
|
82
|
+
rowTemplate: AXDataGridRowTemplateComponent;
|
83
|
+
gridDetailTemplate: AXDataGridDetailTemplateComponent;
|
84
|
+
private _contentDataSource;
|
85
|
+
private _dataSource;
|
86
|
+
get dataSource(): AXDataSourceComponent;
|
87
|
+
set dataSource(v: AXDataSourceComponent);
|
88
|
+
groupHideOpenParents: boolean;
|
89
|
+
cellClick: EventEmitter<AXDataGridCellEvent>;
|
90
|
+
cellDbClick: EventEmitter<AXDataGridCellEvent>;
|
91
|
+
cellFocuse: EventEmitter<AXDataGridCellEvent>;
|
92
|
+
rowClick: EventEmitter<AXDaagridRowClickEvent>;
|
93
|
+
rowDbClick: EventEmitter<AXDaagridRowClickEvent>;
|
94
|
+
selectionChanged: EventEmitter<AXDataGridSelectionChangeEvent>;
|
95
|
+
rowSelectionChange: EventEmitter<AXDataGridSelectionChangeEvent>;
|
96
|
+
onRowSelectionChanged: EventEmitter<AXDataGridRowSelectionChangeEvent>;
|
97
|
+
getRowHeight(param: any): any;
|
98
|
+
rowClass?: (params: AXGridRowParams) => (string | string[]) | (string | string[]);
|
99
|
+
rtl: boolean;
|
100
|
+
constructor(ref: ElementRef, cdr: ChangeDetectorRef);
|
101
|
+
private calcHeight;
|
102
|
+
private get intenalGridDataSource();
|
103
|
+
getMainMenuItems(e: any): string[];
|
104
|
+
ngOnDestroy(): void;
|
105
|
+
isServerSideGroup: (e: any) => any;
|
106
|
+
getColumnDefs: () => any;
|
107
|
+
getCurrentPageNumber: () => {
|
108
|
+
current: any;
|
109
|
+
total: any;
|
110
|
+
};
|
111
|
+
paginationGoToPage(number: any): void;
|
112
|
+
getServerSideGroupKey: (e: any) => any;
|
113
|
+
internalGridReady(gridOptions: any): void;
|
114
|
+
ngAfterContentInit(): void;
|
115
|
+
ngOnInit(): void;
|
116
|
+
gridSelectRow(): void;
|
117
|
+
rebuildGrid(): void;
|
118
|
+
ngAfterViewInit(): void;
|
119
|
+
mapColumns(): void;
|
120
|
+
displayedColumnsChanged(e: any): void;
|
121
|
+
refresh(route?: any[]): void;
|
122
|
+
internalGridCellClicked(e: CellClickedEvent): void;
|
123
|
+
internalGridCellDoubleClicked(e: CellClickedEvent): void;
|
124
|
+
internalGridCellFocused(e: CellClickedEvent): void;
|
125
|
+
internalGridRowClicked(e: RowClickedEvent): void;
|
126
|
+
internalGridRowDoubleClicked(e: CellClickedEvent): void;
|
127
|
+
differenceOf2Arrays(array1: any, array2: any): any[];
|
128
|
+
rowSelectionChanged(e: any): void;
|
129
|
+
internalGridSelectionChanged(e: any): void;
|
130
|
+
private mapCellEvent;
|
131
|
+
private mapRowEvent;
|
132
|
+
deselectAll(): void;
|
133
|
+
deselectByKeyField(keyField: any): void;
|
134
|
+
internalGetRowClass: (p: any) => string | string[];
|
135
|
+
showLoading(): void;
|
136
|
+
hideLoading(): void;
|
137
|
+
internalGridSizeChanged(e: GridSizeChangedEvent): void;
|
138
|
+
internalGridFirstDataRendered(e: FirstDataRenderedEvent): void;
|
139
|
+
private performSizeColumnsToFit;
|
140
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<AXDataGridComponent, never>;
|
141
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<AXDataGridComponent, "ax-data-grid", never, { "remoteOperation": "remoteOperation"; "rowMultiSelectWithClick": "rowMultiSelectWithClick"; "suppressRowClickSelection": "suppressRowClickSelection"; "suppressCellSelection": "suppressCellSelection"; "sizeColumnsToFit": "sizeColumnsToFit"; "showCheckBox": "showCheckBox"; "floatingFilter": "floatingFilter"; "selectionMode": "selectionMode"; "pagination": "pagination"; "selectRow": "selectRow"; "rowGroupPanelShow": "rowGroupPanelShow"; "loadOnInit": "loadOnInit"; "keyField": "keyField"; "hasChildField": "hasChildField"; "searchText": "searchText"; "filter": "filter"; "columns": "columns"; "rowHeight": "rowHeight"; "dataSource": "dataSource"; "groupHideOpenParents": "groupHideOpenParents"; "rowClass": "rowClass"; "rtl": "rtl"; }, { "columnsChange": "columnsChange"; "cellClick": "cellClick"; "cellDbClick": "cellDbClick"; "cellFocuse": "cellFocuse"; "rowClick": "rowClick"; "rowDbClick": "rowDbClick"; "selectionChanged": "selectionChanged"; "rowSelectionChange": "rowSelectionChange"; "onRowSelectionChanged": "onRowSelectionChanged"; }, ["searchInput", "toolbar", "rowTemplate", "gridDetailTemplate", "_contentDataSource", "_inlineColumns"], ["ax-toolbar"]>;
|
142
|
+
}
|
@@ -5,19 +5,16 @@ export interface AXGridRowEvent {
|
|
5
5
|
}
|
6
6
|
export interface AXGridRowCommandEvent extends AXGridRowEvent {
|
7
7
|
command: string;
|
8
|
-
htmlEvent:UIEvent
|
8
|
+
htmlEvent: UIEvent;
|
9
9
|
}
|
10
10
|
export interface AXGridCellEvent extends AXGridRowEvent {
|
11
11
|
column: any;
|
12
12
|
value: any;
|
13
13
|
}
|
14
|
-
|
15
|
-
|
16
14
|
export interface AXGridRowParams extends AXGridRowEvent {
|
17
15
|
}
|
18
16
|
export interface AXGridCellParams extends AXGridCellEvent {
|
19
17
|
}
|
20
|
-
|
21
18
|
export interface AXGridRowSelectionEvent {
|
22
19
|
items: AXGridRowEvent[];
|
23
20
|
}
|
@@ -0,0 +1,23 @@
|
|
1
|
+
import 'ag-grid-enterprise';
|
2
|
+
import * as i0 from "@angular/core";
|
3
|
+
import * as i1 from "./datagrid.component";
|
4
|
+
import * as i2 from "./columns/text-column.component";
|
5
|
+
import * as i3 from "./columns/check-column.component";
|
6
|
+
import * as i4 from "./columns/selection-column.component";
|
7
|
+
import * as i5 from "./columns/date-column.component";
|
8
|
+
import * as i6 from "./columns/row-number-column.component";
|
9
|
+
import * as i7 from "./columns/command-column.component";
|
10
|
+
import * as i8 from "./filters/filter.component";
|
11
|
+
import * as i9 from "./templates/row-template.component";
|
12
|
+
import * as i10 from "./templates/detail-template.component";
|
13
|
+
import * as i11 from "./templates/cell-template.component";
|
14
|
+
import * as i12 from "@angular/common";
|
15
|
+
import * as i13 from "@acorex/core";
|
16
|
+
import * as i14 from "@angular/forms";
|
17
|
+
import * as i15 from "@acorex/components";
|
18
|
+
import * as i16 from "ag-grid-angular";
|
19
|
+
export declare class AXDataGridModule {
|
20
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<AXDataGridModule, never>;
|
21
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<AXDataGridModule, [typeof i1.AXDataGridComponent, typeof i2.AXGridTextColumn, typeof i3.AXGridCheckColumn, typeof i4.AXGridSelectionColumn, typeof i5.AXGridDateColumn, typeof i6.AXGridRowNumberColumn, typeof i7.AXGridCommandColumn, typeof i3.BooleanRenderer, typeof i3.BooleanFilterRenderer, typeof i2.TextFilterRenderer, typeof i8.AXDataGridFilterComponent, typeof i9.AXDataGridRowTemplateComponent, typeof i10.AXDataGridDetailTemplateComponent, typeof i9.AXDataGridRowTemplateRenderer, typeof i10.AXDataGridDetailTemplateRenderer, typeof i11.AXDataGridCellTemplateComponent, typeof i11.AXDataGridCellTemplateRenderer, typeof i5.AXDatePickerFilterComponent, typeof i7.CommandRenderer], [typeof i12.CommonModule, typeof i13.AXCoreModule, typeof i14.FormsModule, typeof i15.AXTextBoxModule, typeof i15.AXCheckBoxModule, typeof i15.AXSelectBoxModule, typeof i15.AXDataSourceModule, typeof i15.AXButtonModule, typeof i15.AXDatePickerModule, typeof i16.AgGridModule], [typeof i1.AXDataGridComponent, typeof i8.AXDataGridFilterComponent, typeof i9.AXDataGridRowTemplateComponent, typeof i10.AXDataGridDetailTemplateComponent, typeof i9.AXDataGridRowTemplateRenderer, typeof i10.AXDataGridDetailTemplateRenderer, typeof i11.AXDataGridCellTemplateComponent, typeof i11.AXDataGridCellTemplateRenderer, typeof i2.AXGridTextColumn, typeof i6.AXGridRowNumberColumn, typeof i3.AXGridCheckColumn, typeof i5.AXGridDateColumn, typeof i4.AXGridSelectionColumn, typeof i7.AXGridCommandColumn, typeof i3.BooleanRenderer, typeof i3.BooleanFilterRenderer, typeof i7.CommandRenderer]>;
|
22
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<AXDataGridModule>;
|
23
|
+
}
|
@@ -0,0 +1,5 @@
|
|
1
|
+
import * as i0 from "@angular/core";
|
2
|
+
export declare class AXDataGridFilterComponent {
|
3
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<AXDataGridFilterComponent, never>;
|
4
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<AXDataGridFilterComponent, "ax-data-grid-filter", never, {}, {}, never, ["*"]>;
|
5
|
+
}
|
@@ -0,0 +1,22 @@
|
|
1
|
+
import { TemplateRef } from '@angular/core';
|
2
|
+
import { ICellRendererAngularComp } from 'ag-grid-angular';
|
3
|
+
import { ICellRendererParams } from 'ag-grid-community';
|
4
|
+
import * as i0 from "@angular/core";
|
5
|
+
export declare class AXDataGridCellTemplateComponent {
|
6
|
+
templateRef: TemplateRef<any>;
|
7
|
+
renderer: any;
|
8
|
+
params: any;
|
9
|
+
constructor();
|
10
|
+
ngOnInit(): void;
|
11
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<AXDataGridCellTemplateComponent, never>;
|
12
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<AXDataGridCellTemplateComponent, "ax-cell-template", never, {}, {}, ["templateRef"], ["*"]>;
|
13
|
+
}
|
14
|
+
export declare class AXDataGridCellTemplateRenderer implements ICellRendererAngularComp {
|
15
|
+
rowData: any;
|
16
|
+
templateRef: TemplateRef<any>;
|
17
|
+
constructor();
|
18
|
+
agInit(params: ICellRendererParams): void;
|
19
|
+
refresh(params: ICellRendererParams): boolean;
|
20
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<AXDataGridCellTemplateRenderer, never>;
|
21
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<AXDataGridCellTemplateRenderer, "ng-component", never, {}, {}, never, never>;
|
22
|
+
}
|
@@ -0,0 +1,21 @@
|
|
1
|
+
import { TemplateRef } from '@angular/core';
|
2
|
+
import { ICellRendererAngularComp } from 'ag-grid-angular';
|
3
|
+
import * as i0 from "@angular/core";
|
4
|
+
export declare class AXDataGridDetailTemplateComponent {
|
5
|
+
templateRef: TemplateRef<any>;
|
6
|
+
renderer: any;
|
7
|
+
params: any;
|
8
|
+
constructor();
|
9
|
+
ngOnInit(): void;
|
10
|
+
height: number;
|
11
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<AXDataGridDetailTemplateComponent, never>;
|
12
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<AXDataGridDetailTemplateComponent, "ax-grid-detail-template", never, { "height": "height"; }, {}, ["templateRef"], ["*"]>;
|
13
|
+
}
|
14
|
+
export declare class AXDataGridDetailTemplateRenderer implements ICellRendererAngularComp {
|
15
|
+
refresh(params: any): boolean;
|
16
|
+
templateRef: TemplateRef<any>;
|
17
|
+
data: any;
|
18
|
+
agInit(params: any): void;
|
19
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<AXDataGridDetailTemplateRenderer, never>;
|
20
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<AXDataGridDetailTemplateRenderer, "ng-component", never, {}, {}, never, never>;
|
21
|
+
}
|
@@ -0,0 +1,20 @@
|
|
1
|
+
import { TemplateRef } from '@angular/core';
|
2
|
+
import { ICellRendererAngularComp } from 'ag-grid-angular';
|
3
|
+
import * as i0 from "@angular/core";
|
4
|
+
export declare class AXDataGridRowTemplateComponent {
|
5
|
+
templateRef: TemplateRef<any>;
|
6
|
+
renderer: any;
|
7
|
+
params: any;
|
8
|
+
constructor();
|
9
|
+
ngOnInit(): void;
|
10
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<AXDataGridRowTemplateComponent, never>;
|
11
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<AXDataGridRowTemplateComponent, "ax-row-template", never, {}, {}, ["templateRef"], ["*"]>;
|
12
|
+
}
|
13
|
+
export declare class AXDataGridRowTemplateRenderer implements ICellRendererAngularComp {
|
14
|
+
templateRef: TemplateRef<any>;
|
15
|
+
data: any;
|
16
|
+
refresh(params: any): boolean;
|
17
|
+
agInit(params: any): void;
|
18
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<AXDataGridRowTemplateRenderer, never>;
|
19
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<AXDataGridRowTemplateRenderer, "ng-component", never, {}, {}, never, never>;
|
20
|
+
}
|
@@ -0,0 +1,33 @@
|
|
1
|
+
import { ChangeDetectorRef, ElementRef } from '@angular/core';
|
2
|
+
import { AXDataGridComponent } from '../../data-grid/datagrid.component';
|
3
|
+
import { AXGridDataColumn } from '../../data-grid/columns/column.component';
|
4
|
+
import { AXButtonItem } from '@acorex/core';
|
5
|
+
import { AXToolbarSearchComponent, AXBasePopupPageComponent, AXMenuItemClickEvent, AXDataSourceComponent } from '@acorex/components';
|
6
|
+
import * as i0 from "@angular/core";
|
7
|
+
export declare class AXDataLovPopupComponent extends AXBasePopupPageComponent {
|
8
|
+
private cdr;
|
9
|
+
private ref;
|
10
|
+
grid: AXDataGridComponent;
|
11
|
+
searchBox: AXToolbarSearchComponent;
|
12
|
+
columns: AXGridDataColumn[];
|
13
|
+
selectedItems: any[];
|
14
|
+
keyField: string;
|
15
|
+
allowNull: boolean;
|
16
|
+
hasChildField: string;
|
17
|
+
rtl: boolean;
|
18
|
+
selectedRows: any[];
|
19
|
+
pagination: boolean;
|
20
|
+
constructor(cdr: ChangeDetectorRef, ref: ElementRef);
|
21
|
+
dataSource: AXDataSourceComponent;
|
22
|
+
selectionMode: string;
|
23
|
+
ngOnInit(): void;
|
24
|
+
onDoneClick(): void;
|
25
|
+
rowDoubleClicked(e: any): void;
|
26
|
+
onCancelClick(): void;
|
27
|
+
rowSelectionChange(e: any): void;
|
28
|
+
ngAfterViewInit(): void;
|
29
|
+
getFooterButtons(): AXButtonItem[];
|
30
|
+
onFooterButtonClick(e: AXMenuItemClickEvent): void;
|
31
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<AXDataLovPopupComponent, never>;
|
32
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<AXDataLovPopupComponent, "ng-component", never, {}, {}, never, never>;
|
33
|
+
}
|
@@ -0,0 +1,43 @@
|
|
1
|
+
import { EventEmitter, ElementRef, TemplateRef } from '@angular/core';
|
2
|
+
import { AXPopupService, AXBaseInputComponent, AXBaseSizableComponent, AXElementSize, AXValidation } from '@acorex/components';
|
3
|
+
import { AXDataSourceComponent, AXSelectBoxComponent, AXDataEvent, AXValidatableComponent } from '@acorex/components';
|
4
|
+
import * as i0 from "@angular/core";
|
5
|
+
export declare class AXLOVComponent extends AXValidatableComponent implements AXBaseSizableComponent, AXBaseInputComponent {
|
6
|
+
private popup;
|
7
|
+
private ref;
|
8
|
+
private _contentValidation;
|
9
|
+
private _validation;
|
10
|
+
get validation(): AXValidation;
|
11
|
+
set validation(v: AXValidation);
|
12
|
+
constructor(popup: AXPopupService, ref: ElementRef);
|
13
|
+
selectBox: AXSelectBoxComponent;
|
14
|
+
dataSource: AXDataSourceComponent;
|
15
|
+
private columns;
|
16
|
+
rowTemplate: TemplateRef<any>;
|
17
|
+
textField: string;
|
18
|
+
allowSearch: boolean;
|
19
|
+
valueField: string;
|
20
|
+
hasChildField: string;
|
21
|
+
allowNull: boolean;
|
22
|
+
popupSize: 'sm' | 'md' | 'lg' | 'full';
|
23
|
+
pagination: boolean;
|
24
|
+
selectedItems: any[];
|
25
|
+
readonly: boolean;
|
26
|
+
disabled: boolean;
|
27
|
+
chipsWidth: string;
|
28
|
+
size: AXElementSize;
|
29
|
+
caption: string;
|
30
|
+
mode: 'single' | 'multiple';
|
31
|
+
placeholder: string;
|
32
|
+
onSelectionChange: EventEmitter<AXDataEvent<any>>;
|
33
|
+
rtl: boolean;
|
34
|
+
focus(): void;
|
35
|
+
refresh(): void;
|
36
|
+
handleButtonClick(): void;
|
37
|
+
ngOnInit(): void;
|
38
|
+
ngAfterContentInit(): void;
|
39
|
+
handleSelectChange(e: any): void;
|
40
|
+
open(): Promise<any>;
|
41
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<AXLOVComponent, never>;
|
42
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<AXLOVComponent, "ax-lov", never, { "validation": "validation"; "textField": "textField"; "allowSearch": "allowSearch"; "valueField": "valueField"; "hasChildField": "hasChildField"; "allowNull": "allowNull"; "popupSize": "popupSize"; "pagination": "pagination"; "selectedItems": "selectedItems"; "readonly": "readonly"; "disabled": "disabled"; "chipsWidth": "chipsWidth"; "size": "size"; "caption": "caption"; "mode": "mode"; "placeholder": "placeholder"; "rtl": "rtl"; }, { "onSelectionChange": "onSelectionChange"; }, ["_contentValidation", "dataSource", "rowTemplate", "columns"], ["[start]", "[end]"]>;
|
43
|
+
}
|
@@ -0,0 +1,12 @@
|
|
1
|
+
import * as i0 from "@angular/core";
|
2
|
+
import * as i1 from "./data-lov.component";
|
3
|
+
import * as i2 from "./data-lov-popup/data-lov-popup.component";
|
4
|
+
import * as i3 from "@angular/common";
|
5
|
+
import * as i4 from "@angular/forms";
|
6
|
+
import * as i5 from "../data-grid/datagrid.module";
|
7
|
+
import * as i6 from "@acorex/components";
|
8
|
+
export declare class AXLOVModule {
|
9
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<AXLOVModule, never>;
|
10
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<AXLOVModule, [typeof i1.AXLOVComponent, typeof i2.AXDataLovPopupComponent], [typeof i3.CommonModule, typeof i4.FormsModule, typeof i5.AXDataGridModule, typeof i6.AXDataSourceModule, typeof i6.AXButtonModule, typeof i6.AXToolbarModule, typeof i6.AXSelectBoxModule, typeof i6.AXSearchBoxModule], [typeof i1.AXLOVComponent, typeof i2.AXDataLovPopupComponent]>;
|
11
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<AXLOVModule>;
|
12
|
+
}
|
package/package.json
CHANGED
@@ -1,17 +1,37 @@
|
|
1
|
-
{
|
2
|
-
"name": "@acorex/data-grid",
|
3
|
-
"version": "5.1.
|
4
|
-
"peerDependencies": {
|
5
|
-
"@angular/common": "^13.3.8",
|
6
|
-
"@angular/core": "^13.3.8",
|
7
|
-
"ag-grid-angular": "^24.0.0",
|
8
|
-
"ag-grid-community": "^24.0.0",
|
9
|
-
"ag-grid-enterprise": "^24.0.0"
|
10
|
-
},
|
11
|
-
"dependencies": {
|
12
|
-
"ag-grid-angular": "^24.0.0",
|
13
|
-
"ag-grid-community": "^24.0.0",
|
14
|
-
"ag-grid-enterprise": "^24.0.0",
|
15
|
-
"tslib": "^2.0.0"
|
16
|
-
}
|
17
|
-
|
1
|
+
{
|
2
|
+
"name": "@acorex/data-grid",
|
3
|
+
"version": "5.1.7",
|
4
|
+
"peerDependencies": {
|
5
|
+
"@angular/common": "^13.3.8",
|
6
|
+
"@angular/core": "^13.3.8",
|
7
|
+
"ag-grid-angular": "^24.0.0",
|
8
|
+
"ag-grid-community": "^24.0.0",
|
9
|
+
"ag-grid-enterprise": "^24.0.0"
|
10
|
+
},
|
11
|
+
"dependencies": {
|
12
|
+
"ag-grid-angular": "^24.0.0",
|
13
|
+
"ag-grid-community": "^24.0.0",
|
14
|
+
"ag-grid-enterprise": "^24.0.0",
|
15
|
+
"tslib": "^2.0.0"
|
16
|
+
},
|
17
|
+
"module": "fesm2015/acorex-data-grid.mjs",
|
18
|
+
"es2020": "fesm2020/acorex-data-grid.mjs",
|
19
|
+
"esm2020": "esm2020/acorex-data-grid.mjs",
|
20
|
+
"fesm2020": "fesm2020/acorex-data-grid.mjs",
|
21
|
+
"fesm2015": "fesm2015/acorex-data-grid.mjs",
|
22
|
+
"typings": "acorex-data-grid.d.ts",
|
23
|
+
"exports": {
|
24
|
+
"./package.json": {
|
25
|
+
"default": "./package.json"
|
26
|
+
},
|
27
|
+
".": {
|
28
|
+
"types": "./acorex-data-grid.d.ts",
|
29
|
+
"esm2020": "./esm2020/acorex-data-grid.mjs",
|
30
|
+
"es2020": "./fesm2020/acorex-data-grid.mjs",
|
31
|
+
"es2015": "./fesm2015/acorex-data-grid.mjs",
|
32
|
+
"node": "./fesm2015/acorex-data-grid.mjs",
|
33
|
+
"default": "./fesm2020/acorex-data-grid.mjs"
|
34
|
+
}
|
35
|
+
},
|
36
|
+
"sideEffects": false
|
37
|
+
}
|
@@ -5,16 +5,13 @@ export * from './lib/data-grid/columns/date-column.component';
|
|
5
5
|
export * from './lib/data-grid/columns/selection-column.component';
|
6
6
|
export * from './lib/data-grid/columns/text-column.component';
|
7
7
|
export * from './lib/data-grid/columns/row-number-column.component';
|
8
|
-
|
9
8
|
export * from './lib/data-grid/datagrid.component';
|
10
9
|
export * from './lib/data-grid/datagrid.events';
|
11
10
|
export * from './lib/data-grid/datagrid.module';
|
12
|
-
|
13
11
|
export * from './lib/data-grid/filters/filter.component';
|
14
12
|
export * from './lib/data-grid/templates/cell-template.component';
|
15
13
|
export * from './lib/data-grid/templates/row-template.component';
|
16
14
|
export * from './lib/data-grid/templates/detail-template.component';
|
17
|
-
|
18
15
|
export * from './lib/data-lov/data-lov-popup/data-lov-popup.component';
|
19
16
|
export * from './lib/data-lov/data-lov.component';
|
20
17
|
export * from './lib/data-lov/data-lov.module';
|
package/karma.conf.js
DELETED
@@ -1,32 +0,0 @@
|
|
1
|
-
// Karma configuration file, see link for more information
|
2
|
-
// https://karma-runner.github.io/1.0/config/configuration-file.html
|
3
|
-
|
4
|
-
module.exports = function (config) {
|
5
|
-
config.set({
|
6
|
-
basePath: '',
|
7
|
-
frameworks: ['jasmine', '@angular-devkit/build-angular'],
|
8
|
-
plugins: [
|
9
|
-
require('karma-jasmine'),
|
10
|
-
require('karma-chrome-launcher'),
|
11
|
-
require('karma-jasmine-html-reporter'),
|
12
|
-
require('karma-coverage-istanbul-reporter'),
|
13
|
-
require('@angular-devkit/build-angular/plugins/karma')
|
14
|
-
],
|
15
|
-
client: {
|
16
|
-
clearContext: false // leave Jasmine Spec Runner output visible in browser
|
17
|
-
},
|
18
|
-
coverageIstanbulReporter: {
|
19
|
-
dir: require('path').join(__dirname, '../../../coverage/acorex/data-grid'),
|
20
|
-
reports: ['html', 'lcovonly', 'text-summary'],
|
21
|
-
fixWebpackSourcePaths: true
|
22
|
-
},
|
23
|
-
reporters: ['progress', 'kjhtml'],
|
24
|
-
port: 9876,
|
25
|
-
colors: true,
|
26
|
-
logLevel: config.LOG_INFO,
|
27
|
-
autoWatch: true,
|
28
|
-
browsers: ['Chrome'],
|
29
|
-
singleRun: false,
|
30
|
-
restartOnFileChange: true
|
31
|
-
});
|
32
|
-
};
|
package/ng-package.json
DELETED
@@ -1,12 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"$schema": "../../../node_modules/ng-packagr/ng-package.schema.json",
|
3
|
-
"dest": "../../../dist/acorex/data-grid",
|
4
|
-
"lib": {
|
5
|
-
"entryFile": "src/public-api.ts"
|
6
|
-
},
|
7
|
-
"allowedNonPeerDependencies": [
|
8
|
-
"ag-grid-community",
|
9
|
-
"ag-grid-angular",
|
10
|
-
"ag-grid-enterprise"
|
11
|
-
]
|
12
|
-
}
|
@@ -1,113 +0,0 @@
|
|
1
|
-
import {
|
2
|
-
Component,
|
3
|
-
ChangeDetectionStrategy,
|
4
|
-
ViewChild,
|
5
|
-
ViewContainerRef
|
6
|
-
} from '@angular/core';
|
7
|
-
import { AXGridDataColumn } from './column.component';
|
8
|
-
import { ICellRendererAngularComp, IFilterAngularComp } from 'ag-grid-angular';
|
9
|
-
import {
|
10
|
-
ICellRendererParams,
|
11
|
-
IFilterParams,
|
12
|
-
RowNode,
|
13
|
-
IDoesFilterPassParams,
|
14
|
-
IAfterGuiAttachedParams
|
15
|
-
} from 'ag-grid-community';
|
16
|
-
|
17
|
-
@Component({
|
18
|
-
selector: 'ax-check-column',
|
19
|
-
template: '',
|
20
|
-
providers: [{ provide: AXGridDataColumn, useExisting: AXGridCheckColumn }],
|
21
|
-
changeDetection: ChangeDetectionStrategy.OnPush
|
22
|
-
})
|
23
|
-
|
24
|
-
export class AXGridCheckColumn extends AXGridDataColumn {
|
25
|
-
constructor() {
|
26
|
-
super();
|
27
|
-
}
|
28
|
-
|
29
|
-
render() {
|
30
|
-
const col = super.render();
|
31
|
-
if (!col.cellRendererFramework) {
|
32
|
-
col.cellRendererFramework = BooleanRenderer;
|
33
|
-
}
|
34
|
-
if (this.allowFiltering) {
|
35
|
-
col.filterFramework = BooleanFilterRenderer;
|
36
|
-
}
|
37
|
-
return col;
|
38
|
-
}
|
39
|
-
}
|
40
|
-
|
41
|
-
@Component({
|
42
|
-
template: `
|
43
|
-
<ax-check-box [value]='value' readonly='true'></ax-check-box>
|
44
|
-
`,
|
45
|
-
changeDetection: ChangeDetectionStrategy.OnPush
|
46
|
-
})
|
47
|
-
export class BooleanRenderer implements ICellRendererAngularComp {
|
48
|
-
value: boolean;
|
49
|
-
constructor() { }
|
50
|
-
agInit(params: ICellRendererParams): void {
|
51
|
-
this.value = params.value;
|
52
|
-
}
|
53
|
-
refresh(params: ICellRendererParams): boolean {
|
54
|
-
this.value = params.value;
|
55
|
-
return true;
|
56
|
-
}
|
57
|
-
}
|
58
|
-
|
59
|
-
@Component({
|
60
|
-
template: `
|
61
|
-
<ax-data-grid-filter>
|
62
|
-
<ax-select-box
|
63
|
-
label='Select Box'
|
64
|
-
[items]='selectItem'
|
65
|
-
></ax-select-box>
|
66
|
-
</ax-data-grid-filter>
|
67
|
-
`,
|
68
|
-
changeDetection: ChangeDetectionStrategy.OnPush
|
69
|
-
})
|
70
|
-
export class BooleanFilterRenderer implements IFilterAngularComp {
|
71
|
-
public value?: boolean = null;
|
72
|
-
private params: IFilterParams;
|
73
|
-
private valueGetter: (rowNode: RowNode) => any;
|
74
|
-
@ViewChild('input', { static: true, read: ViewContainerRef }) public input;
|
75
|
-
|
76
|
-
selectItem = [
|
77
|
-
{ value: 0, label: 'True' },
|
78
|
-
{ value: 1, label: 'False' },
|
79
|
-
];
|
80
|
-
agInit(params: IFilterParams): void {
|
81
|
-
this.params = params;
|
82
|
-
this.valueGetter = (params.valueGetter) as any;
|
83
|
-
}
|
84
|
-
|
85
|
-
isFilterActive(): boolean {
|
86
|
-
return this.value !== null && this.value !== undefined;
|
87
|
-
}
|
88
|
-
|
89
|
-
doesFilterPass(params: IDoesFilterPassParams): boolean {
|
90
|
-
return this.value === this.valueGetter(params.node);
|
91
|
-
}
|
92
|
-
|
93
|
-
getModel(): any {
|
94
|
-
return { value: this.value };
|
95
|
-
}
|
96
|
-
|
97
|
-
setModel(model: any): void {
|
98
|
-
this.value = model ? model.value : null;
|
99
|
-
}
|
100
|
-
|
101
|
-
ngAfterViewInit(params: IAfterGuiAttachedParams): void {
|
102
|
-
window.setTimeout(() => {
|
103
|
-
this.input.element.nativeElement.focus();
|
104
|
-
});
|
105
|
-
}
|
106
|
-
|
107
|
-
onChange(newValue): void {
|
108
|
-
if (this.value !== newValue) {
|
109
|
-
this.value = newValue;
|
110
|
-
this.params.filterChangedCallback();
|
111
|
-
}
|
112
|
-
}
|
113
|
-
}
|