|
|
{{ $invoice->no }} |
{{ \Carbon\Carbon::parse($invoice->created_at)->format('d/m/y') }} |
{{ \Carbon\Carbon::parse($invoice->created_at)->format('H:i') }} |
{{ $invoice->users_name }} |
{{ $invoice->sales_name }} |
{{ $invoice->total_qty }} |
{{ $invoice->subtotal }} |
{{ number_format($invoice->disc_total ?? 0, 2, ',', '.') }} |
@if ($invoice->cashback !== 'N')
{{ $invoice->value }} |
@else
0 |
@endif
{{ $invoice->grandtotal }} |
@if ($invoice->payment === 'Multi')
@php
$totalCash += $invoice->cash;
$totalSubtotalCard += $invoice->transfer;
@endphp
{{ $invoice->cash }} |
{{ $invoice->transfer }} |
@elseif ($invoice->payment === 'Cash')
@php
$totalCash += $invoice->grandtotal;
@endphp
{{ $invoice->grandtotal }} |
0 |
@elseif ($invoice->payment === 'Qris')
@php
$totalSubtotalCard += $invoice->grandtotal;
@endphp
0 |
{{ $invoice->grandtotal }} |
@elseif ($invoice->payment === 'Card')
@php
$totalSubtotalCard += $invoice->grandtotal;
@endphp
0 |
{{ $invoice->grandtotal }} |
{{-- mz --}}
@else
0 |
0 |
@endif
@endforeach
|
|
Grand Total |
{{ $invoices->sum('total_qty') }} |
{{ $invoices->sum('subtotal') }} |
{{ $invoices->sum('discount') }} |
{{ $invoices->sum('value') }} |
{{ $invoices->sum('grandtotal') }} |
{{ $totalCash }} |
{{ $totalSubtotalCard }} |