@push('styles') .table td { border-top: 1px solid #e3e6f0; padding: 1.5rem 0.5rem; } .progress { border-radius: 10px; overflow: hidden; } .progress-bar { font-size: 0.75rem; font-weight: 600; } @endpush @extends('admin.layout') @section('title', 'Manajemen Invoice') @section('content')

Manajemen Invoice

Kelola semua invoice dan tagihan hotel

Buat Invoice Baru Laporan
Statistik Invoice

Total Invoice

Total Pendapatan

Sudah Dibayar

Belum Dibayar

{{ number_format($stats['total_invoices']) }}

Invoice

Rp {{ number_format($stats['total_amount'], 0, ',', '.') }}

Semua invoice

Rp {{ number_format($stats['paid_amount'], 0, ',', '.') }}

Invoice lunas

Rp {{ number_format($stats['pending_amount'], 0, ',', '.') }}

Menunggu pembayaran
Status Pembayaran:
@php $paidPercentage = $stats['total_amount'] > 0 ? ($stats['paid_amount'] / $stats['total_amount']) * 100 : 0; $pendingPercentage = 100 - $paidPercentage; @endphp
{{ number_format($paidPercentage, 1) }}% Lunas
{{ number_format($pendingPercentage, 1) }}% Pending
Ringkasan:
  • {{ number_format($stats['paid_invoices']) }} invoice sudah dibayar
  • {{ number_format($stats['pending_invoices']) }} invoice belum dibayar
Filter & Pencarian
Reset
Daftar Invoice
{{ $invoices->total() }} Invoice
@if($invoices->count() > 0)
Terpilih: 0
@foreach($invoices as $invoice) @php $statusConfig = [ 'paid' => ['class' => 'success', 'icon' => 'check-circle', 'text' => 'Lunas'], 'overdue' => ['class' => 'danger', 'icon' => 'exclamation-triangle', 'text' => 'Terlambat'], 'draft' => ['class' => 'secondary', 'icon' => 'edit', 'text' => 'Draft'], 'sent' => ['class' => 'info', 'icon' => 'paper-plane', 'text' => 'Terkirim'], 'cancelled' => ['class' => 'dark', 'icon' => 'times-circle', 'text' => 'Dibatalkan'] ]; $status = $statusConfig[$invoice->status] ?? ['class' => 'light', 'icon' => 'file', 'text' => 'Pending']; @endphp @endforeach
Aksi No. Invoice Tanggal Booking Tamu Total Channel
@csrf @method('DELETE')
{{ $invoice->invoice_number }} {{ $status['text'] }}
{{ $invoice->created_at->format('d/m/Y') }} {{ $invoice->booking->booking_code ?? 'N/A' }}
{{ $invoice->booking->guest_name ?? 'N/A' }}
@php $totalInclude = max(0, (int) ($invoice->subtotal ?? 0) + (int) ($invoice->services_total ?? 0) - (int) ($invoice->discount_amount ?? 0)); @endphp
Rp {{ number_format($totalInclude, 0, ',', '.') }}
@php $chan = $invoice->paymentChannel; @endphp @if($chan) {{ $chan->name }} @else - @endif
@else
Tidak ada invoice ditemukan

Belum ada invoice yang dibuat untuk kriteria pencarian ini.

@endif @if($invoices->hasPages()) @include('admin.custom-pagination', ['paginator' => $invoices]) @endif
@endsection @push('scripts') @endpush