@syncfusion/ej2-gantt 21.1.41 → 21.2.3
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/CHANGELOG.md +10 -0
- package/dist/ej2-gantt.min.js +2 -2
- package/dist/ej2-gantt.umd.min.js +2 -2
- package/dist/ej2-gantt.umd.min.js.map +1 -1
- package/dist/es6/ej2-gantt.es2015.js +21 -10
- package/dist/es6/ej2-gantt.es2015.js.map +1 -1
- package/dist/es6/ej2-gantt.es5.js +22 -10
- package/dist/es6/ej2-gantt.es5.js.map +1 -1
- package/dist/global/ej2-gantt.min.js +2 -2
- package/dist/global/ej2-gantt.min.js.map +1 -1
- package/dist/global/index.d.ts +1 -1
- package/package.json +20 -23
- package/src/gantt/actions/edit.js +1 -1
- package/src/gantt/actions/taskbar-edit.d.ts +1 -1
- package/src/gantt/actions/taskbar-edit.js +2 -2
- package/src/gantt/base/task-processor.js +2 -2
- package/src/gantt/renderer/chart-rows.js +17 -5
- package/styles/bootstrap-dark.css +3 -0
- package/styles/bootstrap.css +3 -0
- package/styles/bootstrap4.css +3 -0
- package/styles/bootstrap5-dark.css +3 -0
- package/styles/bootstrap5.css +3 -0
- package/styles/fabric-dark.css +3 -0
- package/styles/fabric.css +3 -0
- package/styles/fluent-dark.css +3 -0
- package/styles/fluent.css +3 -0
- package/styles/gantt/_theme.scss +4 -0
- package/styles/gantt/bootstrap-dark.css +3 -0
- package/styles/gantt/bootstrap.css +3 -0
- package/styles/gantt/bootstrap4.css +3 -0
- package/styles/gantt/bootstrap5-dark.css +3 -0
- package/styles/gantt/bootstrap5.css +3 -0
- package/styles/gantt/fabric-dark.css +3 -0
- package/styles/gantt/fabric.css +3 -0
- package/styles/gantt/fluent-dark.css +3 -0
- package/styles/gantt/fluent.css +3 -0
- package/styles/gantt/highcontrast-light.css +3 -0
- package/styles/gantt/highcontrast.css +3 -0
- package/styles/gantt/material-dark.css +3 -0
- package/styles/gantt/material.css +3 -0
- package/styles/gantt/tailwind-dark.css +3 -0
- package/styles/gantt/tailwind.css +3 -0
- package/styles/highcontrast-light.css +3 -0
- package/styles/highcontrast.css +3 -0
- package/styles/material-dark.css +3 -0
- package/styles/material.css +3 -0
- package/styles/tailwind-dark.css +3 -0
- package/styles/tailwind.css +3 -0
|
@@ -3918,13 +3918,13 @@ var TaskProcessor = /** @__PURE__ @class */ (function (_super) {
|
|
|
3918
3918
|
minStartDate.getTime() === maxEndDate.getTime() ? true : false;
|
|
3919
3919
|
if (this.compareDates(previousStartDate, minStartDate) !== 0) {
|
|
3920
3920
|
this.parent.setRecordValue(ganttProp.isAutoSchedule ? 'startDate' : 'autoStartDate', minStartDate, parentData.ganttProperties, true);
|
|
3921
|
-
if ((((!isNullOrUndefined(ganttProp.autoDuration)) ? ganttProp.autoDuration === 0 : ganttProp.duration === 0)) && parentData['isManual'] && milestone) {
|
|
3921
|
+
if ((((!isNullOrUndefined(ganttProp.autoDuration)) ? ganttProp.autoDuration === 0 : ganttProp.duration === 0)) && parentData['isManual'] && milestone && (parentData.hasChildRecords && parentData.ganttProperties.isAutoSchedule && this.parent.editModule.taskbarEditModule.taskbarEditedArgs.action !== "TaskbarEditing")) {
|
|
3922
3922
|
this.parent.setRecordValue('startDate', minStartDate, parentData.ganttProperties, true);
|
|
3923
3923
|
}
|
|
3924
3924
|
}
|
|
3925
3925
|
if (this.compareDates(previousEndDate, maxEndDate) !== 0) {
|
|
3926
3926
|
this.parent.setRecordValue(ganttProp.isAutoSchedule ? 'endDate' : 'autoEndDate', maxEndDate, parentData.ganttProperties, true);
|
|
3927
|
-
if ((((!isNullOrUndefined(ganttProp.autoDuration)) ? ganttProp.autoDuration === 0 : ganttProp.duration === 0)) && parentData['isManual'] && milestone) {
|
|
3927
|
+
if ((((!isNullOrUndefined(ganttProp.autoDuration)) ? ganttProp.autoDuration === 0 : ganttProp.duration === 0)) && parentData['isManual'] && milestone && (parentData.hasChildRecords && parentData.ganttProperties.isAutoSchedule && this.parent.editModule.taskbarEditModule.taskbarEditedArgs.action !== "TaskbarEditing")) {
|
|
3928
3928
|
this.parent.setRecordValue('endDate', maxEndDate, parentData.ganttProperties, true);
|
|
3929
3929
|
}
|
|
3930
3930
|
}
|
|
@@ -9776,7 +9776,7 @@ var ChartRows = /** @__PURE__ @class */ (function (_super) {
|
|
|
9776
9776
|
'<div class="' + manualParentMilestoneBottom + '" style="top:' +
|
|
9777
9777
|
(this.milesStoneRadius) + 'px;border-right-width:' + this.milesStoneRadius + 'px; border-left-width:' +
|
|
9778
9778
|
this.milesStoneRadius + 'px; border-top-width:' + this.milesStoneRadius + 'px;"></div></div>';
|
|
9779
|
-
return this.createDivElement(data.ganttProperties.
|
|
9779
|
+
return this.createDivElement(data.ganttProperties.duration !== 0 ? template : milestoneTemplate);
|
|
9780
9780
|
};
|
|
9781
9781
|
/**
|
|
9782
9782
|
* To get parent taskbar node.
|
|
@@ -9972,7 +9972,7 @@ var ChartRows = /** @__PURE__ @class */ (function (_super) {
|
|
|
9972
9972
|
var template = '<div class="' + taskBarMainContainer + ' ' +
|
|
9973
9973
|
this.parent.getUnscheduledTaskClass(data.ganttProperties) + ' ' +
|
|
9974
9974
|
((data.ganttProperties.cssClass) ? data.ganttProperties.cssClass : '') + '" ' +
|
|
9975
|
-
' tabindex="-1" role="term" style="' + ((data.ganttProperties.isMilestone && !manualParent) ?
|
|
9975
|
+
' tabindex="-1" role="term" style="' + ((data.ganttProperties.isMilestone && !manualParent && !(data.hasChildRecords && !data.ganttProperties.isAutoSchedule)) ?
|
|
9976
9976
|
('width:' + this.milestoneHeight + 'px;height:' +
|
|
9977
9977
|
this.milestoneHeight + 'px;margin-top:' + this.milestoneMarginTop + 'px;' + (this.parent.enableRtl ? 'right:' : 'left:') + (data.ganttProperties.left -
|
|
9978
9978
|
(this.milestoneHeight / 2)) + 'px;') : ('width:' + data.ganttProperties.width +
|
|
@@ -10267,6 +10267,7 @@ var ChartRows = /** @__PURE__ @class */ (function (_super) {
|
|
|
10267
10267
|
* @private
|
|
10268
10268
|
*/
|
|
10269
10269
|
ChartRows.prototype.createTaskbarTemplate = function () {
|
|
10270
|
+
var _a;
|
|
10270
10271
|
var trs = [].slice.call(this.ganttChartTableBody.querySelectorAll('tr'));
|
|
10271
10272
|
this.ganttChartTableBody.innerHTML = '';
|
|
10272
10273
|
var collapsedResourceRecord = [];
|
|
@@ -10297,6 +10298,10 @@ var ChartRows = /** @__PURE__ @class */ (function (_super) {
|
|
|
10297
10298
|
}
|
|
10298
10299
|
}
|
|
10299
10300
|
else {
|
|
10301
|
+
var dupChartBody = void 0;
|
|
10302
|
+
dupChartBody = createElement('tbody', {
|
|
10303
|
+
id: this.parent.element.id + 'GanttTaskTableBody'
|
|
10304
|
+
});
|
|
10300
10305
|
for (var i = 0; i < this.parent.currentViewData.length; i++) {
|
|
10301
10306
|
var tempTemplateData = this.parent.currentViewData[i];
|
|
10302
10307
|
if (this.parent.viewType === 'ResourceView') {
|
|
@@ -10309,9 +10314,9 @@ var ChartRows = /** @__PURE__ @class */ (function (_super) {
|
|
|
10309
10314
|
}
|
|
10310
10315
|
}
|
|
10311
10316
|
var tRow = this.getGanttChartRow(i, tempTemplateData);
|
|
10312
|
-
|
|
10317
|
+
dupChartBody.appendChild(tRow);
|
|
10313
10318
|
if (this.parent.enableImmutableMode) {
|
|
10314
|
-
this.refreshedTr.push(
|
|
10319
|
+
this.refreshedTr.push(dupChartBody.querySelectorAll('tr')[i]);
|
|
10315
10320
|
this.refreshedData.push(this.parent.currentViewData[i]);
|
|
10316
10321
|
}
|
|
10317
10322
|
// To maintain selection when virtualization is enabled
|
|
@@ -10319,6 +10324,7 @@ var ChartRows = /** @__PURE__ @class */ (function (_super) {
|
|
|
10319
10324
|
this.parent.selectionModule.maintainSelectedRecords(parseInt(tRow.getAttribute('aria-rowindex'), 10));
|
|
10320
10325
|
}
|
|
10321
10326
|
}
|
|
10327
|
+
(_a = this.ganttChartTableBody).replaceChildren.apply(_a, dupChartBody.childNodes);
|
|
10322
10328
|
}
|
|
10323
10329
|
this.parent.renderTemplates();
|
|
10324
10330
|
this.triggerQueryTaskbarInfo();
|
|
@@ -10376,9 +10382,15 @@ var ChartRows = /** @__PURE__ @class */ (function (_super) {
|
|
|
10376
10382
|
taskbarContainerNode[0].appendChild([].slice.call(manualTaskbar)[0]);
|
|
10377
10383
|
}
|
|
10378
10384
|
}
|
|
10379
|
-
if (parentTaskbarTemplateNode && parentTaskbarTemplateNode.length > 0) {
|
|
10385
|
+
if ((this.templateData.ganttProperties.autoDuration !== 0) && !this.templateData.ganttProperties.isMilestone && parentTaskbarTemplateNode && parentTaskbarTemplateNode.length > 0) {
|
|
10380
10386
|
taskbarContainerNode[0].appendChild([].slice.call(parentTaskbarTemplateNode)[0]);
|
|
10381
10387
|
}
|
|
10388
|
+
else if ((this.templateData.ganttProperties.duration === 0 && this.templateData.ganttProperties.isMilestone && this.templateData.ganttProperties.isAutoSchedule)) {
|
|
10389
|
+
var milestoneTemplateNode = this.getMilestoneNode(i, taskbarContainerNode);
|
|
10390
|
+
if (milestoneTemplateNode && milestoneTemplateNode.length > 0) {
|
|
10391
|
+
taskbarContainerNode[0].appendChild([].slice.call(milestoneTemplateNode)[0]);
|
|
10392
|
+
}
|
|
10393
|
+
}
|
|
10382
10394
|
if (this.parent.renderBaseline && this.templateData.ganttProperties.baselineStartDate &&
|
|
10383
10395
|
this.templateData.ganttProperties.baselineEndDate) {
|
|
10384
10396
|
taskBaselineTemplateNode = ((this.templateData.ganttProperties.baselineStartDate.getTime() === this.templateData.ganttProperties.baselineEndDate.getTime()) || ((!isNullOrUndefined(this.templateData.ganttProperties.baselineStartDate) && !isNullOrUndefined(this.templateData.ganttProperties.startDate) && (this.templateData.ganttProperties.baselineStartDate.getTime() === this.templateData.ganttProperties.startDate.getTime()))
|
|
@@ -19825,7 +19837,7 @@ var TaskbarEdit = /** @__PURE__ @class */ (function (_super) {
|
|
|
19825
19837
|
: ganttRecord.left;
|
|
19826
19838
|
var tierMode = this.parent.timelineModule.bottomTier !== 'None' ? this.parent.timelineModule.bottomTier :
|
|
19827
19839
|
this.parent.timelineModule.topTier;
|
|
19828
|
-
var remainingContribution = (1 / (this.parent.timelineModule.getIncrement(this.getDateByLeft(left), 1, 'Day') / (1000 * 60 * 60 * 24)));
|
|
19840
|
+
var remainingContribution = (1 / (this.parent.timelineModule.getIncrement(this.getDateByLeft(left, isNullOrUndefined(ganttRecord) ? ganttRecord.isMilestone : null, ganttRecord), 1, 'Day') / (1000 * 60 * 60 * 24)));
|
|
19829
19841
|
var remainDays = this.parent.perDayWidth - (this.parent.perDayWidth / remainingContribution);
|
|
19830
19842
|
var remainDaysInDecimal = remainDays / this.parent.perDayWidth;
|
|
19831
19843
|
if (isRoundOff === undefined) {
|
|
@@ -19873,7 +19885,7 @@ var TaskbarEdit = /** @__PURE__ @class */ (function (_super) {
|
|
|
19873
19885
|
var milliSecondsPerPixel = (24 * 60 * 60 * 1000) / this.parent.perDayWidth;
|
|
19874
19886
|
pStartDate.setTime(pStartDate.getTime() + (left * milliSecondsPerPixel));
|
|
19875
19887
|
/* To render the milestone in proper date while editing */
|
|
19876
|
-
if (isMilestone) {
|
|
19888
|
+
if (isMilestone && !isNullOrUndefined(property.predecessor) && property.predecessor.length > 0) {
|
|
19877
19889
|
pStartDate.setDate(pStartDate.getDate() - 1);
|
|
19878
19890
|
this.parent.dateValidationModule.setTime(this.parent.defaultEndTime, pStartDate);
|
|
19879
19891
|
pStartDate = this.parent.dateValidationModule.checkStartDate(pStartDate, property, true);
|
|
@@ -24776,7 +24788,7 @@ var Edit$2 = /** @__PURE__ @class */ (function () {
|
|
|
24776
24788
|
this.parent.predecessorModule.isValidatedParentTaskID = '';
|
|
24777
24789
|
}
|
|
24778
24790
|
if (this.parent.allowParentDependency && ganttRecord.hasChildRecords && this.parent.previousRecords[ganttRecord.uniqueID].ganttProperties.startDate &&
|
|
24779
|
-
(args.action === "DrawConnectorLine")) {
|
|
24791
|
+
(args.action === "DrawConnectorLine") || (args.action === "DialogEditing")) {
|
|
24780
24792
|
this.updateChildItems(ganttRecord);
|
|
24781
24793
|
}
|
|
24782
24794
|
this.updateParentItemOnEditing();
|