@php($totalDue = 0 ) @foreach ($list as $p) @endforeach
#id Date Type C Name username Reseller POP MR ID Col By Entry BY Package Amount Discount Due
{{ $p->id }} {{ date('d-M-Y h:i:s A', strtotime($p->created_at)) }} {{ $p->income->head->name ?? '' }} {{ $p->clientsinfo->clients_name ?? '' }} {{ $p->clients->userid ?? '' }} {{ $p->clients->pop->reseller->name ?? '' }} {{ $p->clients->pop->popname ?? '' }} {{ $p->money_receipt_number }} {{ $p->user->name ?? '' }} {{ $p->employee->name ?? '' }} {{ $p->clients->packages->package_name ?? '' }} {{ $p->paid_amount }} {{ $p->discount_amount }} {{ $p->clients->customerAccount->dueAmount > 0 ? $p->clients->customerAccount->dueAmount : 0 }} @php($totalDue+= ($p->clients->customerAccount->dueAmount > 0 ? $p->clients->customerAccount->dueAmount : 0) ) {{-- @php() --}}