@syncfusion/ej2-gantt 24.2.6 → 24.2.7

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 : 24.2.6
3
+ * version : 24.2.7
4
4
  * Copyright Syncfusion Inc. 2001 - 2023. 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@24.2.5",
3
+ "_id": "@syncfusion/ej2-gantt@24.2.6",
4
4
  "_inBundle": false,
5
- "_integrity": "sha512-LV2u4unQ+4SPXAAD+vRWowCxYnbQBTm3FMvNZx39ND/phnXf/SzFVT5ARWku3pPpwvxj4/9LhCOmMKwViYYNYQ==",
5
+ "_integrity": "sha512-X2u9gA4L3DyIe+tijmv/uYOaj/8YppYXjTnea4l5rBrqvx5SQSKxP67rI41ekq6VMAqhSFkwcjvm2sNcdfLKGw==",
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.syncfusioninternal.com/repository/ej2-hotfix-new/@syncfusion/ej2-gantt/-/ej2-gantt-24.2.5.tgz",
27
- "_shasum": "29042207067b2db658b74a56b58e763baa69f347",
26
+ "_resolved": "https://nexus.syncfusioninternal.com/repository/ej2-hotfix-new/@syncfusion/ej2-gantt/-/ej2-gantt-24.2.6.tgz",
27
+ "_shasum": "7e7ad57f3c6a2bda1014a76f45f1af11d563d364",
28
28
  "_spec": "@syncfusion/ej2-gantt@*",
29
29
  "_where": "/jenkins/workspace/elease-automation_release_24.1.1/packages/included",
30
30
  "author": {
@@ -35,21 +35,21 @@
35
35
  },
36
36
  "bundleDependencies": false,
37
37
  "dependencies": {
38
- "@syncfusion/ej2-base": "~24.2.5",
39
- "@syncfusion/ej2-buttons": "~24.2.5",
38
+ "@syncfusion/ej2-base": "~24.2.7",
39
+ "@syncfusion/ej2-buttons": "~24.2.7",
40
40
  "@syncfusion/ej2-calendars": "~24.2.5",
41
41
  "@syncfusion/ej2-data": "~24.2.3",
42
- "@syncfusion/ej2-dropdowns": "~24.2.6",
43
- "@syncfusion/ej2-grids": "~24.2.5",
44
- "@syncfusion/ej2-inputs": "~24.2.6",
42
+ "@syncfusion/ej2-dropdowns": "~24.2.7",
43
+ "@syncfusion/ej2-grids": "~24.2.7",
44
+ "@syncfusion/ej2-inputs": "~24.2.7",
45
45
  "@syncfusion/ej2-layouts": "~24.2.4",
46
46
  "@syncfusion/ej2-lists": "~24.2.4",
47
47
  "@syncfusion/ej2-navigations": "~24.2.4",
48
48
  "@syncfusion/ej2-notifications": "~24.2.4",
49
49
  "@syncfusion/ej2-popups": "~24.2.5",
50
- "@syncfusion/ej2-richtexteditor": "~24.2.4",
50
+ "@syncfusion/ej2-richtexteditor": "~24.2.7",
51
51
  "@syncfusion/ej2-svg-base": "~24.2.3",
52
- "@syncfusion/ej2-treegrid": "~24.2.5"
52
+ "@syncfusion/ej2-treegrid": "~24.2.7"
53
53
  },
54
54
  "deprecated": false,
55
55
  "description": "Essential JS 2 Gantt Component",
@@ -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": "24.2.6",
77
+ "version": "24.2.7",
78
78
  "sideEffects": false
79
79
  }
