From 95fd0aa45d269638eb02abfd49e0ae91298f55d9 Mon Sep 17 00:00:00 2001 From: Omair Saleh Date: Tue, 1 Nov 2022 15:45:46 +0800 Subject: [PATCH] shipping sales report --- routes/web.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/routes/web.php b/routes/web.php index 814cf554..a9756baa 100644 --- a/routes/web.php +++ b/routes/web.php @@ -461,7 +461,7 @@ Route::get('/container/billing/{month}/{year}', function($month, $year){ foreach($containers as $container) { $packingLists = $container->packingLists; $totalBillable += count($packingLists); - echo '

'.$container->reference.'

'; + echo '

'.$container->reference.' ('.$container->loading_date->format('d-m-Y').')

'; foreach ($packingLists as $packingList) { $invoice = $packingList->transactions() @@ -481,7 +481,7 @@ Route::get('/container/billing/{month}/{year}', function($month, $year){ $totalBilled += $invoice->amount; $totalPaid += $payments->sum('amount'); - echo ''.$packingList->reference.' | Amount: '.$invoice->amount.' | Paid: '.$payments->sum('amount').' | Invoice Date: '.$invoice->created_at. (($invoice->amount - $payments->sum('amount')) < 0.01 ? '' : '('.$invoice->created_at->diffForHumans().')').''; + echo ''.$packingList->reference.' | Amount: '.$invoice->amount.' | Paid: '.$payments->sum('amount').' | Invoice Date: '.$invoice->created_at->format('d-m-Y'). (($invoice->amount - $payments->sum('amount')) < 0.01 ? '' : '('.$invoice->created_at->diffForHumans().')').''; echo '
'; }