devexpress-gantt 4.1.41 → 4.1.43

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/dx-gantt.css CHANGED
@@ -1,7 +1,7 @@
1
1
  /*!
2
2
  * DevExpress Gantt (dx-gantt)
3
- * Version: 4.1.41
4
- * Build date: Mon Jan 30 2023
3
+ * Version: 4.1.43
4
+ * Build date: Thu Mar 30 2023
5
5
  *
6
6
  * Copyright (c) 2012 - 2023 Developer Express Inc. ALL RIGHTS RESERVED
7
7
  * Read about DevExpress licensing here: https://www.devexpress.com/Support/EULAs
package/dist/dx-gantt.js CHANGED
@@ -1,7 +1,7 @@
1
1
  /*!
2
2
  * DevExpress Gantt (dx-gantt)
3
- * Version: 4.1.41
4
- * Build date: Mon Jan 30 2023
3
+ * Version: 4.1.43
4
+ * Build date: Thu Mar 30 2023
5
5
  *
6
6
  * Copyright (c) 2012 - 2023 Developer Express Inc. ALL RIGHTS RESERVED
7
7
  * Read about DevExpress licensing here: https://www.devexpress.com/Support/EULAs
@@ -6155,6 +6155,9 @@ var GanttView = (function () {
6155
6155
  else
6156
6156
  this.adjustOwnerControl();
6157
6157
  };
6158
+ GanttView.prototype.getTaskTreeLine = function (taskKey) {
6159
+ return this.viewModel.getTaskTreeLine(taskKey).reverse();
6160
+ };
6158
6161
  GanttView.prototype.setTaskValue = function (id, fieldName, newValue) {
6159
6162
  var command = this.commandManager.updateTaskCommand;
6160
6163
  var task = this.getTaskByPublicId(id);
@@ -6181,6 +6184,8 @@ var GanttView = (function () {
6181
6184
  };
6182
6185
  GanttView.prototype.getPrevTask = function (taskId) {
6183
6186
  var item = this.viewModel.findItem(taskId);
6187
+ if (!item)
6188
+ return null;
6184
6189
  var parent = item.parent || this.viewModel.root;
6185
6190
  var index = parent.children.indexOf(item) - 1;
6186
6191
  return index > -1 ? item.parent.children[index].task : item.parent.task;
@@ -19064,14 +19069,14 @@ var ValidationController = (function () {
19064
19069
  });
19065
19070
  return result;
19066
19071
  };
19067
- ValidationController.prototype.moveEndDependTasks = function (predecessorTaskId, predecessorPreviousEndDate, isAfterCorrectParents) {
19072
+ ValidationController.prototype.moveEndDependTasks = function (predecessorTaskId, predecessorPreviousEndDate, moveInitiatorId) {
19068
19073
  var _this = this;
19069
- if (isAfterCorrectParents === void 0) { isAfterCorrectParents = false; }
19074
+ if (moveInitiatorId === void 0) { moveInitiatorId = null; }
19070
19075
  var dependencies = this.viewModel.dependencies.items.filter(function (d) { return d.predecessorId === predecessorTaskId && !d.isStartDependency; });
19071
19076
  var predecessorTask = this.viewModel.tasks.getItemById(predecessorTaskId);
19072
19077
  dependencies.forEach(function (dependency) {
19073
19078
  var successorTask = _this.viewModel.tasks.getItemById(dependency.successorId);
19074
- var isMoveNotRequired = !successorTask || (isAfterCorrectParents && predecessorTask.parentId === successorTask.parentId) || (successorTask.parentId == predecessorTask.id);
19079
+ var isMoveNotRequired = !successorTask || (moveInitiatorId && _this.viewModel.checkParent(successorTask.internalId, moveInitiatorId)) || (successorTask.parentId === predecessorTask.id);
19075
19080
  if (isMoveNotRequired)
19076
19081
  return;
19077
19082
  var successorRangeBeforeMove = new DateRange_1.DateRange(new Date(successorTask.start.getTime()), new Date(successorTask.end.getTime()));
@@ -19103,14 +19108,14 @@ var ValidationController = (function () {
19103
19108
  }
19104
19109
  });
19105
19110
  };
19106
- ValidationController.prototype.moveStartDependTasks = function (predecessorTaskId, predecessorPreviousStartDate, isAfterCorrectParents) {
19111
+ ValidationController.prototype.moveStartDependTasks = function (predecessorTaskId, predecessorPreviousStartDate, moveInitiatorId) {
19107
19112
  var _this = this;
19108
- if (isAfterCorrectParents === void 0) { isAfterCorrectParents = false; }
19113
+ if (moveInitiatorId === void 0) { moveInitiatorId = null; }
19109
19114
  var dependencies = this.viewModel.dependencies.items.filter(function (d) { return d.predecessorId === predecessorTaskId && d.isStartDependency; });
19110
19115
  var predecessorTask = this.viewModel.tasks.getItemById(predecessorTaskId);
19111
19116
  dependencies.forEach(function (dependency) {
19112
19117
  var successorTask = _this.viewModel.tasks.getItemById(dependency.successorId);
19113
- var isMoveNotRequired = !successorTask || (isAfterCorrectParents && predecessorTask.parentId === successorTask.parentId) || (successorTask.parentId == predecessorTask.id);
19118
+ var isMoveNotRequired = !successorTask || (moveInitiatorId && _this.viewModel.checkParent(successorTask.internalId, moveInitiatorId)) || (successorTask.parentId === predecessorTask.id);
19114
19119
  if (isMoveNotRequired)
19115
19120
  return;
19116
19121
  var successorRangeBeforeMove = new DateRange_1.DateRange(new Date(successorTask.start.getTime()), new Date(successorTask.end.getTime()));
@@ -19282,8 +19287,8 @@ var ValidationController = (function () {
19282
19287
  this.updateChildRangeByParent(taskId, delta, changedTasks);
19283
19288
  if (this.isValidateDependenciesRequired)
19284
19289
  changedTasks.forEach(function (i) {
19285
- _this.moveStartDependTasks(i.id, i.start, true);
19286
- _this.moveEndDependTasks(i.id, i.end, true);
19290
+ _this.moveStartDependTasks(i.id, i.start, taskId);
19291
+ _this.moveEndDependTasks(i.id, i.end, taskId);
19287
19292
  });
19288
19293
  this.updateOwnerInAutoParentMode();
19289
19294
  }
@@ -19646,6 +19651,14 @@ var ViewVisualModel = (function () {
19646
19651
  item = item.parent;
19647
19652
  }
19648
19653
  }
19654
+ else {
19655
+ var task = this.tasks.getItemById(taskId);
19656
+ var parent_1 = this.tasks.getItemById(task === null || task === void 0 ? void 0 : task.parentId);
19657
+ while (parent_1) {
19658
+ result.push(parent_1.id);
19659
+ parent_1 = this.tasks.getItemById(parent_1.parentId);
19660
+ }
19661
+ }
19649
19662
  return result;
19650
19663
  };
19651
19664
  ViewVisualModel.prototype.getDependentTasksHash = function () {
@@ -1,7 +1,7 @@
1
1
  /*!
2
2
  * DevExpress Gantt (dx-gantt.min)
3
- * Version: 4.1.41
4
- * Build date: Mon Jan 30 2023
3
+ * Version: 4.1.43
4
+ * Build date: Thu Mar 30 2023
5
5
  *
6
6
  * Copyright (c) 2012 - 2023 Developer Express Inc. ALL RIGHTS RESERVED
7
7
  * Read about DevExpress licensing here: https://www.devexpress.com/Support/EULAs