@extends('layouts.app') @section('title', 'Laporan Bulanan') @section('content')
{{ \Carbon\Carbon::createFromDate($year, $month, 1)->translatedFormat('F Y') }}
Total Pendapatan
Rp {{ number_format($totalRevenue, 0, ',', '.') }}
Invoice Terbayar
{{ $paidInvoices }} / {{ $totalInvoices }}
{{ $totalInvoices > 0 ? round(($paidInvoices / $totalInvoices) * 100, 1) : 0 }}% collection rate
Pelanggan Baru
{{ $newCustomers }}
Pelanggan Churn
{{ $churnedCustomers }}
| Tanggal | Jumlah Invoice | Pendapatan | Aksi |
|---|---|---|---|
| {{ $day['date'] }} {{ \Carbon\Carbon::createFromDate($year, $month, 1)->translatedFormat('F') }} | {{ $day['count'] }} invoice | Rp {{ number_format($day['revenue'], 0, ',', '.') }} | Detail |