@extends('layout.app') @section('content')

Sale Invoice List

@php $total = 0; $discount = 0; $paid = 0; $due = 0; @endphp @foreach ($list as $row) @php $total += $row->total; $discount += $row->discount; $paid += $row->paid; $due += $row->total - ($row->discount + $row->paid); @endphp @endforeach
SL Customer B Date Total Discount Paid Due Action
{{ $loop->iteration }} {{ $row->bandwidthSaleCustomer->customer_name ?? '' }} {{ $row->billing_date }} {{ $row->total }} {{ $row->discount }} {{ $row->paid }} @php $d_amount = $row->total - ($row->discount + $row->paid); @endphp {{ number_format($d_amount, 2) }}
Total {{ number_format($total, 2) }} {{ number_format($discount, 2) }} {{ number_format($paid, 2) }} {{ number_format($due, 2) }}
@endsection