Task End date at backend

background : System is loading the tasks and links from the backend api.

For each task there is a start date and duration. And the tasks are interdependent.

e.g. Op 10–& ;Op 20 --; Op 30.

To Be: Using the gantt module the end date of each task should be calculated and using the gantt.createDataProcessor() it should be send back to backend api(through REST put)

Problem Statement: The end date of first operation (e.g. Op 10) is never getting calculated and it is not detected by gantt.createDataProcessor().

However the end date of dependent tasks e.g. Op 20, Op 30 are getting calculated.

Please provide the solution /workaround to calculate the end date of root task.

If the root task is a project task, it is expected behavior.
Project tasks ignore the date parameters(start_date, end_date, duration) and obtain them from the children. So, you don’t need to worry that the end_date is not updated as project tasks should be loaded with the correct dates regardless of the end_date value.
If you still need to have the correct dates in the database, you need to manually implement a custom solution and use the updateTask method on project tasks. Here is an example of how you can do that when loading tasks:
Here are examples of the implementation when you update children tasks:

Thanks for the response. Task is not project type. Let me explain:
we are loading data from excel to backend then we send it to frontend to load data to gantt.
Please refer below picture of project schedule structure. We are not able to get calculated end date for OP10 for every subproject WO-01/WO-02/WO-03 etc. Here almost all tasks are sequentially linked i.e. OP10->OP20->OP30->OP40 like that. End date is calculated and available for OP20 and onward but not for OP10, which is very first task.
Can you please help us on this.

Thank you for the clarification.
It seems that you rely on the auto-scheduling function. When Gantt auto-schedule tasks, only the successor tasks will be changed, so after they are updated, Gantt will send the changes to the server.
For example, in the following snippet, Gantt will send the changes for tasks #2, #3, and #4. As Task #1 was updated, the changes aren’t sent to the server:

To send the changes for each task after loading the chart, you need to update it:

If you have a different use case, please, reproduce the issue in the snippet, then click on the “Share” button and send me the link.