@syncfusion/ej2-grids 20.3.47-54738 → 20.3.47-54739
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/dist/ej2-grids.min.js +1 -0
- package/helpers/e2e/gridhelper.d.ts +59 -0
- package/helpers/e2e/index.d.ts +1 -0
- package/package.json +1 -1
- package/src/components.d.ts +5 -0
- package/src/grid/actions/aggregate.d.ts +31 -0
- package/src/grid/actions/batch-edit.d.ts +116 -0
- package/src/grid/actions/blazor-action.d.ts +47 -0
- package/src/grid/actions/checkbox-filter.d.ts +47 -0
- package/src/grid/actions/clipboard.d.ts +69 -0
- package/src/grid/actions/column-chooser.d.ts +114 -0
- package/src/grid/actions/column-menu.d.ts +99 -0
- package/src/grid/actions/command-column.d.ts +31 -0
- package/src/grid/actions/context-menu.d.ts +102 -0
- package/src/grid/actions/data.d.ts +110 -0
- package/src/grid/actions/detail-row.d.ts +73 -0
- package/src/grid/actions/dialog-edit.d.ts +21 -0
- package/src/grid/actions/edit.d.ts +271 -0
- package/src/grid/actions/excel-export.d.ts +89 -0
- package/src/grid/actions/excel-filter.d.ts +53 -0
- package/src/grid/actions/export-helper.d.ts +67 -0
- package/src/grid/actions/filter.d.ts +253 -0
- package/src/grid/actions/foreign-key.d.ts +20 -0
- package/src/grid/actions/freeze.d.ts +17 -0
- package/src/grid/actions/group.d.ts +178 -0
- package/src/grid/actions/infinite-scroll.d.ts +146 -0
- package/src/grid/actions/inline-edit.d.ts +21 -0
- package/src/grid/actions/lazy-load-group.d.ts +40 -0
- package/src/grid/actions/logger.d.ts +30 -0
- package/src/grid/actions/normal-edit.d.ts +76 -0
- package/src/grid/actions/page.d.ts +117 -0
- package/src/grid/actions/pdf-export.d.ts +142 -0
- package/src/grid/actions/print.d.ts +67 -0
- package/src/grid/actions/reorder.d.ts +95 -0
- package/src/grid/actions/resize.d.ts +117 -0
- package/src/grid/actions/row-reorder.d.ts +92 -0
- package/src/grid/actions/scroll.d.ts +114 -0
- package/src/grid/actions/search.d.ts +72 -0
- package/src/grid/actions/selection.d.ts +481 -0
- package/src/grid/actions/show-hide.d.ts +55 -0
- package/src/grid/actions/sort.d.ts +138 -0
- package/src/grid/actions/toolbar.d.ts +84 -0
- package/src/grid/actions/virtual-scroll.d.ts +23 -0
- package/src/grid/actions.d.ts +39 -0
- package/src/grid/aggregate.d.ts +4 -0
- package/src/grid/base/constant.d.ts +559 -0
- package/src/grid/base/enum.d.ts +704 -0
- package/src/grid/base/grid.d.ts +3627 -0
- package/src/grid/base/interface.d.ts +2567 -0
- package/src/grid/base/string-literals.d.ts +87 -0
- package/src/grid/base/type.d.ts +42 -0
- package/src/grid/base/util.d.ts +747 -0
- package/src/grid/base.d.ts +11 -0
- package/src/grid/column-chooser.d.ts +4 -0
- package/src/grid/column-menu.d.ts +4 -0
- package/src/grid/command-column.d.ts +4 -0
- package/src/grid/common/checkbox-filter-base.d.ts +137 -0
- package/src/grid/common/excel-filter-base.d.ts +115 -0
- package/src/grid/common/filter-interface.d.ts +42 -0
- package/src/grid/common/index.d.ts +5 -0
- package/src/grid/common.d.ts +6 -0
- package/src/grid/context-menu.d.ts +4 -0
- package/src/grid/detail-row.d.ts +4 -0
- package/src/grid/edit.d.ts +4 -0
- package/src/grid/excel-export.d.ts +4 -0
- package/src/grid/filter.d.ts +4 -0
- package/src/grid/foreign-key.d.ts +4 -0
- package/src/grid/freeze.d.ts +4 -0
- package/src/grid/group.d.ts +4 -0
- package/src/grid/index.d.ts +9 -0
- package/src/grid/infinite-scroll.d.ts +4 -0
- package/src/grid/lazy-load-group.d.ts +4 -0
- package/src/grid/logger.d.ts +4 -0
- package/src/grid/models/aggregate.d.ts +138 -0
- package/src/grid/models/cell.d.ts +38 -0
- package/src/grid/models/column-chooser-settings.d.ts +20 -0
- package/src/grid/models/column.d.ts +1122 -0
- package/src/grid/models/models.d.ts +7 -0
- package/src/grid/models/page-settings.d.ts +55 -0
- package/src/grid/models/row.d.ts +62 -0
- package/src/grid/models.d.ts +7 -0
- package/src/grid/page.d.ts +4 -0
- package/src/grid/pdf-export.d.ts +4 -0
- package/src/grid/renderer/autocomplete-edit-cell.d.ts +20 -0
- package/src/grid/renderer/batch-edit-renderer.d.ts +23 -0
- package/src/grid/renderer/boolean-edit-cell.d.ts +30 -0
- package/src/grid/renderer/boolean-filter-ui.d.ts +42 -0
- package/src/grid/renderer/caption-cell-renderer.d.ts +45 -0
- package/src/grid/renderer/cell-merge-renderer.d.ts +23 -0
- package/src/grid/renderer/cell-renderer.d.ts +91 -0
- package/src/grid/renderer/column-freeze-renderer.d.ts +166 -0
- package/src/grid/renderer/combobox-edit-cell.d.ts +19 -0
- package/src/grid/renderer/command-column-renderer.d.ts +31 -0
- package/src/grid/renderer/content-renderer.d.ts +210 -0
- package/src/grid/renderer/date-filter-ui.d.ts +31 -0
- package/src/grid/renderer/datepicker-edit-cell.d.ts +20 -0
- package/src/grid/renderer/default-edit-cell.d.ts +22 -0
- package/src/grid/renderer/detail-expand-cell-renderer.d.ts +21 -0
- package/src/grid/renderer/detail-header-indent-renderer.d.ts +20 -0
- package/src/grid/renderer/dialog-edit-renderer.d.ts +39 -0
- package/src/grid/renderer/dropdown-edit-cell.d.ts +32 -0
- package/src/grid/renderer/edit-cell-base.d.ts +25 -0
- package/src/grid/renderer/edit-renderer.d.ts +35 -0
- package/src/grid/renderer/expand-cell-renderer.d.ts +28 -0
- package/src/grid/renderer/filter-cell-renderer.d.ts +36 -0
- package/src/grid/renderer/filter-menu-operator.d.ts +43 -0
- package/src/grid/renderer/filter-menu-renderer.d.ts +65 -0
- package/src/grid/renderer/footer-renderer.d.ts +50 -0
- package/src/grid/renderer/freeze-renderer.d.ts +142 -0
- package/src/grid/renderer/group-lazy-load-renderer.d.ts +177 -0
- package/src/grid/renderer/header-cell-renderer.d.ts +54 -0
- package/src/grid/renderer/header-indent-renderer.d.ts +20 -0
- package/src/grid/renderer/header-renderer.d.ts +156 -0
- package/src/grid/renderer/indent-cell-renderer.d.ts +20 -0
- package/src/grid/renderer/inline-edit-renderer.d.ts +39 -0
- package/src/grid/renderer/inputmask-edit-cell.d.ts +18 -0
- package/src/grid/renderer/multiselect-edit-cell.d.ts +18 -0
- package/src/grid/renderer/number-filter-ui.d.ts +30 -0
- package/src/grid/renderer/numeric-edit-cell.d.ts +27 -0
- package/src/grid/renderer/render.d.ts +104 -0
- package/src/grid/renderer/responsive-dialog-renderer.d.ts +84 -0
- package/src/grid/renderer/row-drag-drop-renderer.d.ts +20 -0
- package/src/grid/renderer/row-drag-header-indent-render.d.ts +20 -0
- package/src/grid/renderer/row-renderer.d.ts +55 -0
- package/src/grid/renderer/stacked-cell-renderer.d.ts +23 -0
- package/src/grid/renderer/string-filter-ui.d.ts +39 -0
- package/src/grid/renderer/summary-cell-renderer.d.ts +15 -0
- package/src/grid/renderer/template-edit-cell.d.ts +13 -0
- package/src/grid/renderer/timepicker-edit-cell.d.ts +18 -0
- package/src/grid/renderer/toggleswitch-edit-cell.d.ts +27 -0
- package/src/grid/renderer/virtual-content-renderer.d.ts +221 -0
- package/src/grid/renderer/virtual-freeze-renderer.d.ts +382 -0
- package/src/grid/renderer.d.ts +42 -0
- package/src/grid/reorder.d.ts +4 -0
- package/src/grid/resize.d.ts +4 -0
- package/src/grid/row-reorder.d.ts +4 -0
- package/src/grid/selection.d.ts +4 -0
- package/src/grid/services/aria-service.d.ts +34 -0
- package/src/grid/services/cell-render-factory.d.ts +14 -0
- package/src/grid/services/focus-strategy.d.ts +192 -0
- package/src/grid/services/freeze-row-model-generator.d.ts +14 -0
- package/src/grid/services/group-model-generator.d.ts +68 -0
- package/src/grid/services/intersection-observer.d.ts +23 -0
- package/src/grid/services/renderer-factory.d.ts +14 -0
- package/src/grid/services/row-model-generator.d.ts +41 -0
- package/src/grid/services/service-locator.d.ts +14 -0
- package/src/grid/services/summary-model-generator.d.ts +43 -0
- package/src/grid/services/value-formatter.d.ts +16 -0
- package/src/grid/services/virtual-row-model-generator.d.ts +55 -0
- package/src/grid/services/width-controller.d.ts +35 -0
- package/src/grid/services.d.ts +11 -0
- package/src/grid/sort.d.ts +4 -0
- package/src/grid/toolbar.d.ts +4 -0
- package/src/grid/virtual-scroll.d.ts +4 -0
- package/src/index.d.ts +5 -0
- package/src/pager/external-message.d.ts +55 -0
- package/src/pager/index.d.ts +9 -0
- package/src/pager/numeric-container.d.ts +78 -0
- package/src/pager/pager-dropdown.d.ts +68 -0
- package/src/pager/pager-message.d.ts +50 -0
- package/src/pager/pager.d.ts +341 -0
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
import { ContextMenu as Menu } from '@syncfusion/ej2-navigations';
|
|
2
|
+
import { IGrid, IAction, ContextMenuClickEventArgs } from '../base/interface';
|
|
3
|
+
import { ServiceLocator } from '../services/service-locator';
|
|
4
|
+
export declare const menuClass: CMenuClassList;
|
|
5
|
+
export interface CMenuClassList {
|
|
6
|
+
header: string;
|
|
7
|
+
content: string;
|
|
8
|
+
edit: string;
|
|
9
|
+
batchEdit: string;
|
|
10
|
+
editIcon: string;
|
|
11
|
+
pager: string;
|
|
12
|
+
cancel: string;
|
|
13
|
+
save: string;
|
|
14
|
+
delete: string;
|
|
15
|
+
copy: string;
|
|
16
|
+
pdf: string;
|
|
17
|
+
group: string;
|
|
18
|
+
ungroup: string;
|
|
19
|
+
csv: string;
|
|
20
|
+
excel: string;
|
|
21
|
+
fPage: string;
|
|
22
|
+
lPage: string;
|
|
23
|
+
nPage: string;
|
|
24
|
+
pPage: string;
|
|
25
|
+
ascending: string;
|
|
26
|
+
descending: string;
|
|
27
|
+
groupHeader: string;
|
|
28
|
+
touchPop: string;
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* The `ContextMenu` module is used to handle context menu actions.
|
|
32
|
+
*/
|
|
33
|
+
export declare class ContextMenu implements IAction {
|
|
34
|
+
private element;
|
|
35
|
+
contextMenu: Menu;
|
|
36
|
+
private defaultItems;
|
|
37
|
+
private disableItems;
|
|
38
|
+
private hiddenItems;
|
|
39
|
+
private gridID;
|
|
40
|
+
private parent;
|
|
41
|
+
private serviceLocator;
|
|
42
|
+
private l10n;
|
|
43
|
+
private localeText;
|
|
44
|
+
private targetColumn;
|
|
45
|
+
private eventArgs;
|
|
46
|
+
isOpen: boolean;
|
|
47
|
+
row: HTMLTableRowElement;
|
|
48
|
+
cell: HTMLTableCellElement;
|
|
49
|
+
private targetRowdata;
|
|
50
|
+
constructor(parent?: IGrid, serviceLocator?: ServiceLocator);
|
|
51
|
+
/**
|
|
52
|
+
* @returns {void}
|
|
53
|
+
* @hidden
|
|
54
|
+
*/
|
|
55
|
+
addEventListener(): void;
|
|
56
|
+
/**
|
|
57
|
+
* @returns {void}
|
|
58
|
+
* @hidden
|
|
59
|
+
*/
|
|
60
|
+
removeEventListener(): void;
|
|
61
|
+
private keyDownHandler;
|
|
62
|
+
private render;
|
|
63
|
+
private enableAfterRenderMenu;
|
|
64
|
+
private getMenuItems;
|
|
65
|
+
private getLastPage;
|
|
66
|
+
private contextMenuOpen;
|
|
67
|
+
/**
|
|
68
|
+
* @param {ContextMenuClickEventArgs} args - specifies the ContextMenuClickEventArgs argument type
|
|
69
|
+
* @returns {void}
|
|
70
|
+
* @hidden
|
|
71
|
+
*/
|
|
72
|
+
contextMenuItemClick(args: ContextMenuClickEventArgs): void;
|
|
73
|
+
private contextMenuOnClose;
|
|
74
|
+
private getLocaleText;
|
|
75
|
+
private updateItemStatus;
|
|
76
|
+
private contextMenuBeforeOpen;
|
|
77
|
+
private ensureTarget;
|
|
78
|
+
private ensureFrozenHeader;
|
|
79
|
+
private ensureDisabledStatus;
|
|
80
|
+
/**
|
|
81
|
+
* Gets the context menu element from the Grid.
|
|
82
|
+
*
|
|
83
|
+
* @returns {Element} returns the element
|
|
84
|
+
*/
|
|
85
|
+
getContextMenu(): Element;
|
|
86
|
+
/**
|
|
87
|
+
* Destroys the context menu component in the Grid.
|
|
88
|
+
*
|
|
89
|
+
* @function destroy
|
|
90
|
+
* @returns {void}
|
|
91
|
+
* @hidden
|
|
92
|
+
*/
|
|
93
|
+
destroy(): void;
|
|
94
|
+
private getModuleName;
|
|
95
|
+
private generateID;
|
|
96
|
+
private getKeyFromId;
|
|
97
|
+
private buildDefaultItems;
|
|
98
|
+
private getDefaultItems;
|
|
99
|
+
private setLocaleKey;
|
|
100
|
+
private getColumn;
|
|
101
|
+
private selectRow;
|
|
102
|
+
}
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
import { Query, DataManager } from '@syncfusion/ej2-data';
|
|
2
|
+
import { IDataProcessor, IGrid, PendingState } from '../base/interface';
|
|
3
|
+
import { PredicateModel } from '../base/grid-model';
|
|
4
|
+
import { ServiceLocator } from '../services/service-locator';
|
|
5
|
+
import { Column } from '../models/column';
|
|
6
|
+
/**
|
|
7
|
+
* Grid data module is used to generate query and data source.
|
|
8
|
+
*
|
|
9
|
+
* @hidden
|
|
10
|
+
*/
|
|
11
|
+
export declare class Data implements IDataProcessor {
|
|
12
|
+
dataManager: DataManager;
|
|
13
|
+
/** @hidden */
|
|
14
|
+
isQueryInvokedFromData: boolean;
|
|
15
|
+
protected parent: IGrid;
|
|
16
|
+
protected serviceLocator: ServiceLocator;
|
|
17
|
+
protected dataState: PendingState;
|
|
18
|
+
foreignKeyDataState: PendingState;
|
|
19
|
+
/**
|
|
20
|
+
* Constructor for data module.
|
|
21
|
+
*
|
|
22
|
+
* @param {IGrid} parent - specifies the IGrid
|
|
23
|
+
* @param {ServiceLocator} serviceLocator - specifies the service locator
|
|
24
|
+
* @hidden
|
|
25
|
+
*/
|
|
26
|
+
constructor(parent?: IGrid, serviceLocator?: ServiceLocator);
|
|
27
|
+
private reorderRows;
|
|
28
|
+
protected getModuleName(): string;
|
|
29
|
+
/**
|
|
30
|
+
* The function used to initialize dataManager and external query
|
|
31
|
+
*
|
|
32
|
+
* @returns {void}
|
|
33
|
+
*/
|
|
34
|
+
private initDataManager;
|
|
35
|
+
/**
|
|
36
|
+
* The function is used to generate updated Query from Grid model.
|
|
37
|
+
*
|
|
38
|
+
* @param {boolean} skipPage - specifies the boolean to skip the page
|
|
39
|
+
* @returns {Query} returns the Query
|
|
40
|
+
* @hidden
|
|
41
|
+
*/
|
|
42
|
+
generateQuery(skipPage?: boolean): Query;
|
|
43
|
+
/**
|
|
44
|
+
* @param {Query} query - specifies the query
|
|
45
|
+
* @returns {Query} - returns the query
|
|
46
|
+
* @hidden
|
|
47
|
+
*/
|
|
48
|
+
aggregateQuery(query: Query): Query;
|
|
49
|
+
protected virtualGroupPageQuery(query: Query): Query;
|
|
50
|
+
protected pageQuery(query: Query, skipPage?: boolean): Query;
|
|
51
|
+
protected groupQuery(query: Query): Query;
|
|
52
|
+
protected sortQuery(query: Query): Query;
|
|
53
|
+
protected searchQuery(query: Query, fcolumn?: Column, isForeignKey?: boolean): Query;
|
|
54
|
+
protected filterQuery(query: Query, column?: PredicateModel[], skipFoerign?: boolean): Query;
|
|
55
|
+
private fGeneratePredicate;
|
|
56
|
+
/**
|
|
57
|
+
* The function is used to get dataManager promise by executing given Query.
|
|
58
|
+
*
|
|
59
|
+
* @param {object} args - specifies the object
|
|
60
|
+
* @param {string} args.requestType - Defines the request type
|
|
61
|
+
* @param {string[]} args.foreignKeyData - Defines the foreignKeyData.string
|
|
62
|
+
* @param {Object} args.data - Defines the data.
|
|
63
|
+
* @param {number} args.index - Defines the index .
|
|
64
|
+
* @param {Query} query - Defines the query which will execute along with data processing.
|
|
65
|
+
* @returns {Promise<Object>} - returns the object
|
|
66
|
+
* @hidden
|
|
67
|
+
*/
|
|
68
|
+
getData(args?: {
|
|
69
|
+
requestType?: string;
|
|
70
|
+
foreignKeyData?: string[];
|
|
71
|
+
data?: Object;
|
|
72
|
+
index?: number;
|
|
73
|
+
}, query?: Query): Promise<Object>;
|
|
74
|
+
private insert;
|
|
75
|
+
private executeQuery;
|
|
76
|
+
private formatGroupColumn;
|
|
77
|
+
private crudActions;
|
|
78
|
+
/**
|
|
79
|
+
* @param {object} changes - specifies the changes
|
|
80
|
+
* @param {string} key - specifies the key
|
|
81
|
+
* @param {object} original - specifies the original data
|
|
82
|
+
* @param {Query} query - specifies the query
|
|
83
|
+
* @returns {Promise<Object>} returns the object
|
|
84
|
+
* @hidden
|
|
85
|
+
*/
|
|
86
|
+
saveChanges(changes: Object, key: string, original: Object, query?: Query): Promise<Object>;
|
|
87
|
+
private getKey;
|
|
88
|
+
/**
|
|
89
|
+
* @returns {boolean} returns whether its remote data
|
|
90
|
+
* @hidden
|
|
91
|
+
*/
|
|
92
|
+
isRemote(): boolean;
|
|
93
|
+
private addRows;
|
|
94
|
+
private removeRows;
|
|
95
|
+
private getColumnByField;
|
|
96
|
+
protected destroy(): void;
|
|
97
|
+
getState(): PendingState;
|
|
98
|
+
setState(state: PendingState): Object;
|
|
99
|
+
getForeignKeyDataState(): PendingState;
|
|
100
|
+
setForeignKeyDataState(state: PendingState): void;
|
|
101
|
+
getStateEventArgument(query: Query): PendingState;
|
|
102
|
+
private eventPromise;
|
|
103
|
+
/**
|
|
104
|
+
* Gets the columns where searching needs to be performed from the Grid.
|
|
105
|
+
*
|
|
106
|
+
* @returns {string[]} returns the searched column field names
|
|
107
|
+
*/
|
|
108
|
+
private getSearchColumnFieldNames;
|
|
109
|
+
private refreshFilteredCols;
|
|
110
|
+
}
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
import { IGrid } from '../base/interface';
|
|
2
|
+
import { ServiceLocator } from '../services/service-locator';
|
|
3
|
+
import { Row } from '../models/row';
|
|
4
|
+
import { Column } from '../models/column';
|
|
5
|
+
/**
|
|
6
|
+
* The `DetailRow` module is used to handle detail template and hierarchy Grid operations.
|
|
7
|
+
*/
|
|
8
|
+
export declare class DetailRow {
|
|
9
|
+
private aria;
|
|
10
|
+
private parent;
|
|
11
|
+
private focus;
|
|
12
|
+
private lastrowcell;
|
|
13
|
+
private childRefs;
|
|
14
|
+
/**
|
|
15
|
+
* Constructor for the Grid detail template module
|
|
16
|
+
*
|
|
17
|
+
* @param {IGrid} parent - specifies the IGrid
|
|
18
|
+
* @param {ServiceLocator} locator - specifes the serviceLocator
|
|
19
|
+
* @hidden
|
|
20
|
+
*/
|
|
21
|
+
constructor(parent?: IGrid, locator?: ServiceLocator);
|
|
22
|
+
private clickHandler;
|
|
23
|
+
private toogleExpandcollapse;
|
|
24
|
+
/**
|
|
25
|
+
* @hidden
|
|
26
|
+
* @param {IGrid} gObj - specifies the grid Object
|
|
27
|
+
* @param {Row<Column>}rowObj - specifies the row object
|
|
28
|
+
* @param {string} printMode - specifies the printmode
|
|
29
|
+
* @returns {Object} returns the object
|
|
30
|
+
*/
|
|
31
|
+
getGridModel(gObj: IGrid, rowObj: Row<Column>, printMode: string): Object;
|
|
32
|
+
private promiseResolve;
|
|
33
|
+
private isDetailRow;
|
|
34
|
+
private destroy;
|
|
35
|
+
private getTDfromIndex;
|
|
36
|
+
/**
|
|
37
|
+
* Expands a detail row with the given target.
|
|
38
|
+
*
|
|
39
|
+
* @param {Element} target - Defines the collapsed element to expand.
|
|
40
|
+
* @returns {void}
|
|
41
|
+
*/
|
|
42
|
+
expand(target: number | Element): void;
|
|
43
|
+
/**
|
|
44
|
+
* Collapses a detail row with the given target.
|
|
45
|
+
*
|
|
46
|
+
* @param {Element} target - Defines the expanded element to collapse.
|
|
47
|
+
* @returns {void}
|
|
48
|
+
*/
|
|
49
|
+
collapse(target: number | Element): void;
|
|
50
|
+
/**
|
|
51
|
+
* Expands all the detail rows of the Grid.
|
|
52
|
+
*
|
|
53
|
+
* @returns {void}
|
|
54
|
+
*/
|
|
55
|
+
expandAll(): void;
|
|
56
|
+
/**
|
|
57
|
+
* Collapses all the detail rows of the Grid.
|
|
58
|
+
*
|
|
59
|
+
* @returns {void}
|
|
60
|
+
*/
|
|
61
|
+
collapseAll(): void;
|
|
62
|
+
private expandCollapse;
|
|
63
|
+
private keyPressHandler;
|
|
64
|
+
private refreshColSpan;
|
|
65
|
+
private destroyChildGrids;
|
|
66
|
+
/**
|
|
67
|
+
* For internal use only - Get the module name.
|
|
68
|
+
*
|
|
69
|
+
* @returns {string} returns the module name
|
|
70
|
+
* @private
|
|
71
|
+
*/
|
|
72
|
+
protected getModuleName(): string;
|
|
73
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { IGrid } from '../base/interface';
|
|
2
|
+
import { EditRender } from '../renderer/edit-renderer';
|
|
3
|
+
import { ServiceLocator } from '../services/service-locator';
|
|
4
|
+
import { NormalEdit } from './normal-edit';
|
|
5
|
+
/**
|
|
6
|
+
* `DialogEdit` module is used to handle dialog editing actions.
|
|
7
|
+
*
|
|
8
|
+
* @hidden
|
|
9
|
+
*/
|
|
10
|
+
export declare class DialogEdit extends NormalEdit {
|
|
11
|
+
protected parent: IGrid;
|
|
12
|
+
protected serviceLocator: ServiceLocator;
|
|
13
|
+
protected renderer: EditRender;
|
|
14
|
+
constructor(parent?: IGrid, serviceLocator?: ServiceLocator, renderer?: EditRender);
|
|
15
|
+
closeEdit(): void;
|
|
16
|
+
addRecord(data?: Object, index?: number): void;
|
|
17
|
+
endEdit(): void;
|
|
18
|
+
updateRow(index: number, data?: Object): void;
|
|
19
|
+
deleteRecord(fieldname?: string, data?: Object): void;
|
|
20
|
+
protected startEdit(tr?: Element): void;
|
|
21
|
+
}
|
|
@@ -0,0 +1,271 @@
|
|
|
1
|
+
import { L10n } from '@syncfusion/ej2-base';
|
|
2
|
+
import { IGrid, IAction, NotifyArgs, IEdit } from '../base/interface';
|
|
3
|
+
import { EditRender } from '../renderer/edit-renderer';
|
|
4
|
+
import { ServiceLocator } from '../services/service-locator';
|
|
5
|
+
import { Column } from '../models/column';
|
|
6
|
+
import { FormValidator } from '@syncfusion/ej2-inputs';
|
|
7
|
+
/**
|
|
8
|
+
* The `Edit` module is used to handle editing actions.
|
|
9
|
+
*/
|
|
10
|
+
export declare class Edit implements IAction {
|
|
11
|
+
protected renderer: EditRender;
|
|
12
|
+
/** @hidden */
|
|
13
|
+
editModule: IEdit;
|
|
14
|
+
/** @hidden */
|
|
15
|
+
formObj: FormValidator;
|
|
16
|
+
/** @hidden */
|
|
17
|
+
mFormObj: FormValidator;
|
|
18
|
+
/** @hidden */
|
|
19
|
+
frFormObj: FormValidator;
|
|
20
|
+
/** @hidden */
|
|
21
|
+
virtualFormObj: FormValidator;
|
|
22
|
+
private static editCellType;
|
|
23
|
+
private editType;
|
|
24
|
+
protected parent: IGrid;
|
|
25
|
+
protected serviceLocator: ServiceLocator;
|
|
26
|
+
protected l10n: L10n;
|
|
27
|
+
private dialogObj;
|
|
28
|
+
private alertDObj;
|
|
29
|
+
private actionBeginFunction;
|
|
30
|
+
private actionCompleteFunction;
|
|
31
|
+
private preventObj;
|
|
32
|
+
private eventDetails;
|
|
33
|
+
isLastRow?: boolean;
|
|
34
|
+
deleteRowUid: string;
|
|
35
|
+
editCellDialogClose: boolean;
|
|
36
|
+
/**
|
|
37
|
+
* Constructor for the Grid editing module
|
|
38
|
+
*
|
|
39
|
+
* @param {IGrid} parent - specifies the IGrid
|
|
40
|
+
* @param {ServiceLocator} serviceLocator - specifies the servicelocator
|
|
41
|
+
* @hidden
|
|
42
|
+
*/
|
|
43
|
+
constructor(parent?: IGrid, serviceLocator?: ServiceLocator);
|
|
44
|
+
private updateColTypeObj;
|
|
45
|
+
/**
|
|
46
|
+
* For internal use only - Get the module name.
|
|
47
|
+
*
|
|
48
|
+
* @returns {string} returns the module name
|
|
49
|
+
* @private
|
|
50
|
+
*/
|
|
51
|
+
protected getModuleName(): string;
|
|
52
|
+
/**
|
|
53
|
+
* @param {NotifyArgs} e - specifies the notifyargs
|
|
54
|
+
* @returns {void}
|
|
55
|
+
* @hidden
|
|
56
|
+
*/
|
|
57
|
+
onPropertyChanged(e: NotifyArgs): void;
|
|
58
|
+
private updateEditObj;
|
|
59
|
+
private initialEnd;
|
|
60
|
+
/**
|
|
61
|
+
* Edits any bound record in the Grid by TR element.
|
|
62
|
+
*
|
|
63
|
+
* @param {HTMLTableRowElement} tr - Defines the table row to be edited.
|
|
64
|
+
* @returns {void}
|
|
65
|
+
*/
|
|
66
|
+
startEdit(tr?: HTMLTableRowElement): void;
|
|
67
|
+
/**
|
|
68
|
+
* @param {Element} tr - specifies the tr element
|
|
69
|
+
* @param {object} args - specifies the object
|
|
70
|
+
* @param {Element} args.row -specfifes the row
|
|
71
|
+
* @param {string} args.requestType - specifies the request type
|
|
72
|
+
* @returns {void}
|
|
73
|
+
* @hidden
|
|
74
|
+
*/
|
|
75
|
+
checkLastRow(tr: Element, args?: {
|
|
76
|
+
row?: Element;
|
|
77
|
+
requestType?: string;
|
|
78
|
+
}): void;
|
|
79
|
+
/**
|
|
80
|
+
* Cancels edited state.
|
|
81
|
+
*
|
|
82
|
+
* @returns {void}
|
|
83
|
+
*/
|
|
84
|
+
closeEdit(): void;
|
|
85
|
+
protected refreshToolbar(): void;
|
|
86
|
+
/**
|
|
87
|
+
* To adds a new row at the top with the given data. When data is not passed, it will add empty rows.
|
|
88
|
+
* > `editSettings.allowEditing` should be true.
|
|
89
|
+
*
|
|
90
|
+
* @param {Object} data - Defines the new add record data.
|
|
91
|
+
* @param {number} index - Defines the row index to be added
|
|
92
|
+
* @returns {void}
|
|
93
|
+
*/
|
|
94
|
+
addRecord(data?: Object, index?: number): void;
|
|
95
|
+
/**
|
|
96
|
+
* Deletes a record with the given options. If fieldname and data are not given, the Grid will delete the selected record.
|
|
97
|
+
* > `editSettings.allowDeleting` should be true.
|
|
98
|
+
*
|
|
99
|
+
* @param {string} fieldname - Defines the primary key field name of the column.
|
|
100
|
+
* @param {Object} data - Defines the JSON data record to be deleted.
|
|
101
|
+
* @returns {void}
|
|
102
|
+
*/
|
|
103
|
+
deleteRecord(fieldname?: string, data?: Object): void;
|
|
104
|
+
/**
|
|
105
|
+
* Deletes a visible row by TR element.
|
|
106
|
+
*
|
|
107
|
+
* @param {HTMLTableRowElement} tr - Defines the table row element.
|
|
108
|
+
* @returns {void}
|
|
109
|
+
*/
|
|
110
|
+
deleteRow(tr: HTMLTableRowElement): void;
|
|
111
|
+
/**
|
|
112
|
+
* If Grid is in editable state, you can save a record by invoking endEdit.
|
|
113
|
+
*
|
|
114
|
+
* @returns {void}
|
|
115
|
+
*/
|
|
116
|
+
endEdit(): void;
|
|
117
|
+
/**
|
|
118
|
+
* To update the specified cell by given value without changing into edited state.
|
|
119
|
+
*
|
|
120
|
+
* @param {number} rowIndex Defines the row index.
|
|
121
|
+
* @param {string} field Defines the column field.
|
|
122
|
+
* @param {string | number | boolean | Date} value - Defines the value to be changed.
|
|
123
|
+
* @returns {void}
|
|
124
|
+
*/
|
|
125
|
+
updateCell(rowIndex: number, field: string, value: string | number | boolean | Date): void;
|
|
126
|
+
/**
|
|
127
|
+
* To update the specified row by given values without changing into edited state.
|
|
128
|
+
*
|
|
129
|
+
* @param {number} index Defines the row index.
|
|
130
|
+
* @param {Object} data Defines the data object to be updated.
|
|
131
|
+
* @returns {void}
|
|
132
|
+
*/
|
|
133
|
+
updateRow(index: number, data: Object): void;
|
|
134
|
+
/**
|
|
135
|
+
* Resets added, edited, and deleted records in the batch mode.
|
|
136
|
+
*
|
|
137
|
+
* @returns {void}
|
|
138
|
+
*/
|
|
139
|
+
batchCancel(): void;
|
|
140
|
+
/**
|
|
141
|
+
* Bulk saves added, edited, and deleted records in the batch mode.
|
|
142
|
+
*
|
|
143
|
+
* @returns {void}
|
|
144
|
+
*/
|
|
145
|
+
batchSave(): void;
|
|
146
|
+
/**
|
|
147
|
+
* Changes a particular cell into edited state based on the row index and field name provided in the `batch` mode.
|
|
148
|
+
*
|
|
149
|
+
* @param {number} index - Defines row index to edit a particular cell.
|
|
150
|
+
* @param {string} field - Defines the field name of the column to perform batch edit.
|
|
151
|
+
* @returns {void}
|
|
152
|
+
*/
|
|
153
|
+
editCell(index: number, field: string): void;
|
|
154
|
+
/**
|
|
155
|
+
* Checks the status of validation at the time of editing. If validation is passed, it returns true.
|
|
156
|
+
*
|
|
157
|
+
* @returns {boolean} returns whether the form is validated
|
|
158
|
+
*/
|
|
159
|
+
editFormValidate(): boolean;
|
|
160
|
+
/**
|
|
161
|
+
* Gets the added, edited,and deleted data before bulk save to the DataSource in batch mode.
|
|
162
|
+
*
|
|
163
|
+
* @returns {Object} returns the Object
|
|
164
|
+
*/
|
|
165
|
+
getBatchChanges(): Object;
|
|
166
|
+
/**
|
|
167
|
+
* Gets the current value of the edited component.
|
|
168
|
+
*
|
|
169
|
+
* @returns {Object} returns the Object
|
|
170
|
+
*/
|
|
171
|
+
getCurrentEditCellData(): Object;
|
|
172
|
+
/**
|
|
173
|
+
* Saves the cell that is currently edited. It does not save the value to the DataSource.
|
|
174
|
+
*
|
|
175
|
+
* @returns {void}
|
|
176
|
+
*/
|
|
177
|
+
saveCell(): void;
|
|
178
|
+
private endEditing;
|
|
179
|
+
private showDialog;
|
|
180
|
+
getValueFromType(col: Column, value: string | Date | boolean): number | string | Date | boolean;
|
|
181
|
+
private destroyToolTip;
|
|
182
|
+
private createConfirmDlg;
|
|
183
|
+
private createAlertDlg;
|
|
184
|
+
private alertClick;
|
|
185
|
+
private dlgWidget;
|
|
186
|
+
private dlgCancel;
|
|
187
|
+
private dlgOk;
|
|
188
|
+
private destroyEditComponents;
|
|
189
|
+
/**
|
|
190
|
+
* @returns {void}
|
|
191
|
+
* @hidden
|
|
192
|
+
*/
|
|
193
|
+
addEventListener(): void;
|
|
194
|
+
/**
|
|
195
|
+
* @returns {void}
|
|
196
|
+
* @hidden
|
|
197
|
+
*/
|
|
198
|
+
removeEventListener(): void;
|
|
199
|
+
private actionComplete;
|
|
200
|
+
/**
|
|
201
|
+
* @param {Element} form - specifies the element
|
|
202
|
+
* @param {Object} editedData - specifies the edited data
|
|
203
|
+
* @returns {Object} returns the object
|
|
204
|
+
* @hidden
|
|
205
|
+
*/
|
|
206
|
+
getCurrentEditedData(form: Element, editedData: Object): Object;
|
|
207
|
+
private getValue;
|
|
208
|
+
/**
|
|
209
|
+
* @param {NotifyArgs} e - specifies the NotifyArgs
|
|
210
|
+
* @returns {void}
|
|
211
|
+
* @hidden
|
|
212
|
+
*/
|
|
213
|
+
onActionBegin(e: NotifyArgs): void;
|
|
214
|
+
/**
|
|
215
|
+
* @param {Column[]} cols - specfies the column
|
|
216
|
+
* @returns {void}
|
|
217
|
+
* @hidden
|
|
218
|
+
*/
|
|
219
|
+
destroyWidgets(cols?: Column[]): void;
|
|
220
|
+
/**
|
|
221
|
+
* @returns {void}
|
|
222
|
+
* @hidden
|
|
223
|
+
*/
|
|
224
|
+
destroyForm(): void;
|
|
225
|
+
/**
|
|
226
|
+
* To destroy the editing.
|
|
227
|
+
*
|
|
228
|
+
* @returns {void}
|
|
229
|
+
* @hidden
|
|
230
|
+
*/
|
|
231
|
+
destroy(): void;
|
|
232
|
+
private keyPressHandler;
|
|
233
|
+
private curretRowFocus;
|
|
234
|
+
private preventBatch;
|
|
235
|
+
private executeAction;
|
|
236
|
+
/**
|
|
237
|
+
* @param {Column[]} cols - specifies the column
|
|
238
|
+
* @returns {void}
|
|
239
|
+
* @hidden
|
|
240
|
+
*/
|
|
241
|
+
applyFormValidation(cols?: Column[]): void;
|
|
242
|
+
/**
|
|
243
|
+
* @param {HTMLFormElement} form - Defined Form element
|
|
244
|
+
* @param {Object} rules - Defines form rules
|
|
245
|
+
* @returns {FormValidator} Returns formvalidator instance
|
|
246
|
+
* @hidden
|
|
247
|
+
*/
|
|
248
|
+
createFormObj(form: HTMLFormElement, rules: Object): FormValidator;
|
|
249
|
+
private valErrorPlacement;
|
|
250
|
+
private getElemTable;
|
|
251
|
+
resetElemPosition(elem: HTMLElement, args: {
|
|
252
|
+
status: string;
|
|
253
|
+
inputName: string;
|
|
254
|
+
element: HTMLElement;
|
|
255
|
+
message: string;
|
|
256
|
+
}): void;
|
|
257
|
+
private validationComplete;
|
|
258
|
+
private createTooltip;
|
|
259
|
+
/**
|
|
260
|
+
* @param {Column} col - specfies the column
|
|
261
|
+
* @returns {boolean} returns the whether column is grouped
|
|
262
|
+
* @hidden
|
|
263
|
+
*/
|
|
264
|
+
checkColumnIsGrouped(col: Column): boolean;
|
|
265
|
+
/**
|
|
266
|
+
* @param {object} editors -specfies the editors
|
|
267
|
+
* @returns {void}
|
|
268
|
+
* @hidden
|
|
269
|
+
*/
|
|
270
|
+
static AddEditors(editors: object): void;
|
|
271
|
+
}
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
import { IGrid, ExcelExportProperties } from '../base/interface';
|
|
2
|
+
import { Workbook } from '@syncfusion/ej2-excel-export';
|
|
3
|
+
import { ServiceLocator } from '../services/service-locator';
|
|
4
|
+
/**
|
|
5
|
+
* @hidden
|
|
6
|
+
* `ExcelExport` module is used to handle the Excel export action.
|
|
7
|
+
*/
|
|
8
|
+
export declare class ExcelExport {
|
|
9
|
+
private parent;
|
|
10
|
+
private isExporting;
|
|
11
|
+
private theme;
|
|
12
|
+
private book;
|
|
13
|
+
private workSheet;
|
|
14
|
+
private rows;
|
|
15
|
+
private columns;
|
|
16
|
+
private styles;
|
|
17
|
+
private data;
|
|
18
|
+
private rowLength;
|
|
19
|
+
private footer;
|
|
20
|
+
private expType;
|
|
21
|
+
private includeHiddenColumn;
|
|
22
|
+
private isCsvExport;
|
|
23
|
+
private isBlob;
|
|
24
|
+
private blobPromise;
|
|
25
|
+
private exportValueFormatter;
|
|
26
|
+
private isElementIdChanged;
|
|
27
|
+
private helper;
|
|
28
|
+
private groupedColLength;
|
|
29
|
+
private globalResolve;
|
|
30
|
+
private gridPool;
|
|
31
|
+
private locator;
|
|
32
|
+
private l10n;
|
|
33
|
+
private sheet;
|
|
34
|
+
/**
|
|
35
|
+
* Constructor for the Grid Excel Export module.
|
|
36
|
+
*
|
|
37
|
+
* @param {IGrid} parent - specifies the IGrid
|
|
38
|
+
* @param {ServiceLocator} locator - specifies the ServiceLocator
|
|
39
|
+
* @hidden
|
|
40
|
+
*/
|
|
41
|
+
constructor(parent?: IGrid, locator?: ServiceLocator);
|
|
42
|
+
/**
|
|
43
|
+
* For internal use only - Get the module name.
|
|
44
|
+
*
|
|
45
|
+
* @returns {string} returns the module name
|
|
46
|
+
*/
|
|
47
|
+
private getModuleName;
|
|
48
|
+
private init;
|
|
49
|
+
/**
|
|
50
|
+
* Export Grid to Excel file.
|
|
51
|
+
*
|
|
52
|
+
* @param {IGrid} grid - Defines the grid.
|
|
53
|
+
* @param {exportProperties} exportProperties - Defines the export properties of the Grid.
|
|
54
|
+
* @param {isMultipleExport} isMultipleExport - Defines is multiple Grid's are exported.
|
|
55
|
+
* @param {Workbook} workbook - Defined the Workbook if multiple Grid is exported.
|
|
56
|
+
* @param {boolean} isCsv - true if export to CSV.
|
|
57
|
+
* @param {boolean} isBlob - true if isBlob is enabled.
|
|
58
|
+
* @returns {Promise<any>} - Returns the map for export.
|
|
59
|
+
*/
|
|
60
|
+
Map(grid: IGrid, exportProperties: ExcelExportProperties, isMultipleExport: boolean, workbook: Workbook, isCsv: boolean, isBlob: boolean): Promise<any>;
|
|
61
|
+
private exportingSuccess;
|
|
62
|
+
private processRecords;
|
|
63
|
+
private processInnerRecords;
|
|
64
|
+
private organiseRows;
|
|
65
|
+
private processGridExport;
|
|
66
|
+
private processRecordContent;
|
|
67
|
+
private processGroupedRows;
|
|
68
|
+
private processRecordRows;
|
|
69
|
+
private setImage;
|
|
70
|
+
private childGridCell;
|
|
71
|
+
private processAggregates;
|
|
72
|
+
private fillAggregates;
|
|
73
|
+
private aggregateStyle;
|
|
74
|
+
private getAggreateValue;
|
|
75
|
+
private mergeOptions;
|
|
76
|
+
private getColumnStyle;
|
|
77
|
+
private headerRotation;
|
|
78
|
+
private processHeaderContent;
|
|
79
|
+
private getHeaderThemeStyle;
|
|
80
|
+
private updateThemeStyle;
|
|
81
|
+
private getCaptionThemeStyle;
|
|
82
|
+
private getRecordThemeStyle;
|
|
83
|
+
private processExcelHeader;
|
|
84
|
+
private updatedCellIndex;
|
|
85
|
+
private processExcelFooter;
|
|
86
|
+
private getIndex;
|
|
87
|
+
private parseStyles;
|
|
88
|
+
destroy(): void;
|
|
89
|
+
}
|