@extends('admin.layout') @section('title', 'Laporan Invoice') @section('content')

Laporan Invoice

Analisis dan laporan komprehensif invoice hotel

Kembali ke Invoice
Filter Laporan
Total Invoice
{{ number_format($reportData['total_invoices'] ?? 0) }}
Total Pendapatan
Rp {{ number_format($reportData['total_amount'] ?? 0, 0, ',', '.') }}
Sudah Dibayar
Rp {{ number_format($reportData['paid_amount'] ?? 0, 0, ',', '.') }}
{{ $reportData['paid_count'] ?? 0 }} invoice
Belum Dibayar
Rp {{ number_format($reportData['pending_amount'] ?? 0, 0, ',', '.') }}
{{ $reportData['pending_count'] ?? 0 }} invoice
Status Invoice
Pendapatan per Channel Pembayaran
@if(request('report_type') === 'monthly')
Laporan Bulanan
@foreach($reportData['monthly_data'] as $month => $data) @endforeach
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, ',', '.') }}
@endif @if(request('report_type') === 'detailed')
Laporan Detail Invoice
@forelse(($reportData['detailed_rows'] ?? []) as $row) @empty @endforelse
No. Invoice Tanggal Booking Code Nama Tamu Hotel Sumber Booking Kategori Item Unit/Kamar Qty Nominal Status Jatuh Tempo Tanggal Pembayaran
{{ $row['invoice_number'] }} {{ $row['report_date']->format('d/m/Y') }} {{ $row['booking_code'] }} {{ $row['guest_name'] }} {{ $row['hotel_name'] }} {{ $row['booking_source'] }} {{ $row['category'] ?? '-' }} {{ $row['item_name'] ?? '-' }} {{ $row['room_label'] ?? '-' }} {{ number_format($row['quantity'] ?? 0, 0, ',', '.') }} Rp {{ number_format($row['line_amount'] ?? 0, 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[$row['status']] ?? ucfirst($row['status']) }} @if($row['due_date']) {{ $row['due_date']->format('d/m/Y') }} @else - @endif @if($row['paid_at']) {{ $row['paid_at']->format('d/m/Y H:i') }} @else - @endif
Tidak ada data detail untuk rentang tanggal ini.
@endif @if(request('report_type', 'summary') === 'summary')
Breakdown Status
@foreach($reportData['status_breakdown'] as $status => $data) @endforeach
@php $labels = [ 'draft' => 'Draft', 'sent' => 'Terkirim', 'paid' => 'Dibayar', 'overdue' => 'Terlambat', 'cancelled' => 'Dibatalkan' ]; $colors = [ 'draft' => ['#6c757d', '#f2f3f5'], 'sent' => ['#17a2b8', '#e8f7fb'], 'paid' => ['#28a745', '#eaf7ea'], 'overdue' => ['#dc3545', '#fdecef'], 'cancelled' => ['#343a40', '#eceeef'] ]; $c = $colors[$status] ?? ['#6c757d', '#f2f3f5']; @endphp {{ $labels[$status] ?? ucfirst($status) }} {{ $data['count'] }} invoice Rp {{ number_format($data['amount'], 0, ',', '.') }}
Breakdown per Channel Pembayaran
@foreach($reportData['channel_breakdown'] as $channel) @endforeach
{{ $channel['name'] }} {{ $channel['count'] }} invoice Rp {{ number_format($channel['amount'], 0, ',', '.') }}
Breakdown per Sumber Booking
@foreach($reportData['source_breakdown'] as $src) @endforeach
{{ $src['name'] }} {{ $src['count'] }} invoice Rp {{ number_format($src['amount'], 0, ',', '.') }}
@endif
@endsection @push('scripts') @endpush