@syncfusion/ej2-gantt 22.2.9 → 22.2.11

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 : 22.2.9
3
+ * version : 22.2.11
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@22.2.8",
3
+ "_id": "@syncfusion/ej2-gantt@22.2.10",
4
4
  "_inBundle": false,
5
- "_integrity": "sha512-UTHsxz5sv2/7KScjT2IhII+IVw91jejNdGwxmktM3GbTDYh89N27rpHiw6G0P6qReyrWJpteJlMQVmtt2T7iZQ==",
5
+ "_integrity": "sha512-OWQ3upCLGYSsF4wYB0QsSoQeluIk7sjLl13HEb3lTEd3Q5LfasrlDBkdDaoo3P6xzR3lOhZoroCDylkdVah5CA==",
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": "https://nexus.syncfusion.com/repository/ej2-hotfix-new/@syncfusion/ej2-gantt/-/ej2-gantt-22.2.8.tgz",
27
- "_shasum": "4bdb30759d7aef5c6f457046cc7fc9bbe41b42c0",
26
+ "_resolved": "https://nexus.syncfusion.com/repository/ej2-hotfix-new/@syncfusion/ej2-gantt/-/ej2-gantt-22.2.10.tgz",
27
+ "_shasum": "8b0fe3189bee207e9cc43e3712fb1b503c0be83f",
28
28
  "_spec": "@syncfusion/ej2-gantt@*",
29
29
  "_where": "/jenkins/workspace/elease-automation_release_21.1.1/packages/included",
30
30
  "author": {
@@ -35,19 +35,19 @@
35
35
  },
36
36
  "bundleDependencies": false,
37
37
  "dependencies": {
38
- "@syncfusion/ej2-base": "~22.2.9",
38
+ "@syncfusion/ej2-base": "~22.2.10",
39
39
  "@syncfusion/ej2-buttons": "~22.2.9",
40
- "@syncfusion/ej2-calendars": "~22.2.9",
40
+ "@syncfusion/ej2-calendars": "~22.2.11",
41
41
  "@syncfusion/ej2-data": "~22.2.5",
42
- "@syncfusion/ej2-dropdowns": "~22.2.9",
43
- "@syncfusion/ej2-grids": "~22.2.9",
42
+ "@syncfusion/ej2-dropdowns": "~22.2.11",
43
+ "@syncfusion/ej2-grids": "~22.2.11",
44
44
  "@syncfusion/ej2-inputs": "~22.2.9",
45
45
  "@syncfusion/ej2-layouts": "~22.2.9",
46
- "@syncfusion/ej2-lists": "~22.2.9",
47
- "@syncfusion/ej2-navigations": "~22.2.8",
46
+ "@syncfusion/ej2-lists": "~22.2.11",
47
+ "@syncfusion/ej2-navigations": "~22.2.11",
48
48
  "@syncfusion/ej2-notifications": "~22.2.5",
49
- "@syncfusion/ej2-popups": "~22.2.9",
50
- "@syncfusion/ej2-richtexteditor": "~22.2.9",
49
+ "@syncfusion/ej2-popups": "~22.2.11",
50
+ "@syncfusion/ej2-richtexteditor": "~22.2.10",
51
51
  "@syncfusion/ej2-svg-base": "~22.2.8",
52
52
  "@syncfusion/ej2-treegrid": "~22.2.9"
53
53
  },
@@ -74,6 +74,6 @@
74
74
  "url": "git+https://github.com/syncfusion/ej2-gantt.git"
75
75
  },
76
76
  "typings": "index.d.ts",
77
- "version": "22.2.9",
77
+ "version": "22.2.11",
78
78
  "sideEffects": false
79
79
  }
