todoman
todoman copied to clipboard
Show subtasks in a better way
It would be great if subtasks would be grouped within their task, e.g. by intending the description or something.
subtasks = use RELATED-TO
Sounds reasonable. :+1:
I won't have time myself to address this, but further discussion around it or PRs are welcome.
Because the Subtasks thing, it seems like the related to field is not stored at the moment? If not where is it, if yes how can I access it ^^ (interested in solving this issue)
~The field is not read or used at all right now; so a first step would likely be adding support to the models to it. models.py is the starting place for that.~
~Once models actually have this field, I guess the Todo
class can have a related()
method that returns related Todo
s. This would likely have to be resolved when loading from the cache or by the List
class.~
Never mind, related
is used right now, though for recurring tasks. Back to the thinkboard.
Oh, unlucky https://github.com/JBenda/todoman/tree/feature/hierarchySupport, there are some thoughts of implementing hierarchy in the cache with nested sets, but it's kind of hard to correctly implement the cache_update, because everything just removes the items, which you can't easily with a hierarchy, because then it will break. So we maybe need to introduce the concept of file update instead of delete insert.
That I implemented a new parent field is then bad luck ^^
The RELATED-TO
field can have a RELTYPE
attribute, which can be PARENT
, CHILD
, SIBLING
or an X-
value.
Having subtasks defined with RELTYPE=PARENT
and/or RELTYPE=CHILD
sounds very reasonable.
In the absence of a RELTYPE
, I would rather not treat them as subtasks, since it may be some other kind of relationship.
For recurrent items, I believe using SIBLING
might make sense, but might be best to use something like RELTYPE=X-RECURRENCE-OF=XZY
.