feat: add drill-down filters for data table date and org unit columns [PR6] - #3736
Open
BRaimbault wants to merge 17 commits into
Open
BRaimbault wants to merge 17 commits into
BRaimbault wants to merge 17 commits into
Conversation
Contributor
|
🚀 Deployed on https://pr-3736.maps.netlify.dhis2.org |
BRaimbault
force-pushed
the
feat/datatable-pr6-new-filters
branch
from
July 27, 2026 15:00
5ad158e to
ea5c6d8
Compare
BRaimbault
marked this pull request as ready for review
August 4, 2026 15:22
edoardo
force-pushed
the
feat/datatable-pr6-new-filters
branch
from
August 24, 2026 09:55
8c95a68 to
3f068fc
Compare
HendrikThePendric
requested changes
Aug 24, 2026
HendrikThePendric
left a comment
Contributor
There was a problem hiding this comment.
I think there are some fundamental issues with the org-unit fetch side of this PR. Normally a path has the unit's own ID in it, but this PR seems to assume it stops at the parent.
BRaimbault
force-pushed
the
feat/datatable-pr6-new-filters
branch
from
September 1, 2026 10:27
3f068fc to
5586866
Compare
BRaimbault
force-pushed
the
feat/datatable-pr6-new-filters
branch
from
September 7, 2026 10:23
5586866 to
f225f4b
Compare
Collaborator
Author
|
Thanks for your review @HendrikThePendric, I addressed your specific comments and marked them as resolved. The |
BRaimbault
removed this pull request from stack #3735
September 9, 2026 08:34
BRaimbault
added this pull request to stack #3765
September 9, 2026 08:34
BRaimbault
force-pushed
the
feat/datatable-pr6-new-filters
branch
from
September 9, 2026 08:36
67dc16f to
74c21ee
Compare
…filtered, and a richer selection filter
…cate lookup fetch
Same drift as prior rebases: the merge driver's timestamp-only resolutions left message entries stale relative to the merged source. Re-run the extraction to bring it back in sync.
useOrgUnitAncestorNames flattened every ancestor id out of every org unit path and fetched a name for all of them, including a row's own org unit (already have its name) and its immediate parent (already have parentName) - for a facility layer, that's the vast majority of the distinct-id set, since self+immediate-parent dominate a typical many-leaves/few-ancestors hierarchy. Seed idToName from data already in memory via buildKnownOrgUnitNames, and only fetch what's still missing. Also add a module-level session cache so a name fetched once is never re-fetched for the rest of the session, even across unrelated table views. Safe for event/tracked-entity layers without any special-casing: attachOrgUnitPaths never sets name/parentName on those rows, and an event/entity's own id never collides with an org-unit id actually being looked up, so buildKnownOrgUnitNames naturally contributes nothing for them - confirmed by its own test coverage.
BRaimbault
force-pushed
the
feat/datatable-pr6-new-filters
branch
from
September 10, 2026 12:49
74c21ee to
589879e
Compare
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



Part of DHIS2-21456
Description
Replaces the flat value-list filter with a hierarchical drill-down popover for date/time and org unit data table columns:
useOrgUnitAncestorNameshook.useGroupFilterInputhook andGroupFilterPopoverpresentational component (extracted mid-PR from two near-duplicate implementations), plus a genericprefixTree.jsutility for building/flattening/search-matching the tree.Also included, found while reworking org unit columns:
parentName/ouname).true/false.createdAt/updatedAtexposed as columns.Quality checklist
Add N/A to items that are not applicable.
Screenshots
supporting images