@php $grandTotal = 0; @endphp @forelse($data as $key => $item) @php $grandTotal += floatval($item->grand_total); @endphp @empty @endforelse
No Kode Tgl Pembelian Pelanggan Pengguna Total Discount Ppn Grand Total
{{ $key += 1 }} {{ $item->code ?? '-' }} {{ $item->date ?? '-' }} {{ $item->transaction_type }} {{ $item->customer ? $item->customer->name : "-" }} {{ $item->user ? $item->user->username : "-" }} {{ number_format($item->total ?? 0,2,',','.') }} @if($item->discount_type == "NOMINAL") ( RP ) @else ( % ) @endif {{ number_format($item->discount ?? 0,2,',','.') }} {{ number_format($item->tax ?? 0,2,',','.') }} {{ number_format($item->grand_total ?? 0,2,',','.') }}
Data tidak ditemukan
Total Penjualaan
{{ number_format($grandTotal ?? 0,2,',','.') }}