According to our design requirement, user should be able to select minimum price and maximum price from a dropdown and properties gets filtered based on the selected range. Can this functionality be achieved using sitecore sxa search filters ?
1 Answer
It is not possible out of the box. You can play with ranges by using Filter (Manage Range) rendering but you won't have a dropdown there, only the following configuration is possible:
You can also define range using Filter (Range Slider) rendering, but again - no dropdowns there:
So in order to manage ranges using dropdowns, you would need some custom development. There is a couple of ways to implement such rendering. If you would like to go with the SXA approach I would suggest to:
- take a look at Filter (Dropdown) rendering - both view and script (where you will see how the dropdown is populated with the values)
- then you would need to combine the logic which is populating dropdowns with the logic of Filter (Manage range)
The other way is to build something custom and just use the query parameters to pass selected range to the server (just like we are doing this in SXA by updating hash parameters):
-
Thank you for the reply @Dawid. I will check on customizing it– FahmidaCommented Apr 26, 2019 at 5:28