예제 #1
0
 protected function checkOwnInvoice(Invoice $invoice, Request $request, $em)
 {
     $paymentHelper = new PaymentHelper();
     $id = $this->getCurrentCustomId($paymentHelper);
     if (!$invoice->isOwnInvoice($id)) {
         throw new AccessDeniedHttpException('Not your own invoice');
     }
     return true;
 }