@if(!empty($checkInvoice))
@if($checkInvoice->type > 0)
Currently your subscription is:
@if(!empty($records->type))
{{ $records->type == 1 ? 'monthly' : ($records->type == 2 ? 'yearly' : 'quarter') }}
@endif
@if(!empty($checkInvoice) && $records->type==1)
Start Date:
{{ \Carbon\Carbon::parse($checkInvoice->due_date)->addDays(1)->format('jS F, Y') }}
End Date:
{{ \Carbon\Carbon::parse($checkInvoice->due_date)->addMonth()->format('jS F, Y') }}
@endif
@if(!empty($checkInvoice) && $records->type==2)
Start Date:
{{ \Carbon\Carbon::parse($checkInvoice->due_date)->addDays(1)->format('jS F, Y') }}
End Date:
{{ \Carbon\Carbon::parse($checkInvoice->due_date)->addYear()->format('jS F, Y') }}
@endif
@if(!empty($checkInvoice) && $records->type==3)
Start Date:
{{ \Carbon\Carbon::parse($checkInvoice->due_date)->addDays(1)->format('jS F, Y') }}
End Date:
{{ \Carbon\Carbon::parse($checkInvoice->due_date)->addDays(90)->format('jS F, Y') }}
@endif
@endif
Cars Washed: {{ $washedDataCount }}
Sent Notifications: {{ $checkInvoice->total_notifications_count??0}}
Transactions With Phone#
{{$washedDataNoMessages}}
Billing Start Date:
{{ \Carbon\Carbon::parse($checkInvoice->whatsapp_start_date)->format('d-m-Y') }}
Billing End Date:
{{ \Carbon\Carbon::parse($checkInvoice->whatsapp_end_date)->format('d-m-Y') }}
Total Charges:
{{ $checkInvoice->total_notifications_count }} x 0.3 =
R {{ number_format($checkInvoice->total_notifications_count * 0.3, 2) }}
* Charges are calculated at 30 cents per WhatsApp Notification.
@else
You currently have nothing to pay
@endif
@if(!empty($checkInvoice))
Download Invoice
@if($checkInvoice->type > 0)
@if($checkInvoice->is_paid == 0)
Pay All
@endif
@endif
@else
@endif
@if(isset($previousBill) && $previousBill->isNotEmpty())
@foreach ($previousBill as $key => $bill)
@if($bill->type > 0)
Subscription Charge: R {{ $bill->amount }}
Subscription Start Date:
{{ \Carbon\Carbon::parse($bill->bill_date)->format('d-m-Y') }}
Subscription End Date:
{{ \Carbon\Carbon::parse($bill->due_date)->format('d-m-Y') }}
@endif
WhatsApp Charge: R {{ $bill->whatsapp_amount ?? '0.00' }}
Total:
R {{ number_format(($bill->amount ?? 0) + ($bill->whatsapp_amount ?? 0), 2) }}
@endforeach
@else
Nothing to show here
@endif