-
Notifications
You must be signed in to change notification settings - Fork 219
Filter Products by Attribute: Fix the page reload which happens when clicking the filter button on PHP templates #6287
Conversation
Size Change: +137 B (0%) Total Size: 868 kB
ℹ️ View Unchanged
|
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.
@tjcafferkey Thanks for the PR! I can confirm that the page doesn't reload anymore after selecting the attribute within the block with the filter button. But look like the issue with Active Filters is still there. In the screenshot below, only selected attributes from the Filter by Color
block appear in the Active Filters block, Color filter doesn't have a filter button while the Size filter does:
…er button is not available
@dinhtungdu good catch, I've just pushed a commit to fix that! |
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.
@tjcafferkey with 97a684c, the first issue comes back, please check my screencast for more detail. I tested with the Filter button enabled.
Screen.Recording.2022-04-21.at.17.51.55.mov
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 got a weird behavior with the filter button enabled block:
- Enable the filter button for Filter Products by Attribute block.
- On the front end, select one or two attributes, and click the filter button.
- See the page reload: the filtered product result is correct, and the selected attributes appear in the Active Filters block => which are expected behaviors.
- The Filter Products by Attribute now only shows selected attributes, with product count set to
0
. - In my case, I have another Filter block by another attribute (filter button disabled), that block disappears after the page load.
Screen.Recording.2022-04-21.at.22.58.39.mov
… for PHP templates
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.
Thanks so much for your updates! Finally, it's working now!
This PR fixes the page reload which is triggered immediately when you uncheck an attribute filter when the "Filter button" option is enabled.
Fixes #6283
Fixes #6282
Testing
Automated Tests
Manual Testing
How to test the changes in this Pull Request:
User Facing Testing
These are steps for user testing (where "user" is someone interacting with this change that is not editing any code).
Performance Impact
Changelog