Skip to content

[IMP] project_ux: show sub-tasks when the "Is Sub-Task" filter is active - #147

Open
les-adhoc wants to merge 1 commit into
ingadhoc:19.0from
adhoc-dev:19.0-t-73273-les
Open

[IMP] project_ux: show sub-tasks when the "Is Sub-Task" filter is active#147
les-adhoc wants to merge 1 commit into
ingadhoc:19.0from
adhoc-dev:19.0-t-73273-les

Conversation

@les-adhoc

Copy link
Copy Markdown
Contributor

What

The "Is Sub-Task" filter (parent_id != False) returned an empty task list whenever the "Show Sub-Tasks" display mode was off, with no hint as to why — so an existing sub-task looked like it did not exist.

Why

The task list model injects display_in_project = True while sub-tasks are hidden. That field is False for any sub-task sharing its parent's project, so combining it with the sub-task filter yields an empty set.

How

  • _processSearchDomain (list/kanban model): when the domain already restricts to sub-tasks, drop the display_in_project leaf so the filter is honored and the sub-tasks show up — no need to toggle the display mode by hand.
  • Control panel: the "Show Sub-Tasks" toggle is reflected as selected while the filter forces sub-tasks visible, avoiding an inconsistent "off but showing" state.

Test plan

  1. Create a task with a sub-task in the same project.
  2. Open the task list with "Show Sub-Tasks" off.
  3. Activate the "Is Sub-Task" filter → the sub-task now appears, and the "Show Sub-Tasks" toggle shows as selected.
  4. Remove the filter → the toggle returns to its stored preference.

The "Is Sub-Task" filter restricts the domain to parent_id != False, but the
task list keeps sub-tasks hidden while the "Show Sub-Tasks" display mode is
off: the model injects display_in_project = True, which is False for any
sub-task sharing its parent's project. The list then comes back empty with no
hint, so the sub-task looks like it does not exist.

When the sub-task filter is active, drop the display_in_project leaf so the
filter is honored and the sub-tasks show up, without requiring the user to
enable the display mode by hand. The "Show Sub-Tasks" toggle is reflected as
selected while the filter forces it, to avoid an inconsistent "off but showing"
state.
@roboadhoc

Copy link
Copy Markdown
Contributor

Pull request status dashboard

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants