@extends('backend.master') @section('content')
Data Tables
@php $total=0;$installment=0; @endphp @foreach($buyers as $buyer) @foreach($buyer->plots as $plot) @php $paid=$buyer->advance_amount+$plot->buyerInstallments->sum('amount_payed'); $remaining=($plot->booking_price-$buyer->advance_amount)-$plot->buyerInstallments->sum('amount_payed'); @endphp @php $total+=$plot->buyerInstallments->sum('amount_payed'); $installment+=$plot->buyerInstallments->count(); @endphp @endforeach @endforeach
File Number Owner Name Remaining Amount Paid Amount Total Installments Recieved Installment Date/time Entry Date/Time
{{$plot->plot_file_no}} {{$buyer->full_name}}{{$remaining}} {{$paid}} {{$plot->buyerInstallments->count()}} {{$buyer->created_at->format('d')}} of every month {{$buyer->created_at}}

Total Installments Amount : {{$total}}

   

No of Installments : {{$installment}}

@stop