{{--The ID to be printed--}}
@if($prescription->prescriptionDrugs()->count()>0 || $prescription->prescriptionPharmacyDrugs()->count()>0)

{{$patient->clinic->name}}
{{$patient->clinic->address}}
{{$patient->clinic->phone}}
{{$patient->clinic->email}}

Patient : {{$patient->first_name}} {{$patient->last_name}} {{$patient->dob ? Utils::getAge($patient->dob) : ""}} {{Utils::getFormattedDate($prescription->created_at)}}

    @foreach($prescription->prescriptionDrugs as $drug)
  1. {{$drug->drug->name}} ({{$drug->dosage ? $drug->dosage->description:""}} {{$drug->frequency ? ", ".$drug->frequency->description:""}} {{$drug->period ? ", ".$drug->period->description:""}})
  2. @endforeach
@if($prescription->prescriptionPharmacyDrugs()->count()>0)

Drugs to be taken from a pharmacy

    @foreach($prescription->prescriptionPharmacyDrugs as $index=>$pharmacyDrug)
  1. {{$pharmacyDrug->drug}} {{$pharmacyDrug->remarks ? "(Remarks : ".$pharmacyDrug->remarks.")" : ""}}
  2. @endforeach
@endif
@else {{-- Info message if there are no prescriptions to be issued --}}

Sorry!

There's no drugs in this prescription to be printed.
@endif

Important!

When printing the prescriptions, avoid printing headers and footers by changing Print Settings from the print preview.
{{--@if($prescription->prescriptionPharmacyDrugs()->count()>0)--}}
{{--@endif--}}