2016-11-21 12:47:59 +01:00

21 lines
539 B
PHP

<?php
class AtosOverride extends Atos
{
public function hookOrderConfirmation($params)
{
if ($params['objOrder']->module != $this->name)
return;
// fix delay after payment
sleep(5);
if ($params['objOrder']->valid || $params['objOrder']->current_state == _PS_OS_PAYMENT_)
$this->context->smarty->assign(array('status' => 'ok', 'id_order' => $params['objOrder']->id));
else
$this->context->smarty->assign('status', 'failed');
return $this->display(__FILE__, 'views/templates/hook/hookorderconfirmation.tpl');
}
}