@php $db_settings = \App\Models\Setting::get(); $settings = []; foreach ($db_settings as $row) { $settings[$row->name] = $row->value; } @endphp
@if (isset($settings['icon']) && is_file('storage/settings/' . $settings['icon'])) @endif

{{ $settings['website_name'] ?? '' }}

{{ $settings['address'] ?? '' }}

{{ $settings['number_1'] ?? '' }}{{ $settings['number_2'] ? ', ' . $settings['number_2'] : '' }}

@if (isset($settings['icon']) && is_file('storage/settings/' . $settings['icon'])) @endif

Patient Receipt

Patient Name
{{ $item?->pat?->name }}
Patient No
{{ $item?->pat?->phone }}
Date
{{ \Carbon\Carbon::parse($item->date)->format('d M, Y') }}
Invoice No
{{ $item?->sr?->service_name }}
@php $counter = 1; $total = 0; $paid = (float) $item?->payment ?? 0; @endphp @foreach ($item?->sr?->repeater as $key => $rep) @php $total += $rep->rate * $rep->quantity; @endphp @endforeach
# Service Description Amount Quantity Sub Total
{{ $key + 1 }} Service charges {{ $rep->srv_type->name ?? 'N/A' }} {{ $rep->rate }} $ {{ $rep->quantity }} {{ $rep->rate * $rep->quantity }} $
# Discount {{ $discount }} $
Total Amount {{ $total - $discount }} $

Payment Details

Paid: {{ $paid }} $
Total Paid: {{ $total_paid }} $

Balance Details

Total Amount: {{ $total - $discount }} $
Balance: {{ ($total - $discount) - $total_paid }} $
Thank you for choosing {{ $settings['website_name'] ?? '' }}!