// Fix share customer on shops
This commit is contained in:
@@ -712,7 +712,8 @@ class ShopCore extends ObjectModel
|
|||||||
if ($alias)
|
if ($alias)
|
||||||
$alias .= '.';
|
$alias .= '.';
|
||||||
|
|
||||||
if ($share == Shop::SHARE_CUSTOMER && Shop::getContext() == Shop::CONTEXT_SHOP)
|
$group = Shop::getGroupFromShop(Shop::getContextShopID(), false);
|
||||||
|
if ($share == Shop::SHARE_CUSTOMER && Shop::getContext() == Shop::CONTEXT_SHOP && $group['share_customer'])
|
||||||
$restriction = ' AND '.$alias.'id_shop_group = '.(int)Shop::getContextShopGroupID();
|
$restriction = ' AND '.$alias.'id_shop_group = '.(int)Shop::getContextShopGroupID();
|
||||||
else
|
else
|
||||||
$restriction = ' AND '.$alias.'id_shop IN ('.implode(', ', Shop::getContextListShopID($share)).') ';
|
$restriction = ' AND '.$alias.'id_shop IN ('.implode(', ', Shop::getContextListShopID($share)).') ';
|
||||||
|
|||||||
Reference in New Issue
Block a user