@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.
Files changed (111) hide show
  1. package/dist/ej2-treegrid.min.js +1 -1
  2. package/dist/ej2-treegrid.umd.min.js +1 -1
  3. package/dist/ej2-treegrid.umd.min.js.map +1 -1
  4. package/dist/es6/ej2-treegrid.es2015.js +156 -35
  5. package/dist/es6/ej2-treegrid.es2015.js.map +1 -1
  6. package/dist/es6/ej2-treegrid.es5.js +158 -35
  7. package/dist/es6/ej2-treegrid.es5.js.map +1 -1
  8. package/dist/global/ej2-treegrid.min.js +1 -1
  9. package/dist/global/ej2-treegrid.min.js.map +1 -1
  10. package/dist/ts/undefined +73 -602
  11. package/index.d.ts +4 -0
  12. package/index.js +4 -0
  13. package/package.json +1 -1
  14. package/src/index.d.ts +4 -0
  15. package/src/treegrid/actions/batch-edit.d.ts +73 -0
  16. package/src/treegrid/actions/clipboard.d.ts +36 -0
  17. package/src/treegrid/actions/column-chooser.d.ts +37 -0
  18. package/src/treegrid/actions/column-menu.d.ts +24 -0
  19. package/src/treegrid/actions/command-column.d.ts +24 -0
  20. package/src/treegrid/actions/context-menu.d.ts +42 -0
  21. package/src/treegrid/actions/crud-actions.d.ts +66 -0
  22. package/src/treegrid/actions/crud-actions.js +1 -1
  23. package/src/treegrid/actions/detail-row.d.ts +39 -0
  24. package/src/treegrid/actions/edit.d.ts +112 -0
  25. package/src/treegrid/actions/edit.js +3 -2
  26. package/src/treegrid/actions/excel-export.d.ts +59 -0
  27. package/src/treegrid/actions/excel-export.js +14 -3
  28. package/src/treegrid/actions/filter.d.ts +57 -0
  29. package/src/treegrid/actions/freeze-column.d.ts +28 -0
  30. package/src/treegrid/actions/index.d.ts +24 -0
  31. package/src/treegrid/actions/infinite-scroll.d.ts +96 -0
  32. package/src/treegrid/actions/logger.d.ts +25 -0
  33. package/src/treegrid/actions/page.d.ts +67 -0
  34. package/src/treegrid/actions/pdf-export.d.ts +55 -0
  35. package/src/treegrid/actions/print.d.ts +37 -0
  36. package/src/treegrid/actions/reorder.d.ts +36 -0
  37. package/src/treegrid/actions/resize.d.ts +36 -0
  38. package/src/treegrid/actions/rowdragdrop.d.ts +113 -0
  39. package/src/treegrid/actions/rowdragdrop.js +2 -2
  40. package/src/treegrid/actions/selection.d.ts +51 -0
  41. package/src/treegrid/actions/selection.js +9 -0
  42. package/src/treegrid/actions/sort.d.ts +63 -0
  43. package/src/treegrid/actions/summary.d.ts +47 -0
  44. package/src/treegrid/actions/toolbar.d.ts +52 -0
  45. package/src/treegrid/actions/virtual-scroll.d.ts +55 -0
  46. package/src/treegrid/actions/virtual-scroll.js +13 -1
  47. package/src/treegrid/base/constant.d.ts +162 -0
  48. package/src/treegrid/base/data.d.ts +90 -0
  49. package/src/treegrid/base/data.js +20 -3
  50. package/src/treegrid/base/index.d.ts +11 -0
  51. package/src/treegrid/base/interface.d.ts +182 -0
  52. package/src/treegrid/base/treegrid.d.ts +2190 -0
  53. package/src/treegrid/base/treegrid.js +86 -17
  54. package/src/treegrid/enum.d.ts +155 -0
  55. package/src/treegrid/index.d.ts +9 -0
  56. package/src/treegrid/models/column.d.ts +752 -0
  57. package/src/treegrid/models/edit-settings.d.ts +90 -0
  58. package/src/treegrid/models/filter-settings.d.ts +203 -0
  59. package/src/treegrid/models/index.d.ts +24 -0
  60. package/src/treegrid/models/infinite-scroll-settings.d.ts +25 -0
  61. package/src/treegrid/models/loading-indicator.d.ts +19 -0
  62. package/src/treegrid/models/page-settings.d.ts +60 -0
  63. package/src/treegrid/models/rowdrop-settings.d.ts +27 -0
  64. package/src/treegrid/models/search-settings.d.ts +71 -0
  65. package/src/treegrid/models/selection-settings.d.ts +79 -0
  66. package/src/treegrid/models/sort-settings.d.ts +40 -0
  67. package/src/treegrid/models/summary.d.ts +124 -0
  68. package/src/treegrid/models/textwrap-settings.d.ts +16 -0
  69. package/src/treegrid/renderer/index.d.ts +5 -0
  70. package/src/treegrid/renderer/render.d.ts +41 -0
  71. package/src/treegrid/renderer/virtual-row-model-generator.d.ts +16 -0
  72. package/src/treegrid/renderer/virtual-tree-content-render.d.ts +75 -0
  73. package/src/treegrid/renderer/virtual-tree-content-render.js +11 -6
  74. package/src/treegrid/utils.d.ts +70 -0
  75. package/styles/bootstrap5.3-lite.css +2 -1090
  76. package/styles/bootstrap5.3.css +3 -1091
  77. package/styles/fluent2-lite.css +8 -1129
  78. package/styles/fluent2.css +8 -1129
  79. package/styles/material3-dark-lite.css +10 -1098
  80. package/styles/material3-dark.css +10 -1098
  81. package/styles/material3-lite.css +10 -1098
  82. package/styles/material3.css +10 -1098
  83. package/styles/tailwind3-lite.css +77 -1213
  84. package/styles/tailwind3.css +84 -1220
  85. package/styles/treegrid/_bds-definition.scss +0 -25
  86. package/styles/treegrid/_bigger.scss +6 -6
  87. package/styles/treegrid/_bootstrap-dark-definition.scss +0 -25
  88. package/styles/treegrid/_bootstrap-definition.scss +0 -25
  89. package/styles/treegrid/_bootstrap4-definition.scss +0 -25
  90. package/styles/treegrid/_bootstrap5-definition.scss +0 -25
  91. package/styles/treegrid/_bootstrap5.3-definition.scss +0 -25
  92. package/styles/treegrid/_fabric-dark-definition.scss +0 -25
  93. package/styles/treegrid/_fabric-definition.scss +0 -25
  94. package/styles/treegrid/_fluent-definition.scss +0 -25
  95. package/styles/treegrid/_fluent2-definition.scss +0 -25
  96. package/styles/treegrid/_fusionnew-definition.scss +0 -25
  97. package/styles/treegrid/_highcontrast-definition.scss +0 -25
  98. package/styles/treegrid/_highcontrast-light-definition.scss +0 -25
  99. package/styles/treegrid/_layout.scss +29 -29
  100. package/styles/treegrid/_material-dark-definition.scss +0 -25
  101. package/styles/treegrid/_material-definition.scss +0 -25
  102. package/styles/treegrid/_material3-definition.scss +0 -25
  103. package/styles/treegrid/_tailwind-definition.scss +0 -25
  104. package/styles/treegrid/_tailwind3-definition.scss +17 -42
  105. package/styles/treegrid/bootstrap5.3.css +3 -1091
  106. package/styles/treegrid/fluent2.css +8 -1129
  107. package/styles/treegrid/material3-dark.css +10 -1098
  108. package/styles/treegrid/material3.css +10 -1098
  109. package/styles/treegrid/tailwind3.css +84 -1220
  110. package/treegrid.d.ts +4 -0
  111. package/treegrid.js +4 -0
