Non-existing filter option gives strange result
- perfectwebteam
-
Topic Author
- Offline
-- Joomla version -- : 3.6.2
-- PHP version -- : 5.6.24
-- Browser(s) name and version -- : Chrome 52.0.2743.82 (64-bit)
-- Error-message(debug-mod must be tuned on) -- : no error message
I have a menu item (only accessible as administrator) showing all products from a chosen category.
Above the list of products we placed a filter.
The combination "PNP/NPN" and "M8 Quick-disconnect" should result in no products.
When you select this non-existing combination and press the button "filter" the page comes back without any products (as expected) and more options selected (not expected).
I was expecting two other things
- Text that this combination is not possible
- No other filter options selected
How can this be achieved?
Please Log in or Create an account to join the conversation.
1. The fact that there is no message when no results are found is because we don't display any by default as it appears most merchants don't want one. But you can add it easily:
www.hikashop.com/support/forum/filters-s...e-result.html#232388
2. I suppose that the problem must come from the values that you're using in your custom field which must overlap and thus the filter system finds a match for the selection of the value.
Could you provide a screenshot of the setting of the custom field of that output type filter ?
Please Log in or Create an account to join the conversation.
- perfectwebteam
-
Topic Author
- Offline
HIKASHOP_NO_RESULT='No results found!'
Still the same issue as mentioned in my initial post.
2. See the attached files.
Please Log in or Create an account to join the conversation.
1. I've tested is and it works just fine with your example. So you must have done something wrong with your override. Try adding it via the HikaShop configuration as explained in the documention link I gave you.
2. Change the code:
You're in dynamic display mode where the filters display all the values of the products in the listing. Since there are no products after the filtering, there are no values. So instead of not displaying any values in the filters, it displays all of them.
Please Log in or Create an account to join the conversation.
- perfectwebteam
-
Topic Author
- Offline
The page mentioned is a category view with a filter on top of it.
components/com_hikashop/views/category/tmpl/listing.php
When I add ```echo 'test';``` after line 144 and refresh the page without the results I can see "test" appear in the screen.
There is no way I see the variable "HIKASHOP_NO_RESULT" in that screen. And I cannot see the relation of components/com_hikashop/views/product/tmpl/listing.php into components/com_hikashop/views/category/tmpl/listing.php
Can you help me on this one?
Please Log in or Create an account to join the conversation.
Regarding the "no results" message, I don't understand what you're talking about.
The link I gave you says that you need to add the line:
HIKASHOP_NO_RESULT=" "
in the override area of your translation file through the Languages tab of the HikaShop configuration.
There is no need to change any "listing.php" file.
Please Log in or Create an account to join the conversation.
- perfectwebteam
-
Topic Author
- Offline
The first is still open... I don't see my translation of HIKASHOP_NO_RESULT=" "
I've added my override to Components > Hikashop > Configuration > System > Languages > English (one language on this site) > Edit > Override > added HIKASHOP_NO_RESULT="No results with current filter. Please use other filter options."
But the created override is not visible on the frontend after using the filter. Not even when I disable all template overrides for com_hikashop. What I tried to explain is that the page I'm looking it is a category view with a filter on top of it. it is displayed using components/com_hikashop/views/CATEGORY/tmpl/listing.php
The text variable HIKASHOP_NO_RESULT does not appear in this php file. It appears in components/com_hikashop/views/PRODUCT/tmpl/listing.php.
How can I make HIKASHOP_NO_RESULT appear on a category view?
Please Log in or Create an account to join the conversation.
Let's make it in a different way, can you provide the concern page Url and a Backend Access references ?
Note : You can use our Contact us form to provide these references.
Awaiting news from you.
Regards
Please Log in or Create an account to join the conversation.
- perfectwebteam
-
Topic Author
- Offline
We found the issue and corrected it. It was coming from the fact that you're using a categories listing instead of a products listing as is usually the case for products filtering and that case wasn't properly handled by the "no results" message system.
We'll add the modification for that in the next version of HikaShop.
Please Log in or Create an account to join the conversation.