credit note

This commit is contained in:
edmondlang
2023-08-01 01:56:31 +08:00
parent 1495cd8520
commit ef63dad63d
2 changed files with 4 additions and 2 deletions
@@ -45,6 +45,8 @@ class GenerateCreditNotePdfLogic
{
$transaction = $this->fetchesTransaction->execute(['id' => $request->route('id')]);
$booking = $transaction->booking;
// $purchaseOrder = $transaction->owner()->transactions()
// ->where('type', TransactionType::PURCHASE_ORDER)
// ->complete()
@@ -52,7 +54,7 @@ class GenerateCreditNotePdfLogic
$supplier = $this->fetchesCompany->execute(['id' => $transaction->receiver]);
$pdf = LaravelMpdf::loadView('pages.pdfs.credit_note', ['transaction' => $transaction, 'po_order_transaction' => null, 'supplier' => $supplier]);
$pdf = LaravelMpdf::loadView('pages.pdfs.credit_note', ['transaction' => $transaction, 'booking' => $booking, 'supplier' => $supplier]);
return $pdf->stream('MockUpWhiteForm.pdf');
}