Problem/Motivation
When we choose not all filters in the "Views Exposed Filters Summary" area settings, but only several, the "Reset" link still resets all exposed filters, instead of only the chosen ones.
Steps to reproduce
1. Using the default Drupal setup, create a view page listing all nodes, and expose two filters: "Content Type", "Tags".
2. Create a couple of nodes and tags.
3. Add the "Views Exposed Filters Summary" area to the view, in the settings choose only "Tags" filter.
4. Open the view page, choose "Content Type = Article" and "Tags = Tag1", apply the filter.
5. Click on the "Reset" link.
Expected result: Only the "Tags" exposed filter values should be reset.
Actual result: The "Content Type = Article" is reset too.
Proposed resolution
Add handling of the list of selected filters, and skip resetting filters that are not selected.
Remaining tasks
User interface changes
API changes
Data model changes
Issue fork views_filters_summary-3548371
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #3
murzI prepared the MR with the fix, please review.
Comment #4
mably commentedThanks @murz, sounds like an interesting improvement.
Will make a few tweaks and merge it.
Comment #5
mably commentedCurrent implementation is more a "Remove all" than a "Reset", am I right?
But I guess that what it was supposed to do in the first place.
Comment #6
murzThe "Remove all" is called "Reset" in the code, as I see ;)
Comment #7
mably commented@murz we should be ready for merge, could you have a final look?
Comment #8
murzYeah, improvements look good to me, and even still works well! ;) Let's merge!
Comment #10
mably commentedComment #12
mably commentedMerged.
Let's wait a few days before releasing 3.3.0-beta1.