now inheriting due date when child task is created

Signed-off-by: Stephan Richter <s.richter@srsoftware.de>
This commit is contained in:
2025-10-12 00:05:07 +02:00
parent dd84bad070
commit 00df660fb7
2 changed files with 6 additions and 0 deletions

View File

@@ -65,6 +65,11 @@ public class Task implements Mappable {
return this;
}
public Task dueDate(LocalDate newValue) {
dueDate = newValue;
return this;
}
public LocalDate dueDate(){
return dueDate;
}

View File

@@ -355,6 +355,7 @@ public class TaskModule extends BaseHandler implements TaskService {
json.put(MEMBERS, Map.of()); // reset member map for task-to-be-created
Task task = Task.of(json);
if (parentTask != null && parentTask.dueDate() != null && task.dueDate() == null) task.dueDate(parentTask.dueDate());
task = taskDb.save(task);
// do actual member assignment