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

Purchase List

@php $total = 0; $paid = 0; $due = 0; @endphp @foreach ($list as $item) @php $total += $item->total_price; $paid += $item->paid; $due += $item->total_price - $item->paid; @endphp @endforeach
SL Invoice Document Provider Billing Date Total Paid Due Action
{{ $item->id }} {{ $item->invoice_no }} {{ $item->provider->company_name ?? '' }} {{ $item->billing_date }} {{ $item->total_price }} {{ $item->paid }} @php $d_amount = $item->total_price - $item->paid; @endphp {{ number_format($d_amount, 2) }}
Total {{ number_format($total, 2) }} {{ number_format($paid, 2) }} {{ number_format($due, 2) }}
@endsection @section('ajax') @endsection