-
-
Notifications
You must be signed in to change notification settings - Fork 242
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
[Northumberland] Being able to filter on one category in multiple parent categories #4895
base: master
Are you sure you want to change the base?
Conversation
@dracos Was hoping to get this finished but tests failing so need to look into it further. Hopefully 90% complete unless totally wrong approach so putting as a WIP so can get advice if you have time to look at it to get a rough idea. |
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #4895 +/- ##
=======================================
Coverage 82.34% 82.35%
=======================================
Files 409 409
Lines 31845 31876 +31
Branches 5063 5071 +8
=======================================
+ Hits 26222 26250 +28
- Misses 4126 4127 +1
- Partials 1497 1499 +2 ☔ View full report in Codecov by Sentry. |
927848b
to
02ddf58
Compare
f9cb3dc
to
1cbb8f8
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I first got "Not a HASH reference" from Dashboard.pm line 291 when trying to view the dashboard. I added a && ref $col3 eq 'HASH'
there which fixed that (old extra might not be a hash). But I can't then seem to get this to work, I'm afraid?
I have "Street cleaning" in three parent categories, "Parent A", "Parent B", "Parent C". Each has 2 reports in it. I selected the Parent A Street cleaning, hit submit, the URL has category=Street+cleaning-group-Parent+A
in it, but all three are ticked in the resultant page and all 6 reports are still shown in the summary table, still under "Multiple". Same as selecting "All Parent A". I think the first part is due to the reverse
which means "Street cleaning" is set as the key, just like it was beforehand; and the category filter still seems to have the same information/display.
Given that, I'm afraid I haven't really looked at the display code further on, but I'm finding it quite hard to understand what it's doing, so it might need talking through the best way to proceed. I don't think we want this to be this complicated if we can help it.
1cbb8f8
to
9aef9f4
Compare
If I add |
4330bd8
to
f25639b
Compare
…e parent categories Set up categories in index to include name of their group. Use this group name to check if a report is in the selected category (through extra->group). If there are reports that don't identify as being in that category, then still use a 'Multiple' category. mysociety/societyworks#4039
f25639b
to
2a0b5f0
Compare
Set up categories in index to include name of their group.
Use this group name to check if a report is in the selected category (through extra->group).
If there are reports that don't identify as being in that category, then still use a 'Multiple' category.
Fixes https://github.com/mysociety/societyworks/issues/4039
[skip changelog]