Hi,
The HikaMarket category class have a function "processListing".
When a category listing module is displayed in the vendor page ; that function can alter the content of the module.
The processing is only made when the setting "Synchronize" is on.
If the setting "only with products" is set in the category listing module configuration, HikaMarket will filter the category to only display thus which have products of the current vendor.
There is also some commented/unpublished code in that function in order to change dynamically the "main category" and target the vendor category instead:
if((int)$filter_type == 0) {
$vendorClass = hikamarket::get('class.vendor');
$rootCategory = $vendorClass->getRootCategory($vendor_id);
if(empty($rootCategory))
return;
if(isset($filters['category_parent_id'])) {
$filters['category_parent_id'] = 'a.category_parent_id = ' . (int)$rootCategory;
} else {
foreach($filters as &$filter) {
if(substr($filter, 0, 23) != 'a.category_parent_id = ')
continue;
$filter = 'a.category_parent_id = ' . (int)$rootCategory;
break;
}
unset($filter);
}
}
You can place that code just below
$filter_type = $view->params->get('filter_type');
$filter_only_products = $view->params->get('only_if_products',0);
$vendor_id = hikamarket::getCID('vendor_id');
in order to activate the feature.
And I'll see to publish that in the next HikaMarket release.
Regards,