Closed arcady-zherdev closed 1 year ago
The issue reason is skipping of non-working time. Here is a workaround:
Ext,define('MyApp.Task', {
extend : 'Gnt.model.Task',
convertToMilestoneWithoutPropagation : function() {
var me = this,
propagate = false;
if (!me.isMilestone()) {
propagate = me.setStartDateWithoutPropagation(me.getEndDate(), false, false);
var taskStore = me.getTaskStore(true),
scheduleByConstraints = taskStore && taskStore.scheduleByConstraints;
if (scheduleByConstraints) {
me.markForRescheduling();
}
}
return propagate;
}
});
Fixed in Gantt for ExtJS v6.1.20
SampleProject(1).zip Forum post
It can be reproduced in msproject_import sample.
Say the working duration is 8AM ~ 5PM and there is a one day task [2019/4/8 8AM ~ 2019/4/8 5PM). The StartDate should be changed to 2019/4/8 5PM(same with EndDate) when converting it to milestone since the duration of a milestone is zero. But the StartDate is changed to 2019/4/9 8AM actually. Then the converted milestone will be in error state since StartDate(2019/4/9 8AM) is later than EndDate(2019/4/8 5PM)