@php($sl=1)
@php($previousDueAmount = 0)
@if(isset($invoice->previousDue))
@php($previousDue = $invoice->previousDue)
| {{ $sl++ }} |
Previous Due |
{{ $previousDue->description }} |
{{ numberFormat($previousDueAmount = $previousDue->receivable) }} |
@endif
@foreach($details as $detail)
@php($paymentItem = $detail->classItem->item)
| {{ $sl++ }} |
{{ $paymentItem->name }} |
@if($paymentItem->billing_cycle==3)
{{ $detail->month->name }}
@elseif($paymentItem->billing_cycle==2)
{{ $invoice->year }} - {{ $invoice->year+1 }}
@endif
|
{{ numberFormat($detail->receivable_amount) }} |
@endforeach
@php($fine=0) @php($fineDiscount=0)
@if($invoice->status==1)
@if(isset($invoice->fine) and $invoice->invoice_type==3)
| {{ ++$sl }} |
{{ 'Late Fee' }} |
{{ $invoice->fine->delay }} |
@php($fine=$invoice->fine->amount)
{{ numberFormat($fine) }} |
@if($invoice->fine->discount>0)
| {{ ++$sl }} |
{{ 'Discount' }} |
Late Fee |
@php($fineDiscount=$invoice->fine->discount)
{{ numberFormat($fineDiscount) }} |
@endif
@endif
@elseif($invoice->status=2)
@php($delay = invoiceDelay($invoice->deadline))
@if($delay>0)
@php($lateFee = lateFee($invoice->id))
| {{ ++$sl }} |
{{ 'Late Fee' }} |
{{ $lateFee['reference'] }} |
{{-- @php($fine=$delay*siteInfo('daily_fine'))--}}
@php($fine=$lateFee['fine'])
{{ numberFormat($fine) }} |
@endif
@endif
@php($total = $previousDueAmount + $details->sum('receivable_amount')+$fine-$fineDiscount)
| Total |
{{ numberFormat($total) }} |
| In Word: {{ convertNumberToWord($total) }} taka only |
@php($dueDate = invoiceDueDate($invoice->id))
Last date of payment : {{ dateFormat($dueDate,'jS M Y') }}
|
@if($invoice->invoice_type==3)
Important Note:
@php($secondDueDate = secondInvoiceDueDate($invoice->id))
- Tk.500/- will be added as a late fee after {{ dateFormat($dueDate,'jS M Y') }}
- Tk.750/- will be added as a late fee after {{ dateFormat($secondDueDate,'jS M Y') }}
|
@endif