@syncfusion/ej2-treegrid 26.1.35-469198 → 26.1.35-760834
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-treegrid.min.js +1 -1
- package/dist/ej2-treegrid.umd.min.js +1 -1
- package/dist/ej2-treegrid.umd.min.js.map +1 -1
- package/dist/es6/ej2-treegrid.es2015.js +156 -35
- package/dist/es6/ej2-treegrid.es2015.js.map +1 -1
- package/dist/es6/ej2-treegrid.es5.js +158 -35
- package/dist/es6/ej2-treegrid.es5.js.map +1 -1
- package/dist/global/ej2-treegrid.min.js +1 -1
- package/dist/global/ej2-treegrid.min.js.map +1 -1
- package/dist/ts/undefined +73 -602
- package/index.d.ts +4 -0
- package/index.js +4 -0
- package/package.json +1 -1
- package/src/index.d.ts +4 -0
- package/src/treegrid/actions/batch-edit.d.ts +73 -0
- package/src/treegrid/actions/clipboard.d.ts +36 -0
- package/src/treegrid/actions/column-chooser.d.ts +37 -0
- package/src/treegrid/actions/column-menu.d.ts +24 -0
- package/src/treegrid/actions/command-column.d.ts +24 -0
- package/src/treegrid/actions/context-menu.d.ts +42 -0
- package/src/treegrid/actions/crud-actions.d.ts +66 -0
- package/src/treegrid/actions/crud-actions.js +1 -1
- package/src/treegrid/actions/detail-row.d.ts +39 -0
- package/src/treegrid/actions/edit.d.ts +112 -0
- package/src/treegrid/actions/edit.js +3 -2
- package/src/treegrid/actions/excel-export.d.ts +59 -0
- package/src/treegrid/actions/excel-export.js +14 -3
- package/src/treegrid/actions/filter.d.ts +57 -0
- package/src/treegrid/actions/freeze-column.d.ts +28 -0
- package/src/treegrid/actions/index.d.ts +24 -0
- package/src/treegrid/actions/infinite-scroll.d.ts +96 -0
- package/src/treegrid/actions/logger.d.ts +25 -0
- package/src/treegrid/actions/page.d.ts +67 -0
- package/src/treegrid/actions/pdf-export.d.ts +55 -0
- package/src/treegrid/actions/print.d.ts +37 -0
- package/src/treegrid/actions/reorder.d.ts +36 -0
- package/src/treegrid/actions/resize.d.ts +36 -0
- package/src/treegrid/actions/rowdragdrop.d.ts +113 -0
- package/src/treegrid/actions/rowdragdrop.js +2 -2
- package/src/treegrid/actions/selection.d.ts +51 -0
- package/src/treegrid/actions/selection.js +9 -0
- package/src/treegrid/actions/sort.d.ts +63 -0
- package/src/treegrid/actions/summary.d.ts +47 -0
- package/src/treegrid/actions/toolbar.d.ts +52 -0
- package/src/treegrid/actions/virtual-scroll.d.ts +55 -0
- package/src/treegrid/actions/virtual-scroll.js +13 -1
- package/src/treegrid/base/constant.d.ts +162 -0
- package/src/treegrid/base/data.d.ts +90 -0
- package/src/treegrid/base/data.js +20 -3
- package/src/treegrid/base/index.d.ts +11 -0
- package/src/treegrid/base/interface.d.ts +182 -0
- package/src/treegrid/base/treegrid.d.ts +2190 -0
- package/src/treegrid/base/treegrid.js +86 -17
- package/src/treegrid/enum.d.ts +155 -0
- package/src/treegrid/index.d.ts +9 -0
- package/src/treegrid/models/column.d.ts +752 -0
- package/src/treegrid/models/edit-settings.d.ts +90 -0
- package/src/treegrid/models/filter-settings.d.ts +203 -0
- package/src/treegrid/models/index.d.ts +24 -0
- package/src/treegrid/models/infinite-scroll-settings.d.ts +25 -0
- package/src/treegrid/models/loading-indicator.d.ts +19 -0
- package/src/treegrid/models/page-settings.d.ts +60 -0
- package/src/treegrid/models/rowdrop-settings.d.ts +27 -0
- package/src/treegrid/models/search-settings.d.ts +71 -0
- package/src/treegrid/models/selection-settings.d.ts +79 -0
- package/src/treegrid/models/sort-settings.d.ts +40 -0
- package/src/treegrid/models/summary.d.ts +124 -0
- package/src/treegrid/models/textwrap-settings.d.ts +16 -0
- package/src/treegrid/renderer/index.d.ts +5 -0
- package/src/treegrid/renderer/render.d.ts +41 -0
- package/src/treegrid/renderer/virtual-row-model-generator.d.ts +16 -0
- package/src/treegrid/renderer/virtual-tree-content-render.d.ts +75 -0
- package/src/treegrid/renderer/virtual-tree-content-render.js +11 -6
- package/src/treegrid/utils.d.ts +70 -0
- package/styles/bootstrap5.3-lite.css +2 -1090
- package/styles/bootstrap5.3.css +3 -1091
- package/styles/fluent2-lite.css +8 -1129
- package/styles/fluent2.css +8 -1129
- package/styles/material3-dark-lite.css +10 -1098
- package/styles/material3-dark.css +10 -1098
- package/styles/material3-lite.css +10 -1098
- package/styles/material3.css +10 -1098
- package/styles/tailwind3-lite.css +77 -1213
- package/styles/tailwind3.css +84 -1220
- package/styles/treegrid/_bds-definition.scss +0 -25
- package/styles/treegrid/_bigger.scss +6 -6
- package/styles/treegrid/_bootstrap-dark-definition.scss +0 -25
- package/styles/treegrid/_bootstrap-definition.scss +0 -25
- package/styles/treegrid/_bootstrap4-definition.scss +0 -25
- package/styles/treegrid/_bootstrap5-definition.scss +0 -25
- package/styles/treegrid/_bootstrap5.3-definition.scss +0 -25
- package/styles/treegrid/_fabric-dark-definition.scss +0 -25
- package/styles/treegrid/_fabric-definition.scss +0 -25
- package/styles/treegrid/_fluent-definition.scss +0 -25
- package/styles/treegrid/_fluent2-definition.scss +0 -25
- package/styles/treegrid/_fusionnew-definition.scss +0 -25
- package/styles/treegrid/_highcontrast-definition.scss +0 -25
- package/styles/treegrid/_highcontrast-light-definition.scss +0 -25
- package/styles/treegrid/_layout.scss +29 -29
- package/styles/treegrid/_material-dark-definition.scss +0 -25
- package/styles/treegrid/_material-definition.scss +0 -25
- package/styles/treegrid/_material3-definition.scss +0 -25
- package/styles/treegrid/_tailwind-definition.scss +0 -25
- package/styles/treegrid/_tailwind3-definition.scss +17 -42
- package/styles/treegrid/bootstrap5.3.css +3 -1091
- package/styles/treegrid/fluent2.css +8 -1129
- package/styles/treegrid/material3-dark.css +10 -1098
- package/styles/treegrid/material3.css +10 -1098
- package/styles/treegrid/tailwind3.css +84 -1220
- package/treegrid.d.ts +4 -0
- package/treegrid.js +4 -0
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { TreeGrid } from '../base/treegrid';
|
|
2
|
+
import { QueryOptions } from '@syncfusion/ej2-data';
|
|
3
|
+
/**
|
|
4
|
+
* TreeGrid Aggregate module
|
|
5
|
+
*
|
|
6
|
+
* @hidden
|
|
7
|
+
*/
|
|
8
|
+
export declare class Aggregate {
|
|
9
|
+
private parent;
|
|
10
|
+
private flatChildRecords;
|
|
11
|
+
private summaryQuery;
|
|
12
|
+
/**
|
|
13
|
+
* Constructor for Aggregate module
|
|
14
|
+
*
|
|
15
|
+
* @param {TreeGrid} parent - Tree Grid instance
|
|
16
|
+
*/
|
|
17
|
+
constructor(parent?: TreeGrid);
|
|
18
|
+
/**
|
|
19
|
+
* For internal use only - Get the module name.
|
|
20
|
+
*
|
|
21
|
+
* @private
|
|
22
|
+
* @returns {string} Returns Summary module name
|
|
23
|
+
*/
|
|
24
|
+
private getModuleName;
|
|
25
|
+
removeEventListener(): void;
|
|
26
|
+
/**
|
|
27
|
+
* Function to calculate summary values
|
|
28
|
+
*
|
|
29
|
+
* @param {QueryOptions[]} summaryQuery - DataManager query for aggregate operations
|
|
30
|
+
* @param {Object[]} filteredData - Filtered data collection
|
|
31
|
+
* @param {boolean} isSort - Specified whether sorting operation performed
|
|
32
|
+
* @hidden
|
|
33
|
+
* @returns {Object[]} - return flat records with summary values
|
|
34
|
+
*/
|
|
35
|
+
calculateSummaryValue(summaryQuery: QueryOptions[], filteredData: Object[], isSort: boolean): Object[];
|
|
36
|
+
private getChildRecordsLength;
|
|
37
|
+
private createSummaryItem;
|
|
38
|
+
private getSummaryValues;
|
|
39
|
+
private getFormatFromType;
|
|
40
|
+
/**
|
|
41
|
+
* To destroy the Aggregate module
|
|
42
|
+
*
|
|
43
|
+
* @returns {void}
|
|
44
|
+
* @hidden
|
|
45
|
+
*/
|
|
46
|
+
destroy(): void;
|
|
47
|
+
}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
import { TreeGrid } from '../base';
|
|
2
|
+
/**
|
|
3
|
+
* Toolbar Module for TreeGrid
|
|
4
|
+
*
|
|
5
|
+
* @hidden
|
|
6
|
+
*/
|
|
7
|
+
export declare class Toolbar {
|
|
8
|
+
private parent;
|
|
9
|
+
constructor(parent: TreeGrid);
|
|
10
|
+
/**
|
|
11
|
+
* For internal use only - Get the module name.
|
|
12
|
+
*
|
|
13
|
+
* @private
|
|
14
|
+
* @returns {string} - Returns Toolbar module name
|
|
15
|
+
*/
|
|
16
|
+
private getModuleName;
|
|
17
|
+
/**
|
|
18
|
+
* @hidden
|
|
19
|
+
* @returns {void}
|
|
20
|
+
*/
|
|
21
|
+
addEventListener(): void;
|
|
22
|
+
/**
|
|
23
|
+
* @hidden
|
|
24
|
+
* @returns {void}
|
|
25
|
+
*/
|
|
26
|
+
removeEventListener(): void;
|
|
27
|
+
private refreshToolbar;
|
|
28
|
+
private toolbarClickHandler;
|
|
29
|
+
/**
|
|
30
|
+
* Gets the toolbar of the TreeGrid.
|
|
31
|
+
*
|
|
32
|
+
* @returns {Element} - Returns Toolbar element
|
|
33
|
+
* @hidden
|
|
34
|
+
*/
|
|
35
|
+
getToolbar(): Element;
|
|
36
|
+
/**
|
|
37
|
+
* Enables or disables ToolBar items.
|
|
38
|
+
*
|
|
39
|
+
* @param {string[]} items - Defines the collection of itemID of ToolBar items.
|
|
40
|
+
* @param {boolean} isEnable - Defines the items to be enabled or disabled.
|
|
41
|
+
* @returns {void}
|
|
42
|
+
* @hidden
|
|
43
|
+
*/
|
|
44
|
+
enableItems(items: string[], isEnable: boolean): void;
|
|
45
|
+
/**
|
|
46
|
+
* Destroys the ToolBar.
|
|
47
|
+
*
|
|
48
|
+
* @method destroy
|
|
49
|
+
* @returns {void}
|
|
50
|
+
*/
|
|
51
|
+
destroy(): void;
|
|
52
|
+
}
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import { TreeGrid } from '../base/treegrid';
|
|
2
|
+
import { VirtualScroll as GridVirtualScroll, IGrid, ServiceLocator } from '@syncfusion/ej2-grids';
|
|
3
|
+
/**
|
|
4
|
+
* TreeGrid Virtual Scroll module will handle Virtualization
|
|
5
|
+
*
|
|
6
|
+
* @hidden
|
|
7
|
+
*/
|
|
8
|
+
export declare class VirtualScroll {
|
|
9
|
+
private parent;
|
|
10
|
+
private expandCollapseRec;
|
|
11
|
+
private prevstartIndex;
|
|
12
|
+
private prevendIndex;
|
|
13
|
+
private visualData;
|
|
14
|
+
private prevrequestType;
|
|
15
|
+
prevSelectedRecord: object;
|
|
16
|
+
/**
|
|
17
|
+
* Constructor for VirtualScroll module
|
|
18
|
+
*
|
|
19
|
+
* @param {TreeGrid} parent - Tree Grid instance
|
|
20
|
+
*/
|
|
21
|
+
constructor(parent?: TreeGrid);
|
|
22
|
+
private returnVisualData;
|
|
23
|
+
/**
|
|
24
|
+
* For internal use only - Get the module name.
|
|
25
|
+
*
|
|
26
|
+
* @private
|
|
27
|
+
* @returns {string} - Returns VirtualScroll module name
|
|
28
|
+
*/
|
|
29
|
+
protected getModuleName(): string;
|
|
30
|
+
/**
|
|
31
|
+
* @hidden
|
|
32
|
+
* @returns {void}
|
|
33
|
+
*/
|
|
34
|
+
addEventListener(): void;
|
|
35
|
+
/**
|
|
36
|
+
* @hidden
|
|
37
|
+
* @returns {void}
|
|
38
|
+
*/
|
|
39
|
+
removeEventListener(): void;
|
|
40
|
+
private collapseExpandVirtualchilds;
|
|
41
|
+
private virtualPageAction;
|
|
42
|
+
/**
|
|
43
|
+
* To destroy the virtualScroll module
|
|
44
|
+
*
|
|
45
|
+
* @returns {void}
|
|
46
|
+
* @hidden
|
|
47
|
+
*/
|
|
48
|
+
destroy(): void;
|
|
49
|
+
}
|
|
50
|
+
export declare class TreeVirtual extends GridVirtualScroll {
|
|
51
|
+
constructor(parent: IGrid, locator?: ServiceLocator);
|
|
52
|
+
getModuleName(): string;
|
|
53
|
+
protected instantiateRenderers(): void;
|
|
54
|
+
ensurePageSize(): void;
|
|
55
|
+
}
|
|
@@ -33,6 +33,7 @@ var VirtualScroll = /** @class */ (function () {
|
|
|
33
33
|
function VirtualScroll(parent) {
|
|
34
34
|
this.prevstartIndex = -1;
|
|
35
35
|
this.prevendIndex = -1;
|
|
36
|
+
this.prevSelectedRecord = [];
|
|
36
37
|
this.parent = parent;
|
|
37
38
|
Grid.Inject(TreeVirtual);
|
|
38
39
|
this.addEventListener();
|
|
@@ -88,6 +89,10 @@ var VirtualScroll = /** @class */ (function () {
|
|
|
88
89
|
this.parent.selectionSettings.mode === 'Row' && !this.parent.selectionSettings.persistSelection) {
|
|
89
90
|
this.parent.grid.clearSelection();
|
|
90
91
|
}
|
|
92
|
+
if (getValue('isCollapseAll', this.parent) && this.parent.selectionSettings.persistSelection && this.parent.getSelectedRecords().length > 0) {
|
|
93
|
+
this.prevSelectedRecord = this.parent.getSelectedRecords();
|
|
94
|
+
this.parent.grid.clearSelection();
|
|
95
|
+
}
|
|
91
96
|
var requestType = getValue('isCollapseAll', this.parent) ? 'collapseAll' : 'refresh';
|
|
92
97
|
getValue('grid.renderModule', this.parent).dataManagerSuccess(ret, { requestType: requestType });
|
|
93
98
|
};
|
|
@@ -118,7 +123,7 @@ var VirtualScroll = /** @class */ (function () {
|
|
|
118
123
|
}
|
|
119
124
|
else {
|
|
120
125
|
var requestType = pageingDetails.actionArgs.requestType;
|
|
121
|
-
if (requestType === 'filtering' || requestType === 'collapseAll' || requestType === 'searching' ||
|
|
126
|
+
if (requestType === 'filtering' || requestType === 'collapseAll' || requestType === 'searching' || (requestType === 'refresh' && getValue('isExpandAll', this.parent)) ||
|
|
122
127
|
(requestType === 'refresh' && this.parent.enableCollapseAll && endIndex > visualData.length && isNullOrUndefined(this.expandCollapseRec))) {
|
|
123
128
|
startIndex = 0;
|
|
124
129
|
endIndex = this.parent.grid.pageSettings.pageSize - 1;
|
|
@@ -159,6 +164,12 @@ var VirtualScroll = /** @class */ (function () {
|
|
|
159
164
|
}
|
|
160
165
|
}
|
|
161
166
|
//}
|
|
167
|
+
if (this.prevrequestType === 'collapseAll' && pageingDetails.actionArgs.requestType === 'virtualscroll'
|
|
168
|
+
&& !isNullOrUndefined(this.parent.idMapping) && startIndex === 0) {
|
|
169
|
+
startIndex = 0;
|
|
170
|
+
endIndex = this.parent.grid.pageSettings.pageSize - 1;
|
|
171
|
+
this.parent.grid.notify(events.virtualActionArgs, { setTop: true });
|
|
172
|
+
}
|
|
162
173
|
if ((this.parent.enableCollapseAll || this.parent.expandStateMapping) && !isNullOrUndefined(this.expandCollapseRec)) {
|
|
163
174
|
if (pageingDetails.count < this.parent.getRows()[0].getBoundingClientRect().height) {
|
|
164
175
|
startIndex = 0;
|
|
@@ -177,6 +188,7 @@ var VirtualScroll = /** @class */ (function () {
|
|
|
177
188
|
}
|
|
178
189
|
this.prevstartIndex = startIndex;
|
|
179
190
|
this.prevendIndex = endIndex;
|
|
191
|
+
this.prevrequestType = pageingDetails.actionArgs.requestType;
|
|
180
192
|
}
|
|
181
193
|
this.parent.notify('updateAction', pageingDetails);
|
|
182
194
|
};
|
|
@@ -0,0 +1,162 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @hidden
|
|
3
|
+
*/
|
|
4
|
+
export declare const load: string;
|
|
5
|
+
/** @hidden */
|
|
6
|
+
export declare const rowDataBound: string;
|
|
7
|
+
/** @hidden */
|
|
8
|
+
export declare const dataBound: string;
|
|
9
|
+
/** @hidden */
|
|
10
|
+
export declare const queryCellInfo: string;
|
|
11
|
+
/** @hidden */
|
|
12
|
+
export declare const beforeDataBound: string;
|
|
13
|
+
/** @hidden */
|
|
14
|
+
export declare const actionBegin: string;
|
|
15
|
+
/** @hidden */
|
|
16
|
+
export declare const dataStateChange: string;
|
|
17
|
+
/** @hidden */
|
|
18
|
+
export declare const actionComplete: string;
|
|
19
|
+
/** @hidden */
|
|
20
|
+
export declare const rowSelecting: string;
|
|
21
|
+
/** @hidden */
|
|
22
|
+
export declare const rowSelected: string;
|
|
23
|
+
/** @hidden */
|
|
24
|
+
export declare const checkboxChange: string;
|
|
25
|
+
/** @hidden */
|
|
26
|
+
export declare const rowDeselected: string;
|
|
27
|
+
/** @hidden */
|
|
28
|
+
export declare const toolbarClick: string;
|
|
29
|
+
/** @hidden */
|
|
30
|
+
export declare const beforeExcelExport: string;
|
|
31
|
+
/** @hidden */
|
|
32
|
+
export declare const beforePdfExport: string;
|
|
33
|
+
/** @hidden */
|
|
34
|
+
export declare const resizeStop: string;
|
|
35
|
+
/** @hidden */
|
|
36
|
+
export declare const expanded: string;
|
|
37
|
+
/** @hidden */
|
|
38
|
+
export declare const expanding: string;
|
|
39
|
+
/** @hidden */
|
|
40
|
+
export declare const collapsed: string;
|
|
41
|
+
/** @hidden */
|
|
42
|
+
export declare const collapsing: string;
|
|
43
|
+
/** @hidden */
|
|
44
|
+
export declare const remoteExpand: string;
|
|
45
|
+
/** @hidden */
|
|
46
|
+
export declare const localPagedExpandCollapse: string;
|
|
47
|
+
/** @hidden */
|
|
48
|
+
export declare const pagingActions: string;
|
|
49
|
+
/** @hidden */
|
|
50
|
+
export declare const printGridInit: string;
|
|
51
|
+
/** @hidden */
|
|
52
|
+
export declare const contextMenuOpen: string;
|
|
53
|
+
/** @hidden */
|
|
54
|
+
export declare const contextMenuClick: string;
|
|
55
|
+
/** @hidden */
|
|
56
|
+
export declare const beforeCopy: string;
|
|
57
|
+
/** @hidden */
|
|
58
|
+
export declare const beforePaste: string;
|
|
59
|
+
/** @hidden */
|
|
60
|
+
export declare const savePreviousRowPosition: string;
|
|
61
|
+
/** @hidden */
|
|
62
|
+
export declare const crudAction: string;
|
|
63
|
+
/** @hidden */
|
|
64
|
+
export declare const beginEdit: string;
|
|
65
|
+
/** @hidden */
|
|
66
|
+
export declare const beginAdd: string;
|
|
67
|
+
/** @hidden */
|
|
68
|
+
export declare const recordDoubleClick: string;
|
|
69
|
+
/** @hidden */
|
|
70
|
+
export declare const cellSave: string;
|
|
71
|
+
/** @hidden */
|
|
72
|
+
export declare const cellSaved: string;
|
|
73
|
+
/** @hidden */
|
|
74
|
+
export declare const cellEdit: string;
|
|
75
|
+
/** @hidden */
|
|
76
|
+
export declare const batchDelete: string;
|
|
77
|
+
/** @hidden */
|
|
78
|
+
export declare const batchCancel: string;
|
|
79
|
+
/** @hidden */
|
|
80
|
+
export declare const batchAdd: string;
|
|
81
|
+
/** @hidden */
|
|
82
|
+
export declare const beforeBatchDelete: string;
|
|
83
|
+
/** @hidden */
|
|
84
|
+
export declare const beforeBatchAdd: string;
|
|
85
|
+
/** @hidden */
|
|
86
|
+
export declare const beforeBatchSave: string;
|
|
87
|
+
/** @hidden */
|
|
88
|
+
export declare const batchSave: string;
|
|
89
|
+
/** @hidden */
|
|
90
|
+
export declare const keyPressed: string;
|
|
91
|
+
/** @hidden */
|
|
92
|
+
export declare const updateData: string;
|
|
93
|
+
/** @hidden */
|
|
94
|
+
export declare const doubleTap: string;
|
|
95
|
+
/** @hidden */
|
|
96
|
+
export declare const virtualColumnIndex: string;
|
|
97
|
+
/** @hidden */
|
|
98
|
+
export declare const virtualActionArgs: string;
|
|
99
|
+
/** @hidden */
|
|
100
|
+
export declare const destroy: string;
|
|
101
|
+
/** @hidden */
|
|
102
|
+
export declare const dataListener: string;
|
|
103
|
+
/** @hidden */
|
|
104
|
+
export declare const indexModifier: string;
|
|
105
|
+
/** @hidden */
|
|
106
|
+
export declare const beforeStartEdit: string;
|
|
107
|
+
/** @hidden */
|
|
108
|
+
export declare const beforeBatchCancel: string;
|
|
109
|
+
/** @hidden */
|
|
110
|
+
export declare const batchEditFormRendered: string;
|
|
111
|
+
/** @hidden */
|
|
112
|
+
export declare const detailDataBound: string;
|
|
113
|
+
/** @hidden */
|
|
114
|
+
export declare const rowDrag: string;
|
|
115
|
+
/** @hidden */
|
|
116
|
+
export declare const rowDragStartHelper: string;
|
|
117
|
+
/** @hidden */
|
|
118
|
+
export declare const rowDrop: string;
|
|
119
|
+
/** @hidden */
|
|
120
|
+
export declare const rowDragStart: string;
|
|
121
|
+
/** @hidden */
|
|
122
|
+
export declare const rowsAdd: string;
|
|
123
|
+
/** @hidden */
|
|
124
|
+
export declare const rowsRemove: string;
|
|
125
|
+
/** @hidden */
|
|
126
|
+
export declare const rowdraging: string;
|
|
127
|
+
/** @hidden */
|
|
128
|
+
export declare const rowDropped: string;
|
|
129
|
+
/** @hidden */
|
|
130
|
+
export declare const autoCol: string;
|
|
131
|
+
/** @hidden */
|
|
132
|
+
export declare const rowDeselecting: string;
|
|
133
|
+
/** @hidden */
|
|
134
|
+
export declare const headerContent: string;
|
|
135
|
+
/** @hidden */
|
|
136
|
+
export declare const movableContent: string;
|
|
137
|
+
/** @hidden */
|
|
138
|
+
export declare const movableHeader: string;
|
|
139
|
+
/** @hidden */
|
|
140
|
+
export declare const frozenContent: string;
|
|
141
|
+
/** @hidden */
|
|
142
|
+
export declare const frozenHeader: string;
|
|
143
|
+
/** @hidden */
|
|
144
|
+
export declare const content: string;
|
|
145
|
+
/** @hidden */
|
|
146
|
+
export declare const table: string;
|
|
147
|
+
/** @hidden */
|
|
148
|
+
export declare const leftRight: string;
|
|
149
|
+
/** @hidden */
|
|
150
|
+
export declare const frozenRight: string;
|
|
151
|
+
/** @hidden */
|
|
152
|
+
export declare const frozenLeft: string;
|
|
153
|
+
/** @hidden */
|
|
154
|
+
export declare const dataColIndex: string;
|
|
155
|
+
/** @hidden */
|
|
156
|
+
export declare const ariaColIndex: string;
|
|
157
|
+
/** @hidden */
|
|
158
|
+
export declare const dataRowIndex: string;
|
|
159
|
+
/** @hidden */
|
|
160
|
+
export declare const ariaRowIndex: string;
|
|
161
|
+
/** @hidden */
|
|
162
|
+
export declare const actionFailure: string;
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
import { TreeGrid } from './treegrid';
|
|
2
|
+
import { BeforeDataBoundArgs } from '@syncfusion/ej2-grids';
|
|
3
|
+
/**
|
|
4
|
+
* Internal dataoperations for tree grid
|
|
5
|
+
*
|
|
6
|
+
* @hidden
|
|
7
|
+
*/
|
|
8
|
+
export declare class DataManipulation {
|
|
9
|
+
private taskIds;
|
|
10
|
+
private parentItems;
|
|
11
|
+
private zerothLevelData;
|
|
12
|
+
private storedIndex;
|
|
13
|
+
private batchChanges;
|
|
14
|
+
private addedRecords;
|
|
15
|
+
private parent;
|
|
16
|
+
private dataResults;
|
|
17
|
+
private sortedData;
|
|
18
|
+
private hierarchyData;
|
|
19
|
+
private isSelfReference;
|
|
20
|
+
private isSortAction;
|
|
21
|
+
private infiniteScrollData;
|
|
22
|
+
constructor(grid: TreeGrid);
|
|
23
|
+
/**
|
|
24
|
+
* @hidden
|
|
25
|
+
* @returns {void}
|
|
26
|
+
*/
|
|
27
|
+
addEventListener(): void;
|
|
28
|
+
/**
|
|
29
|
+
* @hidden
|
|
30
|
+
* @returns {void}
|
|
31
|
+
*/
|
|
32
|
+
removeEventListener(): void;
|
|
33
|
+
/**
|
|
34
|
+
* To destroy the dataModule
|
|
35
|
+
*
|
|
36
|
+
* @returns {void}
|
|
37
|
+
* @hidden
|
|
38
|
+
*/
|
|
39
|
+
destroy(): void;
|
|
40
|
+
/**
|
|
41
|
+
* @hidden
|
|
42
|
+
* @returns {boolean} -Returns whether remote data binding
|
|
43
|
+
*/
|
|
44
|
+
isRemote(): boolean;
|
|
45
|
+
/**
|
|
46
|
+
* Function to manipulate datasource
|
|
47
|
+
*
|
|
48
|
+
* @param {Object} data - Provide tree grid datasource to convert to flat data
|
|
49
|
+
* @hidden
|
|
50
|
+
* @returns {void}
|
|
51
|
+
*/
|
|
52
|
+
convertToFlatData(data: Object): void;
|
|
53
|
+
private convertJSONData;
|
|
54
|
+
private selfReferenceUpdate;
|
|
55
|
+
/**
|
|
56
|
+
* Function to update the zeroth level parent records in remote binding
|
|
57
|
+
*
|
|
58
|
+
* @param {BeforeDataBoundArgs} args - contains data before its bounds to tree grid
|
|
59
|
+
* @hidden
|
|
60
|
+
* @returns {void}
|
|
61
|
+
*/
|
|
62
|
+
private updateParentRemoteData;
|
|
63
|
+
/**
|
|
64
|
+
* Function to manipulate datasource
|
|
65
|
+
*
|
|
66
|
+
* @param {{record: ITreeData, rows: HTMLTableRowElement[], parentRow: HTMLTableRowElement}} rowDetails - Row details for which child rows has to be fetched
|
|
67
|
+
* @param {ITreeData} rowDetails.record - current expanding record
|
|
68
|
+
* @param {HTMLTableRowElement[]} rowDetails.rows - Expanding Row element
|
|
69
|
+
* @param {HTMLTableRowElement} rowDetails.parentRow - Curent expanding row element
|
|
70
|
+
* @param {boolean} isChild - Specified whether current record is already a child record
|
|
71
|
+
* @hidden
|
|
72
|
+
* @returns {void}
|
|
73
|
+
*/
|
|
74
|
+
private collectExpandingRecs;
|
|
75
|
+
private fetchRemoteChildData;
|
|
76
|
+
private remoteVirtualAction;
|
|
77
|
+
private beginSorting;
|
|
78
|
+
private createRecords;
|
|
79
|
+
/**
|
|
80
|
+
* Function to perform filtering/sorting action for local data
|
|
81
|
+
*
|
|
82
|
+
* @param {BeforeDataBoundArgs} args - data details to be processed before binding to grid
|
|
83
|
+
* @hidden
|
|
84
|
+
* @returns {void}
|
|
85
|
+
*/
|
|
86
|
+
dataProcessor(args?: BeforeDataBoundArgs): void;
|
|
87
|
+
private paging;
|
|
88
|
+
private updateData;
|
|
89
|
+
private updateAction;
|
|
90
|
+
}
|
|
@@ -344,16 +344,20 @@ var DataManipulation = /** @class */ (function () {
|
|
|
344
344
|
var clonequries = qry.queries.filter(function (e) { return e.fn !== 'onPage' && e.fn !== 'onWhere'; });
|
|
345
345
|
qry.queries = clonequries;
|
|
346
346
|
qry.isCountRequired = true;
|
|
347
|
+
var idMappingValue = parseInt(rowDetails.record[this.parent.idMapping], 10);
|
|
348
|
+
if (isNaN(idMappingValue)) {
|
|
349
|
+
idMappingValue = rowDetails.record[this.parent.idMapping].toString();
|
|
350
|
+
}
|
|
347
351
|
if (this.parent.enableVirtualization && rowDetails.action === 'remoteExpand') {
|
|
348
352
|
qry.take(this.parent.pageSettings.pageSize);
|
|
349
353
|
var expandDetail = [];
|
|
350
|
-
expandDetail.push('ExpandingAction',
|
|
354
|
+
expandDetail.push('ExpandingAction', idMappingValue.toString());
|
|
351
355
|
qry.expand(expandDetail);
|
|
352
356
|
}
|
|
353
357
|
else if (this.parent.enableVirtualization && rowDetails.action === 'collapse') {
|
|
354
358
|
qry.take(this.parent.grid.pageSettings.pageSize);
|
|
355
359
|
var expandDetail = [];
|
|
356
|
-
expandDetail.push('CollapsingAction',
|
|
360
|
+
expandDetail.push('CollapsingAction', idMappingValue.toString());
|
|
357
361
|
qry.expand(expandDetail);
|
|
358
362
|
}
|
|
359
363
|
qry.where(this.parent.parentIdMapping, 'equal', rowDetails.record[this.parent.idMapping]);
|
|
@@ -548,6 +552,9 @@ var DataManipulation = /** @class */ (function () {
|
|
|
548
552
|
e["" + result_1] = _this.parent.summaryModule.calculateSummaryValue(summaryQuery, e["" + result_1], true);
|
|
549
553
|
}
|
|
550
554
|
}
|
|
555
|
+
if (rowDetails.action === 'remoteExpand' && _this.parent.allowPaging && _this.parent.pageSettings.pageSizeMode === 'All') {
|
|
556
|
+
_this.parent.grid.pageSettings.totalRecordsCount = _this.parent.grid.currentViewData.length + result.length;
|
|
557
|
+
}
|
|
551
558
|
if (_this.parent.enableVirtualization) {
|
|
552
559
|
_this.parent.grid.pageSettings.totalRecordsCount = e.count;
|
|
553
560
|
}
|
|
@@ -601,7 +608,17 @@ var DataManipulation = /** @class */ (function () {
|
|
|
601
608
|
}
|
|
602
609
|
if ((!isNullOrUndefined(currentData[this.parent.childMapping]) && !isCountRequired(this.parent)) ||
|
|
603
610
|
((currentData[this.parent.hasChildMapping]) && isCountRequired(this.parent))) {
|
|
604
|
-
currentData.
|
|
611
|
+
if (!isNullOrUndefined(currentData[this.parent.childMapping])) {
|
|
612
|
+
if (currentData[this.parent.childMapping].length > 0) {
|
|
613
|
+
currentData.hasChildRecords = true;
|
|
614
|
+
}
|
|
615
|
+
else {
|
|
616
|
+
currentData.hasChildRecords = false;
|
|
617
|
+
}
|
|
618
|
+
}
|
|
619
|
+
else {
|
|
620
|
+
currentData.hasChildRecords = true;
|
|
621
|
+
}
|
|
605
622
|
if (this.parent.enableCollapseAll || !isNullOrUndefined(this.parent.dataStateChange)
|
|
606
623
|
&& isNullOrUndefined(currentData[this.parent.childMapping])) {
|
|
607
624
|
currentData.expanded = false;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Base export
|
|
3
|
+
*/
|
|
4
|
+
export * from './treegrid';
|
|
5
|
+
export * from './treegrid-model';
|
|
6
|
+
export * from './constant';
|
|
7
|
+
export * from './data';
|
|
8
|
+
export * from './interface';
|
|
9
|
+
export * from '../actions/reorder';
|
|
10
|
+
export * from '../actions/resize';
|
|
11
|
+
export * from '../actions/rowdragdrop';
|