fix renderOrderId
This commit is contained in:
parent
67736843ff
commit
b7e2dd0007
@ -112,9 +112,9 @@ class Cart extends BaseCart
|
||||
* @return integer $id_order associated cart order id
|
||||
*/
|
||||
public function getOrderId() {
|
||||
if (static::$_shouldRenderOrderId) {
|
||||
if (static::$_shouldRenderOrderId === true) {
|
||||
return (int)\Db::getInstance()->getValue('
|
||||
SELECT `id_order ` FROM `'._DB_PREFIX_.'orders`
|
||||
SELECT `id_order` FROM `'._DB_PREFIX_.'orders`
|
||||
WHERE `id_cart` = '.(int)$this->id.'
|
||||
');
|
||||
} else {
|
||||
|
@ -121,7 +121,7 @@ class PayboxController extends ApiBaseController {
|
||||
$paybox->validateOrder((int)$cart->id, _PS_OS_PAYMENT_, ((int)$input_data['MONTANT']) / 100, $paybox->displayName, $info, array(), NULL, false, $user->secure_key, $data);
|
||||
$paybox->saveInformationPaiement($data);
|
||||
}
|
||||
$cart->_shouldRenderOrderId = true;
|
||||
$cart::$_shouldRenderOrderId = true;
|
||||
return $cart;
|
||||
}
|
||||
|
||||
|
@ -102,7 +102,7 @@ class PaypalController extends ApiBaseController {
|
||||
if ($result !== true) {
|
||||
throw new HttpBadRequestException('Une erreur est survenue lors de la validation de votre commmande. Veuillez réesayer ultérieurement.');
|
||||
}
|
||||
$cart->_shouldRenderOrderId = true;
|
||||
$cart::$_shouldRenderOrderId = true;
|
||||
return $cart;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user