[-] BO : Bug fixed related to #PSCFV-1354 - Specific price with multishop, groups/currencies/countries should vary in function of the selected shop

This commit is contained in:
fBrignoli
2012-05-16 15:51:22 +00:00
parent 604b572ed2
commit bf66f03fd7
5 changed files with 57 additions and 6 deletions
+13
View File
@@ -212,6 +212,19 @@ class CurrencyCore extends ObjectModel
return $tab;
}
public static function getCurrenciesByIdShop($id_shop = 0)
{
$sql = 'SELECT *
FROM `'._DB_PREFIX_.'currency` c
LEFT JOIN `'._DB_PREFIX_.'currency_shop` cs ON (cs.`id_currency` = c.`id_currency`)
'.($id_shop != 0 ? ' WHERE cs.`id_shop` = '.(int)$id_shop : '').'
GROUP BY c.id_currency
ORDER BY `name` ASC';
return Db::getInstance()->executeS($sql);
}
public static function getPaymentCurrenciesSpecial($id_module, $id_shop = null)
{
if (is_null($id_shop))