Bug 451606

Summary: Date sorting should use sub-tasks in the task view
Product: [Applications] Merkuro Reporter: flyos
Component: generalAssignee: Claudio Cambra <claudio.cambra>
Status: REPORTED ---    
Severity: normal CC: carl
Priority: NOR    
Version First Reported In: 1.0.0   
Target Milestone: ---   
Platform: unspecified   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description flyos 2022-03-17 08:38:35 UTC
SUMMARY
In the "Tasks view", we can sort by "Due date" to have the soonest due task to be printed first. This works well, except when you have sub-tasks. Then, only the due date of the primary task is taken into account. I believe (this can be discussed of course) that this is not the expected behaviour: "due date" sorting is a way to prioritise tasks according to time left for the completion. In that regard, if a sub-task is due TODAY, even if the primary task is due later (or has no due date at all), I would expect the sub-task to appear in the TODAY category.

STEPS TO REPRODUCE
1. Generate a primary task without due date and attach a sub-task with a due date, for example today
2. In the task view, sort by due date

OBSERVED RESULT
Even if the sub-task is due today, it appears in the category in which the primary task belongs (No defined date).

EXPECTED RESULT
In order to see what I need to do e.g. today, I would expect the tasks to be sorted according to the earliest due date of the sub-tasks. This way, if a sub-task is due today, it would appear on top of the task view, for me to realise I have to tackle it, no matter the due date of the primary task.