@extends('admin.layout_admin.main') @section('css') @endsection @section('content') @php $filters = []; if (request()->filled('q')) { $filters[] = 'Từ khóa: ' . e(request('q')) . ''; } if (request()->filled('status')) { $statuses = ['0' => 'Chưa thanh toán', '1' => 'Đã thanh toán']; $filters[] = 'Trạng thái: ' . ($statuses[request('status')] ?? 'Không rõ') . ''; } if (request()->filled('filter_mode')) { $mode = request('filter_mode'); $label = match ($mode) { 'today' => 'Hôm nay', 'this_week' => 'Tuần này', 'this_month' => 'Tháng này', 'this_year' => 'Năm nay', default => null, }; if ($label) { $filters[] = 'Chế độ lọc: ' . $label . ''; } } @endphp
Kết quả tìm kiếm: {!! implode(', ', $filters) !!}
@endif @if ($prescriptions->count() > 0)| STT | Mã | Giấy khám bệnh | Bệnh nhân | Bác sĩ | Tổng tiền (VNĐ) | Trạng thái | Hành động |
|---|---|---|---|---|---|---|---|
| {{ $prescriptions->firstItem() + $key }} | {{ $prescription->prescription_code }} | {{ $prescription->medical_certificate->medical_certificate_code }} | {{ $prescription->medical_certificate->patient->name ?? 'Lỗi' }} | {{ $prescription->doctor->name }} | {{ number_format($prescription->total_payment, 0, ',', '.') }} | @if ($prescription->status == 1) Đã thanh toán @else Chưa thanh toán @endif |
Chưa có đơn thuốc nào!
@endif