@extends('adminlte::page') @section('title', 'Invoice') @section('content')
{{-- Watermark --}} Watermark
{{-- Header --}}
School Logo

{{ config('app.name', 'School Management System') }}

Official Invoice

{{ config('school.address', 'Kisarawe, Pwani') }} | {{ config('school.phone', '+255 000 000 000') }}
Invoice No: #{{ str_pad($invoice->id, 5, '0', STR_PAD_LEFT) }}
Date: {{ $invoice->payment_date ? $invoice->payment_date->format('d M, Y H:i') : 'N/A' }}

{{-- Budget & Payment Info --}}
Budget Information
Department {{ $invoice->budget->department->name ?? 'N/A' }}
Month / Year {{ $invoice->budget->month }} / {{ $invoice->budget->year }}
Status {{ ucfirst(str_replace('_', ' ', $invoice->status)) }}
Note {{ $invoice->budget->note ?? '-' }}
Payment Information
Amount TZS {{ number_format($invoice->amount, 2) }}
Approved By {{ $invoice->approvedBy->name ?? '-' }}
Paid By {{ $invoice->paidBy->name ?? '-' }}
Payment Date {{ $invoice->payment_date ? $invoice->payment_date->format('d M, Y H:i') : '-' }}
Note {{ $invoice->note ?? '-' }}
{{-- Invoice Items --}}
Invoice Items
@foreach($invoiceItems as $item) @endforeach
# Item Description Amount (TZS) Status Approved By Note / Comment
{{ $loop->iteration }} {{ $item->item }} {{ $item->description ?? '-' }} {{ number_format($item->price, 2) }} {{ ucfirst(str_replace('_', ' ', $item->status)) }} {{ $item->approvedBy->name ?? '-' }} {{ $item->note ?? '-' }}
{{-- Totals --}}
Total Amount (TZS) {{ number_format($totalAmount, 2) }}
Paid (TZS) {{ number_format($paidAmount, 2) }}
Remaining (TZS) {{ number_format($remainingAmount, 2) }}
{{-- Signature Area --}}

__________________________

Approved By (DO)

__________________________

Paid By (Finance)

__________________________

Received By

{{-- Footer Buttons --}}
Back
Thank you for your payment!
@stop