@extends('layouts.main') @push('styles') @endpush @section('content')
{{ $hospital_information->phone_number }}, {{ $hospital_information->email }},
{{ get_name($hospital_information->sub_county,'id', 'name', 'subcounties') }}, {{ get_name($hospital_information->district,'id', 'name', 'districts') }},
{{ $hospital_information->country }}.
| {{ __('payments.items') }} | {{ __('payments.vendor') }} | {{ __('payments.quantity') }} | {{ __('payments.unit_cost') }} | {{ __('payments.amount_paid') }} | {{ __('payments.paid_from_bank') }} | {{ __('payments.staff') }} | {{ __('payments.transaction_date') }} | {{ __('payments.record_date') }} | @if(Auth::user()->can('delete-payment-record')){{ __('payments.action') }} | @endif
|---|---|---|---|---|---|---|---|---|---|
|
@php
$bill = \Streamline\Models\HospitalBill::find($item->bill_id);
$items = explode(',', $bill->item_ids);
$quantities = explode(',', $bill->item_quantities);
@endphp
@if($bill->bill_type == 'DRU')
@for($x = 0; $x < count($items); $x++)
{{ get_name($items[$x], 'id', 'name', 'drugs') }} @endfor @elseif($bill->bill_type == 'SUN') @for($x = 0; $x < count($items); $x++) {{ get_name($items[$x], 'id', 'name', 'sundries') }} @endfor @elseif($bill->bill_type == 'DEN') @for($x = 0; $x < count($items); $x++) {{ get_name($items[$x], 'id', 'name', 'dentals') }} @endfor @elseif($bill->bill_type == 'RAD') @for($x = 0; $x < count($items); $x++) {{ get_name($items[$x], 'id', 'name', 'radiologies') }} @endfor @elseif($bill->bill_type == 'LAB') @for($x = 0; $x < count($items); $x++) {{ get_name($items[$x], 'id', 'name', 'labs') }} @endfor @elseif($bill->bill_type == 'GEN') @for($x = 0; $x < count($items); $x++) {{ get_name($items[$x], 'id', 'name', 'general_items') }} @endfor @elseif($bill->bill_type == 'PAY') @for($x = 0; $x < count($items); $x++) {{ get_name($items[$x], 'id', 'name', 'payment_items') }} @endfor @elseif($bill->bill_type == 'EYE') @for($x = 0; $x < count($items); $x++) {{ get_name($items[$x], 'id', 'name', 'eye_glasses') }} @endfor @endif |
{{ get_name($item->vendor, 'id', 'name', 'suppliers') }} |
@for($x = 0; $x < count($items); $x++)
{{ $quantities[$x]." units" }} @endfor |
@if($bill->bill_type == 'DRU')
@for($x = 0; $x < count($items); $x++)
{{ ugandan_shillings(get_name($items[$x], 'id', 'cost_price', 'drugs')) }} @endfor @elseif($bill->bill_type == 'SUN') @for($x = 0; $x < count($items); $x++) {{ ugandan_shillings(get_name($items[$x], 'id', 'cost_price', 'sundries')) }} @endfor @elseif($bill->bill_type == 'DEN') @for($x = 0; $x < count($items); $x++) {{ ugandan_shillings(get_name($items[$x], 'id', 'cost_price', 'dentals')) }} @endfor @elseif($bill->bill_type == 'RAD') @for($x = 0; $x < count($items); $x++) {{ ugandan_shillings(get_name($items[$x], 'id', 'cost_price', 'radiologies')) }} @endfor @elseif($bill->bill_type == 'LAB') @for($x = 0; $x < count($items); $x++) {{ ugandan_shillings(get_name($items[$x], 'id', 'cost_price', 'labs')) }} @endfor @elseif($bill->bill_type == 'GEN') @for($x = 0; $x < count($items); $x++) {{ ugandan_shillings(get_name($items[$x], 'id', 'cost_price', 'general_items')) }} @endfor @elseif($bill->bill_type == 'PAY') @for($x = 0; $x < count($items); $x++) {{ ugandan_shillings(get_name($items[$x], 'id', 'unit_cost', 'payment_items')) }} @endfor @elseif($bill->bill_type == 'EYE') @for($x = 0; $x < count($items); $x++) {{ ugandan_shillings(get_name($items[$x], 'id', 'buying_price', 'eye_glasses')) }} @endfor @endif |
{{ ugandan_shillings($item->amount) }} | {{ get_name($item->account_id, 'id', 'name', 'chart_of_accounts') }} | {{ get_full_name($item->created_by, 'id', 'first_name', 'last_name', 'users') }} | {{ streamline_date($item->expense_date) }} | {{ streamline_date_time_short($item->created_at) }} | @if(Auth::user()->can('delete-payment-record'))@if(is_payment_transaction_reconciled($item->id) == false) @else {{ __('payments.undo_payment') }} @endif | @endif
| {{ __('payments.total') }} | {{ ugandan_shillings($total) }} | @if(Auth::user()->can('delete-payment-record')) | @endif |