Hi,
We are using DHTMLX Gantt with Angular and using inline editing. As per the design, working days are configurable and we are having an issue when Monday to Friday are working days and Saturday and Sunday are non working days.
The issue is, when we adjusting the duration, if the task ends on Monday, end date control displays it as Saturday (this is happening for all weeks). Refer below screenshot.
Could you please help us to resolve this issue.
Duration editor is configured as below.
export const DURATION_EDITOR = { type: ‘number’, map_to: ‘duration’, min: 0, max: 5000 };
Duration template is configured as below.
private adjustTaskDurationTemplate(task: GanttTaskInfo): string {
task.duration = Math.floor(task.duration);
return ‘
}
End date editor is configured as below.
export const END_DATE_EDITOR = { type: ‘date’, map_to: ‘end_date’ };
End date template is configured as below.
private displayEndDateTemplate(task: GanttTaskInfo): string {
return ‘
}
Working days are configured as below.
gantt.config.xml_date = “%d-%m-%Y”;
antt.config.work_time = true;
gantt.setWorkTime({ hours: [“8:00-16:00”] });
gantt.config.duration_unit = “day”;
gantt.setWorkTime({ day: 1, hours: true });
gantt.setWorkTime({ day: 2, hours: true });
gantt.setWorkTime({ day: 3, hours: true });
gantt.setWorkTime({ day: 4, hours: true });
gantt.setWorkTime({ day: 5, hours: true });
gantt.setWorkTime({ day: 6, hours: false });
gantt.setWorkTime({ day: 0, hours: false });
Thank you.