Only show product or categorie as a filter result

  • Posts: 28
  • Thank you received: 0
10 years 7 months ago #152814

The following categorie structure is in place:
- A
+-- B
+-- C
+-- D

By default we would like to show e.g. only the products listed in A (subcategorie disabled); When a user selects a filter, all products (subcategories included) may be displayed.

Is there a possibility we can only display products as a search result instead of default listed?

Please Log in or Create an account to join the conversation.

  • Posts: 82864
  • Thank you received: 13372
  • MODERATOR
10 years 7 months ago #152835

Hi,

That's possible. First you need to deactivate the filters on your products listing menu/module so that it displays your categories menu item with the products like you want (the default "categories listing" menu item of HikaShop should already do that).
Then, setup a products listing menu item displaying all your products via the Joomla menu manager (the default "products listing" menu item of HikaShop should already do that).
Then, configure the HikaShop filters module with the id of the menu item you created in the "Menu" option of the module with the "force redirect" option turned on.
That way, when the user uses the filters module, he will see the matching products throughout all your categories while otherwise, he will be able to navigate your products catalog by categories.

Please Log in or Create an account to join the conversation.

  • Posts: 28
  • Thank you received: 0
10 years 7 months ago #153139

Hi Nicolas,

thank you for your response. I've setup the system like your description.

Dynamic filters are unfortunately still read using the 'original' (show products in category) menu item; After selecting a filter, the menu will be redirected and all filters are shown. Is it possible to show all possibilities (and keep dynamic filter in place)?

Please Log in or Create an account to join the conversation.

  • Posts: 82864
  • Thank you received: 13372
  • MODERATOR
10 years 7 months ago #153151

There is no option to that.
You could try to add the code:

global $Itemid;
if($Itemid!=XXX) $datas=array();
before:
$html[$key]=$this->filterClass->displayFilter($filter, $this->params->get('main_div_name'), $this, $datas);
to:
in the file "filter" of the view "product" via the menu Display>Views in order to deactivate the dynamicity of the filters when not on the menu item XXX which should be the id of the menu item you configured in your filters module.

Please Log in or Create an account to join the conversation.

Time to create page: 0.056 seconds
Powered by Kunena Forum