@syncfusion/ej2-treegrid 34.2.2 → 34.2.5

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.
@@ -1,12 +1,3 @@
1
- /*!
2
- * filename: index.d.ts
3
- * version : 34.2.2
4
- * Copyright Syncfusion Inc. 2001 - 2025. All rights reserved.
5
- * Use of this code is subject to the terms of our license.
6
- * A copy of the current license can be obtained at any time by e-mailing
7
- * licensing@syncfusion.com. Any infringement will be prosecuted under
8
- * applicable laws.
9
- */
10
1
  import * as _treegrid from '@syncfusion/ej2-treegrid';
11
2
 
12
3
  export declare namespace ej {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@syncfusion/ej2-treegrid",
3
- "version": "34.2.2",
3
+ "version": "34.2.5",
4
4
  "description": "Essential JS 2 TreeGrid Component",
5
5
  "author": "Syncfusion Inc.",
6
6
  "license": "SEE LICENSE IN license",
@@ -8,10 +8,10 @@
8
8
  "module": "./index.js",
9
9
  "es2015": "./dist/es6/ej2-treegrid.es5.js",
10
10
  "dependencies": {
11
- "@syncfusion/ej2-base": "~34.2.2",
11
+ "@syncfusion/ej2-base": "~34.2.5",
12
12
  "@syncfusion/ej2-data": "~34.2.2",
13
- "@syncfusion/ej2-grids": "~34.2.2",
14
- "@syncfusion/ej2-popups": "~34.2.2"
13
+ "@syncfusion/ej2-grids": "~34.2.5",
14
+ "@syncfusion/ej2-popups": "~34.2.4"
15
15
  },
16
16
  "devDependencies": {},
17
17
  "keywords": [
@@ -9,7 +9,7 @@ import { getExpandStatus, isRemoteData } from '../utils';
9
9
  */
10
10
  var DetailRow = /** @class */ (function () {
11
11
  function DetailRow(parent) {
12
- initializeTelemetryFeature('detailRow', 'treegrid');
12
+ initializeTelemetryFeature('DetailRow', 'TreeGrid');
13
13
  Grid.Inject(detailrow);
14
14
  this.parent = parent;
15
15
  this.addEventListener();
@@ -25,7 +25,7 @@ var Edit = /** @class */ (function () {
25
25
  this.isAddedRowByContextMenu = false;
26
26
  this.isIndexUndefined = false;
27
27
  this.isAddedMultipleRowsByMethod = false;
28
- initializeTelemetryFeature('edit', 'treegrid');
28
+ initializeTelemetryFeature('Edit', 'TreeGrid');
29
29
  Grid.Inject(GridEdit);
30
30
  this.parent = parent;
31
31
  this.isSelfReference = !isNullOrUndefined(parent.parentIdMapping);
@@ -1,7 +1,7 @@
1
1
  import { getObject, Grid, ExcelExport as GridExcel, ExportHelper } from '@syncfusion/ej2-grids';
2
2
  import { Data } from '@syncfusion/ej2-grids';
3
3
  import { isRemoteData, isOffline, getParentData, getExpandStatus } from '../utils';
4
- import { isNullOrUndefined, setValue, extend } from '@syncfusion/ej2-base';
4
+ import { isNullOrUndefined, setValue, extend, initializeTelemetryFeature } from '@syncfusion/ej2-base';
5
5
  import { DataManager, Query } from '@syncfusion/ej2-data';
6
6
  import * as event from '../base/constant';
7
7
  /**
@@ -17,6 +17,7 @@ var ExcelExport = /** @class */ (function () {
17
17
  */
18
18
  function ExcelExport(parent) {
19
19
  this.isCollapsedStatePersist = false;
20
+ initializeTelemetryFeature('ExcelExport', 'TreeGrid');
20
21
  Grid.Inject(GridExcel);
21
22
  this.parent = parent;
22
23
  this.dataResults = {};
@@ -54,4 +54,5 @@ export declare class Filter {
54
54
  private checkChildExsist;
55
55
  private updateFilterLevel;
56
56
  private clearFilterLevel;
57
+ private checkNegativePredicate;
57
58
  }
@@ -13,7 +13,7 @@ var Filter = /** @class */ (function () {
13
13
  * @param {TreeGrid} parent - Tree Grid instance
14
14
  */
15
15
  function Filter(parent) {
16
- initializeTelemetryFeature('filter', 'treegrid');
16
+ initializeTelemetryFeature('Filter', 'TreeGrid');
17
17
  Grid.Inject(GridFilter);
18
18
  this.parent = parent;
19
19
  this.isHierarchyFilter = false;
@@ -164,6 +164,7 @@ var Filter = /** @class */ (function () {
164
164
  };
165
165
  Filter.prototype.checkChildExsist = function (records) {
166
166
  var childRec = getObject('childRecords', records);
167
+ var isNegativeOperator = this.checkNegativePredicate();
167
168
  var isExist = false;
168
169
  for (var count = 0; count < childRec.length; count++) {
169
170
  var ischild = childRec[parseInt(count.toString(), 10)].childRecords;
@@ -171,11 +172,14 @@ var Filter = /** @class */ (function () {
171
172
  this.parent.filterSettings.hierarchyMode : this.parent.searchSettings.hierarchyMode;
172
173
  if (((hierarchyMode === 'Child' || hierarchyMode === 'Both') && (this.parent.grid.filterSettings.columns.length !== 0
173
174
  || this.parent.grid.searchSettings.key !== ''))) {
174
- var uniqueIDValue = getValue('uniqueIDFilterCollection', this.parent);
175
- if (!Object.prototype.hasOwnProperty.call(uniqueIDValue, childRec[parseInt(count.toString(), 10)].uniqueID)) {
176
- this.filteredResult.push(childRec[parseInt(count.toString(), 10)]);
177
- setValue('uniqueIDFilterCollection.' + childRec[parseInt(count.toString(), 10)].uniqueID, childRec[parseInt(count.toString(), 10)], this.parent);
178
- isExist = true;
175
+ var recordID = childRec[parseInt(count.toString(), 10)].uniqueID;
176
+ if (!isNegativeOperator) {
177
+ var uniqueIDValue = getValue('uniqueIDFilterCollection', this.parent);
178
+ if (!Object.prototype.hasOwnProperty.call(uniqueIDValue, childRec[parseInt(count.toString(), 10)].uniqueID)) {
179
+ this.filteredResult.push(childRec[parseInt(count.toString(), 10)]);
180
+ setValue('uniqueIDFilterCollection.' + childRec[parseInt(count.toString(), 10)].uniqueID, childRec[parseInt(count.toString(), 10)], this.parent);
181
+ isExist = true;
182
+ }
179
183
  }
180
184
  }
181
185
  if ((hierarchyMode === 'None')
@@ -226,6 +230,17 @@ var Filter = /** @class */ (function () {
226
230
  this.filteredResult = [];
227
231
  this.parent.notify('updateResults', { result: flatData, count: flatData.length });
228
232
  };
233
+ Filter.prototype.checkNegativePredicate = function () {
234
+ var filterColumns = this.parent.grid.filterSettings.columns;
235
+ for (var i = 0; i < filterColumns.length; i++) {
236
+ var operator = getValue('operator', filterColumns[parseInt(i.toString(), 10)]);
237
+ if (operator === 'doesnotcontain' || operator === 'notequal' || operator === 'doesnotstartwith'
238
+ || operator === 'doesnotendwith' || operator === 'notin') {
239
+ return true;
240
+ }
241
+ }
242
+ return false;
243
+ };
229
244
  return Filter;
230
245
  }());
231
246
  export { Filter };
@@ -1,6 +1,6 @@
1
1
  import { Grid, InfiniteScroll as GridInfiniteScroll, getRowIndexFromElement } from '@syncfusion/ej2-grids';
2
2
  import { RowRenderer, resetRowIndex } from '@syncfusion/ej2-grids';
3
- import { getValue, isNullOrUndefined, remove } from '@syncfusion/ej2-base';
3
+ import { getValue, isNullOrUndefined, remove, initializeTelemetryFeature } from '@syncfusion/ej2-base';
4
4
  import * as events from '../base/constant';
5
5
  import { DataManager, Predicate, Query } from '@syncfusion/ej2-data';
6
6
  import { findChildrenRecords } from '../utils';
@@ -16,6 +16,7 @@ var InfiniteScroll = /** @class */ (function () {
16
16
  * @param {TreeGrid} parent - Tree Grid instance
17
17
  */
18
18
  function InfiniteScroll(parent) {
19
+ initializeTelemetryFeature('InfiniteScroll', 'TreeGrid');
19
20
  this.parent = parent;
20
21
  Grid.Inject(GridInfiniteScroll);
21
22
  this.addEventListener();
@@ -11,7 +11,7 @@ import { getExpandStatus, isFilterChildHierarchy } from '../utils';
11
11
  */
12
12
  var Page = /** @class */ (function () {
13
13
  function Page(parent) {
14
- initializeTelemetryFeature('pager', 'treegrid');
14
+ initializeTelemetryFeature('Page', 'TreeGrid');
15
15
  Grid.Inject(GridPage);
16
16
  this.parent = parent;
17
17
  this.addEventListener();
@@ -1,6 +1,6 @@
1
1
  import { getObject, PdfExport as GridPdf, Grid } from '@syncfusion/ej2-grids';
2
2
  import { isRemoteData, isOffline } from '../utils';
3
- import { isNullOrUndefined, setValue, extend, getValue } from '@syncfusion/ej2-base';
3
+ import { isNullOrUndefined, setValue, extend, getValue, initializeTelemetryFeature } from '@syncfusion/ej2-base';
4
4
  import { DataManager, Query } from '@syncfusion/ej2-data';
5
5
  import * as event from '../base/constant';
6
6
  /**
@@ -16,6 +16,7 @@ var PdfExport = /** @class */ (function () {
16
16
  */
17
17
  function PdfExport(parent) {
18
18
  this.isCollapsedStatePersist = false;
19
+ initializeTelemetryFeature('PdfExport', 'TreeGrid');
19
20
  Grid.Inject(GridPdf);
20
21
  this.parent = parent;
21
22
  this.dataResults = {};
@@ -45,7 +45,7 @@ var RowDD = /** @class */ (function () {
45
45
  * Indicates whether the item is being added to the bottom of the TreeGrid.
46
46
  */
47
47
  this.isaddtoBottom = false;
48
- initializeTelemetryFeature('rowDragAndDrop', 'treegrid');
48
+ initializeTelemetryFeature('RowDD', 'TreeGrid');
49
49
  Grid.Inject(GridDragDrop);
50
50
  this.parent = parent;
51
51
  this.addEventListener();
@@ -9,7 +9,7 @@ import { getParentData } from '../utils';
9
9
  */
10
10
  var Sort = /** @class */ (function () {
11
11
  function Sort(grid) {
12
- initializeTelemetryFeature('sort', 'treegrid');
12
+ initializeTelemetryFeature('Sort', 'TreeGrid');
13
13
  Grid.Inject(GridSort);
14
14
  this.parent = grid;
15
15
  this.taskIds = [];
@@ -13,7 +13,7 @@ var __extends = (this && this.__extends) || (function () {
13
13
  })();
14
14
  import { Grid, VirtualScroll as GridVirtualScroll } from '@syncfusion/ej2-grids';
15
15
  import { RenderType } from '@syncfusion/ej2-grids';
16
- import { getValue, isNullOrUndefined } from '@syncfusion/ej2-base';
16
+ import { getValue, isNullOrUndefined, initializeTelemetryFeature } from '@syncfusion/ej2-base';
17
17
  import * as events from '../base/constant';
18
18
  import { DataManager, Predicate, Query } from '@syncfusion/ej2-data';
19
19
  import { getExpandStatus } from '../utils';
@@ -35,6 +35,7 @@ var VirtualScroll = /** @class */ (function () {
35
35
  this.setEndIndexToGantt = true;
36
36
  this.prevendIndex = -1;
37
37
  this.prevSelectedRecord = [];
38
+ initializeTelemetryFeature('VirtualScroll', 'TreeGrid');
38
39
  this.parent = parent;
39
40
  Grid.Inject(TreeVirtual);
40
41
  this.addEventListener();
@@ -600,6 +600,9 @@ var DataManipulation = /** @class */ (function () {
600
600
  getValue('grid.renderModule', _this.parent).dataManagerSuccess(e, virtualArgs);
601
601
  }
602
602
  _this.parent.trigger(events.expanded, args);
603
+ })
604
+ .catch(function (e) {
605
+ _this.parent.trigger(events.actionFailure, e);
603
606
  });
604
607
  };
605
608
  DataManipulation.prototype.remoteVirtualAction = function (virtualArgs) {
@@ -108,6 +108,7 @@ var TreeGrid = /** @class */ (function (_super) {
108
108
  return false;
109
109
  }
110
110
  };
111
+ initializeTelemetry('TreeGrid');
111
112
  TreeGrid_1.Inject(TreeGridSelection, TreeLogger);
112
113
  setValue('mergePersistData', _this.mergePersistTreeGridData, _this);
113
114
  var logger = 'Logger';
@@ -818,7 +819,6 @@ var TreeGrid = /** @class */ (function (_super) {
818
819
  */
819
820
  TreeGrid.prototype.render = function () {
820
821
  var _this = this;
821
- initializeTelemetry('treegrid');
822
822
  if (this.isReact) {
823
823
  this.grid.isReact = true;
824
824
  this.grid.portals = [];
@@ -169,7 +169,7 @@ var Render = /** @class */ (function () {
169
169
  else {
170
170
  expand = !(!data.expanded || !getExpandStatus(this.parent, data, this.parent.grid.getCurrentViewRecords()));
171
171
  // TicketsID 43483: While Modify Data Expand and Collapse Icon Behavior Changed
172
- if (this.parent.editSettings.mode === 'Cell' && !isRemoteData(this.parent)) {
172
+ if (this.parent.editSettings.mode === 'Cell' && !isRemoteData(this.parent) && this.parent.allowPaging) {
173
173
  var selectedRow = this.parent.flatData.find(function (item) { return item.uniqueID === data.uniqueID; });
174
174
  if (!isNullOrUndefined(selectedRow)) {
175
175
  expand = data.expanded !== selectedRow.expanded ? selectedRow.expanded : data.expanded;