// BugFix : Problem with token
This commit is contained in:
@@ -278,6 +278,9 @@ class AuthControllerCore extends FrontController
|
|||||||
$this->context->cart->id_address_delivery = Address::getFirstCustomerAddressId((int)($customer->id));
|
$this->context->cart->id_address_delivery = Address::getFirstCustomerAddressId((int)($customer->id));
|
||||||
$this->context->cart->id_address_invoice = Address::getFirstCustomerAddressId((int)($customer->id));
|
$this->context->cart->id_address_invoice = Address::getFirstCustomerAddressId((int)($customer->id));
|
||||||
$this->context->cart->update();
|
$this->context->cart->update();
|
||||||
|
// Add customer to the context
|
||||||
|
$this->context->customer = $customer;
|
||||||
|
|
||||||
Hook::exec('authentication');
|
Hook::exec('authentication');
|
||||||
|
|
||||||
// Login information have changed, so we check if the cart rules still apply
|
// Login information have changed, so we check if the cart rules still apply
|
||||||
@@ -291,8 +294,10 @@ class AuthControllerCore extends FrontController
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
elog('here???');
|
||||||
if ($this->ajax)
|
if ($this->ajax)
|
||||||
{
|
{
|
||||||
|
elog(Tools::getToken(false));
|
||||||
$return = array(
|
$return = array(
|
||||||
'hasError' => !empty($this->errors),
|
'hasError' => !empty($this->errors),
|
||||||
'errors' => $this->errors,
|
'errors' => $this->errors,
|
||||||
|
|||||||
@@ -272,12 +272,12 @@ function confirmFreeOrder()
|
|||||||
{
|
{
|
||||||
var array_split = html.split(':');
|
var array_split = html.split(':');
|
||||||
if (array_split[0] === 'freeorder')
|
if (array_split[0] === 'freeorder')
|
||||||
{
|
{
|
||||||
if (isGuest)
|
if (isGuest)
|
||||||
document.location.href = guestTrackingUrl+'?id_order='+encodeURIComponent(array_split[1])+'&email='+encodeURIComponent(array_split[2]);
|
document.location.href = guestTrackingUrl+'?id_order='+encodeURIComponent(array_split[1])+'&email='+encodeURIComponent(array_split[2]);
|
||||||
else
|
else
|
||||||
document.location.href = historyUrl;
|
document.location.href = historyUrl;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
error: function(XMLHttpRequest, textStatus, errorThrown) {alert("TECHNICAL ERROR: unable to confirm the order \n\nDetails:\nError thrown: " + XMLHttpRequest + "\n" + 'Text status: ' + textStatus);}
|
error: function(XMLHttpRequest, textStatus, errorThrown) {alert("TECHNICAL ERROR: unable to confirm the order \n\nDetails:\nError thrown: " + XMLHttpRequest + "\n" + 'Text status: ' + textStatus);}
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user