@extends('layouts.owner') @section('breadcrumb') Laporan / Tunggakan @endsection @section('content')

Laporan Tunggakan

Analisa piutang dan keterlambatan pembayaran.

Export CSV

Total Tunggakan Aktif

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

Jumlah Penghuni Menunggak

{{ $data['count'] }} Orang

@if($data['items']->isEmpty())

Yeay! Tidak ada tunggakan.

Semua penghuni sudah membayar tagihan mereka tepat waktu.

@else @foreach($data['items'] as $invoice)
{{ substr($invoice->resident->user->name, 0, 1) }}

{{ $invoice->resident->user->name }}

{{ $invoice->lease->room->property->name }} - Unit {{ $invoice->lease->room->room_number }}

#{{ $invoice->invoice_number }} Rp {{ number_format($invoice->total_amount, 0, ',', '.') }} {{ $invoice->due_date->translatedFormat('d M Y') }} @if($invoice->overdue_days > 0) Telat {{ $invoice->overdue_days }} Hari @else Menunggu (H-{{ abs($invoice->due_date->diffInDays(now())) }}) @endif Kirim Reminder @endforeach
@endif @endsection