From c7df242539a0dc4f9084b139d02a76db14b8cce5 Mon Sep 17 00:00:00 2001 From: dMetzger Date: Sat, 19 May 2012 14:40:10 +0000 Subject: [PATCH] [-] BO : refresh currency rates button fixed --- classes/Currency.php | 6 +++--- controllers/admin/AdminCurrenciesController.php | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/classes/Currency.php b/classes/Currency.php index a9c92fc43..befc25fd1 100644 --- a/classes/Currency.php +++ b/classes/Currency.php @@ -388,10 +388,10 @@ class CurrencyCore extends ObjectModel if (!$default_currency = Currency::getDefaultCurrency()) return Tools::displayError('No default currency'); - $currencies = Currency::getCurrencies(true); + $currencies = Currency::getCurrencies(true, false); foreach ($currencies as $currency) - $currency->refreshCurrency($feed->list, $isoCodeSource, $default_currency); - + if ($currency->id != $default_currency->id) + $currency->refreshCurrency($feed->list, $isoCodeSource, $default_currency); } /** diff --git a/controllers/admin/AdminCurrenciesController.php b/controllers/admin/AdminCurrenciesController.php index 49962dd42..5ffdc0a5b 100644 --- a/controllers/admin/AdminCurrenciesController.php +++ b/controllers/admin/AdminCurrenciesController.php @@ -291,7 +291,7 @@ class AdminCurrenciesControllerCore extends AdminController */ public function initProcess() { - if (Tools::isSubmit('submitExchangesRates')) + if (Tools::isSubmit('SubmitExchangesRates')) { if ($this->tabAccess['edit'] === '1') $this->action = 'exchangeRates';