I have created a task update script in my RS TaskGroup server. It should modify a tasks value, everytime the task is updated. Unfortunately it does not update the task.
function Handle_Before_UpdateTask (UpdatedTask, OrigTask)
{
UpdatedTask.progress = 0;
rstg.updateTask (UpdatedTask);
return true;
}
You should not call rstg.updateTask inside the "handle"-functions. It should only be used on tasks read from the database, for example via rstg.getTaskById. See documentation https://www.raikosoft.de/script-api/rstg/
You can simply skip rstg.updateTask on the task represented by the UpdatedTask parameter. The server automatically applies your changes to this task before storing it into the database.