[*] BO : Rights verification for multi-shop : delete info()
git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@9200 b9a71923-0436-4b27-9f14-aed3839534dd
This commit is contained in:
@@ -248,7 +248,6 @@ class EmployeeCore extends ObjectModel
|
|||||||
switch ($type = $context->shop->getContextType())
|
switch ($type = $context->shop->getContextType())
|
||||||
{
|
{
|
||||||
case 1:
|
case 1:
|
||||||
info('context shop');
|
|
||||||
if ($context->shop->checkIfShopExist($context->shop->id))
|
if ($context->shop->checkIfShopExist($context->shop->id))
|
||||||
{
|
{
|
||||||
if (!in_array($context->shop->id, self::getEmployeeShopById($id_employee)))
|
if (!in_array($context->shop->id, self::getEmployeeShopById($id_employee)))
|
||||||
@@ -259,7 +258,6 @@ class EmployeeCore extends ObjectModel
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
case 2:
|
case 2:
|
||||||
info('context group');
|
|
||||||
if ($context->shop->checkIfGroupShopExist($context->shop->getGroupID()))
|
if ($context->shop->checkIfGroupShopExist($context->shop->getGroupID()))
|
||||||
{
|
{
|
||||||
$shops = $context->shop->getIdShopsByIdGroupShop($context->shop->getGroupID());
|
$shops = $context->shop->getIdShopsByIdGroupShop($context->shop->getGroupID());
|
||||||
@@ -272,7 +270,6 @@ class EmployeeCore extends ObjectModel
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
case 3:
|
case 3:
|
||||||
info('context all');
|
|
||||||
if ($context->employee->id_profile == _PS_ADMIN_PROFILE_ ||
|
if ($context->employee->id_profile == _PS_ADMIN_PROFILE_ ||
|
||||||
$context->shop->getTotalShopsWhoExists() == self::getTotalEmployeeShopById($id_employee))
|
$context->shop->getTotalShopsWhoExists() == self::getTotalEmployeeShopById($id_employee))
|
||||||
return true;
|
return true;
|
||||||
|
|||||||
Reference in New Issue
Block a user