Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: enable ou tree and levels/groups with user orgunits and display decent title (DHIS2-18066) #1702

Merged
merged 9 commits into from
Nov 22, 2024

Conversation

janhenrikoverland
Copy link
Collaborator

@janhenrikoverland janhenrikoverland commented Sep 23, 2024

Implements DHIS2-18066


Description

The ability to combine the ou tree and levels/groups with user orgunits is a very powerful and useful feature for users. This was supported earlier, but it was enable due to problems with e.g. priting labels in a meaningful way.

We have decided to re-enable this feature as users really want need it. A fix has been included so that the filter title in pivot tables at least says e.g. "Facility level in User organisation unit" instead of "Facility level in USER_ORG_UNIT".


TODO

  • Manual testing

Screenshots

Before - Org unit selector - When User organisation unit is selected, the tree and levels/groups get disabled):
Screenshot from 2024-09-23 12-29-37

After - Org unit selector - All option enabled:
Screenshot from 2024-09-23 12-29-49

After - Org unit selector - All three user orgunit options selected and a level:
Screenshot from 2024-09-23 12-30-26

Copy link
Collaborator

@jenniferarnesen jenniferarnesen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add jest tests for both OrgUnitDimension and getOuLevelAndGroupText. (Copilot can help, also look at PeriodDimension for doing a test on a component)

@janhenrikoverland janhenrikoverland changed the title fix: enable ou tree and levels/groups with user orgunits and display decent title fix: enable ou tree and levels/groups with user orgunits and display decent title (DHIS2-18066) Oct 10, 2024
@jenniferarnesen
Copy link
Collaborator

I'm pretty sure you can remove the mocks from the test.

@janhenrikoverland janhenrikoverland merged commit f58c708 into master Nov 22, 2024
4 checks passed
@janhenrikoverland janhenrikoverland deleted the fix/enable-user-ou-and-groups branch November 22, 2024 13:38
dhis2-bot added a commit that referenced this pull request Nov 22, 2024
## [26.9.3](v26.9.2...v26.9.3) (2024-11-22)

### Bug Fixes

* enable ou tree and levels/groups with user orgunits (DHIS2-18066) ([#1702](#1702)) ([f58c708](f58c708))
@dhis2-bot
Copy link
Contributor

🎉 This PR is included in version 26.9.3 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants