// Context part 31
git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@8087 b9a71923-0436-4b27-9f14-aed3839534dd
This commit is contained in:
@@ -38,15 +38,14 @@ class PdfOrderReturnControllerCore extends FrontController
|
||||
{
|
||||
parent::process();
|
||||
|
||||
$cookie = $this->context->cookie;
|
||||
if (!$cookie->isLogged())
|
||||
if (!$this->context->customer->isLogged())
|
||||
Tools::redirect('index.php?controller=authentication&back=order-follow');
|
||||
|
||||
if (isset($_GET['id_order_return']) AND Validate::isUnsignedId($_GET['id_order_return']))
|
||||
$orderReturn = new OrderReturn((int)($_GET['id_order_return']));
|
||||
if (!isset($orderReturn) OR !Validate::isLoadedObject($orderReturn))
|
||||
die(Tools::displayError('Order return not found'));
|
||||
else if ($orderReturn->id_customer != $cookie->id_customer)
|
||||
else if ($orderReturn->id_customer != $this->context->customer->id)
|
||||
die(Tools::displayError('Order return not found'));
|
||||
else if ($orderReturn->state < 2)
|
||||
die(Tools::displayError('Order return not confirmed'));
|
||||
|
||||
Reference in New Issue
Block a user