@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.allergies') }}

@if(count($allergic_drugs_ids_array) > 0) @php $count = (count($allergic_drugs_ids_array) > 2) ? 2 : count($allergic_drugs_ids_array); @endphp @for($i=0 ; $i < $count ; $i++) @endfor
{!! count($allergic_drugs_ids_array) > 2 ? '
' : '' !!} @else
{{ __('allergies.no_allergy_added') }}
@endif
{{ __('allergies.alerts') }}

@if(isset($known_patient_alerts) && count($known_patient_alerts) > 0) @foreach($known_patient_alerts as $alert) @endforeach @else
{{ __('allergies.no_recorded_alerts') }}
@endif
{{ __('allergies.documents') }}

@if(count($documents) > 0)

@else
{{ __('allergies.no_document_added') }}
@endif
@push('scripts') @endpush