@extends('layouts.app')
@section('title', 'الذمم المُعمّرة')
@php
$bucketMeta = [
'0-30' => ['label' => '0–30 يوم', 'color' => 'success', 'icon' => 'clock', 'desc' => 'حديثة — متابعة عادية'],
'31-60' => ['label' => '31–60 يوم', 'color' => 'info', 'icon' => 'clock-hour-3', 'desc' => 'تستحق المتابعة'],
'61-90' => ['label' => '61–90 يوم', 'color' => 'warning', 'icon' => 'alert-triangle', 'desc' => 'متأخرة — تواصل مع المريض'],
'90+' => ['label' => '90+ يوم', 'color' => 'danger', 'icon' => 'alert-octagon', 'desc' => 'حرجة — قد تحتاج إجراء قانوني'],
];
@endphp
@section('content')
| الفاتورة | التاريخ | العمر | المريض | الإجمالي | المتبقي | |
|---|---|---|---|---|---|---|
{{ $inv->invoice_number }}
|
{{ $inv->issue_date->format('Y-m-d') }} |
{{ $initials }}
{{ $name ?: '—' }}
@if($inv->patient?->phone)
{{ $inv->patient->phone }}
@endif
|
{{ number_format($inv->total, 2) }} | {{ number_format($inv->balance, 2) }} |