@syncfusion/ej2-gantt 20.2.39 → 20.2.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.
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * filename: index.d.ts
3
- * version : 20.2.39
3
+ * version : 20.2.43
4
4
  * Copyright Syncfusion Inc. 2001 - 2020. All rights reserved.
5
5
  * Use of this code is subject to the terms of our license.
6
6
  * A copy of the current license can be obtained at any time by e-mailing
package/package.json CHANGED
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "_from": "@syncfusion/ej2-gantt@*",
3
- "_id": "@syncfusion/ej2-gantt@20.2.38",
3
+ "_id": "@syncfusion/ej2-gantt@20.2.39",
4
4
  "_inBundle": false,
5
- "_integrity": "sha512-Rn0knEwn29g3/0CYudcWWZQSkYbzOvP/Vlbbs+AXZKHQc0b+Kl6TFL+NFY8nuDt/Txt+oP12royOjT2GXqp0aw==",
5
+ "_integrity": "sha512-Hfi4X3srD9FkRRuV7ufhFNi79MR6Pc42eKiD9mkbote2zRiRjBppCutfyU2q745wbc+EFmFz7zoXA4/Za3Q6ww==",
6
6
  "_location": "/@syncfusion/ej2-gantt",
7
7
  "_phantomChildren": {},
8
8
  "_requested": {
@@ -23,8 +23,8 @@
23
23
  "/@syncfusion/ej2-react-gantt",
24
24
  "/@syncfusion/ej2-vue-gantt"
25
25
  ],
26
- "_resolved": "http://nexus.syncfusion.com/repository/ej2-hotfix-new/@syncfusion/ej2-gantt/-/ej2-gantt-20.2.38.tgz",
27
- "_shasum": "14c3049c31d3238a0dff8149dca87874decb2edd",
26
+ "_resolved": "http://nexus.syncfusion.com/repository/ej2-hotfix-new/@syncfusion/ej2-gantt/-/ej2-gantt-20.2.39.tgz",
27
+ "_shasum": "04527bd8b9bd3a5b245fb2223dd6dc9c2ccd93c2",
28
28
  "_spec": "@syncfusion/ej2-gantt@*",
29
29
  "_where": "/jenkins/workspace/automation_release_19.1.0.1-ZPMUBNQ6AUYH6YGEFBPVYMEQLRRW2SLD4XCZ6GATNZJFYJ3RIAOA/packages/included",
30
30
  "author": {
@@ -35,19 +35,19 @@
35
35
  },
36
36
  "bundleDependencies": false,
37
37
  "dependencies": {
38
- "@syncfusion/ej2-base": "~20.2.38",
39
- "@syncfusion/ej2-buttons": "~20.2.38",
40
- "@syncfusion/ej2-calendars": "~20.2.38",
41
- "@syncfusion/ej2-data": "~20.2.38",
42
- "@syncfusion/ej2-dropdowns": "~20.2.39",
43
- "@syncfusion/ej2-grids": "~20.2.39",
44
- "@syncfusion/ej2-inputs": "~20.2.38",
45
- "@syncfusion/ej2-layouts": "~20.2.39",
46
- "@syncfusion/ej2-lists": "~20.2.39",
47
- "@syncfusion/ej2-navigations": "~20.2.39",
48
- "@syncfusion/ej2-popups": "~20.2.39",
49
- "@syncfusion/ej2-richtexteditor": "~20.2.39",
50
- "@syncfusion/ej2-treegrid": "~20.2.39"
38
+ "@syncfusion/ej2-base": "~20.2.43",
39
+ "@syncfusion/ej2-buttons": "~20.2.43",
40
+ "@syncfusion/ej2-calendars": "~20.2.43",
41
+ "@syncfusion/ej2-data": "~20.2.43",
42
+ "@syncfusion/ej2-dropdowns": "~20.2.43",
43
+ "@syncfusion/ej2-grids": "~20.2.43",
44
+ "@syncfusion/ej2-inputs": "~20.2.43",
45
+ "@syncfusion/ej2-layouts": "~20.2.43",
46
+ "@syncfusion/ej2-lists": "~20.2.43",
47
+ "@syncfusion/ej2-navigations": "~20.2.43",
48
+ "@syncfusion/ej2-popups": "~20.2.43",
49
+ "@syncfusion/ej2-richtexteditor": "~20.2.43",
50
+ "@syncfusion/ej2-treegrid": "~20.2.43"
51
51
  },
52
52
  "deprecated": false,
53
53
  "description": "Essential JS 2 Gantt Component",
@@ -75,6 +75,6 @@
75
75
  "url": "git+https://github.com/syncfusion/ej2-gantt.git"
76
76
  },
77
77
  "typings": "index.d.ts",