@@ -610,14 +610,68 @@ var CriticalPath = /** @class */ (function () {
610
610
  var criticalPathIds = [];
611
611
  var index;
612
612
  var predecessorFrom;
613
- for (var x = collection.length - 1; x >= 0; x--) {
613
+ var slackindexes = [];
614
+ var indexes = [];
615
+ for (var z = flatRecords.length - 1; z >= 0; z--) {
616
+ if (flatRecords[parseInt(z.toString(), 10)].slack === '0 day') {
617
+ var index1 = flatRecords[parseInt(z.toString(), 10)].index;
618
+ slackindexes.push(index1);
619
+ }
620
+ }
621
+ var num = 0;
622
+ indexes.push(slackindexes[parseInt(num.toString(), 10)]);
623
+ for (var j = 0; j < indexes.length; j++) {
624
+ var i = flatRecords[indexes[parseInt(j.toString(), 10)]].ganttProperties.predecessor;
625
+ if (!isNullOrUndefined(i)) {
626
+ for (var f = i.length - 1; f >= 0; f--) {
627
+ if (this.parent.viewType === 'ProjectView') {
628
+ var q = modelRecordIds.indexOf(i[parseInt(f.toString(), 10)]['from']);
629
+ for (var k = 0; k < indexes.length; k++) {
630
+ var item = indexes[parseInt(j.toString(), 10)];
631
+ if (item !== q) {
632
+ indexes.push(q);
633
+ }
634
+ break;
635
+ }
636
+ }
637
+ else {
638
+ var q = this.resourceCollectionIds.indexOf(i[parseInt(f.toString(), 10)]['from']);
639
+ for (var k = 0; k < indexes.length; k++) {
640
+ var item = indexes[parseInt(j.toString(), 10)];
641
+ if (item !== q) {
642
+ indexes.push(q);
643
+ }
644
+ break;
645
+ }
646
+ }
647
+ }
648
+ }
649
+ }
650
+ for (var x = 0; x < indexes.length; x++) {
614
651
  if (this.parent.viewType === 'ProjectView') {
615
- index = modelRecordIds.indexOf(collection[x]['taskid'].toString());
652
+ index = modelRecordIds.indexOf(flatRecords[indexes[parseInt(x.toString(), 10)]]['ganttProperties']['taskId'].toString());
616
653
  }
617
654
  else {
618
- index = this.resourceCollectionIds.indexOf(collection[x]['taskid'].toString());
655
+ index = this.resourceCollectionIds.indexOf(flatRecords[indexes[parseInt(x.toString(), 10)]]['TaskID'].toString());
619
656
  }
620
657
  var predecessorLength = flatRecords[index].ganttProperties.predecessor;
658
+ if (isNullOrUndefined(predecessorLength)) {
659
+ if (taskBeyondEnddate.length > 0) {
660
+ for (var i = 0; i < taskBeyondEnddate.length; i++) {
661
+ if (this.parent.viewType === 'ProjectView') {
662
+ index = modelRecordIds.indexOf(taskBeyondEnddate[i].toString());
663
+ }
664
+ else {
665
+ index = this.resourceCollectionIds.indexOf(taskBeyondEnddate[i].toString());
666
+ }
667
+ if (index !== -1 && flatRecords[index].ganttProperties.progress < 100) {
668
+ this.criticalTasks.push(flatRecords[index]);
669
+ criticalPathIds = criticalPathIds.concat(taskBeyondEnddate[i]);
670
+ }
671
+ }
672
+ }
673
+ break;
674
+ }
621
675
  var noSlackValue = 0 + ' ' + flatRecords[index].ganttProperties.durationUnit;
622
676
  for (var i = predecessorLength.length - 1; i >= 0; i--) {
623
677
  var toID = void 0;
@@ -681,21 +735,8 @@ var CriticalPath = /** @class */ (function () {
681
735
  flatRecords[index].isCritical = true;
682
736
  flatRecords[index].ganttProperties.isCritical = true;
683
737
  this.criticalTasks.push(flatRecords[index]);
684
- criticalPathIds.push(collection[x]['taskid']);
685
- }
686
- }
687
- }
688
- if (taskBeyondEnddate.length > 0) {
689
- for (var i = 0; i < taskBeyondEnddate.length; i++) {
690
- if (this.parent.viewType === 'ProjectView') {
691
- index = modelRecordIds.indexOf(taskBeyondEnddate[i].toString());
692
- }
693
- else {
694
- index = this.resourceCollectionIds.indexOf(taskBeyondEnddate[i].toString());
695
- }
696
- if (index !== -1 && flatRecords[index].ganttProperties.progress < 100) {
697
- this.criticalTasks.push(flatRecords[index]);
698
- criticalPathIds = criticalPathIds.concat(taskBeyondEnddate[i]);
738
+ var num_1 = flatRecords[parseInt(index.toString(), 10)]['ganttProperties']['taskId'];
739
+ criticalPathIds.push(num_1);
699
740
  }
700
741
  }
701
742
  }
@@ -2137,7 +2137,7 @@ var DialogEdit = /** @class */ (function () {
2137
2137
  }
2138
2138
  }
2139
2139
  else {
2140
- this.parent.editModule.addRecord(this.addedRecord, this.parent.editSettings.newRowPosition);
2140
+ this.parent.editModule.addRecord(this.addedRecord, this.parent.editSettings.newRowPosition, this.parent.selectedRowIndex);
2141
2141
  }
2142
2142
  }
2143
2143
  return true;
@@ -1334,7 +1334,7 @@ var Edit = /** @class */ (function () {
1334
1334
  this.parent.timelineModule.updateTimeLineOnEditing([tempArray], args.action);
1335
1335
  }
1336
1336
  if (this.parent.viewType === 'ResourceView') {
1337
- if (args.action === 'TaskbarEditing') {
1337
+ if (args.action === 'TaskbarEditing' || args.action === 'DrawConnectorLine') {
1338
1338
  this.updateSharedTask(args.data);
1339
1339
  }
1340
1340
  else if (args.action === 'DialogEditing' || args.action === 'CellEditing' || args.action === 'methodUpdate') {
@@ -276,8 +276,13 @@ var Filter = /** @class */ (function () {
276
276
  break;
277
277
  }
278
278
  if (!isNullOrUndefined(this.parent.element.parentNode)) {
279
+ if (parentNode.parentNode instanceof HTMLDocument) {
280
+ break;
281
+ }
279
282
  parentNode = parentNode.parentNode;
280
- marginTop = parentNode.parentNode.style.marginTop;
283
+ if (parentNode.parentNode && parentNode.parentNode.style) {
284
+ marginTop = parentNode.parentNode.style.marginTop;
285
+ }
281
286
  }
282
287
  parentNodeTop = parentNode.getBoundingClientRect().top;
283
288
  }
@@ -143,7 +143,7 @@ var FocusModule = /** @class */ (function () {
143
143
  }
144
144
  else if (isNullOrUndefined(document.getElementById(this.parent.element.id + '_dialog'))) {
145
145
  e.preventDefault();
146
- ganttObj.addRecord(undefined, this.parent.editSettings.newRowPosition);
146
+ ganttObj.addRecord(undefined, this.parent.editSettings.newRowPosition, this.parent.selectedRowIndex);
147
147
  var focussedElement = ganttObj.element;
148
148
  focussedElement.focus();
149
149
  }
@@ -838,6 +838,9 @@ var Gantt = /** @class */ (function (_super) {
838
838
  this.splitterModule.splitterPreviousPositionChart = pane2.scrollWidth + 1 + 'px';
839
839
  this.splitterModule.splitterObject.paneSettings[0].size = this.splitterModule['getSpliterPositionInPercentage'](this.splitterModule.splitterPreviousPositionGrid);
840
840
  this.splitterModule.splitterObject.paneSettings[1].size = this.splitterModule.splitterPreviousPositionChart;
841
+ if (this.timelineModule.isZoomToFit) {
842
+ this.timelineModule.processZoomToFit();
843
+ }
841
844
  }
842
845
  };
843
846
  Gantt.prototype.keyActionHandler = function (e) {
@@ -3259,8 +3262,8 @@ var Gantt = /** @class */ (function (_super) {
3259
3262
  if (!isNullOrUndefined(taskfields.dependency)) {
3260
3263
  data[taskfields.dependency] = null;
3261
3264
  }
3262
- var position = 'Below';
3263
- this.addRecord(data, position);
3265
+ var position = this.editSettings.newRowPosition;
3266
+ this.addRecord(data, position, this.selectedRowIndex);
3264
3267
  }
3265
3268
  else {
3266
3269
  if (!rowData.hasChildRecords && !rowData.ganttProperties.isMilestone) {
@@ -62,8 +62,12 @@ var Splitter = /** @class */ (function () {
62
62
  },
63
63
  resizing: function (args) {
64
64
  _this.parent.trigger('splitterResizing', args);
65
+ if (_this.parent.timelineModule.isZoomToFit) {
66
+ _this.parent.timelineModule.updateTimelineAfterZooming(_this.parent.timelineModule.timelineEndDate, true);
67
+ }
65
68
  },
66
69
  resizeStop: function (args) {
70
+ _this.parent['calculateDimensions']();
67
71
  var leftPane = args.pane[0];
68
72
  _this.splitterPreviousPositionGrid = leftPane.scrollWidth + 1 + 'px';
69
73
  _this.splitterObject.paneSettings[0].size = _this.getSpliterPositionInPercentage(_this.splitterPreviousPositionGrid);
@@ -457,9 +457,9 @@ var TaskProcessor = /** @class */ (function (_super) {
457
457
  }
458
458
  else {
459
459
  var uniqueId = ganttData.uniqueID.replace(this.parent.element.id + '_data_', '');
460
- if (this.parent.viewType === 'ResourceView' && typeof (ganttData.ganttProperties.taskId) === "string") {
461
- uniqueId = ganttProperties.taskId.toString();
462
- }
460
+ // if (this.parent.viewType === 'ResourceView' && typeof(ganttData.ganttProperties.taskId) === "string") {
461
+ // uniqueId = ganttProperties.taskId.toString();
462
+ // }
463
463
  this.parent.setRecordValue('rowUniqueID', uniqueId, ganttData);
464
464
  this.parent.setRecordValue('rowUniqueID', uniqueId, ganttProperties, true);
465
465
  this.parent.setRecordValue('sharedTaskUniqueIds', [], ganttProperties, true);
@@ -1,4 +1,4 @@
1
- @import url("https://fonts.googleapis.com/css?family=Roboto:400,500");
1
+ @import url("https://fonts.googleapis.com/css?family=Roboto:400,500,700");
2
2
  .e-ddl.e-control-wrapper .e-ddl-icon::before {
3
3
  transform: rotate(0deg);
4
4
  transition: transform 300ms ease;
@@ -1,4 +1,4 @@
1
- @import url("https://fonts.googleapis.com/css?family=Roboto:400,500");
1
+ @import url("https://fonts.googleapis.com/css?family=Roboto:400,500,700");
2
2
  .e-ddl.e-control-wrapper .e-ddl-icon::before {
3
3
  transform: rotate(0deg);
4
4
  transition: transform 300ms ease;