@extends('layouts.portal') @section('title', 'Invoices') @section('page_title', 'Invoices') @section('page_subtitle', 'Manage client invoices and payments') @section('sidebar') @include('admin.partials.sidebar', ['active' => 'invoices']) @endsection @section('content')
Ready for Invoice
Completed wills pending invoicing
Total Invoices
All invoices
Pending Payment
Awaiting payment
Paid
Completed
Total Revenue
From paid invoices
View and manage invoice payments
The following trusts need a package assigned before they can be invoiced:
{{ $trust->client ? $trust->client->full_name : 'Unknown Client' }}
Trust ID: {{ $trust->id }} | Status: {{ ucfirst($trust->status) }}
| Document # | Type | Client | Status | Package | Price | Action |
|---|---|---|---|---|---|---|
| #{{ $doc->id }} | {{ $doc->document_type }} |
{{ $doc->client ? $doc->client->full_name : 'Unknown Client' }} {{ $doc->client ? $doc->client->email : 'No email' }} |
{{ ucfirst($doc->status) }} | {{ $doc->package?->name ?? 'N/A' }} | @if($doc->package) RM{{ number_format($doc->package->price, 2) }} @else N/A @endif | @if($doc->type === 'will') Create Invoice @elseif($doc->type === 'trust') Create Invoice @endif |
All wills and trusts with packages are invoiced or pending approval.
Ready to invoice count: {{ $willsReadyForInvoice }}
| Invoice # | Client | Type | Amount | Status | Due Date | Action |
|---|---|---|---|---|---|---|
| {{ $invoice->invoice_number }} |
{{ $invoice->client ? $invoice->client->full_name : 'Unknown Client' }} {{ $invoice->client ? $invoice->client->email : 'No email' }} |
{{ App\Models\Invoice::getTypes()[$invoice->type] }} |
RM{{ number_format($invoice->total_amount, 2) }}
@if($invoice->discount > 0)
Disc: -RM{{ number_format($invoice->discount, 2) }} @endif |
{{ App\Models\Invoice::getStatuses()[$invoice->status] }} | {{ $invoice->due_date->format('d M Y') }} |
No invoices found.