@extends('admin.layout') @section('title', 'Laporan Invoice') @section('content')
Analisis dan laporan komprehensif invoice hotel
| Bulan | Total Invoice | Total Pendapatan | Sudah Dibayar | Belum Dibayar | Rata-rata per Invoice |
|---|---|---|---|---|---|
| {{ \Carbon\Carbon::parse($month)->format('F Y') }} | {{ number_format($data['total_invoices']) }} | Rp {{ number_format($data['total_amount'], 0, ',', '.') }} | Rp {{ number_format($data['paid_amount'], 0, ',', '.') }} | Rp {{ number_format($data['pending_amount'], 0, ',', '.') }} | Rp {{ number_format($data['average_amount'], 0, ',', '.') }} |
| No. Invoice | Tanggal | Booking Code | Nama Tamu | Hotel | Total | Status | Jatuh Tempo |
|---|---|---|---|---|---|---|---|
| {{ $invoice->invoice_number }} | {{ $invoice->created_at->format('d/m/Y') }} | {{ $invoice->booking->booking_code }} | {{ $invoice->booking->guest_name }} | {{ $invoice->booking->room->hotel->name ?? 'N/A' }} | Rp {{ number_format($invoice->total_amount, 0, ',', '.') }} | @php $statusColors = [ 'draft' => 'secondary', 'sent' => 'info', 'paid' => 'success', 'overdue' => 'danger', 'cancelled' => 'dark' ]; $statusLabels = [ 'draft' => 'Draft', 'sent' => 'Terkirim', 'paid' => 'Dibayar', 'overdue' => 'Terlambat', 'cancelled' => 'Dibatalkan' ]; @endphp {{ $statusLabels[$invoice->status] ?? ucfirst($invoice->status) }} | @if($invoice->due_date) {{ \Carbon\Carbon::parse($invoice->due_date)->format('d/m/Y') }} @else - @endif |
| @php $statusColors = [ 'draft' => 'secondary', 'sent' => 'info', 'paid' => 'success', 'overdue' => 'danger', 'cancelled' => 'dark' ]; $statusLabels = [ 'draft' => 'Draft', 'sent' => 'Terkirim', 'paid' => 'Dibayar', 'overdue' => 'Terlambat', 'cancelled' => 'Dibatalkan' ]; @endphp {{ $statusLabels[$status] ?? ucfirst($status) }} | {{ $data['count'] }} invoice | Rp {{ number_format($data['amount'], 0, ',', '.') }} |
| {{ $hotel['name'] }} | {{ $hotel['count'] }} invoice | Rp {{ number_format($hotel['amount'], 0, ',', '.') }} |