@extends('layouts.app') @section('title', $invoice->invoice_no) @section('crumbs') Dashboard/Invoices/{{ $invoice->invoice_no }} @endsection @section('content')

Invoice items

@forelse ($invoice->items as $item) @empty @endforelse
Description Amount
{{ $item->description }} @if ($item->feeStructure)
{{ $item->feeStructure->feeCategory?->name ?? 'Fee structure' }}
@endif
GH₵ {{ number_format($item->amount, 2) }}
No items on this invoice yet.
@can('manage', $invoice)
@csrf
@endcan

Payments received

@forelse ($invoice->payments as $payment) @empty @endforelse
Payment Date Method Amount Reference Received by
{{ $payment->payment_no }} {{ $payment->paid_at?->format('d M Y H:i') }} {{ ['cash' => 'Cash', 'mobile_money' => 'Mobile money', 'bank_transfer' => 'Bank transfer', 'card' => 'Card', 'cheque' => 'Cheque', 'other' => 'Other'][$payment->method] ?? ucfirst($payment->method) }} GH₵ {{ number_format($payment->amount, 2) }} {{ $payment->reference ?? '—' }} {{ $payment->receivedBy?->full_name ?? '—' }}
No payments recorded against this invoice.

Summary

Subtotal GH₵ {{ number_format($invoice->subtotal, 2) }}
Discount GH₵ {{ number_format($invoice->discount, 2) }}
Total GH₵ {{ number_format($invoice->total, 2) }}
Amount paid GH₵ {{ number_format($invoice->amount_paid, 2) }}
Balance GH₵ {{ number_format($invoice->balance, 2) }}
Academic year: {{ $invoice->academicYear?->name ?? '—' }} @if ($invoice->academicTerm) · Term: {{ $invoice->academicTerm->name }} @endif
@can('manage', $invoice)

Record payment

@if ($invoice->balance <= 0.009)
This invoice is fully settled — nothing to collect.
@else
@csrf
@endif
@endcan
@endsection @push('head') @endpush