Difference between dates

Hi, I have many tasks with start and end date with the same date. e.g: start_date: 03/12/2018 and end_date: 03/12/2018. The difference between them is 0 (in duration), but as we work here, the difference between those dates need to be 1. How can I handle this configuration?

Hello,
It happens because the duration is not inclusive. And Gantt doesn’t have a built-in feature to change that behaviour. But there are various ways to implement that using Gantt API and Javascript.
One of the easiest is to subtract 1 minute from the task’s end_date before updating the task:
http://snippet.dhtmlx.com/a73af08c3

Update:
Please check the following article that explains what you can do to show inclusive dates in Gantt:
https://docs.dhtmlx.com/gantt/desktop__loading.html#taskenddatedisplayampinclusiveenddates

1 Like

Thank you so much! I did what you said and it was the solution.