public function errorAction()
    {
        try {
            $order = $this->getPaymentHandler()->handleError($this->getCurrentRequest(), $this->getBasket());
        } catch (EntityNotFoundException $ex) {
            throw new NotFoundHttpException($ex->getMessage());
        } catch (InvalidTransactionException $ex) {
            throw new UnauthorizedHttpException($ex->getMessage());
        }

        return $this->render('SonataPaymentBundle:Payment:error.html.twig', [
            'order' => $order,
        ]);
    }
public function errorAction()
    {
        try {
            $order = $this->getPaymentHandler()->handleError($this->getCurrentRequest(), $this->getBasket());
        } catch (EntityNotFoundException $ex) {
            throw new NotFoundHttpException($ex->getMessage());
        } catch (InvalidTransactionException $ex) {
            throw new UnauthorizedHttpException($ex->getMessage());
        }

        return $this->render('SonataPaymentBundle:Payment:error.html.twig', [
            'order' => $order,
        ]);
    }
public function errorAction ( ) { try { $ order = $ this -> getPaymentHandler ( ) -> handleError ( $ this -> getCurrentRequest ( ) , $ this -> getBasket ( ) ) ; } catch ( EntityNotFoundException $ ex ) { throw new NotFoundHttpException ( $ ex -> getMessage ( ) ) ; } catch ( InvalidTransactionException $ ex ) { throw new UnauthorizedHttpException ( $ ex -> getMessage ( ) ) ; } return $ this -> render ( 'SonataPaymentBundle:Payment:error.html.twig' , [ 'order' => $ order , ] ) ; }
This action is called by the user after the sendbank
In most case the order is already cancelled by a previous callback.

@throws UnauthorizedHttpException
@throws NotFoundHttpException

@return Response
This action is called by the user after the sendbank In most case the order is already cancelled by a previous callback .