[-] BO: Root category should be the shop category and not the higher category with multiple root and without multishop #PSCFV-8860
This commit is contained in:
@@ -684,8 +684,7 @@ class CategoryCore extends ObjectModel
|
|||||||
else
|
else
|
||||||
return new Category($shop->getCategory(), $id_lang);
|
return new Category($shop->getCategory(), $id_lang);
|
||||||
$is_more_than_one_root_category = count(Category::getCategoriesWithoutParent()) > 1;
|
$is_more_than_one_root_category = count(Category::getCategoriesWithoutParent()) > 1;
|
||||||
if ((!Shop::isFeatureActive() && $is_more_than_one_root_category) ||
|
if (Shop::isFeatureActive() && $is_more_than_one_root_category && Shop::getContext() != Shop::CONTEXT_SHOP)
|
||||||
Shop::isFeatureActive() && $is_more_than_one_root_category && Shop::getContext() != Shop::CONTEXT_SHOP)
|
|
||||||
$category = Category::getTopCategory($id_lang);
|
$category = Category::getTopCategory($id_lang);
|
||||||
else
|
else
|
||||||
$category = new Category($shop->getCategory(), $id_lang);
|
$category = new Category($shop->getCategory(), $id_lang);
|
||||||
|
|||||||
Reference in New Issue
Block a user