@syncfusion/ej2-treegrid 20.3.47 → 20.3.48

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.
@@ -3726,12 +3726,12 @@ let TreeGrid = TreeGrid_1 = class TreeGrid extends Component {
3726
3726
  this.trigger(getObject('name', args), args);
3727
3727
  }
3728
3728
  IsExpandCollapseClicked(args) {
3729
- if (args['name'] === "rowSelecting" && !isNullOrUndefined(args.target) && (args.target.classList.contains('e-treegridexpand')
3729
+ if (args['name'] === 'rowSelecting' && !isNullOrUndefined(args.target) && (args.target.classList.contains('e-treegridexpand')
3730
3730
  || args.target.classList.contains('e-treegridcollapse') || args.target.classList.contains('e-summarycell')) && (isNullOrUndefined(args['previousRowIndex']))) {
3731
3731
  args.cancel = true;
3732
3732
  return;
3733
3733
  }
3734
- else if (args['name'] === "rowDeselecting" && !isNullOrUndefined(args.target) && ((!isNullOrUndefined(args.row) && (!args.row.length)) && (args.target.classList.contains('e-treegridexpand')
3734
+ else if (args['name'] === 'rowDeselecting' && !isNullOrUndefined(args.target) && ((!isNullOrUndefined(args.row) && (!args.row.length)) && (args.target.classList.contains('e-treegridexpand')
3735
3735
  || args.target.classList.contains('e-treegridcollapse') || args.target.classList.contains('e-summarycell')))) {
3736
3736
  args.cancel = true;
3737
3737
  return;
@@ -10819,6 +10819,10 @@ class Edit$1 {
10819
10819
  }
10820
10820
  this.updateGridEditMode('Batch');
10821
10821
  }
10822
+ else if (this.parent.editSettings.mode === 'Cell' && (!column.allowEditing || column.isPrimaryKey)) {
10823
+ this.isOnBatch = true;
10824
+ this.updateGridEditMode('Batch');
10825
+ }
10822
10826
  }
10823
10827
  updateGridEditMode(mode) {
10824
10828
  this.parent.grid.setProperties({ editSettings: { mode: mode } }, true);
@@ -11489,7 +11493,12 @@ class Edit$1 {
11489
11493
  }
11490
11494
  index = (childRecordCount1 > 0) ? (currentDataIndex1 + childRecordCount1) : (currentDataIndex1);
11491
11495
  if (this.isSelfReference) {
11492
- value.taskData[this.parent.parentIdMapping] = value[this.parent.parentIdMapping] = idMapping;
11496
+ if (!this.parent.isLocalData && this.parent.editModule.selectedIndex === -1) {
11497
+ value.taskData[this.parent.parentIdMapping] = value[this.parent.parentIdMapping] = null;
11498
+ }
11499
+ else {
11500
+ value.taskData[this.parent.parentIdMapping] = value[this.parent.parentIdMapping] = idMapping;
11501
+ }
11493
11502
  if (!isNullOrUndefined(value.parentItem)) {
11494
11503
  updateParentRow(key, value.parentItem, 'add', this.parent, this.isSelfReference, value);
11495
11504
  }