package/index.d.ts ADDED
@@ -0,0 +1,4 @@
1
+ /**
2
+ * index
3
+ */
4
+ export * from './src/index';
package/index.js ADDED
@@ -0,0 +1,4 @@
1
+ /**
2
+ * index
3
+ */
4
+ export * from './src/index';
package/package.json CHANGED
@@ -66,6 +66,6 @@
66
66
  "url": "git+https://github.com/syncfusion/ej2-treegrid.git"
67
67
  },
68
68
  "typings": "index.d.ts",
69
- "version": "26.1.35-469198",
69
+ "version": "26.1.35-760834",
70
70
  "sideEffects": false
71
71
  }
package/src/index.d.ts ADDED
@@ -0,0 +1,4 @@
1
+ /**
2
+ * Export TreeGrid component
3
+ */
4
+ export * from './treegrid/index';
@@ -0,0 +1,73 @@
1
+ import { TreeGrid } from '../base';
2
+ /**
3
+ * `BatchEdit` module is used to handle batch editing actions.
4
+ *
5
+ * @hidden
6
+ */
7
+ export declare class BatchEdit {
8
+ private parent;
9
+ private isSelfReference;
10
+ private addRowRecord;
11
+ private batchChildCount;
12
+ private addedRecords;
13
+ private deletedRecords;
14
+ private matrix;
15
+ private batchRecords;
16
+ private currentViewRecords;
17
+ private batchAddedRecords;
18
+ private batchDeletedRecords;
19
+ private batchIndex;
20
+ private batchAddRowRecord;
21
+ private isAdd;
22
+ private newBatchRowAdded;
23
+ private selectedIndex;
24
+ private addRowIndex;
25
+ constructor(parent: TreeGrid);
26
+ addEventListener(): void;
27
+ /**
28
+ * @hidden
29
+ * @returns {void}
30
+ */
31
+ removeEventListener(): void;
32
+ /**
33
+ * To destroy the editModule
34
+ *
35
+ * @returns {void}
36
+ * @hidden
37
+ */
38
+ destroy(): void;
39
+ /**
40
+ * @hidden
41
+ * @returns {Object[]} Returns modified records in batch editing.
42
+ */
43
+ getBatchRecords(): Object[];
44
+ /**
45
+ * @hidden
46
+ * @returns {number} Returns index of newly add row
47
+ */
48
+ getAddRowIndex(): number;
49
+ /**
50
+ * @hidden
51
+ * @returns {number} Returns selected row index
52
+ */
53
+ getSelectedIndex(): number;
54
+ /**
55
+ * @hidden
56
+ * @returns {number} Returns newly added child count
57
+ */
58
+ getBatchChildCount(): number;
59
+ private batchPageAction;
60
+ private cellSaved;
61
+ private beforeBatchAdd;
62
+ private batchAdd;
63
+ private beforeBatchDelete;
64
+ private updateRowIndex;
65
+ private updateChildCount;
66
+ private beforeBatchSave;
67
+ private deleteUniqueID;
68
+ private batchCancelAction;
69
+ private batchSave;
70
+ private getActualRowObjectIndex;
71
+ private immutableBatchAction;
72
+ private nextCellIndex;
73
+ }
@@ -0,0 +1,36 @@
1
+ /**
2
+ * clipboard.ts file
3
+ */
4
+ import { TreeGrid } from '../base/treegrid';
5
+ import { Clipboard as GridClipboard, ServiceLocator } from '@syncfusion/ej2-grids';
6
+ /**
7
+ * The `Clipboard` module is used to handle clipboard copy action.
8
+ *
9
+ * @hidden
10
+ */
11
+ export declare class TreeClipboard extends GridClipboard {
12
+ private treeGridParent;
13
+ private treeCopyContent;
14
+ private copiedUniqueIdCollection;
15
+ protected serviceLocator: ServiceLocator;
16
+ constructor(parent?: TreeGrid, serviceLocator?: ServiceLocator);
17
+ protected setCopyData(withHeader?: boolean): void;
18
+ private parentContentData;
19
+ copy(withHeader?: boolean): void;
20
+ paste(data: string, rowIndex: number, colIndex: number): void;
21
+ /**
22
+ * For internal use only - Get the module name.
23
+ *
24
+ * @private
25
+ * @returns {string} Returns clipboard module name
26
+ */
27
+ protected getModuleName(): string;
28
+ /**
29
+ * To destroy the clipboard
30
+ *
31
+ * @returns {void}
32
+ * @hidden
33
+ */
34
+ destroy(): void;
35
+ private childContentData;
36
+ }
@@ -0,0 +1,37 @@
1
+ import { TreeGrid } from '../base/treegrid';
2
+ /**
3
+ * TreeGrid ColumnChooser module
4
+ *
5
+ * @hidden
6
+ */
7
+ export declare class ColumnChooser {
8
+ private parent;
9
+ /**
10
+ * Constructor for render module
11
+ *
12
+ * @param {TreeGrid} parent - Tree Grid instance.
13
+ */
14
+ constructor(parent?: TreeGrid);
15
+ /**
16
+ * Column chooser can be displayed on screen by given position(X and Y axis).
17
+ *
18
+ * @param {number} X - Defines the X axis.
19
+ * @param {number} Y - Defines the Y axis.
20
+ * @returns {void}
21
+ */
22
+ openColumnChooser(X?: number, Y?: number): void;
23
+ /**
24
+ * Destroys the openColumnChooser.
25
+ *
26
+ * @function destroy
27
+ * @returns {void}
28
+ */
29
+ destroy(): void;
30
+ /**
31
+ * For internal use only - Get the module name.
32
+ *
33
+ * @private
34
+ * @returns {string} Returns ColumnChooser module name
35
+ */
36
+ private getModuleName;
37
+ }
@@ -0,0 +1,24 @@
1
+ import { TreeGrid } from '../base/treegrid';
2
+ /**
3
+ * TreeGrid ColumnMenu module
4
+ *
5
+ * @hidden
6
+ */
7
+ export declare class ColumnMenu {
8
+ private parent;
9
+ /**
10
+ * Constructor for render module
11
+ *
12
+ * @param {TreeGrid} parent - Tree Grid instance
13
+ */
14
+ constructor(parent?: TreeGrid);
15
+ getColumnMenu(): HTMLElement;
16
+ destroy(): void;
17
+ /**
18
+ * For internal use only - Get the module name.
19
+ *
20
+ * @private
21
+ * @returns {string} Returns ColumnMenu module name
22
+ */
23
+ private getModuleName;
24
+ }
@@ -0,0 +1,24 @@
1
+ import { TreeGrid } from '../base';
2
+ /**
3
+ * Command Column Module for TreeGrid
4
+ *
5
+ * @hidden
6
+ */
7
+ export declare class CommandColumn {
8
+ private parent;
9
+ constructor(parent: TreeGrid);
10
+ /**
11
+ * For internal use only - Get the module name.
12
+ *
13
+ * @private
14
+ * @returns {string} Returns CommandColumn module name
15
+ */
16
+ protected getModuleName(): string;
17
+ /**
18
+ * Destroys the ContextMenu.
19
+ *
20
+ * @function destroy
21
+ * @returns {void}
22
+ */
23
+ destroy(): void;
24
+ }
@@ -0,0 +1,42 @@
1
+ import { TreeGrid } from '../base';
2
+ /**
3
+ * ContextMenu Module for TreeGrid
4
+ *
5
+ * @hidden
6
+ */
7
+ export declare class ContextMenu {
8
+ private parent;
9
+ constructor(parent: TreeGrid);
10
+ /**
11
+ * @hidden
12
+ * @returns {void}
13
+ */
14
+ addEventListener(): void;
15
+ /**
16
+ * @hidden
17
+ * @returns {void}
18
+ */
19
+ removeEventListener(): void;
20
+ private contextMenuOpen;
21
+ private contextMenuClick;
22
+ /**
23
+ * For internal use only - Get the module name.
24
+ *
25
+ * @private
26
+ * @returns {string} Returns ContextMenu module name
27
+ */
28
+ protected getModuleName(): string;
29
+ /**
30
+ * Destroys the ContextMenu.
31
+ *
32
+ * @function destroy
33
+ * @returns {void}
34
+ */
35
+ destroy(): void;
36
+ /**
37
+ * Gets the context menu element from the TreeGrid.
38
+ *
39
+ * @returns {Element} Return Context Menu root element.
40
+ */
41
+ getContextMenu(): Element;
42
+ }
@@ -0,0 +1,66 @@
1
+ /**
2
+ * crud-actions.ts file
3
+ */
4
+ import { ITreeData } from '../base/interface';
5
+ import { TreeGrid } from '../base';
6
+ /**
7
+ * Performs CRUD update to Tree Grid data source
8
+ *
9
+ * @param {{value: ITreeData, action: string }} details - Gets modified record value and CRUD action type
10
+ * @param {TreeGrid} details.value - Gets modified record value
11
+ * @param {string} details.action - CRUD action type
12
+ * @param {TreeGrid} control - Tree Grid instance
13
+ * @param {boolean} isSelfReference - Denotes whether Self Referential data binding
14
+ * @param {number} addRowIndex - New add row index
15
+ * @param {number} selectedIndex - Selected Row index
16
+ * @param {string} columnName - Column field name
17
+ * @param {ITreeData} addRowRecord - Newly added record
18
+ * @returns {void}
19
+ */
20
+ export declare function editAction(details: {
21
+ value: ITreeData;
22
+ action: string;
23
+ }, control: TreeGrid, isSelfReference: boolean, addRowIndex: number, selectedIndex: number, columnName?: string, addRowRecord?: ITreeData): void;
24
+ /**
25
+ * Performs Add action to Tree Grid data source
26
+ *
27
+ * @param {{value: ITreeData, action: string }} details - Gets modified record value and CRUD action type
28
+ * @param {TreeGrid} details.value - Gets modified record value
29
+ * @param {string} details.action - CRUD action type
30
+ * @param {Object[]} treeData - Tree Grid data source
31
+ * @param {TreeGrid} control - Tree Grid instance
32
+ * @param {boolean} isSelfReference - Denotes whether Self Referential data binding
33
+ * @param {number} addRowIndex - New add row index
34
+ * @param {number} selectedIndex - Selected Row index
35
+ * @param {ITreeData} addRowRecord - Newly added record
36
+ * @returns {void}
37
+ */
38
+ export declare function addAction(details: {
39
+ value: ITreeData;
40
+ action: string;
41
+ }, treeData: Object[], control: TreeGrid, isSelfReference: boolean, addRowIndex: number, selectedIndex: number, addRowRecord: ITreeData): {
42
+ value: Object;
43
+ isSkip: boolean;
44
+ };
45
+ /**
46
+ * @param {ITreeData[]} childRecords - Child Records collection
47
+ * @param {Object} modifiedData - Modified data in crud action
48
+ * @param {string} action - crud action type
49
+ * @param {string} key - Primary key field name
50
+ * @param {TreeGrid} control - Tree Grid instance
51
+ * @param {boolean} isSelfReference - Specified whether Self Referential data binding
52
+ * @param {ITreeData} originalData - Non updated data from data source, of edited data
53
+ * @param {string} columnName - column field name
54
+ * @returns {boolean} Returns whether child records exists
55
+ */
56
+ export declare function removeChildRecords(childRecords: ITreeData[], modifiedData: Object, action: string, key: string, control: TreeGrid, isSelfReference: boolean, originalData?: ITreeData, columnName?: string): boolean;
57
+ /**
58
+ * @param {string} key - Primary key field name
59
+ * @param {ITreeData} record - Parent Record which has to be updated
60
+ * @param {string} action - CRUD action type
61
+ * @param {TreeGrid} control - Tree Grid instance
62
+ * @param {boolean} isSelfReference - Specified whether self referential data binding
63
+ * @param {ITreeData} child - Specifies child record
64
+ * @returns {void}
65
+ */
66
+ export declare function updateParentRow(key: string, record: ITreeData, action: string, control: TreeGrid, isSelfReference: boolean, child?: ITreeData): void;
@@ -239,7 +239,7 @@ export function removeChildRecords(childRecords, modifiedData, action, key, cont
239
239
  editedData.taskData[keys[parseInt(i.toString(), 10)]] =
240
240
  childRecords[parseInt(j.toString(), 10)][keys[parseInt(i.toString(), 10)]] =
241
241
  modifiedData[keys[parseInt(i.toString(), 10)]];
242
- if (control.grid.editSettings.mode === 'Normal' && control.editSettings.mode === 'Cell') {
242
+ if (control.grid.editSettings.mode === 'Normal' && control.editSettings.mode === 'Cell' && !isNullOrUndefined(control.grid.editModule)) {
243
243
  var editModule = 'editModule';
244
244
  control.grid.editModule["" + editModule].editRowIndex = modifiedData.index;
245
245
  control.grid.editModule["" + editModule].updateCurrentViewData(modifiedData);
@@ -0,0 +1,39 @@
1
+ import { TreeGrid } from '../base';
2
+ /**
3
+ * TreeGrid Detail Row module
4
+ *
5
+ * @hidden
6
+ */
7
+ export declare class DetailRow {
8
+ private parent;
9
+ constructor(parent: TreeGrid);
10
+ /**
11
+ * @hidden
12
+ */
13
+ /**
14
+ * For internal use only - Get the module name.
15
+ *
16
+ * @private
17
+ * @returns {string} Returns DetailRow module name
18
+ */
19
+ protected getModuleName(): string;
20
+ addEventListener(): void;
21
+ /**
22
+ * @hidden
23
+ * @returns {void}
24
+ */
25
+ removeEventListener(): void;
26
+ private setIndentVisibility;
27
+ private dataBoundArg;
28
+ private childRowExpand;
29
+ private rowExpandCollapse;
30
+ private detaildataBound;
31
+ private actioncomplete;
32
+ /**
33
+ * Destroys the DetailModule.
34
+ *
35
+ * @function destroy
36
+ * @returns {void}
37
+ */
38
+ destroy(): void;
39
+ }
@@ -0,0 +1,112 @@
1
+ import { Column } from '@syncfusion/ej2-grids';
2
+ import { TreeGrid } from '../base/treegrid';
3
+ import { RowPosition } from '../enum';
4
+ /**
5
+ * TreeGrid Edit Module
6
+ * The `Edit` module is used to handle editing actions.
7
+ */
8
+ export declare class Edit {
9
+ private parent;
10
+ private isSelfReference;
11
+ private addedRecords;
12
+ private deletedRecords;
13
+ private addRowIndex;
14
+ private addRowRecord;
15
+ private isOnBatch;
16
+ private keyPress;
17
+ private selectedIndex;
18
+ private doubleClickTarget;
19
+ private internalProperties;
20
+ private previousNewRowPosition;
21
+ private batchEditModule;
22
+ private isTabLastRow;
23
+ private prevAriaRowIndex;
24
+ private isAddedRowByMethod;
25
+ private isAddedRowByContextMenu;
26
+ /**
27
+ * Constructor for Edit module
28
+ *
29
+ * @param {TreeGrid} parent - Tree Grid instance
30
+ */
31
+ constructor(parent: TreeGrid);
32
+ /**
33
+ * For internal use only - Get the module name.
34
+ *
35
+ * @private
36
+ * @returns {string} Returns Edit module name
37
+ */
38
+ protected getModuleName(): string;
39
+ /**
40
+ * @hidden
41
+ * @returns {void}
42
+ */
43
+ addEventListener(): void;
44
+ private gridDblClick;
45
+ private getRowPosition;
46
+ private beforeStartEdit;
47
+ private beforeBatchCancel;
48
+ /**
49
+ * @hidden
50
+ * @returns {void}
51
+ */
52
+ removeEventListener(): void;
53
+ /**
54
+ * To destroy the editModule
55
+ *
56
+ * @returns {void}
57
+ * @hidden
58
+ */
59
+ destroy(): void;
60
+ /**
61
+ * @param {Column[]} cols - Column property Collection
62
+ * @hidden
63
+ * @returns {void}
64
+ */
65
+ applyFormValidation(cols?: Column[]): void;
66
+ private editActionEvents;
67
+ private infiniteAddAction;
68
+ private updateInfiniteCurrentViewData;
69
+ private recordDoubleClick;
70
+ private updateGridEditMode;
71
+ private resetIsOnBatch;
72
+ private keyPressed;
73
+ private deleteUniqueID;
74
+ private cellEdit;
75
+ private enableToolbarItems;
76
+ private batchCancel;
77
+ private customCellSave;
78
+ private cellSave;
79
+ private afterCellSave;
80
+ private lastCellTab;
81
+ private updateCell;
82
+ private crudAction;
83
+ private updateIndex;
84
+ private beginAdd;
85
+ private beginEdit;
86
+ private savePreviousRowPosition;
87
+ private beginAddEdit;
88
+ /**
89
+ * If the data,index and position given, Adds the record to treegrid rows otherwise it will create edit form.
90
+ *
91
+ * @returns {void}
92
+ */
93
+ addRecord(data?: Object, index?: number, position?: RowPosition): void;
94
+ /**
95
+ * Checks the status of validation at the time of editing. If validation is passed, it returns true.
96
+ *
97
+ * @returns {boolean} Returns form validation results
98
+ */
99
+ editFormValidate(): boolean;
100
+ /**
101
+ * @hidden
102
+ * @returns {void}
103
+ */
104
+ destroyForm(): void;
105
+ private contentready;
106
+ /**
107
+ * If the row index and field is given, edits the particular cell in a row.
108
+ *
109
+ * @returns {void}
110
+ */
111
+ editCell(rowIndex?: number, field?: string): void;
112
+ }
@@ -796,6 +796,7 @@ var Edit = /** @class */ (function () {
796
796
  this.addRowIndex = this.parent.grid.selectedRowIndex > -1 ? this.parent.grid.selectedRowIndex : 0;
797
797
  }
798
798
  }
799
+ var selectedRecords = this.parent.getSelectedRecords()[0];
799
800
  if ((this.isAddedRowByMethod || (this.isAddedRowByContextMenu && this.parent.grid.selectedRowIndex !== -1)) &&
800
801
  (this.parent.enableVirtualization || this.parent.enableInfiniteScrolling)) {
801
802
  this.addRowRecord = this.parent.flatData[this.parent.grid.selectedRowIndex];
@@ -803,8 +804,8 @@ var Edit = /** @class */ (function () {
803
804
  this.addRowRecord = this.parent.getCurrentViewRecords()[this.addRowIndex];
804
805
  }
805
806
  }
806
- else {
807
- this.addRowRecord = this.parent.getSelectedRecords()[0];
807
+ else if (!isNullOrUndefined(selectedRecords)) {
808
+ this.addRowRecord = selectedRecords;
808
809
  }
809
810
  }
810
811
  if (this.isAddedRowByMethod && args.index !== 0) {
@@ -0,0 +1,59 @@
1
+ import { TreeGrid } from '../base/treegrid';
2
+ import { ExcelExportProperties } from '@syncfusion/ej2-grids';
3
+ import { Fetch } from '@syncfusion/ej2-base';
4
+ import { Query } from '@syncfusion/ej2-data';
5
+ /**
6
+ * TreeGrid Excel Export module
7
+ *
8
+ * @hidden
9
+ */
10
+ export declare class ExcelExport {
11
+ private parent;
12
+ private dataResults;
13
+ private isCollapsedStatePersist;
14
+ /**
15
+ * Constructor for Excel Export module
16
+ *
17
+ * @param {TreeGrid} parent - Tree Grid instance
18
+ */
19
+ constructor(parent?: TreeGrid);
20
+ /**
21
+ * For internal use only - Get the module name.
22
+ *
23
+ * @private
24
+ * @returns {string} Returns ExcelExport module name
25
+ */
26
+ protected getModuleName(): string;
27
+ /**
28
+ * @hidden
29
+ * @returns {void}
30
+ */
31
+ addEventListener(): void;
32
+ /**
33
+ * To destroy the Excel Export
34
+ *
35
+ * @returns {void}
36
+ * @hidden
37
+ */
38
+ destroy(): void;
39
+ /**
40
+ * @hidden
41
+ * @returns {void}
42
+ */
43
+ removeEventListener(): void;
44
+ private updateExcelResultModel;
45
+ Map(excelExportProperties?: ExcelExportProperties, isMultipleExport?: boolean, workbook?: any, isBlob?: boolean, isCsv?: boolean): Promise<Object>;
46
+ protected generateQuery(query: Query, property?: ExcelExportProperties): Query;
47
+ protected manipulateExportProperties(property?: ExcelExportProperties, dtSrc?: Object, queryResult?: Fetch): Object;
48
+ /**
49
+ * TreeGrid Excel Export cell modifier
50
+ *
51
+ * @param {ExcelQueryCellInfoEventArgs} args - current cell details
52
+ * @hidden
53
+ * @returns {void}
54
+ */
55
+ private excelQueryCellInfo;
56
+ private exportRowDataBound;
57
+ private finalPageSetup;
58
+ private isLocal;
59
+ }
@@ -1,4 +1,5 @@
1
- import { getObject, Grid, ExcelExport as GridExcel } from '@syncfusion/ej2-grids';
1
+ import { getObject, Grid, ExcelExport as GridExcel, ExportHelper } from '@syncfusion/ej2-grids';
2
+ import { Data } from '@syncfusion/ej2-grids';
2
3
  import { isRemoteData, isOffline, getParentData, getExpandStatus } from '../utils';
3
4
  import { isNullOrUndefined, setValue, extend } from '@syncfusion/ej2-base';
4
5
  import { DataManager, Query } from '@syncfusion/ej2-data';
@@ -70,14 +71,19 @@ var ExcelExport = /** @class */ (function () {
70
71
  isMultipleExport, workbook, isBlob, isCsv) {
71
72
  var _this = this;
72
73
  var dataSource = this.parent.dataSource;
74
+ var data = new Data(this.parent.grid);
73
75
  var property = Object();
74
76
  setValue('isCsv', isCsv, property);
75
77
  setValue('cancel', false, property);
76
78
  if (!isNullOrUndefined(excelExportProperties)) {
77
79
  this.isCollapsedStatePersist = excelExportProperties.isCollapsedStatePersist;
78
80
  }
79
- if (!isNullOrUndefined(excelExportProperties) && !isNullOrUndefined(excelExportProperties.dataSource)) {
80
- if (!excelExportProperties.dataSource['dataSource']) {
81
+ if (!isNullOrUndefined(excelExportProperties)) {
82
+ if (!isNullOrUndefined(excelExportProperties.dataSource) && !excelExportProperties.dataSource['dataSource']) {
83
+ return this.parent.grid.excelExportModule.Map(this.parent.grid, excelExportProperties, isMultipleExport, workbook, isCsv, isBlob);
84
+ }
85
+ if (excelExportProperties.exportType === 'CurrentPage') {
86
+ excelExportProperties.dataSource = this.parent.getCurrentViewRecords();
81
87
  return this.parent.grid.excelExportModule.Map(this.parent.grid, excelExportProperties, isMultipleExport, workbook, isCsv, isBlob);
82
88
  }
83
89
  }
@@ -88,6 +94,11 @@ var ExcelExport = /** @class */ (function () {
88
94
  if (!_this.isLocal()) {
89
95
  query = _this.generateQuery(query);
90
96
  query.queries = _this.parent.grid.getDataModule().generateQuery().queries;
97
+ query = ExportHelper.getQuery(_this.parent.grid, data);
98
+ if (isNullOrUndefined(_this.parent.filterModule)) {
99
+ query.queries = query.queries.slice(1, 2);
100
+ query.params = query.params.slice(0, 0);
101
+ }
91
102
  setValue('query', query, property);
92
103
  }
93
104
  _this.parent.trigger(event.beforeExcelExport, extend(property, excelExportProperties));
@@ -0,0 +1,57 @@
1
+ import { TreeGrid } from '../base/treegrid';
2
+ /**
3
+ * TreeGrid Filter module will handle filtering action
4
+ *
5
+ * @hidden
6
+ */
7
+ export declare class Filter {
8
+ private parent;
9
+ filteredResult: Object[];
10
+ private flatFilteredData;
11
+ private filteredParentRecs;
12
+ private isHierarchyFilter;
13
+ /**
14
+ * Constructor for Filter module
15
+ *
16
+ * @param {TreeGrid} parent - Tree Grid instance
17
+ */
18
+ constructor(parent?: TreeGrid);
19
+ /**
20
+ * For internal use only - Get the module name.
21
+ *
22
+ * @private
23
+ * @returns {string} Returns Filter module name
24
+ */
25
+ protected getModuleName(): string;
26
+ /**
27
+ * To destroy the Filter module
28
+ *
29
+ * @returns {void}
30
+ * @hidden
31
+ */
32
+ destroy(): void;
33
+ /**
34
+ * @hidden
35
+ * @returns {void}
36
+ */
37
+ addEventListener(): void;
38
+ /**
39
+ * @hidden
40
+ * @returns {void}
41
+ */
42
+ removeEventListener(): void;
43
+ /**
44
+ * Function to update filtered records
45
+ *
46
+ * @param {{data: Object} } dataDetails - Filtered data collection
47
+ * @param {Object} dataDetails.data - Fliltered data collection
48
+ * @hidden
49
+ * @returns {void}
50
+ */
51
+ private updatedFilteredRecord;
52
+ private updateParentFilteredRecord;
53
+ private addParentRecord;
54
+ private checkChildExsist;
55
+ private updateFilterLevel;
56
+ private clearFilterLevel;
57
+ }