Total Row: {{ $list->count() }}
@if (auth()->user()->id == 1) @endif @php($totalOtc = 0 ) @php($totalOtcDiscount = 0 ) @foreach ($list as $p) @if (auth()->user()->id == 1) @endif @php($totalOtc += $p->paid_amount) @php($totalOtcDiscount += $p->discount_amount) @endforeach
#id Date Username Name Paid DiscountOTC
{{ $p->id }} {{ date('d-M-Y h:i:s A', strtotime($p->created_at)) }} {{ $p->clients->userid ?? '' }} {{ $p->clientsinfo->clients_name ?? '' }} {{ $p->paid_amount }} {{ $p->discount_amount }}{{ $p->clientsinfo->otc ?? '' }}
Total {{ number_format($totalOtc, 2, '.', '') }} {{ number_format($totalOtcDiscount, 2, '.', '') }}