Receivables |
30 Days |
60 Days |
90 Days |
Older |
Current |
@php
$total_30_days = 0;
$total_60_days = 0;
$total_90_days = 0;
$total_older_days = 0;
$total_current = 0;
$total_current_sum = 0;
$percentage_30_days = 0;
$percentage_60_days = 0;
$percentage_90_days = 0;
$percentage_older = 0;
@endphp
@foreach($aged_receivables_data as $key => $receivables_data)
@php
$age_by_day_30 = ($receivables_data->age_by_day_30) ? $receivables_data->age_by_day_30 : number_format(0,$decimal_point);
$age_by_day_60 = ($receivables_data->age_by_day_60) ? $receivables_data->age_by_day_60 : number_format(0,$decimal_point);
$age_by_day_90 = ($receivables_data->age_by_day_90) ? $receivables_data->age_by_day_90 : number_format(0,$decimal_point);
$age_by_before_90 = ($receivables_data->age_by_before_90) ? $receivables_data->age_by_before_90 : number_format(0,$decimal_point);
@endphp
@php($total_30_days += $age_by_day_30)
@php($total_60_days += $age_by_day_60)
@php($total_90_days += $age_by_day_90)
@php($total_older_days += $age_by_before_90)
@php($total_current = ($receivables_data->current_total) ? $receivables_data->current_total : number_format(0,$decimal_point))
@php($total_current_sum += $total_current )
@php($percentage_30_days = !empty($total_30_days) ?($total_30_days / $total_current_sum)*100 :0)
@php($percentage_60_days = !empty($total_60_days) ?($total_60_days / $total_current_sum)*100 :0)
@php($percentage_90_days = !empty($total_90_days) ?($total_90_days / $total_current_sum)*100 :0)
@php($percentage_older = !empty($total_older_days) ?($total_older_days / $total_current_sum)*100 :0)
@if(isset($receivables_data->invoice_no))
{{$receivables_data->invoice_no}}
@else
{{$receivables_data->display_name}}
@endif |
{{number_format($age_by_day_30,$decimal_point)}} |
{{number_format($age_by_day_60,$decimal_point)}} |
{{number_format($age_by_day_90,$decimal_point) }} |
{{number_format($age_by_before_90,$decimal_point) }} |
{{ number_format($total_current,$decimal_point)}} |
@endforeach
|
|
|
|
|
|
Total |
{{!empty($total_30_days) ? number_format($total_30_days,$decimal_point) : number_format(0,$decimal_point)}} |
{{!empty($total_60_days) ? number_format($total_60_days,$decimal_point) : number_format(0,$decimal_point)}} |
{{!empty($total_90_days) ? number_format($total_90_days,$decimal_point) : number_format(0,$decimal_point)}} |
{{!empty($total_older_days)? number_format($total_older_days,$decimal_point) : number_format(0,$decimal_point)}} |
{{!empty($total_current_sum) ? number_format($total_current_sum,$decimal_point) : number_format(0,$decimal_point)}} |
|
{{!empty($percentage_30_days)?number_format($percentage_30_days,$decimal_point): number_format(0,$decimal_point)}}% |
{{!empty($percentage_60_days)?number_format($percentage_60_days,$decimal_point): number_format(0,$decimal_point)}} % |
{{!empty($percentage_90_days)?number_format($percentage_90_days,$decimal_point): number_format(0,$decimal_point)}} % |
{{!empty($percentage_older)?number_format($percentage_older,$decimal_point): number_format(0,$decimal_point)}}% |
|