// Improve multishop API

git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@13566 b9a71923-0436-4b27-9f14-aed3839534dd
This commit is contained in:
rMalie
2012-02-23 15:39:44 +00:00
parent ec8f05c3ca
commit b24dcffc9c
71 changed files with 377 additions and 425 deletions

View File

@@ -1249,8 +1249,8 @@ abstract class ModuleCore
LEFT JOIN `'._DB_PREFIX_.'hook` h ON hm.`id_hook` = h.`id_hook`
WHERE h.`name` = \''.pSQL($hookPayment).'\'
AND mc.id_country = '.(int)$billing->id_country.'
AND mc.id_shop = '.(int)$context->shop->getID(true).'
AND mg.id_shop = '.(int)$context->shop->getID(true).'
AND mc.id_shop = '.(int)$context->shop->id.'
AND mg.id_shop = '.(int)$context->shop->id.'
AND (SELECT COUNT(*) FROM '._DB_PREFIX_.'module_shop ms WHERE ms.id_module = m.id_module AND ms.id_shop IN('.implode(', ', $list).')) = '.count($list).'
AND hm.id_shop IN('.implode(', ', $list).')
AND (mg.`id_group` IN('.implode(', ', $groups).'))
@@ -1690,7 +1690,7 @@ abstract class ModuleCore
FROM `'._DB_PREFIX_.'hook_module`
WHERE `id_hook` = '.(int)($id_hook).'
AND `id_module` = '.(int)($this->id).'
AND `id_shop` = '.(int)Context::getContext()->shop->getId(true));
AND `id_shop` = '.(int)Context::getContext()->shop->id);
return $result['position'];
}