Internal: Better abstraction for grouping of tasks #920
Closed
Replies: 3 comments 2 replies
-
@MohamedBassem - possibly of interest... |
Beta Was this translation helpful? Give feedback.
2 replies
-
I wrote up some notes on how to finish off the initial refactoring I did of grouping, to start migrating the grouping code to the
|
Beta Was this translation helpful? Give feedback.
0 replies
-
@claremacrae as discussed today, this may be closed =) |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
There are some missing capabilities for
group by
, which are caused by my naive initial implementation.Missing abstraction for the sort order of group headings
Specifically, the biggest behavioural weakness in the current grouping is that all the group names are sorted alphabetically, which is a blocker for grouping by urgency, for example - see the screenshots in: #788.
It also leads to this oddity in the
group by status
docs - just because of the text sort order:Inability to do
group by [blah] reverse
Also, some users would like to reverse the sort order. For example, several people reported that
group by [date]
broke sorting, as they expected.I can'd find the reference, but a couple of people have expected to groups in reverse date order by doing this:
Because sort's job is to sort tasks within groups, now, I was thinking that the right answer would be to do:
Later: here is where I wrote up reverse-grouping-order previously: #780.
Implementation thoughts
These are half-baked, but it's what I've got...
I recently-ish divided out many hundreds of lines of filtering code from
Query
in toDueDateField
etc insrc/Query/Filter/
The reason I called these
Field
rather thanFilter
is that I was hoping to make the next step to migrate the methods fromGroup
andSort
classes in to the various Field classes.Or, to put it another way, I was hoping that the ordering of groups in
group by
could piggy-back off the already-tested code, including reversal, insort by
.Intention/goal;
I would love to make it so that adding a new row to Quick Reference - for a new property - would be a matter of:
Beta Was this translation helpful? Give feedback.
All reactions