Consolidate tag filtering to _all suffix for AND logic - scopes and parameters#873
Merged
maebeale merged 8 commits intoupdate-tags-uxfrom Feb 9, 2026
Merged
Consolidate tag filtering to _all suffix for AND logic - scopes and parameters#873maebeale merged 8 commits intoupdate-tags-uxfrom
maebeale merged 8 commits intoupdate-tags-uxfrom
Conversation
Merged
Copilot
AI
changed the title
[WIP] Update tags UX to allow multiple selections
Update tags UX - respond to code review feedback
Feb 8, 2026
Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com>
Copilot
AI
changed the title
Update tags UX - respond to code review feedback
Consolidate tag filtering scopes to _all suffix for AND logic semantics
Feb 8, 2026
Collaborator
|
@copilot i want the param name to have all in it too |
Collaborator
|
@copilot add a system test to validate this multiselect on the bottom of tags and taggings indexes works correctly |
Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com>
Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com>
Copilot
AI
changed the title
Consolidate tag filtering scopes to _all suffix for AND logic semantics
Consolidate tag filtering to _all suffix for AND logic - scopes and parameters
Feb 9, 2026
Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com>
Collaborator
|
@copilot do what's needed to get the failing tests to pass |
Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com>
Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com>
Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com>
maebeale
added a commit
that referenced
this pull request
Feb 9, 2026
…arameters (#873) * Initial plan * Consolidate to _all scopes for AND logic semantics Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Rename parameters to use _all suffix for consistency Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Update tests to use _all parameter naming Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Fix missed variable references and add system test for multiselect Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Fix failing tests for parameter naming and case sensitivity Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Use regex for case-insensitive text matching in tests Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Add proper delimiter verification in URL assertions Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com>
maebeale
added a commit
that referenced
this pull request
Feb 9, 2026
* note * Small fixes * Apply df16bd0 * Fix category query to use joins instead of includes for proper ordering Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Improve filter JavaScript to use window.location.search for safer URL handling Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Convert dropdowns to multi-select for multiple sectors and categories Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Add explore_by_combination section to taggings index * Fix tagged_index_path to pass sector_names and category_names directly Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Apply 5c0c467 * Optimize tag_names_all to use GROUP BY/HAVING instead of multiple joins Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Fix ONLY_FULL_GROUP_BY error by using subquery in tag_names_all Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Add explore_by_combination to bottom of tags index * Make Apply Filters button always redirect to taggings index from both tags and taggings pages Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Add clarifying comment about intentional parameter clearing in applyFilters Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Change empty result text * fix call to metadata * Note scopes * Don't see scope for :published * Remove by_most_viewed scopes (they were pre-ahoy) * Consolidate tag filtering to _all suffix for AND logic - scopes and parameters (#873) * Initial plan * Consolidate to _all scopes for AND logic semantics Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Rename parameters to use _all suffix for consistency Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Update tests to use _all parameter naming Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Fix missed variable references and add system test for multiselect Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Fix failing tests for parameter naming and case sensitivity Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Use regex for case-insensitive text matching in tests Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Add proper delimiter verification in URL assertions Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Fix test * Allow for varying order of url param args * Fix the uncheck text --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com>
maebeale
added a commit
that referenced
this pull request
Feb 9, 2026
* note * Small fixes * Apply df16bd0 * Fix category query to use joins instead of includes for proper ordering Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Improve filter JavaScript to use window.location.search for safer URL handling Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Convert dropdowns to multi-select for multiple sectors and categories Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Add explore_by_combination section to taggings index * Fix tagged_index_path to pass sector_names and category_names directly Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Apply 5c0c467 * Optimize tag_names_all to use GROUP BY/HAVING instead of multiple joins Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Fix ONLY_FULL_GROUP_BY error by using subquery in tag_names_all Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Add explore_by_combination to bottom of tags index * Make Apply Filters button always redirect to taggings index from both tags and taggings pages Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Add clarifying comment about intentional parameter clearing in applyFilters Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Change empty result text * fix call to metadata * Note scopes * Don't see scope for :published * Remove by_most_viewed scopes (they were pre-ahoy) * Consolidate tag filtering to _all suffix for AND logic - scopes and parameters (#873) * Initial plan * Consolidate to _all scopes for AND logic semantics Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Rename parameters to use _all suffix for consistency Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Update tests to use _all parameter naming Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Fix missed variable references and add system test for multiselect Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Fix failing tests for parameter naming and case sensitivity Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Use regex for case-insensitive text matching in tests Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Add proper delimiter verification in URL assertions Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com> * Fix test * Allow for varying order of url param args * Fix the uncheck text * Change display of metadata on workshops index --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: maebeale <7607813+maebeale@users.noreply.github.com>
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.
What is the goal of this PR and why is this important?
Consolidate duplicate tag filtering scope implementations and unify parameter naming. The codebase had both
sector_names/category_namesandsector_names_all/category_names_alldoing identical AND logic with different implementations. The_allsuffix now explicitly and consistently indicates AND semantics (items must have ALL specified tags) throughout both scopes and HTTP parameters, distinguishing from typical OR-based scopes.How did you approach the change?
Phase 1: TagFilterable concern consolidation
tag_namesmethod (GROUP BY/HAVING approach)tag_names_allmethod (subquery approach, avoids ONLY_FULL_GROUP_BY errors with eager loading)category_namesandsector_namesscopes, kept only_allversionsPhase 2: Complete parameter renaming
Renamed ALL HTTP parameter references throughout the application:
Updated files (29 total):
search_by_paramsmethodsPhase 3: System test coverage
spec/system/taggings_multiselect_filter_spec.rb) to validate multiselect filter functionality on both tags and taggings index pagesPhase 4: Test fixes
sector_names_all=parameter/explore by combination/ifor case-insensitive text matching (handles "EXPLORE BY COMBINATION" uppercase rendering)sector_names_all=(Adult--Youth|Youth--Adult))Anything else to add?
Net reduction of ~40 lines. Complete consistency achieved - both scope names AND parameter names now use
_allsuffix to clearly indicate AND logic semantics throughout the entire application. Fixed bug where taggings index view was still using old@sector_namesand@category_namesvariables. Added comprehensive test coverage to ensure the multiselect functionality works correctly with the new parameter naming convention. All tests now pass with proper assertions that validate both functionality and URL formatting while being resilient to implementation details like parameter ordering.💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.