Skip to main content

Global on Listings only for one subcategory

More
10 years 11 months ago - 10 years 11 months ago #217837 by peterwijn
-- HikaShop version -- : 2.6.0
-- Joomla version -- : 3.4.4

I was not able to find the full answer in this forum and it seems that something has been changed with HS 2.6.0. I have different categories and subcategories all with the same product listing (also with override). I want one subcategory a complete different layout (more columns and rows, less info on products) with also the quantity field display set on "Global on listings". But the latter only for this subcategory, all other categores should remain "Normal input". In the previous versions you had associated products listings but that seems not working anymore.

Can you help? Thanks.

Forgot to mention that I want to enter this subcategory by clicking on this subcategory in the category list (in he content), so not via a seperate menu.
Last edit: 10 years 11 months ago by peterwijn.

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

More
10 years 11 months ago #217907 by Xavier
Hi,

The best way will be to edit directly the view "product / listing_div" (or listing_table, listing_list based on your settings) and force a setting based on the category, something like:
Code:
if($this->row->product_category == 'XX'){ $this->params->set('show_quantity_field',2); // same thing for the other settings }

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

More
10 years 11 months ago #217945 by peterwijn
Hi Xavier,

Thanks a lot. I did a small change:
if(in_array($this->element->category_id,array('XX')))

And this works great.

Thanks again,
Peter.

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

Time to create page: 0.208 seconds
Powered by Kunena Forum