-
-
Notifications
You must be signed in to change notification settings - Fork 817
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
SearchKit - Hierarchical entity displays #31189
Conversation
🤖 Thank you for contributing to CiviCRM! ❤️ We will need to test and review this PR. 👷 Introduction for new contributors...
Quick links for reviewers...
|
822bc89
to
99fc572
Compare
This trait gives entities a special `_depth` field, selecting it triggers a special get mode which will cause returned records to be returned in nested order.
A hierarchical table shows child rows nested under their parents
99fc572
to
f47ddcd
Compare
@colemanw this looks nice. Just some thoughts/questions...
|
Thanks @mattwire. To answer:
|
Ok great. Well let me know if you'd like this one reviewed/merged in the mean time or if you'd like a little think first :-) |
@mattwire yes it'd be good to get this merged in the meantime. |
Ok, I've done some testing and code review on this. I didn't test the "role permissions" screen as currently don't have a standalone system setup but the groups and contact types seem to work well. Nested permissions checkbox appears for those entities only as expected. |
Overview
Makes it possible to visualize nested hierarchies in search display tables. Updates 3 Admin tables to do so (screenshots below).
Before
Trying to do this in SearchKit was like... 🤔
After
Now you can! Here's the updated "Administer Contact Types" screen in Admin UI:
And here's the "Administer Role Permissions" screen in Standalone:
(requires #31191 to show all the grey checkboxes correctly)
And the updated "Manage Groups" screen in Admin UI:
Technical Details
Adds
HierarchicalEntity
APIv4 trait.A special
_depth
field is available to these entities. Adding it to the select clause will cause returned records to be sorted in nested order.