а

Gantt doesn't update after lag update


#1

When I change the lag for a link, the gantt does not update. However, if I change the dependency type of the lag, it works fine.

I am using the PRO version of the gantt. I have auto_scheduling and auto_scheduling_strict set to true.

I have a custom modal for updating links using the ‘onLinkDblClick’ that updates the link with the given values:

const link = gantt.getLink(id);
link.type = dependencyType;
link.lag = lag;
gantt.updateLink(link.id);

If I look at gantt.getLinks() before and after the update, I see that the link value updates correctly (the lag value changes). However, the task does not get re-scheduled on the gantt.

I added the onAfterAutoSchedule event and added a console.log(taskId) to make sure it was working. It printed {taskID: 2}, so I know that auto schedule is running but not doing anything.

Do you have any suggestions of how to further debug this and get tasks to update when their links’ lag changes?


#2

Hello Glen,
We received your ticket in the support system. Let’s discuss the question there, and here we can post the final solution.


#3

Hi, ramil, may i know the solution, could you help to send me a mail, Thanks.


#4

Hello Weis,
I couldn’t reproduce the issue on the client-side:


http://snippet.dhtmlx.com/07c6aa644

Do you have the lag column in the database? If you don’t have it, that parameter won’t be saved on the server-side.


#5

Hi ramil,

I mean when I drag the task the lag between two tasks not update, is that need to manually update it by gantt.getLinks()?