Création du module FedEx
This commit is contained in:
@@ -12,8 +12,8 @@
|
||||
|
||||
namespace Colissimo\Controller;
|
||||
|
||||
use Colissimo\Colissimo;
|
||||
use Colissimo\Model\Config\ColissimoConfigValue;
|
||||
use Colissimo\FedEx;
|
||||
use Colissimo\Model\Config\FedExConfigValue;
|
||||
use Symfony\Component\HttpFoundation\RedirectResponse;
|
||||
use Thelia\Model\AreaQuery;
|
||||
use Thelia\Controller\Admin\BaseAdminController;
|
||||
@@ -44,7 +44,7 @@ class EditPrices extends BaseAdminController
|
||||
->findPK($area);
|
||||
if ($exists !== null) {
|
||||
|
||||
if (null !== $data = Colissimo::getConfigValue(ColissimoConfigValue::PRICES, null)) {
|
||||
if (null !== $data = FedEx::getConfigValue(FedExConfigValue::PRICES, null)) {
|
||||
$json_data = json_decode(
|
||||
$data,
|
||||
true
|
||||
@@ -62,7 +62,7 @@ class EditPrices extends BaseAdminController
|
||||
}
|
||||
ksort($json_data[$area]['slices']);
|
||||
|
||||
Colissimo::setConfigValue(ColissimoConfigValue::PRICES, json_encode($json_data));
|
||||
FedEx::setConfigValue(FedExConfigValue::PRICES, json_encode($json_data));
|
||||
|
||||
} else {
|
||||
throw new \Exception("Area not found");
|
||||
|
||||
Reference in New Issue
Block a user