@if (session()->has('patient_id') || session()->has('patients_id')) @endif @push('scripts') @endpush @push('styles') @endpush
@php $known_patient_allergies = \Streamline\Models\Allergy::where('patient_id' , $patient->id)->orderBy('created_at','desc')->take(2)->get(); $known_patient_alerts = \Streamline\Models\Alert::where('patient_id' , $patient->id)->orderBy('created_at','desc')->take(2)->get(); $categories = \Streamline\Models\PatientCategory::pluck("name", "id"); $drug_categories_array = DB::table('drug_categories')->pluck('name', 'id'); $drug_categories = \Streamline\Models\DrugCategory::orderBy('name', 'asc')->get(); @endphp {{ __('allergies.category') }} : {{ isset($categories[$patient->category_id]) ? $categories[$patient->category_id] : "N/A" }}
{{ __('allergies.patient_number') }} {{ __('allergies.full_names') }} {{ __('allergies.gender') }} {{ __('allergies.age') }} {{ __('allergies.national_id') }}
{{ $patient->number }} {!! insurance_flag($patient->id) !!} @if(patient_insurance_status($patient->id) == 1) ({{ __('patients.joined_chi_scheme') }} {{patient_duration_on_chi_sheme($patient->id)}}) @endif {{ $patient->gender == 1 ? __('allergies.male') : __('allergies.female') }} {{ get_patients_age($patient->date_of_birth) }} {!! ($patient->national_id == null || $patient->national_id == "") ? "National ID Missing" : strtoupper($patient->national_id) !!}
@if(count($allergic_drugs_ids_array) > 0) @if(isset($allergic_drugs_ids_array[0]) && isset($drug_categories_array[$allergic_drugs_ids_array[0]])) • {{ $drug_categories_array[$allergic_drugs_ids_array[0]] }}
@endif @if(isset($allergic_drugs_ids_array[1]) && isset($drug_categories_array[$allergic_drugs_ids_array[1]])) • {{ $drug_categories_array[$allergic_drugs_ids_array[1]] }}
@endif @else {{ __('allergies.no_recorded_allergies') }} @endif
@if(count($allergic_drugs_ids_array) > 0) {{ __('allergies.view_all') }} @endif
@if(isset($known_patient_alerts) && count($known_patient_alerts) > 0) @if(isset($known_patient_alerts[0])) • {{ $known_patient_alerts[0]->alerts }}
@endif @if(isset($known_patient_alerts[1])) • {{ $known_patient_alerts[1]->alerts }}
@endif @else {{ __('allergies.no_recorded_alerts') }} @endif
@if(isset($known_patient_alerts) && count($known_patient_alerts) > 0) View All @endif
@php $date_of_birth = get_name($patient->id, 'id', 'date_of_birth', 'patients'); $dob = new Carbon\Carbon($date_of_birth); $age_diff_months = $dob->diffInMonths(Carbon\Carbon::now()); @endphp @if($age_diff_months < 61 && is_smart_discharge_enabled())
@if(is_patient_currently_admitted($patient->id)) {!! get_post_discharge_mortality_risk($patient->id) !!} @else @php // just generate the row without displaying anything $disregard_this = get_post_discharge_mortality_risk($patient->id); @endphp Patient is not admitted @endif
@endif
×

{{ __('allergies.allergies_updated') }}

×

{{ __('allergies.alerts_updated') }}


@push('scripts') @endpush