78
- "version": "20.2.39",
78
+ "version": "20.2.43",
79
79
  "sideEffects": false
80
80
  }
@@ -290,7 +290,7 @@ var ContextMenu = /** @class */ (function () {
290
290
  var rowIndex = -1;
291
291
  if (args.gridRow) {
292
292
  // eslint-disable-next-line
293
- rowIndex = parseInt(args.gridRow.getAttribute('aria-rowindex'), 0);
293
+ rowIndex = parseInt(args.gridRow.getAttribute('data-rowindex'), 0);
294
294
  }
295
295
  else if (args.chartRow) {
296
296
  // eslint-disable-next-line
@@ -75,7 +75,7 @@ var Edit = /** @class */ (function () {
75
75
  if (column.field === this.parent.taskFields.id) {
76
76
  this.updateIDColumnEditParams(column);
77
77
  }
78
- else if (column.field === this.parent.taskFields.progress) {
78
+ else if (column.field === this.parent.taskFields.progress && isNullOrUndefined(column.edit)) {
79
79
  this.updateProgessColumnEditParams(column);
80
80
  }
81
81
  else if (column.field === this.parent.taskFields.resourceInfo) {
@@ -2042,6 +2042,7 @@ var Edit = /** @class */ (function () {
2042
2042
  eventArgs.modifiedRecords = args.updatedRecordCollection;
2043
2043
  eventArgs.modifiedTaskData = getTaskData(args.updatedRecordCollection, null, null, this.parent);
2044
2044
  setValue('action', args.action, eventArgs);
2045
+ this.parent.isOnDelete = false;
2045
2046
  this.parent.trigger('actionComplete', eventArgs);
2046
2047
  this.deletedTaskDetails = [];
2047
2048
  this.parent.initiateEditAction(false);
@@ -132,7 +132,7 @@ var RowDD = /** @class */ (function () {
132
132
  ganttDragelem.remove();
133
133
  }
134
134
  var gridRow = closest(args.target, '.e-row');
135
- var dropIndex = gridRow ? parseInt(gridRow.getAttribute('aria-rowindex'), 10) : args.dropIndex;
135
+ var dropIndex = gridRow ? parseInt(gridRow.getAttribute('data-rowindex'), 10) : args.dropIndex;
136
136
  args.dropIndex = dropIndex;
137
137
  args.dropRecord = this.parent.updatedRecords[args.dropIndex];
138
138
  this.parent.trigger('rowDrop', args);
@@ -199,7 +199,7 @@ var DateProcessor = /** @class */ (function () {
199
199
  if (hour > this.parent.defaultEndTime) {
200
200
  this.setTime(this.parent.defaultEndTime, cloneDate);
201
201
  }
202
- else if (hour <= this.parent.defaultStartTime && !ganttProp.isMilestone) {
202
+ else if (hour <= this.parent.defaultStartTime && !isNullOrUndefined(ganttProp) && !ganttProp.isMilestone) {
203
203
  cloneDate.setDate(cloneDate.getDate() - 1);
204
204
  this.setTime(this.parent.defaultEndTime, cloneDate);
205
205
  }
@@ -1271,7 +1271,13 @@ var DateProcessor = /** @class */ (function () {
1271
1271
  }
1272
1272
  sortDates(taskRange);
1273
1273
  if (!minStartDate || !maxEndDate) {
1274
- minStartDate = isNullOrUndefined(minStartDate) ? this.getDateFromFormat(new Date()) : minStartDate;
1274
+ if (!minStartDate) {
1275
+ minStartDate = isNullOrUndefined(minStartDate) ? this.getDateFromFormat(new Date()) : minStartDate;
1276
+ minStartDate.setHours(0, 0, 0, 0);
1277
+ }
1278
+ else {
1279
+ minStartDate = isNullOrUndefined(minStartDate) ? this.getDateFromFormat(new Date()) : minStartDate;
1280
+ }
1275
1281
  maxEndDate = this.getDateFromFormat(new Date(minStartDate.getTime()));
1276
1282
  maxEndDate.setDate(maxEndDate.getDate() + 20);
1277
1283
  }
@@ -24,6 +24,10 @@ export declare class GanttChart {
24
24
  keyboardModule: KeyboardEvents;
25
25
  targetElement: Element;
26
26
  virtualRender: VirtualContentRenderer;
27
+ isEditableElement: any;
28
+ tempNextElement: any;
29
+ nextElementIndex: any;
30
+ childrenIndex: any;
27
31
  constructor(parent: Gantt);
28
32
  private addEventListener;
29
33
  private renderChartContents;
@@ -718,7 +718,7 @@ var GanttChart = /** @class */ (function () {
718
718
  * @private
719
719
  */
720
720
  GanttChart.prototype.expandedGanttRow = function (args) {
721
- if (isNullOrUndefined(args['gridRow'])) {
721
+ if (isNullOrUndefined(args['gridRow']) && this.parent.enableVirtualization) {
722
722
  return;
723
723
  }
724
724
  var record = getValue('data', args);
@@ -928,6 +928,23 @@ var GanttChart = /** @class */ (function () {
928
928
  $target.closest('.e-chart-row') ? $target.closest('.e-chart-row').rowIndex : -1;
929
929
  var isTab = (e.action === 'tab') ? true : false;
930
930
  var nextElement = this.getNextElement($target, isTab, isInEditedState);
931
+ this.tempNextElement = nextElement;
932
+ if (!isNullOrUndefined(nextElement['cellIndex'])) {
933
+ if (this.parent.allowRowDragAndDrop) {
934
+ this.childrenIndex = nextElement['cellIndex'];
935
+ this.nextElementIndex = nextElement['cellIndex'] - 1;
936
+ }
937
+ else {
938
+ this.childrenIndex = nextElement['cellIndex'];
939
+ this.nextElementIndex = nextElement['cellIndex'];
940
+ }
941
+ if (!this.parent.ganttColumns[this.nextElementIndex]['allowEditing'] && this.parent.ganttColumns[this.nextElementIndex]['field'] !== this.parent.taskFields.id) {
942
+ this.isEditableElement = true;
943
+ }
944
+ else {
945
+ this.isEditableElement = false;
946
+ }
947
+ }
931
948
  if (nextElement === 'noNextRow') {
932
949
  this.manageFocus($target, 'remove', true);
933
950
  return;
@@ -975,7 +992,8 @@ var GanttChart = /** @class */ (function () {
975
992
  this.parent.treeGrid.grid.notify('key-pressed', e);
976
993
  }
977
994
  }
978
- if (!isNullOrUndefined(isInEditedState) && !this.parent.editModule.cellEditModule.isCellEdit) {
995
+ if (!(this.parent.editModule && this.parent.editModule.cellEditModule
996
+ && !isNullOrUndefined(this.parent.editModule.cellEditModule.editedColumn))) {
979
997
  if (nextElement) {
980
998
  if ($target.classList.contains('e-rowcell')) {
981
999
  this.manageFocus($target, 'remove', false);
@@ -99,6 +99,7 @@ var GanttTreeGrid = /** @class */ (function () {
99
99
  };
100
100
  GanttTreeGrid.prototype.composeProperties = function () {
101
101
  this.parent.treeGrid.showColumnMenu = this.parent.showColumnMenu;
102
+ this.parent.treeGrid.enableCollapseAll = this.parent.collapseAllParentTasks;
102
103
  this.parent.treeGrid.columnMenuItems = this.parent.columnMenuItems;
103
104
  this.parent.treeGrid.childMapping = isNullOrUndefined(this.parent.taskFields.child) ? '' : this.parent.taskFields.child;
104
105
  this.parent.treeGrid.treeColumnIndex = this.parent.treeColumnIndex;
@@ -1676,6 +1676,12 @@ var ChartRows = /** @class */ (function (_super) {
1676
1676
  }
1677
1677
  var dataId = this.parent.viewType === 'ProjectView' ? data.ganttProperties.taskId : data.ganttProperties.rowUniqueID;
1678
1678
  this.parent.treeGrid.grid.setRowData(dataId, data);
1679
+ var nextEditableElement = this.parent.ganttChartModule.tempNextElement;
1680
+ if (this.parent.ganttChartModule.isEditableElement && nextEditableElement) {
1681
+ this.parent.treeGrid.grid.focusModule.focus();
1682
+ addClass([this.parent.treeGrid.getRows()[tr['ariaRowIndex']].children[this.parent.ganttChartModule.childrenIndex]], 'e-focused');
1683
+ this.parent.ganttChartModule.tempNextElement = null;
1684
+ }
1679
1685
  var row = this.parent.treeGrid.grid.getRowObjectFromUID(this.parent.treeGrid.grid.getDataRows()[index].getAttribute('data-uid'));
1680
1686
  row.data = data;
1681
1687
  }
@@ -240,7 +240,7 @@ var Tooltip = /** @class */ (function () {
240
240
  if (ganttData) {
241
241
  data = ganttData.ganttProperties;
242
242
  taskName = !isNullOrUndefined(data.taskName) ? '<tr class = "e-gantt-tooltip-rowcell"><td colspan="3">' +
243
- data.taskName + '</td></tr>' : '';
243
+ (this.parent.disableHtmlEncode ? data.taskName.replace(/</g, "&lt;").replace(/>/g, "&gt;") : data.taskName) + '</td></tr>' : '';
244
244
  }
245
245
  switch (elementType) {
246
246
  case 'milestone':