@@ -183,6 +183,9 @@ var ConnectorLineEdit = /** @class */ (function () {
183
183
  var match = [];
184
184
  for (var j = 0; j < preArray.length; j++) {
185
185
  var strArray = [];
186
+ var firstPart = void 0;
187
+ var isAlpha = false;
188
+ var predecessorName = void 0;
186
189
  var isGUId = false;
187
190
  var regex = /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/;
188
191
  var elSplit = preArray[j].split('-');
@@ -197,6 +200,26 @@ var ConnectorLineEdit = /** @class */ (function () {
197
200
  isGUId = true;
198
201
  }
199
202
  }
203
+ if (preArray[j].includes('-')) {
204
+ if (preArray[j].includes('-') && preArray[j].includes('days')) {
205
+ predecessorName = preArray[j].slice(-9).toString();
206
+ }
207
+ if (preArray[j].includes('-') && preArray[j].includes('day')) {
208
+ predecessorName = preArray[j].slice(-8).toString();
209
+ }
210
+ else {
211
+ predecessorName = preArray[j].slice(-2).toString();
212
+ }
213
+ if (preArray[j].includes('-') && /[A-Za-z]/.test(predecessorName)) {
214
+ var indexFS = preArray[j].indexOf(predecessorName);
215
+ if (indexFS !== -1) {
216
+ firstPart = preArray[j].substring(0, indexFS);
217
+ if (firstPart.includes('-')) {
218
+ isAlpha = true;
219
+ }
220
+ }
221
+ }
222
+ }
200
223
  if (isGUId) {
201
224
  var split = void 0;
202
225
  split = elSplit[4].split('+');
@@ -224,11 +247,16 @@ var ConnectorLineEdit = /** @class */ (function () {
224
247
  }
225
248
  }
226
249
  else {
227
- values = preArray[j].split('+');
228
- offsetValue = '+';
229
- if (preArray[j].indexOf('-') >= 0) {
230
- values = preArray[j].split('-');
231
- offsetValue = '-';
250
+ if (isAlpha && firstPart.includes('-')) {
251
+ values[0] = firstPart;
252
+ }
253
+ else {
254
+ values = preArray[j].split('+');
255
+ offsetValue = '+';
256
+ if (preArray[j].indexOf('-') >= 0) {
257
+ values = preArray[j].split('-');
258
+ offsetValue = '-';
259
+ }
232
260
  }
233
261
  }
234
262
  if (!isNullOrUndefined(values[0])) {
@@ -43,7 +43,7 @@ var Dependency = /** @class */ (function () {
43
43
  for (var c = 0; c < predecessorVal.length; c++) {
44
44
  var predecessorItem = predecessorVal[c];
45
45
  var preValue = {};
46
- preValue.from = getValue('from', predecessorItem);
46
+ preValue.from = getValue('from', predecessorItem) ? getValue('from', predecessorItem) : predecessorVal[c];
47
47
  preValue.to = getValue('to', predecessorItem) ? getValue('to', predecessorItem) : ganttProp.rowUniqueID;
48
48
  preValue.type = getValue('type', predecessorItem) ? getValue('type', predecessorItem) : 'FS';
49
49
  var offsetUnits = getValue('offset', predecessorItem);
@@ -129,6 +129,9 @@ var Dependency = /** @class */ (function () {
129
129
  var predecessorText;
130
130
  predecessor.split(',').forEach(function (el) {
131
131
  var isGUId = false;
132
+ var firstPart;
133
+ var predecessorName;
134
+ var isAlpha = false;
132
135
  var regex = /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/;
133
136
  var elSplit = el.split('-');
134
137
  var id;
@@ -142,6 +145,26 @@ var Dependency = /** @class */ (function () {
142
145
  isGUId = true;
143
146
  }
144
147
  }
148
+ if (el.includes('-')) {
149
+ if (el.includes('-') && el.includes('days')) {
150
+ predecessorName = el.slice(-9).toString();
151
+ }
152
+ if (el.includes('-') && el.includes('day')) {
153
+ predecessorName = el.slice(-8).toString();
154
+ }
155
+ else {
156
+ predecessorName = el.slice(-2).toString();
157
+ }
158
+ if (el.includes('-') && /[A-Za-z]/.test(predecessorName)) {
159
+ var indexFS = el.indexOf(predecessorName);
160
+ if (indexFS !== -1) {
161
+ firstPart = el.substring(0, indexFS);
162
+ if (firstPart.includes('-')) {
163
+ isAlpha = true;
164
+ }
165
+ }
166
+ }
167
+ }
145
168
  if (isGUId) {
146
169
  var split = void 0;
147
170
  split = elSplit[4].split('+');
@@ -170,11 +193,16 @@ var Dependency = /** @class */ (function () {
170
193
  }
171
194
  }
172
195
  else {
173
- values = el.split('+');
174
- offsetValue = '+';
175
- if (el.indexOf('-') >= 0) {
176
- values = el.split('-');
177
- offsetValue = '-';
196
+ if (isAlpha && firstPart.includes('-')) {
197
+ values[0] = firstPart;
198
+ }
199
+ else {
200
+ values = el.split('+');
201
+ offsetValue = '+';
202
+ if (el.indexOf('-') >= 0) {
203
+ values = el.split('-');
204
+ offsetValue = '-';
205
+ }
178
206
  }
179
207
  }
180
208
  match = [];
@@ -212,6 +240,16 @@ var Dependency = /** @class */ (function () {
212
240
  predecessorText = 'FS';
213
241
  }
214
242
  }
243
+ else if (el.includes('-') && /[A-Za-z]/.test(predecessorName) && firstPart.includes('-')) {
244
+ var type = el.slice(-2).toString();
245
+ type.toUpperCase();
246
+ if (type === 'FS' || type === 'FF' || type === 'SF' || type === 'SS') {
247
+ predecessorText = type;
248
+ }
249
+ else {
250
+ predecessorText = 'FS';
251
+ }
252
+ }
215
253
  else {
216
254
  predecessorText = 'FS';
217
255
  }
@@ -2646,7 +2646,7 @@ var DialogEdit = /** @class */ (function () {
2646
2646
  }
2647
2647
  }
2648
2648
  else {
2649
- if (fieldName === "Duration") {
2649
+ if (fieldName === this.parent.taskFields.duration) {
2650
2650
  var numericValue = parseFloat(String(controlObj.value));
2651
2651
  ;
2652
2652
  tasksData[fieldName] = numericValue;
@@ -1075,9 +1075,16 @@ var DateProcessor = /** @class */ (function () {
1075
1075
  DateProcessor.prototype.convert = function (date, timezone) {
1076
1076
  var fromOffset = date.getTimezoneOffset();
1077
1077
  var toOffset = this.offset(date, timezone);
1078
- date = new Date(date.getTime() + (fromOffset - toOffset) * 60000);
1079
- var toLocalOffset = date.getTimezoneOffset();
1080
- return new Date(date.getTime() + (toLocalOffset - fromOffset) * 60000);
1078
+ if (fromOffset < 0) {
1079
+ date = new Date(date.getTime() - (fromOffset - toOffset) / 60000);
1080
+ var toLocalOffset = date.getTimezoneOffset();
1081
+ return new Date(date.getTime() - (toLocalOffset - fromOffset) / 60000);
1082
+ }
1083
+ else {
1084
+ date = new Date(date.getTime() + (fromOffset - toOffset) * 60000);
1085
+ var toLocalOffset = date.getTimezoneOffset();
1086
+ return new Date(date.getTime() + (toLocalOffset - fromOffset) * 60000);
1087
+ }
1081
1088
  };
1082
1089
  /**
1083
1090
  * @param {string | Date} date .
@@ -1264,7 +1264,12 @@ var TaskProcessor = /** @class */ (function (_super) {
1264
1264
  return ((this.getTimeDifference(sDate, eDate, true) / (1000 * 60 * 60 * 24)) * this.parent.perDayWidth);
1265
1265
  }
1266
1266
  else {
1267
- return ((this.getTimeDifference(sDate, eDate) / (1000 * 60 * 60 * hour)) * this.parent.perDayWidth);
1267
+ if (ganttData.durationUnit === "day" && ganttData.duration < 1 && isNullOrUndefined(this.parent.taskFields.duration)) {
1268
+ return (ganttData.duration * this.parent.perDayWidth);
1269
+ }
1270
+ else {
1271
+ return ((this.getTimeDifference(sDate, eDate) / (1000 * 60 * 60 * hour)) * this.parent.perDayWidth);
1272
+ }
1268
1273
  }
1269
1274
  }
1270
1275
  }
@@ -1275,6 +1280,7 @@ var TaskProcessor = /** @class */ (function (_super) {
1275
1280
  }
1276
1281
  if (this.getSecondsInDecimal(eDate) === this.parent.defaultEndTime) {
1277
1282
  eDate.setHours(24);
1283
+ eDate.setHours(0, 0, 0, 0);
1278
1284
  }
1279
1285
  if (this.getSecondsInDecimal(eDate) === this.parent.defaultStartTime) {
1280
1286
  eDate.setHours(0, 0, 0, 0);
@@ -424,7 +424,7 @@ var GanttTreeGrid = /** @class */ (function () {
424
424
  this.currentEditRow = {};
425
425
  }
426
426
  }
427
- if (getValue('requestType', args) === 'filterafteropen') {
427
+ if (getValue('requestType', args) === 'filterAfterOpen') {
428
428
  this.parent.notify('actionComplete', args);
429
429
  }
430
430
  if (getValue('requestType', args) === 'searching') {