mirror of
https://gitlab.com/signalytic/client-external/streamline/streamline-emr.git
synced 2026-09-11 18:51:31 +00:00
updated streamline-setup v2
This commit is contained in:
+95
-23
@@ -13,6 +13,13 @@
|
||||
background: #b6cce2;
|
||||
border: 1px solid #e4e7ea;
|
||||
}
|
||||
|
||||
.modal_diagnosis {
|
||||
position: fixed;
|
||||
left: 50%;
|
||||
top: 50%;
|
||||
transform: translate(-50%, -50%);
|
||||
}
|
||||
</style>
|
||||
@endpush
|
||||
|
||||
@@ -51,6 +58,10 @@
|
||||
@php
|
||||
$parent_episode_details = \Streamline\Models\PatientEpisode::find($episode->parent_episode_id);
|
||||
$parent_consultations = \Streamline\Models\Consultation::where(['episode_id' => $parent_episode_details->id])->get();
|
||||
//consultation notes
|
||||
$consultation_notes = \Streamline\Models\WardInpatientDetailedNote::where(['patient_id' => $patient_id, 'episode_id' => $parent_episode_details->id, 'ward_id' => 0])->latest()->get(['investigation_and_management_plan_comments', 'clinic_examination_comments', 'history_comments', 'created_by','created_at']);
|
||||
$consultation_notes_details = count($consultation_notes) > 0 ? $consultation_notes : null;
|
||||
$consultation_notes_created_at = isset($consultation_notes_details) ? streamline_date($consultation_notes_details->pluck('created_at')->first()) : null;
|
||||
$parent_consultation_details = count($parent_consultations) > 0 ? $parent_consultations->first() : null;
|
||||
$parent_triage_details = \Streamline\Models\Triage::where(['id' => $parent_episode_details->triage_id])->first();
|
||||
|
||||
@@ -818,26 +829,84 @@
|
||||
|
||||
@if($consultation_with_notes)
|
||||
<div class="white-box">
|
||||
@if(check_if_episode_is_a_followup($episode->id) && !is_null($parent_consultation_details))
|
||||
@php
|
||||
$parent_consultation_history = $parent_consultation_details->history_comments;
|
||||
$parent_consultation_clinical_examination = $parent_consultation_details->clinic_examination_comments;
|
||||
$parent_consultation_inv_and_mgt = $parent_consultation_details->investigation_and_management_plan_comments;
|
||||
@endphp
|
||||
@if(check_if_episode_is_a_followup($episode->id) && !is_null($consultation_notes_details))
|
||||
|
||||
<font color="green"><b>History {{ __('consultations.for_episode_of') }} {{ streamline_date($parent_consultation_details->created_at) }}</b></font>
|
||||
<textarea class="form-control" name="parent_history_comments" readonly>{{ $parent_consultation_history }}</textarea>
|
||||
{{-- fetch all consultation notes --}}
|
||||
@if ( count($consultation_notes) > 0 )
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<font color="green"><b>{{ __('consultations.clinical_examination') }} {{ __('consultations.for_episode_of') }} {{ streamline_date($parent_consultation_details->created_at) }}</b></font>
|
||||
<textarea class="form-control" name="parent_clinic_examination_comments" readonly>{{ $parent_consultation_clinical_examination }}</textarea>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<font color="green"><b>{{ __('consultations.investigation_and_mgt_plan') }} {{ __('consultations.for_episode_of') }} {{ streamline_date($parent_consultation_details->created_at) }}</b></font>
|
||||
<textarea class="form-control" name="parent_investigation_and_management_plan_comments" readonly>{{ $parent_consultation_inv_and_mgt }}</textarea>
|
||||
</div>
|
||||
</div>
|
||||
{{-- History consultation notes --}}
|
||||
|
||||
<h4>{{ __('consultations.consultation_for_episode_of') }} {{ streamline_date($consultation_notes_created_at) }}</h4>
|
||||
|
||||
<table class="table table-condensed color-bordered-table success-bordered-table " style="table-layout: fixed; width:100%">
|
||||
<tr>
|
||||
<thead>
|
||||
<th colspan="2" class="line-height-table" >{{ __('consultations.history') }}</th>
|
||||
<th></th>
|
||||
</thead>
|
||||
</tr>
|
||||
|
||||
@forelse ($consultation_notes as $consultation_note)
|
||||
@if(!empty($consultation_note->history_comments))
|
||||
<tr>
|
||||
<td colspan="2" class="line-height-table" style="width:80%; word-wrap:break-word;"> {{ $consultation_note->history_comments ?? '' }} </td>
|
||||
<td class="line-height-table" style="width:20%; word-wrap:break-word;"> By {{ get_full_name($consultation_note->created_by, 'id', 'first_name', 'last_name', 'users') }} on {{ streamline_date_time($consultation_note->created_at) ?? '' }} </td>
|
||||
|
||||
</tr>
|
||||
@endif
|
||||
@empty
|
||||
{{-- <tr><td colspan="4" class="line-height-table"><code>{{ __('consultations.no_previous_notes') }}</code></td></tr> --}}
|
||||
@endforelse
|
||||
</table>
|
||||
|
||||
{{-- Clinic Examination consultation notes --}}
|
||||
|
||||
<table class="table table-condensed color-bordered-table success-bordered-table " style="table-layout: fixed; width:100%">
|
||||
<tr>
|
||||
<thead>
|
||||
<th colspan="2" class="line-height-table">{{ __('consultations.clinical_examination') }}</th>
|
||||
<th></th>
|
||||
</thead>
|
||||
</tr>
|
||||
|
||||
@forelse ($consultation_notes as $consultation_note)
|
||||
@if(!empty($consultation_note->clinic_examination_comments))
|
||||
<tr>
|
||||
<td colspan="2" class="line-height-table" style="width:80%; word-wrap:break-word;"> {{ $consultation_note->clinic_examination_comments ?? '' }} </td>
|
||||
<td class="line-height-table" style="width:20%; word-wrap:break-word;"> By {{ get_full_name($consultation_note->created_by, 'id', 'first_name', 'last_name', 'users') }} on {{ streamline_date_time($consultation_note->created_at) ?? '' }} </td>
|
||||
</tr>
|
||||
@endif
|
||||
@empty
|
||||
|
||||
{{-- <tr><td colspan="4" class="line-height-table"><code>{{ __('consultations.no_previous_notes') }}</code></td></tr> --}}
|
||||
|
||||
@endforelse
|
||||
</table>
|
||||
|
||||
{{-- Investigation and Management Plan consultation notes --}}
|
||||
<table class="table table-condensed color-bordered-table success-bordered-table " style="table-layout: fixed; width:100%">
|
||||
<tr>
|
||||
<thead>
|
||||
<th colspan="2" class="line-height-table">{{ __('consultations.investigation_and_mgt_plan') }}</th>
|
||||
<th></th>
|
||||
</thead>
|
||||
</tr>
|
||||
|
||||
@forelse ($consultation_notes as $consultation_note)
|
||||
@if(!empty($consultation_note->investigation_and_management_plan_comments))
|
||||
<tr>
|
||||
<td colspan="2" class="line-height-table" style="width:80%; word-wrap:break-word;"> {{ $consultation_note->investigation_and_management_plan_comments ?? '' }} </td>
|
||||
<td class="line-height-table" style="width:20%; word-wrap:break-word;"> By {{ get_full_name($consultation_note->created_by, 'id', 'first_name', 'last_name', 'users') }} on {{ streamline_date_time($consultation_note->created_at) ?? '' }} </td>
|
||||
</tr>
|
||||
@endif
|
||||
@empty
|
||||
{{-- <tr class="line-height-table"><td colspan="4"><code>{{ __('consultations.no_previous_notes') }}</code></td></tr> --}}
|
||||
@endforelse
|
||||
</table>
|
||||
|
||||
@endif
|
||||
|
||||
{{-- end fetch all consultation notes --}}
|
||||
@endif
|
||||
|
||||
<h4>{{ __('consultations.history') }}</h4>
|
||||
@@ -886,7 +955,7 @@
|
||||
</div>
|
||||
</td>
|
||||
<td style="width: 45%; color: #C85F6A;">
|
||||
<div class="well well-sm" id="primary_diagnosis_prompt">{{ $diagnoses_all->firstWhere('id',$parent_consultation_details->primary_diagnosis)->prompts }} </div>
|
||||
<div class="well well-sm" id="primary_diagnosis_prompt">{{ $diagnoses_all->firstWhere('id',$parent_consultation_details->primary_diagnosis)->prompts?? '' }} </div>
|
||||
</td>
|
||||
<td>
|
||||
<div class="well well-sm" id="primary_diagnosis_reference">
|
||||
@@ -2012,8 +2081,8 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="modal fade" id="confirm_diagnosis_modal" tabindex="-1" role="dialog" style="min-width: 400px;position: absolute;top: 80%;left: 10%;">
|
||||
<div class="modal-dialog modal-dialog-centered" role="document">
|
||||
<div class="modal fade modal_diagnosis " id="confirm_diagnosis_modal" role="dialog" aria-labelledby="exampleModalLongTitle" aria-hidden="true">
|
||||
<div class="modal-dialog" style="max-width: 60%;" role="document">
|
||||
<div class="modal-content">
|
||||
<div class="modal-body form-group">
|
||||
<div class="modal-header"></div>
|
||||
@@ -2027,6 +2096,8 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
@@ -2208,6 +2279,7 @@
|
||||
let prim_diag = $('#primary_diagnosis').val();
|
||||
$('#confirm_primary_diagnosis').val(prim_diag).trigger('change');
|
||||
$('#confirm_diagnosis_modal').modal('toggle');
|
||||
$('#confirm_primary_diagnosis').select2({ width: '96%'});
|
||||
|
||||
}
|
||||
|
||||
@@ -2399,7 +2471,7 @@
|
||||
});
|
||||
});
|
||||
|
||||
$('#primary_diagnosis, #confirm_primary_diagnosis, .procedure_performed_by').select2({
|
||||
$('#primary_diagnosis, .procedure_performed_by').select2({
|
||||
placeholder: "-- select --",
|
||||
width: "100%"
|
||||
});
|
||||
@@ -2460,7 +2532,7 @@
|
||||
function submit_after_confirmation(){
|
||||
let confirmed = $('#confirm_primary_diagnosis').val();
|
||||
$('#primary_diagnosis').val(confirmed).trigger('change');
|
||||
$("<input type='text' value='complete' />").attr("id", "complete_consultation").attr("name", "submit-btn").appendTo("#consultation_form");
|
||||
$("<input type='hidden' value='complete' />").attr("id", "complete_consultation").attr("name", "submit-btn").appendTo("#consultation_form");
|
||||
$('#consultation_form').submit();
|
||||
}
|
||||
</script>
|
||||
|
||||
+228
-35
@@ -13,10 +13,24 @@
|
||||
background: #b6cce2;
|
||||
border: 1px solid #e4e7ea;
|
||||
}
|
||||
.modal_diagnosis {
|
||||
position: fixed;
|
||||
left: 50%;
|
||||
top: 50%;
|
||||
transform: translate(-50%, -50%);
|
||||
}
|
||||
|
||||
/* increase width of select2 */
|
||||
.select2-container {
|
||||
width: 100% !important;
|
||||
}
|
||||
</style>
|
||||
@endpush
|
||||
|
||||
@section('content')
|
||||
|
||||
|
||||
|
||||
<div class="row bg-title">
|
||||
<div class="col-lg-3 col-md-4 col-sm-4 col-xs-12">
|
||||
<h4 class="page-title">{{ __('consultations.edit_consultation') }}</h4>
|
||||
@@ -50,6 +64,7 @@
|
||||
$parent_consultations = \Streamline\Models\Consultation::where(['episode_id' => $parent_episode_details->id])->get();
|
||||
$parent_consultation_details = count($parent_consultations) > 0 ? $parent_consultations->first() : null;
|
||||
$parent_triage_details = \Streamline\Models\Triage::where(['id' => $parent_episode_details->triage_id])->first();
|
||||
$parent_consultation_notes = \Streamline\Models\WardInpatientDetailedNote::where(['patient_id' => $episode->patient_id, 'episode_id' => $episode->parent_episode_id, 'ward_id' => 0])->get();
|
||||
|
||||
if(check_if_episode_is_a_followup($parent_episode_details->id)){
|
||||
$episode_has_grand_parent_episode = true;
|
||||
@@ -624,39 +639,131 @@
|
||||
|
||||
@if($consultation_with_notes)
|
||||
<div class="white-box">
|
||||
@if(check_if_episode_is_a_followup($episode->id) && !is_null($parent_consultation_details))
|
||||
@php
|
||||
$parent_consultation_history = $parent_consultation_details->history_comments;
|
||||
$parent_consultation_clinical_examination = $parent_consultation_details->clinic_examination_comments;
|
||||
$parent_consultation_inv_and_mgt = $parent_consultation_details->investigation_and_management_plan_comments;
|
||||
@endphp
|
||||
|
||||
<font color="green"><b>History {{ __('consultations.for_episode_of') }} {{ streamline_date($parent_consultation_details->created_at) }}</b></font>
|
||||
<textarea class="form-control" name="parent_history_comments" readonly>{{ $parent_consultation_history }}</textarea>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<font color="green"><b>{{ __('consultations.clinical_examination') }} {{ __('consultations.for_episode_of') }} {{ streamline_date($parent_consultation_details->created_at) }}</b></font>
|
||||
<textarea class="form-control" name="parent_clinic_examination_comments" readonly>{{ $parent_consultation_clinical_examination }}</textarea>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<font color="green"><b>{{ __('consultations.investigation_and_mgt_plan') }} {{ __('consultations.for_episode_of') }} {{ streamline_date($parent_consultation_details->created_at) }}</b></font>
|
||||
<textarea class="form-control" name="parent_investigation_and_management_plan_comments" readonly>{{ $parent_consultation_inv_and_mgt }}</textarea>
|
||||
<div class="row">
|
||||
<div class="col">
|
||||
<table class="table table-hover color-table success-table table-bordered" style="table-layout:fixed; width:100%;">
|
||||
<thead>
|
||||
<tr><th colspan="{{ (Auth::user()->can('edit-consultation-note') || Auth::user()->can('delete-consultation-note'))? '5':'4' }}" class="text-center">{{ __('consultations.previous_notes') }}</th></tr>
|
||||
<tr>
|
||||
<th>{{ __('consultations.history') }}</th>
|
||||
<th>{{ __('consultations.clinical_examination') }}</th>
|
||||
<th>{{ __('consultations.investigation_and_mgt_plan') }}</th>
|
||||
<th>{{ __('consultations.date') }}</th>
|
||||
@if(Auth::user()->can('edit-consultation-note') || Auth::user()->can('delete-consultation-note'))
|
||||
<th>{{ __('banking.action') }}</th>
|
||||
@endif
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@forelse ($consultation_notes as $consultation_note)
|
||||
<tr id="row_{{ $consultation_note->id }}">
|
||||
<td id="clinic_history_comments_{{ $consultation_note->id }}" style="word-wrap:break-word;">{{ $consultation_note->history_comments }}</td>
|
||||
<td id="clinic_examination_comments_{{ $consultation_note->id }}" style="word-wrap:break-word;">{{ $consultation_note->clinic_examination_comments }}</td>
|
||||
<td id="investigation_and_management_plan_comments_{{ $consultation_note->id }}" style="word-wrap:break-word;">{{ $consultation_note->investigation_and_management_plan_comments}}</td>
|
||||
<td id="created_{{ $consultation_note->id }}" style="word-wrap:break-word;">{{ streamline_date_time($consultation_note->created_at) }} <br> by {{ $users[$consultation_note->created_by]?? '' }}</td>
|
||||
@if (Auth::user()->can('edit-consultation-note') || Auth::user()->can('delete-consultation-note'))
|
||||
<td style="word-wrap:break-word;">
|
||||
@if(Auth::user()->can('edit-consultation-note'))
|
||||
<a class="btn btn-inverse btn-sm btn-rounded" onclick="show_edit_consultation_clinical_notes_modal({{ $consultation_note->id }})" title="{{ __('consultations.edit_clinical_note') }}"><i class="fa fa-pencil"></i> {{ __('consultations.edit_clinical_note') }}</a>
|
||||
@endif
|
||||
|
||||
@if(Auth::user()->can('delete-consultation-note'))
|
||||
<a class="btn btn-danger btn-sm btn-rounded" style="margin-left: 5px" id="delete_row_{{ $consultation_note->id }}" onclick="delete_consultation_clinical_notes({{ $consultation_note->id }})" title="Delete this note"><i class="fa fa-trash"></i></a>
|
||||
@endif
|
||||
</td>
|
||||
@endif
|
||||
</tr>
|
||||
<input type='hidden' value='{{ $consultation_note->clinic_examination_comments}}' name='prev_clinic_examination_comments' id='prev_clinic_examination_comments_{{ $consultation_note->id }}' />
|
||||
<input type='hidden' value='{{ $consultation_note->history_comments}}' name='prev_clinic_history_comments' id='prev_clinic_history_comments_{{ $consultation_note->id }}' />
|
||||
<input type='hidden' value='{{ $consultation_note->investigation_and_management_plan_comments}}' name='prev_investigation_and_management_plan_comments' id='prev_investigation_and_management_plan_comments_{{ $consultation_note->id }}' />
|
||||
{{ Form::hidden('deleted_notes[]', '', ['id' => 'deleted_note_id_'.$consultation_note->id]) }}
|
||||
@empty
|
||||
<tr><td colspan="{{ (Auth::user()->can('edit-consultation-note') || Auth::user()->can('delete-consultation-note'))? '5':'4' }}"><code>{{ __('consultations.no_previous_notes') }}</code></td></tr>
|
||||
@endforelse
|
||||
</tbody>
|
||||
</table>
|
||||
@if (!empty($view_notes))
|
||||
<tr id="read_more"><td colspan="5"><a class="read_more font-weight-bold" style="color : #0099CC; float: right;" onclick="show_all_consultation_notes();">{{ __('consultations.view_more_notes') }}</a></td></tr>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
<div class="row col" id="all_consultation_notes" style="display: none">
|
||||
<div class="panel-group" >
|
||||
<div class="panel panel-inverse">
|
||||
<div class="panel-heading">
|
||||
<h4 class="panel-title">
|
||||
<a data-toggle="collapse" data-parent="#accordion" href="#collapse_all_notes">{{ __('consultations.all_consultation_notes') }}</a>
|
||||
</h4>
|
||||
</div>
|
||||
<div class="panel-body table-bordered" id="collapse_all_notes">
|
||||
<table class="table table-hover color-table success-table table-bordered">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{{ __('consultations.history') }}</th>
|
||||
<th>{{ __('consultations.clinical_examination') }}</th>
|
||||
<th>{{ __('consultations.investigation_and_mgt_plan') }}</th>
|
||||
<th>{{ __('consultations.date') }}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@foreach ($view_notes as $note)
|
||||
<tr>
|
||||
<td>{{ $note->history_comments }}</td>
|
||||
<td>{{ $note->clinic_examination_comments }}</td>
|
||||
<td>{{ $note->investigation_and_management_plan_comments}}</td>
|
||||
<td>{{ streamline_date_time($note->created_at) }} <br> by {{ $users[$note->created_by]?? '' }}</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
|
||||
<h4>{{ __('consultations.history') }}</h4>
|
||||
<textarea class="form-control" name="history_comments" rows="5" placeholder="Notes Here...">{{ $consultation->history_comments }}</textarea>
|
||||
</div>
|
||||
</div>
|
||||
<div class="white-box">
|
||||
@if(check_if_episode_is_a_followup($episode->id) && !empty($parent_consultation_notes))
|
||||
<div class="row">
|
||||
<div class="col table-responsive">
|
||||
<table class="table table-hover color-table success-table table-bordered" style="table-layout:fixed;">
|
||||
<thead>
|
||||
<tr><th colspan="4">Previously Added Consultation Notes {{ __('consultations.for_episode_of') }} {{ streamline_date($parent_consultation_details->created_at) }}</th></tr>
|
||||
<tr>
|
||||
<th>{{ __('consultations.history') }}</th>
|
||||
<th>{{ __('consultations.clinical_examination') }}</th>
|
||||
<th>{{ __('consultations.investigation_and_mgt_plan') }}</th>
|
||||
<th>{{ __('consultations.date') }}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@forelse ($parent_consultation_notes as $consultation_note)
|
||||
<tr>
|
||||
<td style="word-wrap:break-word;">{{ $consultation_note->history_comments }}</td>
|
||||
<td style="word-wrap:break-word;">{{ $consultation_note->clinic_examination_comments }}</td>
|
||||
<td style="word-wrap:break-word;">{{ $consultation_note->investigation_and_management_plan_comments}}</td>
|
||||
<td style="word-wrap:break-word;">{{ streamline_date_time($consultation_note->created_at) }} <br> by {{ $users[$consultation_note->created_by]?? '' }}</td>
|
||||
</tr>
|
||||
@empty
|
||||
<tr><td colspan="4"><code>No previously added consultation notes {{ __('consultations.for_episode_of') }} {{ streamline_date($parent_consultation_details->created_at) }}.</code></td></tr>
|
||||
@endforelse
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<h4>{{ __('consultations.clinical_examination') }}</h4>
|
||||
<textarea class="form-control" name="clinic_examination_comments" rows="5" placeholder="Notes Here...">{{ $consultation->clinic_examination_comments }}</textarea>
|
||||
<div class="col">
|
||||
<h4>{{ __('consultations.history') }}</h4>
|
||||
<textarea class="form-control" name="history_comments" rows="5" placeholder="History Notes Here..."></textarea>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="col">
|
||||
<h4>{{ __('consultations.clinical_examination') }}</h4>
|
||||
<textarea class="form-control" name="clinic_examination_comments" rows="5" placeholder="Clinic Examination Notes Here..."></textarea>
|
||||
</div>
|
||||
<div class="col">
|
||||
<h4>{{ __('consultations.investigation_and_mgt_plan') }}</h4>
|
||||
<textarea class="form-control" name="investigation_and_management_plan_comments" rows="5" placeholder="Notes Here...">{{ $consultation->investigation_and_management_plan_comments }}</textarea>
|
||||
<textarea class="form-control" name="investigation_and_management_plan_comments" rows="5" placeholder="Investigation and Management Plan Notes Here..."></textarea>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -917,7 +1024,7 @@
|
||||
<tr>
|
||||
<td><input type="checkbox" name="chk" id="chk"></td>
|
||||
<td style="width: 30%;">
|
||||
{{ Form::select('other_diagnosis[]', $diagnoses, '', ['class' => 'sec_d form-control col-sm-12']) }}
|
||||
{{ Form::select('other_diagnosis[]', $diagnoses, '', ['class' => 'sec_d form-control col-sm-12 ']) }}
|
||||
</td>
|
||||
<td style="width: 45%"><div class="well well-sm" id="secondary_diagnosis_prompt1"> </div></td>
|
||||
<td style="width: 25%"><div class="well well-sm" id="secondary_diagnosis_reference1"> </div></td>
|
||||
@@ -928,7 +1035,7 @@
|
||||
<tr>
|
||||
<td><input type="checkbox" name="chk" id="chk"></td>
|
||||
<td style="width: 30%;">
|
||||
{{ Form::select('other_diagnosis[]', $diagnoses, $diagnosis, ['class' => 'sec_d form-control col-sm-12']) }}
|
||||
{{ Form::select('other_diagnosis[]', $diagnoses, $diagnosis, ['class' => 'other_diagnosisx sec_d form-control col-sm-12']) }}
|
||||
</td>
|
||||
<td style="width: 45%; color: #C85F6A;"><div class="well well-sm" id="secondary_diagnosis_prompt1">{{ is_object($diagnoses_all->firstWhere('id',$diagnosis)) ? $diagnoses_all->firstWhere('id',$diagnosis)->prompts : '' }} </div></td>
|
||||
<td style="width: 25%"><div class="well well-sm" id="secondary_diagnosis_reference1">{{ is_object($diagnoses_all->firstWhere('id',$diagnosis)) ? $diagnoses_all->firstWhere('id',$diagnosis)->reference_names : '' }} </div></td>
|
||||
@@ -1927,8 +2034,8 @@
|
||||
{{ Form::label('followup_in_charge', __('consultations.assign_incharge')) }}
|
||||
<select name="followup_in_charge" class="form-control col-sm-12 compulsory">
|
||||
<option value="0" selected>{{ __('consultations.not_assigned') }}</option>
|
||||
@foreach($users as $user)
|
||||
<option value="{{ $user->id }}">{{ $user->first_name }} {{ $user->last_name }}</option>
|
||||
@foreach($users as $key => $user)
|
||||
<option value="{{ $key }}">{{ $user }}</option>
|
||||
@endforeach
|
||||
</select>
|
||||
</div>
|
||||
@@ -2023,8 +2130,8 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="modal fade" id="confirm_diagnosis_modal" tabindex="-1" role="dialog" style="min-width: 400px;position: absolute;top: 80%;left: 10%;">
|
||||
<div class="modal-dialog modal-dialog-centered" style="align-items: flex-end;" role="document">
|
||||
<div class="modal fade modal_diagnosis " id="confirm_diagnosis_modal" role="dialog" aria-labelledby="exampleModalLongTitle" aria-hidden="true">
|
||||
<div class="modal-dialog" style="max-width: 60%;" role="document">
|
||||
<div class="modal-content">
|
||||
<div class="modal-body form-group">
|
||||
<h4 class="modal-title" id="exampleModalLabel1">{{ __('consultations.confirm_primary_diagnosis') }}</h4>
|
||||
@@ -2036,7 +2143,42 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
<!-- modal to add a new referral -->
|
||||
<div class="modal" id="modal-consultation-notes" tabindex="-1" aria-labelledby="exampleModalLongTitle" aria-hidden="true" role="dialog" style="top:5%;min-height:70%; ">
|
||||
<div class="modal-dialog modal-lg modal-dialog-centered" role="document">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
|
||||
<h4 class="modal-title">Edit Clinical Consultation Notes</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<div class="row">
|
||||
<h4>{{ __('consultations.history') }}</h4>
|
||||
<textarea class="form-control" name="edit_history_comments" rows="3" id="edit_history_comments">Yes</textarea>
|
||||
</div>
|
||||
<div class="row">
|
||||
<h4>{{ __('consultations.clinical_examination') }}</h4>
|
||||
<textarea class="form-control" name="edit_clinic_examination_comments" rows="3" id="edit_clinic_examination_comments"></textarea>
|
||||
</div>
|
||||
<div class="row">
|
||||
<h4>{{ __('consultations.investigation_and_mgt_plan') }}</h4>
|
||||
<textarea class="form-control" name="edit_investigation_and_management_plan_comments" rows="3" id="edit_investigation_and_management_plan_comments"></textarea>
|
||||
</div>
|
||||
{{ Form::hidden('note_id', '', ['id' => 'note_id']) }}
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">Cancel</button>
|
||||
<a class="btn btn-primary" onclick="edit_consultation_clinical_notes()">Edit Notes</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
@@ -2181,6 +2323,7 @@
|
||||
let prim_diag = $('#primary_diagnosis').val();
|
||||
$('#confirm_primary_diagnosis').val(prim_diag).trigger('change');
|
||||
$('#confirm_diagnosis_modal').modal('toggle');
|
||||
$('#confirm_primary_diagnosis').select2({ width: '96%'});
|
||||
}
|
||||
|
||||
function submitDiagnosis(){
|
||||
@@ -2291,7 +2434,7 @@
|
||||
});
|
||||
});
|
||||
|
||||
$('#primary_diagnosis, #confirm_primary_diagnosis, .procedure_performed_by').select2({
|
||||
$('#primary_diagnosis, .procedure_performed_by, .other_diagnosis').select2({
|
||||
placeholder: "-- select --",
|
||||
width: "100%"
|
||||
});
|
||||
@@ -2343,8 +2486,58 @@
|
||||
function submit_after_confirmation(){
|
||||
let confirmed = $('#confirm_primary_diagnosis').val();
|
||||
$('#primary_diagnosis').val(confirmed).trigger('change');
|
||||
$("<input type='text' value='complete' />").attr("id", "complete_consultation").attr("name", "submit-btn").appendTo("#consultation_edit_form");
|
||||
$("<input type='hidden' value='complete' />").attr("id", "complete_consultation").attr("name", "submit-btn").appendTo("#consultation_edit_form");
|
||||
$('#consultation_edit_form').submit();
|
||||
}
|
||||
|
||||
function delete_consultation_clinical_notes(row_id){
|
||||
if(confirm('Are you sure you want to delete this clinical note?')){
|
||||
$("#deleted_note_id_"+row_id).val(row_id);
|
||||
$("#row_"+row_id).hide();
|
||||
}
|
||||
}
|
||||
|
||||
function show_edit_consultation_clinical_notes_modal(id){
|
||||
$("#note_id").val(id);
|
||||
var investigation_and_management_plan_comments = $('#prev_investigation_and_management_plan_comments_'+id).val();
|
||||
var clinic_examination_comments = $('#prev_clinic_examination_comments_'+id).val();
|
||||
var history_comments = $('#prev_clinic_history_comments_'+id).val();
|
||||
$("#edit_investigation_and_management_plan_comments").val(investigation_and_management_plan_comments);
|
||||
$("#edit_clinic_examination_comments").val(clinic_examination_comments);
|
||||
$("#edit_history_comments").val(history_comments);
|
||||
$('#modal-consultation-notes').modal('show');
|
||||
}
|
||||
|
||||
function edit_consultation_clinical_notes(){
|
||||
var id = $("#note_id").val();
|
||||
var investigation_and_management_plan_comments = $("#edit_investigation_and_management_plan_comments").val();
|
||||
var clinic_examination_comments = $("#edit_clinic_examination_comments").val();
|
||||
var history_comments =$("#edit_history_comments").val();
|
||||
|
||||
$.ajax({
|
||||
method: 'POST',
|
||||
url: '/update_consultation_clinical_notes',
|
||||
data: {'id' : id, 'investigation_and_management_plan_comments':investigation_and_management_plan_comments, 'clinic_examination_comments':clinic_examination_comments, 'history_comments':history_comments },
|
||||
success: function(response){
|
||||
if(!isNaN(response)){
|
||||
|
||||
$('#clinic_examination_comments_'+id).html(clinic_examination_comments);
|
||||
$('#clinic_history_comments_'+id).html(history_comments);
|
||||
$('#investigation_and_management_plan_comments_'+id).html(investigation_and_management_plan_comments);
|
||||
$('#modal-consultation-notes').modal('hide'); //manually hide the modal
|
||||
} else {
|
||||
alert("Clinical Notes could not be edited.");
|
||||
}
|
||||
},
|
||||
error: function(jqXHR, textStatus, errorThrown) {
|
||||
console.log(JSON.stringify(jqXHR));
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function show_all_consultation_notes(){
|
||||
$('.read_more').hide();
|
||||
$('#all_consultation_notes').show();
|
||||
}
|
||||
</script>
|
||||
@endpush
|
||||
|
||||
+377
-74
@@ -56,9 +56,9 @@
|
||||
<div class="container-fluid">
|
||||
@include('layouts.header_pdf_print')
|
||||
|
||||
<h5 class="heading" style="text-align: center;"> OUT-PATIENT REFERRAL NOTES</h5>
|
||||
<h5 class="heading" style="text-align: center;"> OUTPATIENT REFERRAL NOTE</h5>
|
||||
|
||||
<div class="row">
|
||||
<div class="row col">
|
||||
<table class="table table-light table-sm table-borderless">
|
||||
<tr>
|
||||
<th scope="row">{{ __('inpatient.patient_number') }}</th>
|
||||
@@ -76,14 +76,16 @@
|
||||
<th>Consultation Date</th>
|
||||
<td>
|
||||
{{ streamline_date($consultation->created_at) }}
|
||||
</td>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row">{{ __('inpatient.age') }}</th>
|
||||
<td><?php echo get_patients_age($patient->date_of_birth); ?></td>
|
||||
<td>{{ get_patients_age($patient->date_of_birth, $consultation->created_at) }}</td>
|
||||
<td style="border-top: 0px;"> </td>
|
||||
<th></th>
|
||||
<th>Referral Number</th>
|
||||
<td>
|
||||
{{ $patient->number }}
|
||||
</td>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
@@ -102,95 +104,396 @@
|
||||
</table>
|
||||
</div>
|
||||
|
||||
{{-- Symptoms, Priority and Emergency Signs --}}
|
||||
<div class="row">
|
||||
@if( Auth::user()->can('view-patient-episode-primary-diagnoses'))
|
||||
<div class="col">
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<strong>Primary Diagnosis</strong>
|
||||
<div class="card-deck">
|
||||
<div class="card border-0">
|
||||
<div class="card-block">
|
||||
<div class="card-header">
|
||||
<h5 class="card-title text-center">{{ __('consultations.symptoms') }}</h5>
|
||||
</div>
|
||||
@if (!empty($triage->symptoms) || !empty($consultation->symptoms))
|
||||
@php
|
||||
$symptoms_explode = !empty($triage->symptoms)? explode(",", $triage->symptoms):explode(",", $consultation->symptoms);
|
||||
$symptoms_duration = !empty($triage->symptom_duration)? explode(",", $triage->symptom_duration):explode(",", $consultation->symptom_duration);
|
||||
@endphp
|
||||
<p class="card-text">
|
||||
<ul class="list-group list-group-flush">
|
||||
@foreach ($symptoms_explode as $key => $symptom)
|
||||
<li class="list-group-item text-center">{{ ucwords($symptoms[$symptom] ?? '') }} for {{ $symptoms_duration[$key]?? '' }}</li>
|
||||
@endforeach
|
||||
</ul>
|
||||
</p>
|
||||
@else
|
||||
<p class="card-text">
|
||||
<ul class="list-group list-group-flush">
|
||||
<li class='list-group-item text-center font-weight-bold text-danger'>{{ __('consultations.no_symptom_recorded') }}</li>
|
||||
</ul>
|
||||
</p>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
@if (between($years, 0, 12))
|
||||
<div class="card border-0">
|
||||
<div class="card-block">
|
||||
<div class="card-header">
|
||||
<h5 class="card-title text-center">{{ __('triage.emergency_signs') }}</h5>
|
||||
</div>
|
||||
@if (!empty($emergent_signs))
|
||||
<p class="card-text">
|
||||
<ul class="list-group list-group-flush">
|
||||
@foreach ($emergent_signs as $emergent_sign)
|
||||
<li class='list-group-item text-center'>{{ ucwords($emergent_sign ?? '') }}</li>
|
||||
@endforeach
|
||||
</ul>
|
||||
</p>
|
||||
@else
|
||||
<p class="card-text text-success">
|
||||
<ul class="list-group list-group-flush">
|
||||
<li class='list-group-item text-center text-success font-weight-bold'>{{ __('layout.no_emergency_signs') }}</li>
|
||||
</ul>
|
||||
</p>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
<div class="card border-0">
|
||||
<div class="card-block">
|
||||
<div class="card-header">
|
||||
<h5 class="card-title text-center">{{ __('layout.priority_signs') }}</h5>
|
||||
</div>
|
||||
@if (count($priority_signs) > 0)
|
||||
<p class="card-text">
|
||||
<ul class="list-group list-group-flush">
|
||||
@foreach ($priority_signs as $priority_sign)
|
||||
<li class='list-group-item text-center'>{{ ucwords($priority_sign ?? '') }}</li>
|
||||
@endforeach
|
||||
</ul>
|
||||
</p>
|
||||
@else
|
||||
<p class="card-text">
|
||||
<ul class="list-group list-group-flush">
|
||||
<li class='list-group-item text-center text-success font-weight-bold'>{{ __('layout.no_priority_signs') }}</li>
|
||||
</ul>
|
||||
</p>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
@if (isset($triage->any_tb_sysmptoms) && $triage->any_tb_sysmptoms == 1)
|
||||
<div class="card border-0">
|
||||
<div class="card-block">
|
||||
<div class="card-header">
|
||||
<h5 class="card-title text-center">{{ __('layout.tb_screening') }}</h5>
|
||||
</div>
|
||||
<table class="table table-bordered">
|
||||
<tr class="cough_tb_question">
|
||||
<td>A cough for more than two weeks?</td>
|
||||
<td>{{ $triage->cough_for_2_weeks == 1 ? "Yes" : "No" }}</td>
|
||||
</tr>
|
||||
<tr class="fever_tb_question">
|
||||
<td>Persistent fevers for 2 weeks or more?</td>
|
||||
<td>{{ $triage->fever_for_2_weeks == 1 ? "Yes" : "No" }}</td>
|
||||
</tr>
|
||||
<tr class="weight_loss_tb_question">
|
||||
<td>Noticeable weight loss of more than 3 Kg?</td>
|
||||
<td>{{ $triage->tb_weight_loss == 1 ? "Yes" : "No" }}</td>
|
||||
</tr>
|
||||
<tr class="weight_loss_tb_question">
|
||||
<td>Poor weight gain in the last one month?</td>
|
||||
<td>{{ $triage->tb_poor_weight_gain == 1 ? "Yes" : "No" }}</td>
|
||||
</tr>
|
||||
<tr class="excessive_night_sweats_tb_question">
|
||||
<td>Excessive night sweats for three weeks or more?</td>
|
||||
<td>{{ $triage->tb_excessive_night_sweats == 1 ? "Yes" : "No" }}</td>
|
||||
</tr>
|
||||
<tr class="excessive_night_sweats_tb_question">
|
||||
<td>Contact with a person with pulmonary TB or chronic cough?</td>
|
||||
<td>{{ $triage->tb_contact_with_tb_person == 1 ? "Yes" : "No" }}</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
</div> <br>
|
||||
|
||||
<div class="row">
|
||||
<div class="col">
|
||||
<div class="card-deck">
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<strong>Primary Diagnosis</strong>
|
||||
</div>
|
||||
<table class="table table-light table-sm">
|
||||
<thead>
|
||||
<tr>
|
||||
<td>{{ $all_diagnoses[$consultation->primary_diagnosis]?? "" }}</td>
|
||||
</tr>
|
||||
</thead>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
@php
|
||||
$primary_diagnosis = \Streamline\Models\Diagnosis::withTrashed()->find($consultation->primary_diagnosis);
|
||||
@endphp
|
||||
|
||||
<table class="table table-light table-sm">
|
||||
<thead>
|
||||
<tr>
|
||||
<td>{{ $primary_diagnosis ? $primary_diagnosis->name : "" }}</td>
|
||||
</tr>
|
||||
</thead>
|
||||
</table>
|
||||
$other_diagnoses = @unserialize($consultation->other_diagnoses);
|
||||
@endphp
|
||||
|
||||
@if(!empty($other_diagnoses))
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<strong>Secondary Diagnosis</strong>
|
||||
</div>
|
||||
<table class="table table-light table-sm">
|
||||
<thead>
|
||||
@foreach($other_diagnoses as $diagnosis)
|
||||
<tr>
|
||||
<td>{{ $all_diagnoses[$diagnosis]?? "" }}</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
</thead>
|
||||
</table>
|
||||
</div>
|
||||
@endif
|
||||
</div>
|
||||
|
||||
@php
|
||||
$other_diagnoses = @unserialize($consultation->other_diagnoses);
|
||||
@endphp
|
||||
|
||||
@if(!empty($other_diagnoses))
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<strong>Secondary Diagnosis</strong>
|
||||
</div>
|
||||
<table class="table table-light table-sm">
|
||||
<thead>
|
||||
@foreach($other_diagnoses as $diagnosis)
|
||||
@php
|
||||
$other_diagnosis = \Streamline\Models\Diagnosis::withTrashed()->find($diagnosis);
|
||||
@endphp
|
||||
<tr>
|
||||
<td>{{ $other_diagnosis ? $other_diagnosis->name : "" }}</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
</thead>
|
||||
</table>
|
||||
</div>
|
||||
@endif
|
||||
</div>
|
||||
</div> <br>
|
||||
|
||||
<div class="row">
|
||||
@if(!is_null($consultation->comments))
|
||||
<div class="col">
|
||||
<table class="table table-sm table-bordered">
|
||||
<thead class="thead-light">
|
||||
<tr><th>{{ __('patient_episode.comments') }}</th></tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr><td>{!! nl2br(e($consultation->comments)) !!}</td></tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
@endif
|
||||
|
||||
@if(!is_null($consultation->history_comments))
|
||||
<div class="col">
|
||||
<table class="table table-sm table-bordered">
|
||||
<thead class="thead-light">
|
||||
<tr><th>{{ __('patient_episode.history_comments') }}</th></tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr><td>{!! nl2br(e($consultation->history_comments)) !!}</td></tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
@endif
|
||||
|
||||
@if(!is_null($consultation->clinic_examination_comments))
|
||||
<div class="col">
|
||||
<table class="table table-sm table-bordered">
|
||||
<thead class="thead-light">
|
||||
<tr><th>{{ __('patient_episode.clinic_examination_comments') }}</th></tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr><td>{!! nl2br(e($consultation->clinic_examination_comments)) !!}</td></tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
@endif
|
||||
</div>
|
||||
|
||||
@if (!empty($cons_notes))
|
||||
<table class="table table-sm table-bordered">
|
||||
<thead class="thead-light">
|
||||
<tr><th colspan="4" class="text-center">{{ __('consultations.previous_notes') }}</th></tr>
|
||||
<tr>
|
||||
<th>{{ __('consultations.history') }}</th>
|
||||
<th>{{ __('consultations.clinical_examination') }}</th>
|
||||
<th>{{ __('consultations.investigation_and_mgt_plan') }}</th>
|
||||
<th>{{ __('consultations.date') }}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@forelse ($cons_notes as $consultation_note)
|
||||
<tr>
|
||||
<td>{{ $consultation_note->history_comments }}</td>
|
||||
<td>{{ $consultation_note->clinic_examination_comments }}</td>
|
||||
<td>{{ $consultation_note->investigation_and_management_plan_comments}}</td>
|
||||
<td>{{ streamline_date_time($consultation_note->created_at) }}</td>
|
||||
</tr>
|
||||
@empty
|
||||
<tr><td colspan="4"><code>{{ __('consultations.no_previous_notes') }}</code></td></tr>
|
||||
@endforelse
|
||||
</tbody>
|
||||
</table>
|
||||
@endif
|
||||
|
||||
<div class="row">
|
||||
@if(count($opd_investigations) > 0)
|
||||
<div class="col">
|
||||
<table class="table table-light table-sm table-bordered">
|
||||
<thead class="thead-light">
|
||||
<tr>
|
||||
<th>{{ __('patient_file.investigation') }}</th>
|
||||
<th>{{ __('patient_file.result') }}</th>
|
||||
<th>{{ __('patient_file.normal_ranges') }}</th>
|
||||
<th>{{ __('patient_file.comment') }}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@if(count($opd_investigations) > 0)
|
||||
@for($i = 0; $i < count($opd_investigations['name']); $i++)
|
||||
@if(isset($opd_investigations['name'][$i]))
|
||||
<tr>
|
||||
<td>{{ $opd_investigations['name'][$i] }}</td>
|
||||
<td>
|
||||
@if (!empty($opd_investigations['type'][$i]))
|
||||
<strong><code>See attached</code></strong>
|
||||
@else
|
||||
{!! nl2br(e($opd_investigations['value'][$i])) !!}
|
||||
@endif
|
||||
</td>
|
||||
<td>{{ $opd_investigations['normal_ranges'][$i] }}</td>
|
||||
<td>{!! nl2br(e($opd_investigations['comment'][$i])) !!}</td>
|
||||
</tr>
|
||||
@endif
|
||||
@endfor
|
||||
@endif
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
@endif
|
||||
|
||||
@if(count($ordered_procedures) > 0)
|
||||
<div class="col">
|
||||
<table class="table table-light table-sm table-bordered">
|
||||
<thead class="thead-light">
|
||||
<tr><th>{{ __('patient_episode.procedure_name') }}</th></tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@foreach($ordered_procedures as $procedure)
|
||||
@php
|
||||
$procedure_ids = explode(',', $procedure->procedure_id);
|
||||
@endphp
|
||||
@foreach ($procedure_ids as $id)
|
||||
<tr>
|
||||
<td>{{ $procedures[$id] ?? "" }}</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
@endforeach
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
@endif
|
||||
</div>
|
||||
|
||||
<br>
|
||||
|
||||
<div class="row">
|
||||
<div class="col">
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<strong>Investigations done</strong>
|
||||
</div>
|
||||
<table class="table table-light table-sm">
|
||||
<thead>
|
||||
@if(count($ward_investigations) > 0)
|
||||
@for($i = 0; $i < count($ward_investigations['name']); $i++)
|
||||
@if(in_array($i, $ward_investigations_position))
|
||||
<tr>
|
||||
<td colspan="3">
|
||||
<h5><code>{{ $ward_investigations_date[array_search($i, $ward_investigations_position)] }}</code></h5>
|
||||
</td>
|
||||
</tr>
|
||||
@endif
|
||||
@if(count($treatments) > 0)
|
||||
<div class="col">
|
||||
<table class="table table-bordered table-sm">
|
||||
<thead class="thead-light">
|
||||
<tr>
|
||||
<th>{{ __('patient_file.treatment') }}</th>
|
||||
<th>{{ __('patient_file.dosage_freq') }}</th>
|
||||
<th></th>
|
||||
<th>{{ __('prescriptions.instructions') }}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@php $progressive_ids = []; @endphp
|
||||
@foreach($treatments as $treatment)
|
||||
<?php
|
||||
$drugs_array = explode(",", $treatment->drugs);
|
||||
$dosage_array = explode(",", $treatment->doses);
|
||||
$dosage2_array = explode(",", $treatment->dose2);
|
||||
$frequencies_array = explode(",", $treatment->frequencies);
|
||||
$duration_array = explode(",", $treatment->durations);
|
||||
$quantity_dispensed_array = explode(",", $treatment->quantities_dispensed);
|
||||
$instructions_array = explode(",", $treatment->instruction);
|
||||
$purchased_elsewhere_array = explode(",", $treatment->purchased_elsewhere);
|
||||
|
||||
// check if treatment is progressive and ignore
|
||||
if ($treatment->is_treatment_progressive != 0) {
|
||||
$progressive_ids[] = $treatment->is_treatment_progressive;
|
||||
continue;
|
||||
}
|
||||
?>
|
||||
@for ($x = 0; $x < count($drugs_array); $x++)
|
||||
<?php
|
||||
$drug_details = \Streamline\Models\Drug::find($drugs_array[$x]);
|
||||
|
||||
if (!$drug_details) {
|
||||
continue;
|
||||
}
|
||||
|
||||
$drug_form_name = get_name($drug_details->form_id, "id", "name", "unit_of_measure");
|
||||
$drug_unit = get_name($drug_details->unit_id, "id", "name", "drug_units");
|
||||
$drug_strength = $drug_details->strength;
|
||||
|
||||
$treatment_dosage = $dosage_array[$x] ?? "";
|
||||
$treatment_strength = $drug_strength ?? "";
|
||||
?>
|
||||
|
||||
<tr>
|
||||
<td>{{ $ward_investigations['name'][$i] }}</td>
|
||||
<input type="hidden" name="ward_investigation_ids[]" value="{{ $ward_investigations['id'][$i] }}">
|
||||
<td>
|
||||
@if($ward_investigations['type'][$i] == 1 && $ward_investigations['value'][$i] != "Pending")
|
||||
<i style="color: blue"> Refer to investigation report </i>
|
||||
@else
|
||||
{{ $ward_investigations['value'][$i] }}
|
||||
{{ $drug_details->name }}
|
||||
|
||||
@if($purchased_elsewhere_array[$x] == 1)
|
||||
<code>( To Be Purchased elsewhere )</code>
|
||||
@endif
|
||||
</td>
|
||||
<td>{{ $ward_investigations['comment'][$i] }}</td>
|
||||
<td>
|
||||
({{ $dosage_array[$x] }} {!! $drug_unit !!} {{ get_name($frequencies_array[$x], 'id', 'name', 'dosage_frequencies') }})
|
||||
</td>
|
||||
<td>{{ $duration_array[$x] ?? "" }}</td>
|
||||
<td>{{ $instructions_array[$x] ?? "" }}</td>
|
||||
</tr>
|
||||
@endfor
|
||||
@else
|
||||
<tr>
|
||||
<td colspan="3">No investigations done</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
|
||||
@if(count($progressive_ids) > 0)
|
||||
@php
|
||||
$progressive_treatments = \Illuminate\Support\Facades\DB::table('treatments_opd_progressive')->whereIn('id', $progressive_ids)->get();
|
||||
@endphp
|
||||
|
||||
@foreach($progressive_treatments as $treatment)
|
||||
<?php
|
||||
$drugs_array = explode(",", $treatment->drugs);
|
||||
$dosage_array = explode(",", $treatment->dose);
|
||||
$frequencies_array = explode(",", $treatment->drug_frequency);
|
||||
$duration_array = explode(",", $treatment->durations);
|
||||
$quantity_dispensed_array = explode(",", $treatment->quantities_to_dispense);
|
||||
$instructions_array = explode(",", $treatment->instruction);
|
||||
?>
|
||||
@for ($x = 0; $x < count($drugs_array); $x++)
|
||||
<?php
|
||||
$drug_details = \Streamline\Models\Drug::find($drugs_array[$x]);
|
||||
|
||||
if (!$drug_details) {
|
||||
continue;
|
||||
}
|
||||
|
||||
$drug_form_name = get_name($drug_details->form_id, "id", "name", "unit_of_measure");
|
||||
$drug_unit = get_name($drug_details->unit_id, "id", "name", "drug_units");
|
||||
$drug_strength = $drug_details->strength;
|
||||
|
||||
$treatment_dosage = $dosage_array[$x] ?? "";
|
||||
$treatment_strength = $drug_strength ?? "";
|
||||
?>
|
||||
|
||||
<tr>
|
||||
<td>{{ $drug_details->name }}</td>
|
||||
<td>
|
||||
({{ $dosage_array[$x] }} {!! $drug_unit !!} {{ get_name($frequencies_array[$x], 'id', 'name', 'dosage_frequencies') }})
|
||||
</td>
|
||||
<td>{{ $duration_array[$x] ?? "" }}</td>
|
||||
<td>{{ $instructions_array[$x] ?? "" }}</td>
|
||||
</tr>
|
||||
@endfor
|
||||
@endforeach
|
||||
@endif
|
||||
</thead>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
|
||||
+62
-69
@@ -44,6 +44,7 @@
|
||||
$parent_consultations = \Streamline\Models\Consultation::where(['episode_id' => $parent_episode_details->id])->get();
|
||||
$parent_consultation_details = count($parent_consultations) > 0 ? $parent_consultations->first() : null;
|
||||
$parent_triage_details = \Streamline\Models\Triage::where(['id' => $parent_episode_details->triage_id])->first();
|
||||
$parent_consultation_notes = \Streamline\Models\WardInpatientDetailedNote::where(['patient_id' => $episode->patient_id, 'episode_id' => $episode->parent_episode_id, 'ward_id' => 0])->get();
|
||||
|
||||
if(check_if_episode_is_a_followup($parent_episode_details->id)){
|
||||
$episode_has_grand_parent_episode = true;
|
||||
@@ -224,7 +225,7 @@
|
||||
<code>{{ __('consultations.no_observations_recorded') }}</code>
|
||||
@endif
|
||||
|
||||
{{ __('consultations.triage_done_by') }} {!! isset($triage) ? '<font style="color:blue;">'.\Streamline\Models\User::withTrashed()->find($triage->created_by)->first_name. " ".\Streamline\Models\User::withTrashed()->find($triage->created_by)->last_name.' on '.streamline_date_time($triage->created_at).'</font>' : "" !!}
|
||||
{{ __('consultations.triage_done_by') }} {!! isset($triage) ? '<font style="color:blue;">'.$users[$triage->created_by].' on '.streamline_date_time($triage->created_at).'</font>' : "" !!}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -685,38 +686,68 @@
|
||||
|
||||
@if($consultation_with_notes)
|
||||
<div class="white-box">
|
||||
@if(check_if_episode_is_a_followup($episode->id) && !is_null($parent_consultation_details))
|
||||
@php
|
||||
$parent_consultation_history = $parent_consultation_details->history_comments;
|
||||
|
||||
$parent_consultation_clinical_examination = $parent_consultation_details->clinic_examination_comments;
|
||||
|
||||
$parent_consultation_inv_and_mgt = $parent_consultation_details->investigation_and_management_plan_comments;
|
||||
@endphp
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<font color="green"><b>History {{ __('consultations.for_episode_of') }} {{ streamline_date($parent_consultation_details->created_at) }}</b></font>
|
||||
<textarea class="form-control" name="parent_history_comments" readonly>{{ $parent_consultation_history }}</textarea>
|
||||
</div>
|
||||
<h4 class="text-center">Previously Added Consultation Notes</h4>
|
||||
<div class="row">
|
||||
<div class="col table-responsive">
|
||||
<table class="table table-hover color-table success-table table-bordered" style="table-layout:fixed;">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{{ __('consultations.history') }}</th>
|
||||
<th>{{ __('consultations.clinical_examination') }}</th>
|
||||
<th>{{ __('consultations.investigation_and_mgt_plan') }}</th>
|
||||
<th>{{ __('consultations.date') }}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@forelse ($consultation_notes as $consultation_note)
|
||||
<tr>
|
||||
<td style="word-wrap:break-word;">{{ $consultation_note->history_comments }}</td>
|
||||
<td style="word-wrap:break-word;">{{ $consultation_note->clinic_examination_comments }}</td>
|
||||
<td style="word-wrap:break-word;">{{ $consultation_note->investigation_and_management_plan_comments}}</td>
|
||||
<td style="word-wrap:break-word;">{{ streamline_date_time($consultation_note->created_at) }} <br> by {{ $users[$consultation_note->created_by]?? '' }}</td>
|
||||
</tr>
|
||||
@empty
|
||||
<tr><td colspan="4"><code>No previously added consultation notes.</code></td></tr>
|
||||
@endforelse
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<font color="green"><b>{{ __('consultations.clinical_examination') }} {{ __('consultations.for_episode_of') }} {{ streamline_date($parent_consultation_details->created_at) }}</b></font>
|
||||
<textarea class="form-control" name="parent_clinic_examination_comments" readonly>{{ $parent_consultation_clinical_examination }}</textarea>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<font color="green"><b>{{ __('consultations.investigation_and_mgt_plan') }} {{ __('consultations.for_episode_of') }} {{ streamline_date($parent_consultation_details->created_at) }}</b></font>
|
||||
<textarea class="form-control" name="parent_investigation_and_management_plan_comments" readonly>{{ $parent_consultation_inv_and_mgt }}</textarea>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@if(check_if_episode_is_a_followup($episode->id) && !empty($parent_consultation_notes))
|
||||
<div class="white-box">
|
||||
<div class="row">
|
||||
<div class="col table-responsive">
|
||||
<table class="table table-hover color-table success-table table-bordered" style="table-layout:fixed;">
|
||||
<thead>
|
||||
<tr><th colspan="4">Previously Added Consultation Notes {{ __('consultations.for_episode_of') }} {{ streamline_date($parent_consultation_details->created_at) }}</th></tr>
|
||||
<tr>
|
||||
<th>{{ __('consultations.history') }}</th>
|
||||
<th>{{ __('consultations.clinical_examination') }}</th>
|
||||
<th>{{ __('consultations.investigation_and_mgt_plan') }}</th>
|
||||
<th>{{ __('consultations.date') }}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@forelse ($parent_consultation_notes as $consultation_note)
|
||||
<tr>
|
||||
<td style="word-wrap:break-word;">{{ $consultation_note->history_comments }}</td>
|
||||
<td style="word-wrap:break-word;">{{ $consultation_note->clinic_examination_comments }}</td>
|
||||
<td style="word-wrap:break-word;">{{ $consultation_note->investigation_and_management_plan_comments}}</td>
|
||||
<td style="word-wrap:break-word;">{{ streamline_date_time($consultation_note->created_at) }} <br> by {{ $users[$consultation_note->created_by]?? '' }}</td>
|
||||
</tr>
|
||||
@empty
|
||||
<tr><td colspan="4"><code>No previously added consultation notes {{ __('consultations.for_episode_of') }} {{ streamline_date($parent_consultation_details->created_at) }}.</code></td></tr>
|
||||
@endforelse
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
|
||||
<div class="row">
|
||||
{{-- <div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="table-responsive">
|
||||
<table class="table table-hover color-table success-table table-bordered">
|
||||
@@ -733,46 +764,8 @@
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="table-responsive">
|
||||
<table class="table table-hover color-table success-table table-bordered">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{{ __('consultations.clinical_examination') }}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>{!! ($consultation->clinic_examination_comments) ? nl2br(e($consultation->clinic_examination_comments)) : "No comments available" !!}</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="table-responsive">
|
||||
<table class="table table-hover color-table success-table table-bordered">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{{ __('consultations.investigation_and_mgt_plan') }}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>{!! ($consultation->investigation_and_management_plan_comments) ? nl2br(e($consultation->investigation_and_management_plan_comments)) : "No comments available" !!}</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div> --}}
|
||||
|
||||
@endif
|
||||
|
||||
<div class="white-box">
|
||||
|
||||
+998
-707
File diff suppressed because it is too large
Load Diff
+131
-116
@@ -76,24 +76,24 @@
|
||||
<div class="white-box br-5">
|
||||
@include('flash::message')
|
||||
@if(Auth::user()->can('merge-patient-episodes'))
|
||||
<p>
|
||||
<a class="btn btn-warning btn-sm btn-rounded" style="background-color: #d4984a; float:right" target="_blank" href="{{ url('episode_merge_preview') }}"><strong>{{ __('patient_episode.merge_episodes') }}</strong></a><br>
|
||||
</p>
|
||||
<p>
|
||||
<a class="btn btn-warning btn-sm btn-rounded" style="background-color: #d4984a; float:right" target="_blank" href="{{ url('episode_merge_preview') }}"><strong>{{ __('patient_episode.merge_episodes') }}</strong></a><br>
|
||||
</p>
|
||||
@endif
|
||||
<div class="table-responsive">
|
||||
<table class="table color-table success-table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{{ __('patient_episode.episode_date') }}</th>
|
||||
<th>{{ __('patient_episode.clinic') }}</th>
|
||||
<th>{{ __('patient_episode.patient_diagnosis') }}</th>
|
||||
<th>{{ __('patient_episode.consultation_by') }}</th>
|
||||
<th>{{ __('patient_episode.comments') }}</th>
|
||||
<th>{{ __('patient_episode.select') }}</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>{{ __('patient_episode.episode_date') }}</th>
|
||||
<th>{{ __('patient_episode.clinic') }}</th>
|
||||
<th>{{ __('patient_episode.patient_diagnosis') }}</th>
|
||||
<th>{{ __('patient_episode.consultation_by') }}</th>
|
||||
<th>{{ __('patient_episode.comments') }}</th>
|
||||
<th>{{ __('patient_episode.select') }}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@foreach($patient_episodes as $patient_episode)
|
||||
@foreach($patient_episodes as $patient_episode)
|
||||
@php
|
||||
$episode_id = $patient_episode->id;
|
||||
$created_at = Carbon\Carbon::parse($patient_episode->created_at);
|
||||
@@ -139,99 +139,99 @@
|
||||
@endif
|
||||
|
||||
@php
|
||||
$primary_diagnosis = $diagnoses[$primary_diagnosis_id] ?? '';
|
||||
$other_diagnoses = "";
|
||||
$primary_diagnosis = $diagnoses[$primary_diagnosis_id] ?? '';
|
||||
$other_diagnoses = "";
|
||||
|
||||
for($s = 0; $s < count($other_diagnoses_ids); $s++){
|
||||
$other_diagnoses .= isset($diagnoses[$other_diagnoses_ids[$s]]) ? ($diagnoses[$other_diagnoses_ids[$s]] . ", ") : '';
|
||||
}
|
||||
for($s = 0; $s < count($other_diagnoses_ids); $s++){
|
||||
$other_diagnoses .= isset($diagnoses[$other_diagnoses_ids[$s]]) ? ($diagnoses[$other_diagnoses_ids[$s]] . ", ") : '';
|
||||
}
|
||||
|
||||
$is_patient_in_eye_clinic = is_patient_in_eye_clinic($episode_id);
|
||||
$is_patient_in_eye_clinic = is_patient_in_eye_clinic($episode_id);
|
||||
@endphp
|
||||
|
||||
<tr id='my_row{{ $episode_id }}'>
|
||||
<td>
|
||||
<a href="#" style="color: #0099CC">{{ streamline_date_time($patient_episode->created_at) }} </a>
|
||||
<br>
|
||||
<small>{{ __('patient_episode.started_by') }}</small>
|
||||
<small style="color: blue">{{ get_full_name($patient_episode->created_by, "id", "first_name", "last_name", "users") }}</small>
|
||||
<tr id='my_row{{ $episode_id }}'>
|
||||
<td>
|
||||
<a href="#" style="color: #0099CC">{{ streamline_date_time($patient_episode->created_at) }} </a>
|
||||
<br>
|
||||
<small>{{ __('patient_episode.started_by') }}</small>
|
||||
<small style="color: blue">{{ get_full_name($patient_episode->created_by, "id", "first_name", "last_name", "users") }}</small>
|
||||
|
||||
@if(check_if_episode_is_a_followup($patient_episode->id))
|
||||
@if(check_if_episode_is_a_followup($patient_episode->id))
|
||||
@php
|
||||
$original_episode = \Streamline\Models\PatientEpisode::find($patient_episode->parent_episode_id);
|
||||
@endphp
|
||||
<small style="color: green"><br>({{ __('patient_episode.review_from') }} {{ $original_episode ? streamline_date($original_episode->created_at) : '' }})</small>
|
||||
@endif
|
||||
|
||||
@if(Auth::user()->can('delete-empty-episode') && is_episode_safe_to_delete($patient_episode->id))
|
||||
<br>
|
||||
<br>
|
||||
<a class="btn btn-danger btn-sm" href="/patient_episodes/delete_episode/{{ $patient_episode->id }}" onclick="return confirm('Are you sure you want to delete this episode?')">{{ __('patient_episode.remove_episode') }}</a>
|
||||
@endif
|
||||
</td>
|
||||
<td>
|
||||
@if( Auth::user()->can('view-patient-episode-clinic-from-patient-home'))
|
||||
{{ $clinic }}
|
||||
@endif
|
||||
</td>
|
||||
<td>
|
||||
@if( Auth::user()->can('view-patient-episode-primary-diagnoses'))
|
||||
@if(is_eye_module_enabled() && $is_patient_in_eye_clinic)
|
||||
@if(count($right_eye_diagnoses) > 0)
|
||||
@for($x = 0; $x < count($right_eye_diagnoses); $x++)
|
||||
{{ get_name(get_name($right_eye_diagnoses[$x], 'id', 'diagnosis_category', 'diagnoses'), 'id', 'name', 'diagnosis_categories') }} - {{ $diagnoses[$right_eye_diagnoses[$x]] ?? '' }}<br/>
|
||||
@endfor
|
||||
@endif
|
||||
@else
|
||||
{{ __('patient_episode.primary_diagnosis') . ': ' . $primary_diagnosis }}
|
||||
@endif
|
||||
@endif
|
||||
|
||||
<hr>
|
||||
|
||||
@if( Auth::user()->can('view-patient-episode-other-diagnoses'))
|
||||
@if(is_eye_module_enabled() && $is_patient_in_eye_clinic)
|
||||
@if(count($left_eye_diagnoses) > 0)
|
||||
@for($x = 0; $x < count($left_eye_diagnoses); $x++)
|
||||
{{ get_name(get_name($left_eye_diagnoses[$x], 'id', 'diagnosis_category', 'diagnoses'), 'id', 'name', 'diagnosis_categories') }} - {{ $diagnoses[$left_eye_diagnoses[$x]] ?? '' }}<br/>
|
||||
@endfor
|
||||
@endif
|
||||
@else
|
||||
{!! __('patient_episode.other_diagnosis') . ': <br>' !!}
|
||||
{!! read_more($other_diagnoses, 'other_diagnoses_short' . $patient_episode->id, 'other_diagnoses_long' . $patient_episode->id) !!}
|
||||
|
||||
<div id="other_diagnoses_long{{ $patient_episode->id }}" style="display: none;">
|
||||
{!! $other_diagnoses !!}<br/>
|
||||
<a class="read_more" style="color : #0099CC;" onclick= "hide('other_diagnoses_long{{ $patient_episode->id }}');show('other_diagnoses_short{{ $patient_episode->id }}');">{{ __('patient_episode.read_less') }}</a>
|
||||
</div>
|
||||
@endif
|
||||
@endif
|
||||
</td>
|
||||
<td class="hidden-phone">
|
||||
@php
|
||||
$original_episode = \Streamline\Models\PatientEpisode::find($patient_episode->parent_episode_id);
|
||||
$consultation_done_by = !empty($anc->created_by)? $anc->created_by :get_doctor_who_completed_episode_consultation($patient_episode->id);
|
||||
@endphp
|
||||
<small style="color: green"><br>({{ __('patient_episode.review_from') }} {{ $original_episode ? streamline_date($original_episode->created_at) : '' }})</small>
|
||||
@endif
|
||||
|
||||
@if(Auth::user()->can('delete-empty-episode') && is_episode_safe_to_delete($patient_episode->id))
|
||||
<br>
|
||||
<br>
|
||||
<a class="btn btn-danger btn-sm" href="/patient_episodes/delete_episode/{{ $patient_episode->id }}" onclick="return confirm('Are you sure you want to delete this episode?')">{{ __('patient_episode.remove_episode') }}</a>
|
||||
@endif
|
||||
</td>
|
||||
<td>
|
||||
@if( Auth::user()->can('view-patient-episode-clinic-from-patient-home'))
|
||||
{{ $clinic }}
|
||||
@endif
|
||||
</td>
|
||||
<td>
|
||||
@if( Auth::user()->can('view-patient-episode-primary-diagnoses'))
|
||||
@if(is_eye_module_enabled() && $is_patient_in_eye_clinic)
|
||||
@if(count($right_eye_diagnoses) > 0)
|
||||
@for($x = 0; $x < count($right_eye_diagnoses); $x++)
|
||||
{{ get_name(get_name($right_eye_diagnoses[$x], 'id', 'diagnosis_category', 'diagnoses'), 'id', 'name', 'diagnosis_categories') }} - {{ $diagnoses[$right_eye_diagnoses[$x]] ?? '' }}<br/>
|
||||
@endfor
|
||||
@endif
|
||||
@else
|
||||
{{ __('patient_episode.primary_diagnosis') . ': ' . $primary_diagnosis }}
|
||||
@if(!is_null($consultation_done_by))
|
||||
{{ get_full_name($consultation_done_by, "id", "first_name", "last_name", "users") }}
|
||||
@endif
|
||||
@endif
|
||||
|
||||
<hr>
|
||||
|
||||
@if( Auth::user()->can('view-patient-episode-other-diagnoses'))
|
||||
@if(is_eye_module_enabled() && $is_patient_in_eye_clinic)
|
||||
@if(count($left_eye_diagnoses) > 0)
|
||||
@for($x = 0; $x < count($left_eye_diagnoses); $x++)
|
||||
{{ get_name(get_name($left_eye_diagnoses[$x], 'id', 'diagnosis_category', 'diagnoses'), 'id', 'name', 'diagnosis_categories') }} - {{ $diagnoses[$left_eye_diagnoses[$x]] ?? '' }}<br/>
|
||||
@endfor
|
||||
@endif
|
||||
@else
|
||||
{!! __('patient_episode.other_diagnosis') . ': <br>' !!}
|
||||
{!! read_more($other_diagnoses, 'other_diagnoses_short' . $patient_episode->id, 'other_diagnoses_long' . $patient_episode->id) !!}
|
||||
|
||||
<div id="other_diagnoses_long{{ $patient_episode->id }}" style="display: none;">
|
||||
{!! $other_diagnoses !!}<br/>
|
||||
<a class="read_more" style="color : #0099CC;" onclick= "hide('other_diagnoses_long{{ $patient_episode->id }}');show('other_diagnoses_short{{ $patient_episode->id }}');">{{ __('patient_episode.read_less') }}</a>
|
||||
</div>
|
||||
@if($patient_episode->episode_type == 1)
|
||||
<span>{{ __('patient_flow_monitoring.lab_self_request') }}</span>
|
||||
@endif
|
||||
@endif
|
||||
</td>
|
||||
<td class="hidden-phone">
|
||||
@php
|
||||
$consultation_done_by = !empty($anc->created_by)? $anc->created_by :get_doctor_who_completed_episode_consultation($patient_episode->id);
|
||||
@endphp
|
||||
</td>
|
||||
<td class="hidden-phone">
|
||||
{!! read_more($triage_and_consultation_comments, 'short_comment' . $patient_episode->id, 'long_comment' . $patient_episode->id) !!}
|
||||
|
||||
@if(!is_null($consultation_done_by))
|
||||
{{ get_full_name($consultation_done_by, "id", "first_name", "last_name", "users") }}
|
||||
@endif
|
||||
|
||||
@if($patient_episode->episode_type == 1)
|
||||
<span>{{ __('patient_flow_monitoring.lab_self_request') }}</span>
|
||||
@endif
|
||||
</td>
|
||||
<td class="hidden-phone">
|
||||
{!! read_more($triage_and_consultation_comments, 'short_comment' . $patient_episode->id, 'long_comment' . $patient_episode->id) !!}
|
||||
|
||||
<div id="long_comment{{ $patient_episode->id }}" style="display: none;">
|
||||
{!! $triage_and_consultation_comments !!}<br/>
|
||||
<a class="read_more" style="color : #0099CC;" onclick= "hide('long_comment{{ $patient_episode->id }}');show('short_comment{{ $patient_episode->id }}');">{{ __('patient_episode.read_less') }}</a>
|
||||
</div>
|
||||
</td>
|
||||
<td>
|
||||
<input type="radio" onchange="show('menu1'), hide('theatre_menu'), hide('menu2'), hide('pic1'), hide('menu_maternity'), manage_eye_menus('{{ $is_patient_in_eye_clinic }}')" class="radio-option center" name="episode_id" id="episode_id_{{ $patient_episode->id }}" value="{{ $patient_episode->id }}" />
|
||||
</td>
|
||||
</tr>
|
||||
<div id="long_comment{{ $patient_episode->id }}" style="display: none;">
|
||||
{!! $triage_and_consultation_comments !!}<br/>
|
||||
<a class="read_more" style="color : #0099CC;" onclick= "hide('long_comment{{ $patient_episode->id }}');show('short_comment{{ $patient_episode->id }}');">{{ __('patient_episode.read_less') }}</a>
|
||||
</div>
|
||||
</td>
|
||||
<td>
|
||||
<input type="radio" onchange="show('menu1'), hide('theatre_menu'), hide('menu2'), hide('pic1'), hide('menu_maternity'), manage_eye_menus('{{ $is_patient_in_eye_clinic }}')" class="radio-option center" name="episode_id" id="episode_id_{{ $patient_episode->id }}" value="{{ $patient_episode->id }}" />
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
@php
|
||||
$inpatient_info = get_all_first(['episode_id' => $patient_episode->id, 'patient_id' => $patient->id], 'inpatient_info');
|
||||
@@ -276,7 +276,14 @@
|
||||
{{ get_full_name($consultation_done_by, "id", "first_name", "last_name", "users") }}
|
||||
@endif
|
||||
</td>
|
||||
<td> {{ $inpatient_info->comments }}</td>
|
||||
<td>
|
||||
{!! read_more($inpatient_info->comments, 'short_inpatient_comment' . $inpatient_info->id, 'long_inpatient_comment' . $inpatient_info->id) !!}
|
||||
|
||||
<div id="long_inpatient_comment{{ $inpatient_info->id }}" style="display: none;">
|
||||
{!! $inpatient_info->comments !!}<br/>
|
||||
<a class="read_more" style="color : #0099CC;" onclick= "hide('long_inpatient_comment{{ $inpatient_info->id }}');show('short_inpatient_comment{{ $inpatient_info->id }}');">{{ __('patient_episode.read_less') }}</a>
|
||||
</div>
|
||||
</td>
|
||||
<td>
|
||||
@if(get_name($inpatient_info->ward_id, "id", "slug", "wards") == "maternity")
|
||||
<input type="radio" onchange="show('menu_maternity'), hide('theatre_menu'), hide('menu1'), hide('menu2'), hide('pic1')" class="radio-option-inpatient center" name="episode_id" id="episode_id" value="{{ $patient_episode->id }}"/>
|
||||
@@ -325,7 +332,14 @@
|
||||
{{ get_full_name($consultation_done_by, "id", "first_name", "last_name", "users") }}
|
||||
@endif
|
||||
</td>
|
||||
<td>{{ $theatre_information['comments'] }}</td>
|
||||
<td>
|
||||
{!! read_more($theatre_information['comments'], 'short_theatre_comment' . $patient_episode->id, 'long_theatre_comment' . $patient_episode->id) !!}
|
||||
|
||||
<div id="long_theatre_comment{{ $patient_episode->id }}" style="display: none;">
|
||||
{!! $theatre_information['comments'] !!}<br/>
|
||||
<a class="read_more" style="color : #0099CC;" onclick= "hide('long_theatre_comment{{ $patient_episode->id }}');show('short_theatre_comment{{ $patient_episode->id }}');">{{ __('patient_episode.read_less') }}</a>
|
||||
</div>
|
||||
</td>
|
||||
<td>
|
||||
<input type="radio" onchange="show('theatre_menu'), hide('menu_maternity'), hide('menu1'), hide('menu2'), hide('pic1')" class="radio-option-inpatient center" name="episode_id" id="episode_id" value="{{ $patient_episode->id }}"/>
|
||||
</td>
|
||||
@@ -366,7 +380,7 @@
|
||||
</td>
|
||||
</tr>
|
||||
@endif
|
||||
@endforeach
|
||||
@endforeach
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
@@ -502,7 +516,7 @@
|
||||
<div class="row">
|
||||
@if(Auth::user()->can('order-for-eye-glasses') && is_eye_module_enabled())
|
||||
<div class="col-sm-2">
|
||||
<button type="submit" name="submit" class="btn btn-success btn-sm col-sm-12" value="eye_glasses">Order Eye Glasses</button>
|
||||
<button type="submit" name="submit" class="btn btn-success btn-sm col-sm-12" value="eye_glasses">Order Opticals</button>
|
||||
</div>
|
||||
@endif
|
||||
</div>
|
||||
@@ -512,19 +526,19 @@
|
||||
<div class="white-box" id="menu_maternity" style="display: none;">
|
||||
<div class="row">
|
||||
@if(Auth::user()->can('view-maternity-admission'))
|
||||
<div class="col-sm-2">
|
||||
<button name="submit" value="maternity_admission" class="btn btn-success btn-sm btn-block">{{ __('patient_episode.maternity_admission') }}</button>
|
||||
</div>
|
||||
<div class="col-sm-2">
|
||||
<button name="submit" value="maternity_admission" class="btn btn-success btn-sm btn-block">{{ __('patient_episode.maternity_admission') }}</button>
|
||||
</div>
|
||||
@endif
|
||||
@if(Auth::user()->can('view-delivery-record'))
|
||||
<div class="col-sm-2">
|
||||
<button name="submit" value="delivery_record" class="btn btn-success btn-sm btn-block" >{{ __('patient_episode.delivery_record') }}</button>
|
||||
</div>
|
||||
<div class="col-sm-2">
|
||||
<button name="submit" value="delivery_record" class="btn btn-success btn-sm btn-block" >{{ __('patient_episode.delivery_record') }}</button>
|
||||
</div>
|
||||
@endif
|
||||
@if(Auth::user()->can('view-inpatient-sheet'))
|
||||
<div class="col-sm-2">
|
||||
<button name="submit" value="maternity_summary" class="btn btn-success btn-sm btn-block" >{{ __('patient_episode.inpatient_sheet') }}</button>
|
||||
</div>
|
||||
<div class="col-sm-2">
|
||||
<button name="submit" value="maternity_summary" class="btn btn-success btn-sm btn-block" >{{ __('patient_episode.inpatient_sheet') }}</button>
|
||||
</div>
|
||||
@endif
|
||||
@if(Auth::user()->can('view-birth-report'))
|
||||
<div class="col-sm-2">
|
||||
@@ -540,7 +554,7 @@
|
||||
<li><button type="submit" name="submit" value="create_anaesthetics" class="btn btn-default btn-sm btn-link">{{ __('patient_episode.theatre_anaesthetics') }}</button></li>
|
||||
@endif
|
||||
@if(Auth::user()->can('view-anaesthetics-history'))
|
||||
<li><button type="submit" name="submit" value="anaesthetics_history" class="btn btn-default btn-sm btn-link">{{ __('patient_episode.historical_anaesthetics') }}</button></li>
|
||||
<li><button type="submit" name="submit" value="anaesthetics_history" class="btn btn-default btn-sm btn-link">{{ __('patient_episode.historical_anaesthetics') }}</button></li>
|
||||
@endif
|
||||
@if(Auth::user()->can('create-surgery'))
|
||||
<li><button type="submit" name="submit" value="create_surgery" class="btn btn-default btn-sm btn-link">{{ __('patient_episode.theatre_surgery') }}</button></li>
|
||||
@@ -556,19 +570,19 @@
|
||||
<div id="menu2" style="display: none;">
|
||||
<div class="row">
|
||||
@if(Auth::user()->can('view-inpatient-sheet'))
|
||||
<div class="col-sm-2">
|
||||
<button type="submit" name="submit" class="btn btn-success btn-block btn-sm" value="inpatient-sheet-button">{{ __('patient_episode.inpatient_sheet') }}</button>
|
||||
</div>
|
||||
<div class="col-sm-2">
|
||||
<button type="submit" name="submit" class="btn btn-success btn-block btn-sm" value="inpatient-sheet-button">{{ __('patient_episode.inpatient_sheet') }}</button>
|
||||
</div>
|
||||
@endif
|
||||
@if(Auth::user()->can('view-inpatient-billing'))
|
||||
<div class="col-sm-2">
|
||||
<button type="submit" name="submit" class="btn btn-success btn-block btn-sm" value="inpatient_billing">{{ __('patient_episode.inpatient_billing') }}</button>
|
||||
</div>
|
||||
<div class="col-sm-2">
|
||||
<button type="submit" name="submit" class="btn btn-success btn-block btn-sm" value="inpatient_billing">{{ __('patient_episode.inpatient_billing') }}</button>
|
||||
</div>
|
||||
@endif
|
||||
@if(Auth::user()->can('issue-inpatient-attendant-pass'))
|
||||
<div class="col-sm-2">
|
||||
<button type="submit" name="submit" class="btn btn-default btn-block btn-sm" value="inpatient_attendant_pass">{{ __('patient_episode.inpatient_attendant_pass') }}</button>
|
||||
</div>
|
||||
<div class="col-sm-2">
|
||||
<button type="submit" name="submit" class="btn btn-default btn-block btn-sm" value="inpatient_attendant_pass">{{ __('patient_episode.inpatient_attendant_pass') }}</button>
|
||||
</div>
|
||||
@endif
|
||||
<div class="col-sm-2">
|
||||
<button type="submit" name="submit" class="btn btn-primary btn-block btn-sm" value="treatment_sheet">{{ __('patient_episode.treatment_sheet') }}</button>
|
||||
@@ -785,6 +799,7 @@
|
||||
let current_episode_id = $('input[name=episode_id]:checked').val();
|
||||
$("#episode_admission_episode_id").val(current_episode_id);
|
||||
$("#ward_admission_episode").modal("show");
|
||||
$('#admission_ward_id').select2();
|
||||
}
|
||||
},
|
||||
error: function (response) {
|
||||
|
||||
+59
-13
@@ -488,12 +488,26 @@
|
||||
{{ isset($marital_statuses[$patient->marital_status]) ? $marital_statuses[$patient->marital_status] : 'N/A' }}
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th class="highlight">National ID</th>
|
||||
<td>
|
||||
{{ strtoupper($patient->national_id) }}
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
|
||||
@if (isset($other_patients_info_data->non_ugandan_national_id_no))
|
||||
|
||||
<tr>
|
||||
<th class="highlight"> ID Number</th>
|
||||
<td>{{ $other_patients_info_data->non_ugandan_national_id_no ?? '' }}</td>
|
||||
</tr>
|
||||
|
||||
@else
|
||||
<tr>
|
||||
<th class="highlight">National ID</th>
|
||||
<td>{{ $patient->national_id ?? '' }}</td>
|
||||
</tr>
|
||||
|
||||
|
||||
@endif
|
||||
|
||||
|
||||
|
||||
@if (mother_of_patient($patient->id))
|
||||
@php
|
||||
$mother_id = mother_of_patient($patient->id);
|
||||
@@ -533,12 +547,7 @@
|
||||
</td>
|
||||
</tr>
|
||||
@endif
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<div class="col-sm-6">
|
||||
<table class="table table-bordered">
|
||||
<tbody>
|
||||
|
||||
<tr>
|
||||
<th class="highlight">{{ __('layout.next_of_kin') }}</th>
|
||||
<td>{{ $patient->next_of_kin }}</td>
|
||||
@@ -553,6 +562,15 @@
|
||||
<th class="highlight">{{ __('layout.mobile_number') }}</th>
|
||||
<td>{{ $patient->phone }}</td>
|
||||
</tr>
|
||||
|
||||
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<div class="col-sm-6">
|
||||
<table class="table table-bordered">
|
||||
<tbody>
|
||||
|
||||
<tr>
|
||||
<th class="highlight">{{ __('layout.phone_name') }}</th>
|
||||
<td>{{ $patient->phone_owner }}</td>
|
||||
@@ -606,6 +624,34 @@
|
||||
{{ streamline_date($patient->created_at) }}
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
|
||||
<tr>
|
||||
<th class="highlight">Country</th>
|
||||
<td>{{ $country->name ?? '' }}</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<th class="highlight">Foreigner / Refugee</th>
|
||||
<td>
|
||||
|
||||
@if(!empty($other_patients_info_data))
|
||||
@if ($other_patients_info_data->non_ugandan_foreigner_or_refugee == 1)
|
||||
<span>{{ __('patients.foreigner') }} </span>
|
||||
@elseif ($other_patients_info_data->non_ugandan_foreigner_or_refugee == 2)
|
||||
<span>{{ __('patients.refugee') }} </span>
|
||||
@else
|
||||
<span></span>
|
||||
@endif
|
||||
@else
|
||||
<span></span>
|
||||
@endif
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
|
||||
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
@@ -899,6 +945,6 @@
|
||||
@push('scripts')
|
||||
<script src="{{ asset('elite/bower_components/select2/select2.min.js') }}"></script>
|
||||
<script type="text/javascript">
|
||||
$('#new_episode_options').select2();
|
||||
$('#new_episode_options, #admission_ward_id').select2({width: "100%"});
|
||||
</script>
|
||||
@endpush
|
||||
|
||||
+53
-29
@@ -48,7 +48,7 @@
|
||||
<div class="col-md-2">
|
||||
<div class="form-group" id="searchby">
|
||||
{{ Form::label('search_by', __('patient_flow_monitoring.date')) }}
|
||||
{{ Form::select('search_by', ['4'=>'Today', '0'=>'Yesterday','1'=>'Custom Date','2'=>'Custom Range'], '', ['class' => 'form-control','id'=>'search_by', 'required']) }}
|
||||
{{ Form::select('search_by', ['4'=>'Today', '3'=>'Yesterday','1'=>'Custom Date','2'=>'Custom Range'], '', ['class' => 'form-control','id'=>'search_by', 'required']) }}
|
||||
<div class="help-block with-errors"></div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -150,7 +150,7 @@
|
||||
$main_exam = \Illuminate\Support\Facades\DB::table('eye_clinic_main_exam')->where('episode_id', $episode->id)->first();
|
||||
$is_patient_in_eye_clinic = is_patient_in_eye_clinic($episode->id);
|
||||
@endphp
|
||||
|
||||
<input type="hidden" name="patient_id_{{ $episode->id }}" id="patient_id_{{ $episode->id }}" value="{{ $episode->patient_id }}">
|
||||
@if($episode->paid_over == "pos")
|
||||
<tr id="row{{ $episode->id }}">
|
||||
<td>{{ $counter }}</td>
|
||||
@@ -237,7 +237,7 @@
|
||||
</td>
|
||||
<td>
|
||||
@if(is_object($patient) && is_null($patient->deleted_at))
|
||||
<input type="radio" onchange="show({{ $episode->id }})" class="radio-option centered" name="episode_id" value="{{ $episode->id }}" />
|
||||
<input type="radio" onchange="show({{ $episode->id }}), manage_eye_menus('{{ $is_patient_in_eye_clinic }}')" class="radio-option centered" name="episode_id" value="{{ $episode->id }}" />
|
||||
@else
|
||||
<b style="color: red">Patient was deleted</b>
|
||||
@endif
|
||||
@@ -445,7 +445,7 @@
|
||||
<button type="submit" name="main_exam" class="btn btn-success btn-sm col-sm-12 eye_button" value="main_exam" id="main_exam">Main Exam</button>
|
||||
|
||||
@if(Auth::user()->can('create-consultation'))
|
||||
<button type="submit" name="submit" class="btn btn-success btn-sm col-sm-12 normal_button" value="consultation" id="consultation">{{ __('patient_flow_monitoring.consultation') }}</button>
|
||||
<button type="submit" name="submit" class="btn btn-success btn-sm col-sm-12 normal_button" value="consultation" id="consultation" onclick="paymentCheck(this.value)">{{ __('patient_flow_monitoring.consultation') }}</button>
|
||||
@endif
|
||||
</div>
|
||||
<div class="col-sm-2">
|
||||
@@ -500,7 +500,7 @@
|
||||
</div>
|
||||
<div class="col-sm-3">
|
||||
@if(Auth::user()->can('create-consultation-with-notes'))
|
||||
<button type="submit" name="consultation_with_notes" id="consultation_with_notes" class="btn btn-success btn-sm col-sm-12" value="consultation_with_notes">{{ __('patient_episode.consultation_with_notes') }}</button>
|
||||
<button type="submit" name="consultation_with_notes" id="consultation_with_notes" class="btn btn-success btn-sm col-sm-12" value="consultation_with_notes" onclick="paymentCheck(this.value)">{{ __('patient_episode.consultation_with_notes') }}</button>
|
||||
@endif
|
||||
</div>
|
||||
<div class="col-sm-3">
|
||||
@@ -531,7 +531,7 @@
|
||||
<button type="submit" name="main_exam" class="btn btn-success btn-sm col-sm-12 eye_button" value="main_exam" id="main_exam">Main Exam</button>
|
||||
|
||||
@if(Auth::user()->can('create-consultation'))
|
||||
<button type="submit" name="submit" class="btn btn-success btn-sm col-sm-12 normal_button" value="consultation" id="consultation">{{ __('patient_flow_monitoring.consultation') }}</button>
|
||||
<button type="submit" name="submit" class="btn btn-success btn-sm col-sm-12 normal_button" value="consultation" id="consultation" onclick="paymentCheck(this.value)">{{ __('patient_flow_monitoring.consultation') }}</button>
|
||||
@endif
|
||||
</div>
|
||||
<div class="col-sm-2">
|
||||
@@ -586,7 +586,7 @@
|
||||
</div>
|
||||
<div class="col-sm-3">
|
||||
@if(Auth::user()->can('create-consultation-with-notes'))
|
||||
<button type="submit" name="consultation_with_notes" id="consultation_with_notes" class="btn btn-success btn-sm col-sm-12" value="consultation_with_notes">{{ __('patient_episode.consultation_with_notes') }}</button>
|
||||
<button type="submit" name="consultation_with_notes" id="consultation_with_notes" class="btn btn-success btn-sm col-sm-12" value="consultation_with_notes" onclick="paymentCheck(this.value)">{{ __('patient_episode.consultation_with_notes') }}</button>
|
||||
@endif
|
||||
</div>
|
||||
<div class="col-sm-3">
|
||||
@@ -657,6 +657,28 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="modal fade" id="unpaid_consultation_warning" tabindex="-1" role="dialog">
|
||||
<div class="modal-dialog" role="document">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<div class="container-fluid">
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<h4 style="color: red">{{ __('patient_episode.patient_not_paid_consultation') }}</h4>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">{{ __('patient_episode.okay') }}</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
@@ -669,26 +691,6 @@
|
||||
<script src="{{ asset('elite/bower_components/bootstrap-datepicker/bootstrap-datepicker.min.js') }}"></script>
|
||||
|
||||
<script>
|
||||
/*$('.table').DataTable({
|
||||
dom: 'Bfrtip',
|
||||
bInfo: false,
|
||||
bPaginate: false,
|
||||
buttons: [
|
||||
{extend: 'pdf',
|
||||
exportOptions: {
|
||||
stripHtml: false,
|
||||
columns: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]
|
||||
}
|
||||
},
|
||||
{extend: 'print',
|
||||
exportOptions: {
|
||||
stripHtml: false,
|
||||
columns: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]
|
||||
}
|
||||
}
|
||||
]
|
||||
});*/
|
||||
|
||||
let selected_row = 0;
|
||||
|
||||
function show(episodeId) {
|
||||
@@ -727,8 +729,8 @@
|
||||
}
|
||||
});
|
||||
|
||||
$('#triage,#consultation,#create_anaesthetics,#anaesthetics_history,#create_surgery,#surgery_index,#treatment,#investigation,#anc_registration_button,' +
|
||||
'#anc_followup_button,#view_patient_history,#consultation_with_notes,#triage_without_etat,#main_exam,#base_refraction_exam').click(function() {
|
||||
$('#triage,#create_anaesthetics,#anaesthetics_history,#create_surgery,#surgery_index,#treatment,#investigation,#anc_registration_button,' +
|
||||
'#anc_followup_button,#view_patient_history,#triage_without_etat,#main_exam,#base_refraction_exam').click(function() {
|
||||
event.preventDefault();
|
||||
let options = document.getElementsByName('episode_id');
|
||||
let episodeId = 0;
|
||||
@@ -821,5 +823,27 @@
|
||||
$('.normal_button').show();
|
||||
}
|
||||
}
|
||||
|
||||
function paymentCheck(data){
|
||||
let episode_to_check_for_payment = $('input[name=episode_id]:checked').val();
|
||||
let patient_id = $('#patient_id_'+episode_to_check_for_payment).val();
|
||||
let action = data;
|
||||
event.preventDefault();
|
||||
$.ajax({
|
||||
method: 'POST',
|
||||
url: '/check_clinical_consultation_payment',
|
||||
data: {'episode_id' : episode_to_check_for_payment, 'patient_id':patient_id, 'action':action},
|
||||
success: function(response){
|
||||
if (response == "unpaid") {
|
||||
$("#unpaid_consultation_warning").modal("show");
|
||||
} else{
|
||||
window.location.href = response;
|
||||
}
|
||||
},
|
||||
error:function(error){
|
||||
console.log(error);
|
||||
}
|
||||
});
|
||||
}
|
||||
</script>
|
||||
@endpush
|
||||
|
||||
@@ -119,7 +119,7 @@
|
||||
</div>
|
||||
<div class="col-sm-6">
|
||||
{{ Form::label('next_of_kin_phone',__('patients.next_of_kin_phone')) }}
|
||||
{{ Form::text('next_of_kin_phone','',['class' => 'form-control compulsory', 'required']) }}
|
||||
{{ Form::text('next_of_kin_phone','',['class' => 'form-control compulsory', 'required','pattern' => '\d{10}', 'title'=>'Phone number must be exactly 10 digits']) }}
|
||||
<div class="help-block with-errors"></div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -127,7 +127,7 @@
|
||||
|
||||
<div class="form-group">
|
||||
{{ Form::label('phone',__('patients.phone')) }}
|
||||
{{ Form::text('phone','',['class' => 'form-control compulsory','id' => 'phone', 'required' ]) }}
|
||||
{{ Form::text('phone','',['class' => 'form-control compulsory','id' => 'phone', 'required','pattern' => '\d{10}', 'title'=>'Phone number must be exactly 10 digits' ]) }}
|
||||
<div class="help-block with-errors"></div>
|
||||
</div>
|
||||
|
||||
@@ -135,7 +135,7 @@
|
||||
|
||||
<div class="form-group">
|
||||
{{ Form::label('alternative_phone', 'Alternative Phone Number') }}
|
||||
{{ Form::text('alternative_phone','',['class' => 'form-control','id' => 'alternative_phone']) }}
|
||||
{{ Form::text('alternative_phone','',['class' => 'form-control','id' => 'alternative_phone','pattern' => '\d{10}', 'title'=>'Phone number must be exactly 10 digits']) }}
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
@@ -181,11 +181,34 @@
|
||||
<div id="not_ugandan_regions" style="display: none;">
|
||||
<div class="form-group">
|
||||
{{ Form::label('country_id',__('patients.country_of_origin')) }}
|
||||
{{ Form::select('country_id', $countries, '',['class' => 'form-control', 'data-error'=>'Select the country']) }}
|
||||
{{ Form::select('country_id', $countries, '',['class' => 'form-control', 'data-error'=>'Select the country','id' => 'country_picker']) }}
|
||||
<div class="help-block with-errors"></div>
|
||||
{{-- <a href="#modal_residence" data-toggle="modal" id="modal_residence_link"><font size="1">{{ __('patients.add_new_residence') }} </font></a> --}}
|
||||
<a href="#modal_add_country_foreigner" data-toggle="modal" id="modal_add_country_foreigner_id"><font size="1">Add new country </font></a>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="non_ugandan_foreigner_or_refugee">{{ __('patients.foreigner_or_refugee') }}</label>
|
||||
<select id="foreginer_refugee" name="non_ugandan_foreigner_or_refugee" class="form-control ">
|
||||
<option value="null"> -- {{ __('patients.select') }} --</option>
|
||||
<option value="1"> {{ __('patients.foreigner') }} </option>
|
||||
<option value="2"> {{ __('patients.refugee') }} </option>
|
||||
|
||||
</select>
|
||||
<div class="help-block with-errors"></div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="non_ugandan_national_id">{{ __('patients.national_id') }}</label>
|
||||
<input type="text" name="non_ugandan_national_id_no" value="" class="form-control">
|
||||
<div class="help-block with-errors"></div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div id="ugandan_regions">
|
||||
<div class="form-group">
|
||||
{{ Form::label('residence','Residence') }}
|
||||
@@ -236,6 +259,9 @@
|
||||
</div>
|
||||
@endif
|
||||
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
<div class="col-md-8">
|
||||
<hr>
|
||||
@@ -356,6 +382,36 @@
|
||||
</div>
|
||||
<!-- end of residence modals -->
|
||||
|
||||
{{-- start of add other foreigner country modal --}}
|
||||
<div class="modal fade" id="modal_add_country_foreigner" tabindex="-1" role="dialog">
|
||||
<div class="modal-dialog" role="document">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
|
||||
<h4 class="modal-title">Add New Country</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
|
||||
<div class="form-group">
|
||||
<label>Country Name</label>
|
||||
<input type="text" name="new_country_name" id="new_country_name" value="" class="form-control compulsory">
|
||||
<div class="help-block with-errors"></div>
|
||||
</div>
|
||||
|
||||
{{-- @error('name')
|
||||
<span class="text-danger">{{ $message }}</span>
|
||||
@enderror --}}
|
||||
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">{{ __('patients.cancel') }}</button>
|
||||
<a class="btn btn-success" onclick="submitCountry()">{{ __('patients.save') }}</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="modal" id="modal_similar_patients" tabindex="-1" role="dialog" aria-hidden="true">
|
||||
<div class="modal-dialog modal-lg" role="document">
|
||||
<div class="modal-content">
|
||||
@@ -437,6 +493,70 @@
|
||||
});
|
||||
}
|
||||
|
||||
// add new country
|
||||
function submitCountry() {
|
||||
var new_country_name = $("#new_country_name").val();
|
||||
|
||||
if ($("#new_country_name").val() === "" || !$("#new_country_name").val()) {
|
||||
alert("Please make sure that you fill in a country name");
|
||||
return false;
|
||||
}
|
||||
|
||||
var data = {
|
||||
'name':new_country_name,
|
||||
};
|
||||
|
||||
// $.ajax({
|
||||
// method: 'POST',
|
||||
// url: '/patients/add_country',
|
||||
// data: data,
|
||||
// success: function(response){
|
||||
// if(!isNaN(response)){
|
||||
// //response = last inserted id
|
||||
// $('#country_picker').append($('<option>', {
|
||||
// value: response,
|
||||
// text: new_country_name
|
||||
// }));
|
||||
// $('#country_picker').val(response);//preselect the newly added referral
|
||||
// $('#modal_add_country_foreigner').modal('hide'); //manually hide the modal
|
||||
// } else {
|
||||
// alert("error occurred");
|
||||
// }
|
||||
// },
|
||||
// error: function(jqXHR, textStatus, errorThrown) {
|
||||
// alert(JSON.stringify(jqXHR));
|
||||
// console.log(JSON.stringify(jqXHR));
|
||||
// }
|
||||
// });
|
||||
|
||||
$.ajax({
|
||||
method: 'POST',
|
||||
url: '/patients/add_country',
|
||||
data: data,
|
||||
success: function(response) {
|
||||
if (!isNaN(response)) {
|
||||
// response = last inserted id
|
||||
$('#country_picker').append($('<option>', {
|
||||
value: response,
|
||||
text: new_country_name
|
||||
}));
|
||||
$('#country_picker').val(response); // preselect the newly added country
|
||||
$('#modal_add_country_foreigner').modal('hide'); // manually hide the modal
|
||||
} else {
|
||||
alert(response.error || "An unknown error occurred");
|
||||
}
|
||||
},
|
||||
error: function(jqXHR) {
|
||||
var response = jqXHR.responseJSON;
|
||||
if (jqXHR.status === 409 && response && response.error) {
|
||||
alert(response.error); // Show the "Country already exists" message
|
||||
} else {
|
||||
alert("An error occurred: " + JSON.stringify(jqXHR));
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function submitCompany() {
|
||||
var company_name = $("#company_name").val();
|
||||
var company_contact = $("#company_contact").val();
|
||||
@@ -655,7 +775,7 @@
|
||||
});
|
||||
|
||||
/* make residence dropdowns searchable */
|
||||
$('#district_id,#county_id,#subcounty_id,#parish_id,#company,#occupation').select2({
|
||||
$('#district_id,#county_id,#subcounty_id,#parish_id,#company,#occupation,#foreginer_refugee').select2({
|
||||
placeholder: "<?php echo __('patients.select')?>",
|
||||
width: '100%',
|
||||
});
|
||||
@@ -790,4 +910,21 @@
|
||||
}
|
||||
});
|
||||
</script>
|
||||
|
||||
|
||||
{{-- palm vein scanner --}}
|
||||
|
||||
|
||||
{{-- <script type="text/javascript" src="{{ asset('js/palmsecure/fbf.standalone.js') }}" xmlns="http://ddue.schemas.microsoft.com/authoring/2003/5"></script> --}}
|
||||
|
||||
{{-- <script type ="text/javascript" src="{{ asset('js/palmsecure/fbf.module.js') }}"></script> --}}
|
||||
<script type ="text/javascript" src="{{ asset('js/palmsecure/demo.bundle.js') }}"></script>
|
||||
<script type ="text/javascript" src="{{ asset('js/palmsecure/demo.js') }}"></script>
|
||||
|
||||
|
||||
<script type="text/javascript">
|
||||
start();
|
||||
</script>
|
||||
|
||||
{{-- end of palm vein scanner --}}
|
||||
@endpush
|
||||
@@ -1,4 +1,3 @@
|
||||
@php use Streamline\Enums\Roles; @endphp
|
||||
@extends('layouts.main')
|
||||
|
||||
@push('styles')
|
||||
@@ -103,7 +102,7 @@
|
||||
<div class="help-block with-errors"></div>
|
||||
</div>
|
||||
|
||||
@if( Auth::user()->hasRole(Roles::SUPER_ADMIN->value))
|
||||
@if( Auth::user()->hasRole('Super Admin'))
|
||||
<div class="form-group">
|
||||
{{ Form::label('is_test_patient',__('patients.is_test_patient')) }}
|
||||
<br>
|
||||
@@ -131,17 +130,17 @@
|
||||
{{ Form::select('next_of_kin_relationship',$relationships,$patient->next_of_kin_relationship,['class' => 'form-control compulsory']) }}
|
||||
<br>
|
||||
{{ Form::label('next_of_kin_phone',__('patients.next_of_kin_phone')) }}
|
||||
{{ Form::text('next_of_kin_phone',$patient->phone_of_next_of_kin,['class' => 'form-control']) }}
|
||||
{{ Form::text('next_of_kin_phone',$patient->phone_of_next_of_kin,['class' => 'form-control','pattern' => '\d{10}', 'title'=>'Phone number must be exactly 10 digits']) }}
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
{{ Form::label('phone',__('patients.phone')) }}
|
||||
{{ Form::text('phone',$patient->phone,['class' => 'form-control compulsory']) }}
|
||||
{{ Form::text('phone',$patient->phone,['class' => 'form-control compulsory','pattern' => '\d{10}', 'title'=>'Phone number must be exactly 10 digits']) }}
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
{{ Form::label('alternative_phone', 'Alternative Phone Number') }}
|
||||
{{ Form::text('alternative_phone',$patient->alternative_phone,['class' => 'form-control','id' => 'alternative_phone']) }}
|
||||
{{ Form::text('alternative_phone',$patient->alternative_phone,['class' => 'form-control','id' => 'alternative_phone','pattern' => '\d{10}', 'title'=>'Phone number must be exactly 10 digits']) }}
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
@@ -199,6 +198,27 @@
|
||||
{{ Form::select('country_id', $countries, $patient->country_id, ['class' => 'form-control', 'data-error'=>'Select the country']) }}
|
||||
<div class="help-block with-errors"></div>
|
||||
</div>
|
||||
|
||||
@php
|
||||
$other_patients_info_data = !empty($patient->other_patients_info) ? json_decode($patient->other_patients_info) : '';
|
||||
@endphp
|
||||
<div class="form-group">
|
||||
<label for="non_ugandan_foreigner_or_refugee">{{ __('patients.foreigner_or_refugee') }}</label>
|
||||
<select id="foreginer_refugee" name="non_ugandan_foreigner_or_refugee" class="form-control ">
|
||||
<option value="null"> -- {{ __('patients.select') }} --</option>
|
||||
<option value="1" @selected(isset($other_patients_info_data) && is_int($other_patients_info_data) && $other_patients_info_data->non_ugandan_foreigner_or_refugee == 1 ?? '')> {{ __('patients.foreigner') }} </option>
|
||||
<option value="2" @selected(isset($other_patients_info_data) && is_int($other_patients_info_data) && $other_patients_info_data->non_ugandan_foreigner_or_refugee == 2 ?? '')> {{ __('patients.refugee') }} </option>
|
||||
|
||||
</select>
|
||||
<div class="help-block with-errors"></div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="non_ugandan_national_id">{{ __('patients.national_id') }}</label>
|
||||
<input type="text" name="non_ugandan_national_id_no" value=" {{ $other_patients_info_data->non_ugandan_national_id_no ?? '' }}" class="form-control">
|
||||
<div class="help-block with-errors"></div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div id="ugandan_regions" @if($patient->citizenship == 0) style="display: none" @endif>
|
||||
|
||||
@@ -51,13 +51,12 @@
|
||||
|
||||
<div class="col-md-2">
|
||||
<button type="submit" class="btn btn-rounded btn-success"><span class="glyphicon glyphicon-search"></span> {{ __('patients.search') }}</button>
|
||||
<span class="label label-info float-right" style="font-size: 12.5px;"> {{ $patientCount }} {{ __('patients.patients_registered') }}</span>
|
||||
<span class="label label-info float-right" style="font-size: 12.5px;"> {{ count($patient_numbers) }} {{ __('patients.patients_registered') }}</span>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
@if(isset($criteria) && isset($resultCount))
|
||||
<p>{{ __('patients.search_criteria') }} : <code>{{ $criteria }}</code> {{ __('patients.total_results') }} : <code>{{ $resultCount }}</code> <a href="{{ route('patients.index') }}">{{ __('patients.clear_search') }}</a></p>
|
||||
@if(isset($criteria))
|
||||
<p>{{ __('patients.search_criteria') }} : <code>{{ $criteria }}</code></p>
|
||||
@endif
|
||||
{{ Form::close() }}
|
||||
|
||||
@@ -78,8 +77,7 @@
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@if(count($patients) > 0)
|
||||
@foreach($patients as $patient)
|
||||
@foreach($patients as $patient)
|
||||
<tr>
|
||||
<td>{{ $patient->number }}</td>
|
||||
<td>{!! insurance_flag($patient->id) !!}</td>
|
||||
@@ -92,8 +90,8 @@
|
||||
</td>
|
||||
<td>{{ get_patients_age($patient->date_of_birth) }}</td>
|
||||
<td>{{ $patient->phone }}</td>
|
||||
<td><?php echo isset($categories[$patient->category_id]) ? $categories[$patient->category_id] : "N/A"; ?></td>
|
||||
<td>{{ isset($patient_villages[$patient->village_id]) ? $patient_villages[$patient->village_id] : '' }}</td>
|
||||
<td>{{ $categories[$patient->category_id] ?? "N/A" }}</td>
|
||||
<td>{{ $villages[$patient->village_id] ?? '' }}</td>
|
||||
<td><a href="/patients/{{ $patient->id }}/" class="btn btn-rounded btn-info btn-sm"><i class="fa fa-info-circle"></i> {{ __('patients.details') }}</a></td>
|
||||
<td>
|
||||
<a href="/patients/{{ $patient->id }}/edit/" class="btn btn-warning btn-rounded btn-sm"><i class="fa fa-pencil"></i> {{ __('patients.edit') }}</a>
|
||||
@@ -102,10 +100,7 @@
|
||||
<a href="/patient_episodes/set_patient_id/{{ $patient->id }}" class="btn btn-rounded btn-primary btn-sm"><i class="fa fa-hand-pointer-o"></i> <strong>{{ __('patients.select') }}</strong></a>
|
||||
</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
@else
|
||||
<tr class="warning"><td class="center" colspan="10"><code>{{ __('patients.no_records_found') }}</code></td></tr>
|
||||
@endif
|
||||
@endforeach
|
||||
</tbody>
|
||||
|
||||
</table>
|
||||
@@ -177,30 +172,6 @@ $('#previous_numbers .typeahead').typeahead(
|
||||
}
|
||||
);
|
||||
|
||||
$('#first_names .typeahead').typeahead(
|
||||
{
|
||||
hint: true,
|
||||
highlight: true,
|
||||
minLength: 1
|
||||
},
|
||||
{
|
||||
name: 'first_names',
|
||||
source: substringMatcher(<?php echo json_encode($first_names); ?>)
|
||||
}
|
||||
);
|
||||
|
||||
$('#last_names .typeahead').typeahead(
|
||||
{
|
||||
hint: true,
|
||||
highlight: true,
|
||||
minLength: 1
|
||||
},
|
||||
{
|
||||
name: 'last_names',
|
||||
source: substringMatcher(<?php echo json_encode($last_names); ?>)
|
||||
}
|
||||
);
|
||||
|
||||
$('#villages .typeahead').typeahead(
|
||||
{
|
||||
hint: true,
|
||||
@@ -209,7 +180,7 @@ $('#villages .typeahead').typeahead(
|
||||
},
|
||||
{
|
||||
name: 'villages',
|
||||
source: substringMatcher(<?php echo json_encode($villages); ?>)
|
||||
source: substringMatcher(<?php echo json_encode(array_values($villages)); ?>)
|
||||
}
|
||||
);
|
||||
|
||||
@@ -275,19 +246,7 @@ $('.table').DataTable({
|
||||
]
|
||||
});
|
||||
|
||||
|
||||
|
||||
|
||||
$('.sorting').removeClass('sorting');//remove the sorting class
|
||||
$('.sorting_asc').removeClass('sorting_asc');//remove the sorting class
|
||||
</script>
|
||||
@endpush
|
||||
|
||||
@push('styles')
|
||||
<style type="text/css">
|
||||
.color-bordered-table.success-bordered-table {
|
||||
border-top: 0px;
|
||||
}
|
||||
</style>
|
||||
@endpush
|
||||
|
||||
|
||||
+120
-147
@@ -1,160 +1,133 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="{{ app()->getLocale() }}">
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Patient Card</title>
|
||||
<style>
|
||||
@page {
|
||||
size: A8 landscape;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<meta name="description" content="">
|
||||
<meta name="author" content="">
|
||||
body {
|
||||
font-family: Arial, sans-serif;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
|
||||
<link rel="icon" type="image/png" sizes="16x16" href="{{ base_path('public/uploads/streamline/color/streamline_icon-02.png') }}">
|
||||
<title>{{ config('app.name', 'CHI Membership Card - Stre@mline') }}</title>
|
||||
<!-- Bootstrap Core CSS -->
|
||||
<link href="{{ base_path('public/bootstrap/css/bootstrap.min.css') }}" rel="stylesheet">
|
||||
|
||||
<style style="text-css">
|
||||
body{
|
||||
/*font-size: 1.2em;*/
|
||||
}
|
||||
|
||||
thead {
|
||||
/*display: table-header-group;*/
|
||||
}
|
||||
|
||||
tfoot {
|
||||
/*display: table-row-group;*/
|
||||
}
|
||||
|
||||
tr {
|
||||
/*page-break-inside: avoid;*/
|
||||
}
|
||||
|
||||
th{
|
||||
font-weight: bolder;
|
||||
font-size: 22px;
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
td{
|
||||
font-size: 24px;
|
||||
padding-top: 5px;
|
||||
color: #fff;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div class="container-fluid">
|
||||
<div class="row">
|
||||
<div class="col-12">
|
||||
<div style="background-color: rgb(43, 116, 91); color:#fff">
|
||||
<div class="hospital-logo" style="padding-top: 10px;">
|
||||
@include('layouts.header_pdf_print')
|
||||
</div>
|
||||
|
||||
<div class="row" style="padding: 30px;">
|
||||
<div class="col-12" style="padding-top: 10px;">
|
||||
<table>
|
||||
<tr>
|
||||
<td><u>NAME</u></td>
|
||||
<td style="padding-left: 15px;"><u>SEX</u></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>
|
||||
{{ get_full_name($patient->id, "id", "first_name", "last_name", "patients") }}
|
||||
</th>
|
||||
<th style="padding-left: 15px;">
|
||||
{{ $patient->gender == 1 ? "MALE" : "FEMALE" }}
|
||||
</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td></td>
|
||||
<td style="padding-left: 15px;"></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><u>Stre@mline NUMBER</u></td>
|
||||
<td style="padding-left: 15px;"><u>DATE OF BIRTH</u></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>
|
||||
{{ $patient->number }}
|
||||
</th>
|
||||
<th style="padding-left: 15px;">
|
||||
{{ streamline_date($patient->date_of_birth) }}
|
||||
</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td></td>
|
||||
<td style="padding-left: 10px;"></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><u>NIN</u></td>
|
||||
<td style="padding-left: 10px;"><u>HOLDER'S SIGNATURE</u></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>
|
||||
{{ $patient->national_id }}
|
||||
</th>
|
||||
<th style="padding-left: 10px;">
|
||||
{{-- signature --}}
|
||||
</th>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
.a8-container {
|
||||
/*
|
||||
width: 8.5cm;
|
||||
height: 5.4cm; */
|
||||
|
||||
|
||||
<br><br><br>
|
||||
width: 450px;
|
||||
height: 280px;
|
||||
border: 1px solid #000;
|
||||
display: flex;
|
||||
/* align-items: center;
|
||||
justify-content: center; */
|
||||
/* margin: auto; */
|
||||
/* page-break-inside: avoid; */
|
||||
}
|
||||
table {
|
||||
width: 100%;
|
||||
border-collapse: collapse;
|
||||
}
|
||||
th, td {
|
||||
border: 0px solid #000;
|
||||
padding: 0px;
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
|
||||
|
||||
<div class="row">
|
||||
<div class="col-12">
|
||||
<div style="background-color: rgb(43, 116, 91); padding:10px; padding-top: 120px;">
|
||||
<table align="center">
|
||||
|
||||
<tr>
|
||||
<td>HOST HEALTH FACILITY </td>
|
||||
<td>
|
||||
{{ $hospitalInfo->name }}
|
||||
</td>
|
||||
</tr>
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<tr>
|
||||
<td>VILLAGE</td>
|
||||
<td>
|
||||
{{ get_name(get_name($patient->id, "id", "village_id", "patients"), "id", "name", "villages") }}
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
|
||||
<tr>
|
||||
<td>DISTRICT</td>
|
||||
<td>
|
||||
{{ get_name($patient->district_id, "id", "name", "districts") }}
|
||||
</td>
|
||||
</tr>
|
||||
{{-- <div class="a8-container"> --}}
|
||||
<table >
|
||||
{{-- row 1 --}}
|
||||
<tr style=" border-bottom: 1px solid gray; ">
|
||||
<td style="padding:8px;">
|
||||
|
||||
<tr>
|
||||
<td colspan="2" style="background-color: #fff">
|
||||
{{ getDNS1DBarcodePNGOtherOption(sprintf("%04u", $patient->id)) }}
|
||||
{{-- LOGO --}}
|
||||
<img style="max-width: 100px; max-height: 25px;" src="{{ asset($data['hospitalInfo']->logo ?? '') }}" class="" alt="">
|
||||
|
||||
</td>
|
||||
<td style="padding:8px; text-align:right; font-weight:600;">PATIENT CARD</td>
|
||||
</tr>
|
||||
|
||||
|
||||
{{-- row 2 --}}
|
||||
<tr>
|
||||
<td colspan="2" style="font-size:5px; padding-top:10px;padding-left:7px; padding-right:7px; ">NAME</td>
|
||||
</tr>
|
||||
|
||||
{{-- row 3 --}}
|
||||
<tr>
|
||||
<td colspan="2" style="font-size:9px; font-weight:600;padding-left:7px; padding-right:7px;text-transform: uppercase " >
|
||||
{{ $data['patient']->first_name ?? '' }}
|
||||
{{ $data['patient']->last_name ?? '' }}
|
||||
{{ $data['patient']->other_names ?? '' }}
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
{{-- row 4 --}}
|
||||
<tr style="">
|
||||
<td style="font-size:5px; padding-top:10px;padding-left:7px; ">PATIENT NUMBER</td>
|
||||
<td style="font-size:5px; padding-top:10px; padding-right:7px; text-transform: uppercase">RESIDENCE</td>
|
||||
</tr>
|
||||
|
||||
{{-- row 5 --}}
|
||||
|
||||
<tr >
|
||||
<td style="font-size:9px; font-weight:600; padding-left:7px; text-transform: uppercase">{{ $data['patient']->number ?? '' }} </td>
|
||||
<td style="font-size:9px; font-weight:600; padding-right:7px;text-transform: uppercase">{{ get_name(get_name($data['patient']->id, "id", "village_id", "patients"), "id", "name", "villages") }}</td>
|
||||
|
||||
</tr>
|
||||
|
||||
{{-- row 6 --}}
|
||||
|
||||
<tr >
|
||||
<td style="font-size:5px; padding-top:10px; padding-left:7px;vertical-align: top; ">DISTRICT <br>
|
||||
<span style="font-size:9px; font-weight:600; text-transform: uppercase">{{ get_name($data['patient']->district_id, "id", "name", "districts") }} </span>
|
||||
</td>
|
||||
<td style="font-size:5px; padding-top:10px; padding-right:7px;">
|
||||
{{ getDNS1DBarcodePNGOCards(sprintf("%04u", $data['patient']->id)) }}
|
||||
<br>
|
||||
<h4 style="color: black">{{ sprintf("%04u", $patient->id) }}</h4>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<h4 style="color: black">{{ sprintf("%04u", $data['patient']->id) }}</h4></td>
|
||||
</tr>
|
||||
|
||||
|
||||
<div style="text-align: center; color: #fff; padding: 10px; font-size: 22px;">
|
||||
This card should only be used for identification at a Stre@mline network hospital.
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
<tr>
|
||||
<td colspan="2" style="font-size:5px; padding-top:5px; padding-left:7px; padding-right:7px; text-align:left; border-bottom: 0px solid gray; font-style:italic;">
|
||||
This card is a property of {{ $data['hospitalInfo']->name ?? '' }}, If found please return to the facility. <br>
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<tr >
|
||||
<td style="font-size:4px; text-align:left; padding-left:7px; padding-top:-12px; ">Supported by Streamline ; www.streamlinehealth.org</td>
|
||||
<td style="text-align:right; ">
|
||||
<img style="max-width: 60px; max-height: 25px; padding-right:7px; padding-top:5px;" src="{{ asset('uploads/streamline/color/280X50-06.png') }}" class="" alt="">
|
||||
</td>
|
||||
|
||||
</tr>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</table>
|
||||
{{-- </div> --}}
|
||||
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
||||
|
||||
+351
@@ -0,0 +1,351 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="{{ app()->getLocale() }}">
|
||||
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<meta name="description" content="">
|
||||
<meta name="author" content="">
|
||||
|
||||
<link rel="icon" type="image/png" sizes="16x16" href="{{ base_path('public/uploads/streamline/color/streamline_icon-02.png') }}">
|
||||
<title>{{ config('app.name', 'CHI Membership Card - Stre@mline') }}</title>
|
||||
<!-- Bootstrap Core CSS -->
|
||||
{{-- <link href="{{ base_path('public/bootstrap/css/bootstrap.min.css') }}" rel="stylesheet"> --}}
|
||||
<link href="https://stackpath.bootstrapcdn.com/bootstrap/4.5.2/css/bootstrap.min.css" rel="stylesheet">
|
||||
|
||||
|
||||
<style style="text-css">
|
||||
/* body{
|
||||
}
|
||||
|
||||
thead {
|
||||
}
|
||||
|
||||
tfoot {
|
||||
}
|
||||
|
||||
tr {
|
||||
}
|
||||
|
||||
th{
|
||||
font-weight: bolder;
|
||||
font-size: 22px;
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
td{
|
||||
font-size: 24px;
|
||||
padding-top: 5px;
|
||||
color: #fff;
|
||||
} */
|
||||
|
||||
/* new card */
|
||||
.a8-page {
|
||||
width: 8.5cm; /* A8 width */
|
||||
height: 5.4cm; /* A8 height */
|
||||
/* background-color: #f8f9fa; */
|
||||
margin: auto; /* Center the A8 page within the container */
|
||||
border: 1px solid #dee2e6; /* Light border */
|
||||
border-radius: 5px; /* Rounded corners */
|
||||
padding: 5px; /* Reduced padding to fit content */
|
||||
box-sizing: border-box; /* Include padding and border in element's total width and height */
|
||||
overflow: hidden; Hide overflow
|
||||
font-size: 10px; /* Adjust font size to fit content */
|
||||
}
|
||||
.container {
|
||||
height: 100vh; /* Full viewport height */
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
||||
.medical-card-title {
|
||||
font-size: 1.2em;
|
||||
font-weight: bold;
|
||||
text-align: center;
|
||||
margin-bottom: 5px; /* Reduced margin to fit content */
|
||||
}
|
||||
.medical-card-content p {
|
||||
margin: 2px 0; /* Reduced margins to fit content */
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
{{-- column --}}
|
||||
<div class="col">
|
||||
<div class="a8-page">
|
||||
<div class="row" style="padding:3px; background-color:#eaeef3;" >
|
||||
<div class="col-12 col-md">
|
||||
<img style="max-width: 100px; max-height: 25px;" src="{{ asset($hospitalInfo->logo) }}" class="" alt="Responsive image">
|
||||
|
||||
</div>
|
||||
<div class="col-12 col-md text-right" style="font-size:9px; margin-top:8px; font-weight:600;">PATIENT CARD</div>
|
||||
</div>
|
||||
<hr style="margin-top:5px;">
|
||||
|
||||
<div class="row">
|
||||
<div class="col-12 col-md">
|
||||
<p style="font-size:6px; margin-top:-10px;"> NAME</p>
|
||||
<p style="font-size:9px; margin-top:-15px; font-weight:600;"> AREBAHOONA MBABAZI ANGELLA MBABAZI OTHER NAME</p>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-12 col-md">
|
||||
<p style="font-size:6px; margin-top:-10px;"> PATIENT NUMBER</p>
|
||||
<p style="font-size:9px; margin-top:-15px; font-weight:600;"> SCH-24-01290000</p>
|
||||
</div>
|
||||
|
||||
<div class="col-12 col-md">
|
||||
<p style="font-size:6px; margin-top:-10px;"> VILLAGE</p>
|
||||
<p style="font-size:9px; margin-top:-15px; font-weight:600;"> NAKAPIRIPIRITI WARD</p>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="row" style="margin-top:-10px;">
|
||||
<div class="col-12 col-md">
|
||||
<p style="font-size:6px; "> DISTRICT</p>
|
||||
<p style="font-size:9px; margin-top:-15px; font-weight:600;">KABERAMAIDO DISTRICT</p>
|
||||
</div>
|
||||
|
||||
<div class="col-12 col-md">
|
||||
<p style="font-size:6px; "> BARCODE</p>
|
||||
<p style="font-size:9px; margin-top:-15px; font-weight:600;">
|
||||
<img style="max-width: 100%; max-height: 20px; " src="{{ asset($hospitalInfo->lab_stamp) }}" class="" alt="Responsive image">
|
||||
|
||||
</p>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="row" style="margin-top:-8px;">
|
||||
<div class="col-12 col-md">
|
||||
<p style="font-size:8px;">This card is a property of Kisiizi Medical center, if found please return to the facility.</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<hr style="margin-top:-15px;">
|
||||
|
||||
<div class="row">
|
||||
<div class="col-12 col-md-8" style="margin-top:-6px;">
|
||||
<p style="font-size:7px; "><i>Supported by Streamline ; www.streamlinehealth.org </i></p>
|
||||
</div>
|
||||
<div class="col-12 col-md-4" style="margin-top:-17px;">
|
||||
<img style="max-width: 100px; max-height: 20px;" src="{{ asset($hospitalInfo->stamp) }}" class="" alt="Responsive image">
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{{-- column --}}
|
||||
{{-- <div class="col">
|
||||
<div class="a8-page">
|
||||
<div class="row" style="padding:3px; background-color:#eaeef3;" >
|
||||
<div class="col-12 col-md">
|
||||
<img style="max-width: 100px; max-height: 25px;" src="{{ asset($hospital_details->logo) }}" class="" alt="Responsive image">
|
||||
|
||||
</div>
|
||||
<div class="col-12 col-md text-right" style="font-size:9px; margin-top:8px; font-weight:600;">PATIENT CARD</div>
|
||||
</div>
|
||||
<hr style="margin-top:5px;">
|
||||
|
||||
<div class="row">
|
||||
<div class="col-12 col-md">
|
||||
<p style="font-size:6px; margin-top:-10px;"> NAME</p>
|
||||
<p style="font-size:9px; margin-top:-15px; font-weight:600;"> AREBAHOONA MBABAZI ANGELLA MBABAZI OTHER NAME</p>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-12 col-md">
|
||||
<p style="font-size:6px; margin-top:-10px;"> PATIENT NUMBER</p>
|
||||
<p style="font-size:9px; margin-top:-15px; font-weight:600;"> SCH-24-01290000</p>
|
||||
</div>
|
||||
|
||||
<div class="col-12 col-md">
|
||||
<p style="font-size:6px; margin-top:-10px;"> VILLAGE</p>
|
||||
<p style="font-size:9px; margin-top:-15px; font-weight:600;"> NAKAPIRIPIRITI WARD</p>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="row" style="margin-top:-10px;">
|
||||
<div class="col-12 col-md">
|
||||
<p style="font-size:6px; "> DISTRICT</p>
|
||||
<p style="font-size:9px; margin-top:-15px; font-weight:600;">KABERAMAIDO DISTRICT</p>
|
||||
</div>
|
||||
|
||||
<div class="col-12 col-md">
|
||||
<p style="font-size:6px; "> BARCODE</p>
|
||||
<p style="font-size:9px; margin-top:-15px; font-weight:600;">
|
||||
<img style="max-width: 100%; max-height: 20px; " src="{{ asset($hospital_details->lab_stamp) }}" class="" alt="Responsive image">
|
||||
|
||||
</p>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="row" style="margin-top:-8px;">
|
||||
<div class="col-12 col-md">
|
||||
<p style="font-size:8px;">This card is a property of Kisiizi Medical center, if found please return to the facility.</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<hr style="margin-top:-15px;">
|
||||
|
||||
<div class="row">
|
||||
<div class="col-12 col-md-8" style="margin-top:-6px;">
|
||||
<p style="font-size:7px; "><i>Supported by Streamline ; www.streamlinehealth.org </i></p>
|
||||
</div>
|
||||
<div class="col-12 col-md-4" style="margin-top:-17px;">
|
||||
<img style="max-width: 100px; max-height: 20px;" src="{{ asset($hospital_details->stamp) }}" class="" alt="Responsive image">
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
</div> --}}
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
{{-- OLD VIEW --}}
|
||||
{{-- <div class="container-fluid">
|
||||
<div class="row">
|
||||
<div class="col-12">
|
||||
<div style="background-color: rgb(43, 116, 91); color:#fff">
|
||||
<div class="hospital-logo" style="padding-top: 10px;">
|
||||
@include('layouts.header_pdf_print')
|
||||
</div>
|
||||
|
||||
<div class="row" style="padding: 30px;">
|
||||
<div class="col-12" style="padding-top: 10px;">
|
||||
<table>
|
||||
<tr>
|
||||
<td><u>NAME</u></td>
|
||||
<td style="padding-left: 15px;"><u>SEX</u></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>
|
||||
{{ get_full_name($patient->id, "id", "first_name", "last_name", "patients") }}
|
||||
</th>
|
||||
<th style="padding-left: 15px;">
|
||||
{{ $patient->gender == 1 ? "MALE" : "FEMALE" }}
|
||||
</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td></td>
|
||||
<td style="padding-left: 15px;"></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><u>Stre@mline NUMBER</u></td>
|
||||
<td style="padding-left: 15px;"><u>DATE OF BIRTH</u></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>
|
||||
{{ $patient->number }}
|
||||
</th>
|
||||
<th style="padding-left: 15px;">
|
||||
{{ streamline_date($patient->date_of_birth) }}
|
||||
</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td></td>
|
||||
<td style="padding-left: 10px;"></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><u>NIN</u></td>
|
||||
<td style="padding-left: 10px;"><u>HOLDER'S SIGNATURE</u></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>
|
||||
{{ $patient->national_id }}
|
||||
</th>
|
||||
<th style="padding-left: 10px;">
|
||||
</th>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<br><br><br>
|
||||
|
||||
|
||||
|
||||
<div class="row">
|
||||
<div class="col-12">
|
||||
<div style="background-color: rgb(43, 116, 91); padding:10px; padding-top: 120px;">
|
||||
<table align="center">
|
||||
|
||||
<tr>
|
||||
<td>HOST HEALTH FACILITY </td>
|
||||
<td>
|
||||
{{ $hospitalInfo->name }}
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>VILLAGE</td>
|
||||
<td>
|
||||
{{ get_name(get_name($patient->id, "id", "village_id", "patients"), "id", "name", "villages") }}
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>DISTRICT</td>
|
||||
<td>
|
||||
{{ get_name($patient->district_id, "id", "name", "districts") }}
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td colspan="2" style="background-color: #fff">
|
||||
{{ getDNS1DBarcodePNGOtherOption(sprintf("%04u", $patient->id)) }}
|
||||
<br>
|
||||
<h4 style="color: black">{{ sprintf("%04u", $patient->id) }}</h4>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<div style="text-align: center; color: #fff; padding: 10px; font-size: 22px;">
|
||||
This card should only be used for identification at a Stre@mline network hospital.
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div> --}}
|
||||
|
||||
<script src="https://code.jquery.com/jquery-3.5.1.slim.min.js"></script>
|
||||
<script src="https://cdn.jsdelivr.net/npm/@popperjs/core@2.9.3/dist/umd/popper.min.js"></script>
|
||||
<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.5.2/js/bootstrap.min.js"></script>
|
||||
</body>
|
||||
</html>
|
||||
+401
@@ -0,0 +1,401 @@
|
||||
@extends('layouts.main')
|
||||
|
||||
@push('styles')
|
||||
|
||||
<link href="{{ asset('elite/bower_components/bootstrap-datepicker/bootstrap-datepicker.min.css') }}" rel="stylesheet" type="text/css" />
|
||||
<link href="{{ asset('/elite/bower_components/datatables/jquery.dataTables.min.css') }}" rel="stylesheet" type="text/css" />
|
||||
<link href="{{ asset('elite/tables/css/buttons.dataTables.min.css') }}" rel="stylesheet" type="text/css" />
|
||||
<link href="{{ asset('elite/bower_components/select2/select2.min.css') }}" rel="stylesheet" />
|
||||
<link href="{{ asset('elite/bower_components/typeahead.js-master/dist/typehead-min.css') }}" rel="stylesheet">
|
||||
@endpush
|
||||
|
||||
@section('content')
|
||||
<div class="row bg-title">
|
||||
<div class="col-lg-3 col-md-4 col-sm-4 col-xs-12">
|
||||
<h4 class="page-title">{{ __('layout.patient_cards') }}</h4>
|
||||
</div>
|
||||
<div class="col-lg-9 col-sm-8 col-md-8 col-xs-12">
|
||||
<ol class="breadcrumb">
|
||||
<li><a href="{{ route('home') }}">{{ __('patients.dashboard') }}</a></li>
|
||||
<li><a href="{{ route('patients.index') }}">{{ __('patients.patients') }}</a></li>
|
||||
|
||||
<li >{{ __('patients.print_patients_cards') }}</li>
|
||||
|
||||
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="white-box">
|
||||
|
||||
<div class="row">
|
||||
<div class="col-12 col-md">
|
||||
<a href="{{ route('patients.create') }}" class="btn btn-success"><i class="fa fa-plus"></i> {{ __('patients.add_patient') }} </a>
|
||||
<a href="{{ route('patients.index') }}" class="btn btn-info"> <i class="fa fa-eye"></i> {{ __('patients.view_patients') }} </a>
|
||||
</div>
|
||||
|
||||
<div class="col-12 col-md" style="text-align:right;">
|
||||
<a href="{{ route('patients.inactive') }}" class="btn btn-danger"><i class="fa fa-eye-slash"></i> {{ __('patients.inactive_patients') }} </a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="white-box">
|
||||
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="panel panel-default" style="border-radius: 5px;">
|
||||
<div class="panel-body">
|
||||
|
||||
{{-- Search Patient Cards --}}
|
||||
<form action="{{ route('patients.search_patient_cards_to_print') }}" method="POST" >
|
||||
@csrf
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md">
|
||||
<div class="form-group">
|
||||
<label>{{ __('patients.select_registered_date') }}:</label>
|
||||
<select class="form-control required" name="dates" id="dates">
|
||||
{{-- <option value="null">--Select--</option> --}}
|
||||
<option value="today">{{ __('patients.today') }}</option>
|
||||
<option value="yesterday">{{ __('patients.yesterday') }}</option>
|
||||
<option value="custom_date">{{ __('patients.custom_date') }}</option>
|
||||
<option value="custom_date_range">{{ __('patients.date_range') }}</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md" id="sDate" style="display: none;">
|
||||
<div class="form-group">
|
||||
<label>{{ __('patients.start_date') }}:</label>
|
||||
<div class="input-group">
|
||||
<input type="text" name="start_date" id="start_date" class="form-control">
|
||||
<span class="input-group-addon"><i class="icon-calender"></i></span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md" id="eDate" style="display: none;">
|
||||
<div class="form-group">
|
||||
<label>{{ __('patients.end_date') }}:</label>
|
||||
<div class="input-group">
|
||||
<input type="text" name="end_date" id="end_date" class="form-control">
|
||||
<span class="input-group-addon"><i class="icon-calender"></i></span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md">
|
||||
<label>{{ __('patients.select_patients') }}:</label>
|
||||
<div class="input-group">
|
||||
<select class="form-control" name="number[]" id="patient_number" multiple></select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md">
|
||||
<div class="form-group" style="margin-top: 25px;">
|
||||
<button type="submit" class="btn btn-success"><i class="fa fa-paper-plane"></i> {{ __('patients.submit') }}</button>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@include('flash::message')
|
||||
|
||||
|
||||
@php
|
||||
use \Carbon\Carbon;
|
||||
$today = Carbon::now();
|
||||
$patients_current_date = streamline_date($today);
|
||||
@endphp
|
||||
{{-- Process patient cards form --}}
|
||||
<form id="patient_cards_form" action="{{ route('patients.print_patients_cards') }}" method="POST">
|
||||
@csrf
|
||||
<div class="row">
|
||||
|
||||
|
||||
<div class="col-12 col-md" style="text-align:left; margin-bottom:10px;">
|
||||
<h5 style="color:rgb(27, 144, 223);">{{ __('patients.patients_registered_today') }}</h5>
|
||||
</div>
|
||||
<div class="col-12 col-md" style="text-align:right; margin-bottom:10px;">
|
||||
@if (Auth::user()->can('print-patient-cards'))
|
||||
<button type="submit" id="submit-button" class="btn btn-rounded" style="background-color:purple; color:#ffffff;"><i class="fa fa-print"></i> {{ __('patients.print_cards') }}</button>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="table-responsive" style="padding-right:15px; padding-left:15px;">
|
||||
<table class="table success-table table-sm table-striped table-hover " style="color: white; border: 1px solid #00c292;">
|
||||
<thead >
|
||||
<tr style="background-color: #00c292; color: white;">
|
||||
<th style="color: white;">{{ __('patients.hash') }}</th>
|
||||
<th style="color: white;">{{ __('patients.patient_number') }}</th>
|
||||
<th style="color: white;">{{ __('patients.full_names') }}</th>
|
||||
<th style="color: white;">{{ __('patients.gender') }}</th>
|
||||
<th style="color: white;">{{ __('patients.age') }}</th>
|
||||
<th style="color: white;">{{ __('patients.phone_number') }}</th>
|
||||
<th style="color: white;">{{ __('patients.category') }}</th>
|
||||
<th style="color: white;">{{ __('patients.residence') }}</th>
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
||||
|
||||
|
||||
@forelse ( $patients as $key => $patient )
|
||||
|
||||
@php
|
||||
$village = \Streamline\Models\Village::find($patient->village_id);
|
||||
$patient_category = \Streamline\Models\PatientCategory::find($patient->category_id);
|
||||
@endphp
|
||||
|
||||
<tr>
|
||||
<td><input type="checkbox" value="{{ $patient->id }}" name="patients[]" class="patient_cards_checkbox"></td>
|
||||
<td>{{ $patient->number ?? '' }}</td>
|
||||
<td>{!! insurance_flag($patient->id) !!}</td>
|
||||
<td>
|
||||
@if($patient->gender == 1)
|
||||
{{ __('patients.male') }}
|
||||
@else
|
||||
{{ __('patients.female') }}
|
||||
@endif
|
||||
</td>
|
||||
<td>{{ get_patients_age($patient->date_of_birth) }}</td>
|
||||
<td>{{ $patient->phone }}</td>
|
||||
<td>{{ $patient_category->name ?? '' }}</td>
|
||||
<td>{{ $village->name ?? '' }}</td>
|
||||
</tr>
|
||||
|
||||
@empty
|
||||
<tr>
|
||||
<td colspan="3" ></td>
|
||||
<td colspan="3" style="color:red;" >
|
||||
No Patients Found!
|
||||
</td>
|
||||
<td colspan="2" ></td>
|
||||
|
||||
</tr>
|
||||
@endforelse
|
||||
|
||||
|
||||
</tbody>
|
||||
|
||||
</table>
|
||||
<center>
|
||||
{{-- {{ $patients->links() }} --}}
|
||||
{{ $patients->appends(Request::except('page'))->links() }}
|
||||
</center>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</form>
|
||||
|
||||
|
||||
</div>
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
<!-- Typehead Plugin JavaScript -->
|
||||
|
||||
|
||||
<script src="{{ asset('elite/bower_components/select2/select2.min.js') }}"></script>
|
||||
<script src="{{ asset('elite/bower_components/bootstrap-datepicker/bootstrap-datepicker.min.js') }}"></script>
|
||||
<script src="{{ asset('elite/bower_components/datatables/jquery.dataTables.min.js') }}"></script>
|
||||
<script src="{{ asset('elite/tables/js/dataTables.buttons.min.js') }}"></script>
|
||||
<script src="{{ asset('elite/tables/js/buttons.flash.min.js') }}"></script>
|
||||
<script src="{{ asset('elite/tables/js/jszip.min.js') }}"></script>
|
||||
<script src="{{ asset('elite/tables/js/pdfmake.min.js') }}"></script>
|
||||
<script src="{{ asset('elite/tables/js/vfs_fonts.js') }}"></script>
|
||||
<script src="{{ asset('elite/tables/js/buttons.html5.min.js') }}"></script>
|
||||
<script src="{{ asset('elite/tables/js/buttons.print.min.js') }}"></script>
|
||||
|
||||
<script>
|
||||
document.addEventListener('DOMContentLoaded', function() {
|
||||
const checkboxes = document.querySelectorAll('.patient_cards_checkbox');
|
||||
const form = document.getElementById('patient_cards_form');
|
||||
const maxChecked = 10;
|
||||
|
||||
checkboxes.forEach(checkbox => {
|
||||
checkbox.addEventListener('change', function() {
|
||||
const checkedCount = document.querySelectorAll('.patient_cards_checkbox:checked').length;
|
||||
|
||||
if (checkedCount > maxChecked) {
|
||||
alert(`You can only select up to ${maxChecked} patients.`);
|
||||
|
||||
// this.disabled = true;
|
||||
this.checked = false;
|
||||
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
form.addEventListener('submit', function(event) {
|
||||
const checkedCount = document.querySelectorAll('.patient_cards_checkbox:checked').length;
|
||||
|
||||
if (checkedCount === 0) {
|
||||
event.preventDefault();
|
||||
alert('Please select at least one patient.');
|
||||
|
||||
}
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
||||
|
||||
|
||||
<script type="text/javascript">
|
||||
const todays_date = "Patients Registered On " + "{{ $patients_current_date }}";
|
||||
// disable data tables pagination
|
||||
|
||||
$('.table').DataTable({
|
||||
dom: 'Bfrtip',
|
||||
pageLength: 200,
|
||||
paging: false,
|
||||
info: false,
|
||||
buttons: [
|
||||
'copy',
|
||||
{extend: 'csv',
|
||||
message: "Patients Registered",
|
||||
title: todays_date,
|
||||
exportOptions: {
|
||||
columns: [ 1, 2, 3, 4, 5, 6,7]
|
||||
},
|
||||
},
|
||||
{extend: 'excel',
|
||||
message: "Patients Registered",
|
||||
title: todays_date,
|
||||
exportOptions: {
|
||||
columns: [ 1, 2, 3, 4, 5, 6,7]
|
||||
},
|
||||
sheetName: "Patients Registered"
|
||||
},
|
||||
{extend: 'pdf',
|
||||
message: "Patients Registered",
|
||||
title: todays_date,
|
||||
orientation: 'portrait',
|
||||
pageSize: 'LETTER',
|
||||
exportOptions: {
|
||||
columns: [ 1, 2, 3, 4, 5, 6,7]
|
||||
},
|
||||
customize: function (doc) {
|
||||
doc.defaultStyle.fontSize = 10;
|
||||
}
|
||||
},
|
||||
{extend: 'print',
|
||||
message: "Patients Registered",
|
||||
title: todays_date,
|
||||
exportOptions: {
|
||||
columns: [ 1, 2, 3, 4, 5, 6,7]
|
||||
},
|
||||
customize: function (win) {
|
||||
$(win.document.body)
|
||||
.css('font-size', '10pt')
|
||||
.css('background', '#fff')
|
||||
.prepend(
|
||||
'<img src="<?php echo asset('uploads/logo/logo-sm.png'); ?>" style="position:absolute; top:0; right:0;" />'
|
||||
);
|
||||
$(win.document.body).find('table')
|
||||
.addClass('compact')
|
||||
.css('font-size', 'inherit');
|
||||
}
|
||||
}
|
||||
]
|
||||
});
|
||||
|
||||
|
||||
|
||||
|
||||
</script>
|
||||
|
||||
<script type="text/javascript">
|
||||
|
||||
|
||||
|
||||
$('#patient_number').change(function () {
|
||||
let id = $('#patient_number').val();
|
||||
$('#patient_id').val(id);
|
||||
});
|
||||
|
||||
$('#patient_number').select2({
|
||||
placeholder: 'Search by patient details (names and number)',
|
||||
ajax: {
|
||||
url: '/patients/search_patient_by_name_number',
|
||||
dataType: 'json',
|
||||
delay: 250,
|
||||
processResults: function (data) {
|
||||
return {
|
||||
results: $.map(data, function (item) {
|
||||
return {
|
||||
text: item.first_name + " " + item.last_name + " (" + item.number + ")",
|
||||
id: item.id
|
||||
}
|
||||
})
|
||||
};
|
||||
},
|
||||
cache: true
|
||||
}
|
||||
});
|
||||
|
||||
$('#dates').change(function (e) {
|
||||
|
||||
if($(this).val() === "custom_date"){
|
||||
|
||||
$("#eDate").hide();
|
||||
$("#sDate").show();
|
||||
|
||||
}else if($(this).val() === "custom_date_range"){
|
||||
|
||||
$("#sDate").show();
|
||||
$("#eDate").show();
|
||||
}else{
|
||||
|
||||
$("#eDate").hide();
|
||||
$("#sDate").hide();
|
||||
}
|
||||
});
|
||||
|
||||
$('#end_date').datepicker({
|
||||
autoclose: true,
|
||||
todayHighlight: true,
|
||||
format: 'dd-mm-yyyy'
|
||||
});
|
||||
|
||||
$('#start_date').datepicker({
|
||||
autoclose: true,
|
||||
todayHighlight: true,
|
||||
format: 'dd-mm-yyyy'
|
||||
});
|
||||
|
||||
|
||||
$('#staff_member').select2({
|
||||
placeholder: "-- select --"
|
||||
});
|
||||
$('#staff_member_accountant').select2({
|
||||
placeholder: "-- select --"
|
||||
});
|
||||
</script>
|
||||
|
||||
|
||||
@endpush
|
||||
|
||||
@push('styles')
|
||||
<style type="text/css">
|
||||
.color-bordered-table.success-bordered-table {
|
||||
border-top: 0px;
|
||||
}
|
||||
</style>
|
||||
@endpush
|
||||
|
||||
+145
@@ -0,0 +1,145 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Patient Card</title>
|
||||
<style>
|
||||
|
||||
@page {
|
||||
|
||||
/* margin: 5;
|
||||
padding:0;
|
||||
size:A4 potrait;
|
||||
text-align:center; */
|
||||
|
||||
margin-left:35;
|
||||
margin-top:12;
|
||||
margin-right:0;
|
||||
margin-bottom:0;
|
||||
padding:0;
|
||||
size:A4 potrait;
|
||||
text-align:center;
|
||||
}
|
||||
|
||||
body {
|
||||
font-family: Arial, sans-serif;
|
||||
/* margin:0; */
|
||||
}
|
||||
.a8-container {
|
||||
|
||||
width: 8.5cm;
|
||||
height: 5.4cm;
|
||||
|
||||
/* width: 7.4cm;
|
||||
height: 5.2cm; */
|
||||
margin-top:10px;
|
||||
border: 1px solid #000;
|
||||
display: flex;
|
||||
}
|
||||
table {
|
||||
width: 100%;
|
||||
border-collapse: collapse;
|
||||
}
|
||||
th, td {
|
||||
border: 0px solid #000;
|
||||
padding: 0px;
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
|
||||
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
|
||||
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
@php
|
||||
$counter = 0;
|
||||
@endphp
|
||||
|
||||
@foreach($patient_cards as $key => $patient)
|
||||
<td>
|
||||
<div class="a8-container">
|
||||
<table >
|
||||
<tr style=" border-bottom: 1px solid gray; ">
|
||||
<td style="padding:8px;">
|
||||
<img style="max-width: 100px; max-height: 25px;" src="{{ asset($hospital_details->logo ?? '') }}" class="" alt="">
|
||||
</td>
|
||||
<td style="padding:8px; text-align:right; font-weight:600;">PATIENT CARD</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2" style="font-size:6px; padding-top:14px;padding-left:7px; padding-right:7px; ">NAME</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2" style="font-size:9px; font-weight:600;padding-left:7px; padding-right:7px; text-transform: uppercase " >
|
||||
{{ $patient->first_name ?? '' }}
|
||||
{{ $patient->last_name ?? '' }}
|
||||
{{ $patient->other_names ?? '' }}
|
||||
</td>
|
||||
</tr>
|
||||
<tr style="">
|
||||
<td style="font-size:6px; padding-top:10px;padding-left:7px; ">PATIENT NUMBER</td>
|
||||
<td style="font-size:6px; padding-top:10px; padding-right:7px;text-transform: uppercase ">RESIDENCE</td>
|
||||
</tr>
|
||||
<tr >
|
||||
<td style="font-size:9px; font-weight:600; padding-left:7px; ">{{ $patient->number ?? '' }} </td>
|
||||
<td style="font-size:9px; font-weight:600; padding-right:7px; text-transform: uppercase">{{ get_name(get_name($patient->id, "id", "village_id", "patients"), "id", "name", "villages") }}</td>
|
||||
</tr>
|
||||
<tr >
|
||||
<td style="font-size:5px; padding-top:10px; padding-left:7px;vertical-align: top; ">DISTRICT <br>
|
||||
<span style="font-size:9px; font-weight:600; text-transform: uppercase">{{ get_name($patient->district_id, "id", "name", "districts") }} </span>
|
||||
</td>
|
||||
<td style="font-size:5px; padding-top:10px; padding-right:7px;">
|
||||
{{ getDNS1DBarcodePNGOCards(sprintf("%04u", $patient->id)) }}
|
||||
<br>
|
||||
<h4 style="color: black">{{ sprintf("%04u", $patient->id) }}</h4></td>
|
||||
</tr>
|
||||
|
||||
|
||||
<tr>
|
||||
<td colspan="2" style="font-size:5px; padding-top:5px; padding-left:7px; padding-right:7px; text-align:left; border-bottom: 0px solid gray; font-style:italic;">
|
||||
|
||||
This card is a property of {{ $hospital_details->name ?? '' }} , If found please return to the facility. <br>
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
|
||||
|
||||
<tr >
|
||||
<td style="font-size:4px; text-align:left; padding-left:7px; padding-top:-12px; ">Supported by Streamline ; www.streamlinehealth.org</td>
|
||||
<td style="text-align:right; ">
|
||||
<img style="max-width: 60px; max-height: 25px; padding-right:7px; padding-top:5px;" src="{{ asset('uploads/streamline/color/280X50-06.png') }}" class="" alt="">
|
||||
</td>
|
||||
|
||||
</tr>
|
||||
|
||||
</table>
|
||||
</div>
|
||||
|
||||
</td>
|
||||
@php
|
||||
$counter++;
|
||||
@endphp
|
||||
|
||||
@if($counter % 2 == 0)
|
||||
</tr><tr>
|
||||
@endif
|
||||
@endforeach
|
||||
|
||||
@if($counter % 2 != 0)
|
||||
<td></td>
|
||||
@endif
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
||||
+411
@@ -0,0 +1,411 @@
|
||||
@extends('layouts.main')
|
||||
|
||||
@push('styles')
|
||||
<link href="{{ asset('elite/bower_components/bootstrap-datepicker/bootstrap-datepicker.min.css') }}" rel="stylesheet" type="text/css" />
|
||||
<link href="{{ asset('/elite/bower_components/datatables/jquery.dataTables.min.css') }}" rel="stylesheet" type="text/css" />
|
||||
<link href="{{ asset('elite/tables/css/buttons.dataTables.min.css') }}" rel="stylesheet" type="text/css" />
|
||||
<link href="{{ asset('elite/bower_components/select2/select2.min.css') }}" rel="stylesheet" />
|
||||
<link href="{{ asset('elite/bower_components/typeahead.js-master/dist/typehead-min.css') }}" rel="stylesheet">
|
||||
@endpush
|
||||
|
||||
@section('content')
|
||||
<div class="row bg-title">
|
||||
<div class="col-lg-3 col-md-4 col-sm-4 col-xs-12">
|
||||
<h4 class="page-title">{{ __('layout.patient_cards') }}</h4>
|
||||
</div>
|
||||
<div class="col-lg-9 col-sm-8 col-md-8 col-xs-12">
|
||||
<ol class="breadcrumb">
|
||||
<li><a href="{{ route('home') }}">{{ __('patients.dashboard') }}</a></li>
|
||||
<li><a href="{{ route('patients.index') }}">{{ __('patients.patients') }}</a></li>
|
||||
@if (Auth::user()->can('print-patient-cards'))
|
||||
<li class="active">v{{ __('patients.print_patients_cards') }}</li>
|
||||
@endif
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="white-box">
|
||||
|
||||
<div class="row">
|
||||
<div class="col-12 col-md">
|
||||
<a href="{{ route('patients.create') }}" class="btn btn-success"><i class="fa fa-plus"></i> {{ __('patients.add_patient') }} </a>
|
||||
<a href="{{ route('patients.index') }}" class="btn btn-info"> <i class="fa fa-eye"></i> {{ __('patients.view_patients') }} </a>
|
||||
</div>
|
||||
|
||||
<div class="col-12 col-md" style="text-align:right;">
|
||||
<a href="{{ route('patients.inactive') }}" class="btn btn-danger"><i class="fa fa-eye-slash"></i> {{ __('patients.inactive_patients') }} </a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="white-box">
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="panel panel-default" style="border-radius: 5px;">
|
||||
<div class="panel-body">
|
||||
|
||||
{{-- Search Patient Cards --}}
|
||||
<form action="{{ route('patients.search_patient_cards_to_print') }}" method="POST" >
|
||||
@csrf
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md">
|
||||
<div class="form-group">
|
||||
<label>{{ __('patients.select_registered_date') }}:</label>
|
||||
<select class="form-control required" name="dates" id="dates">
|
||||
{{-- <option value="null">--Select--</option> --}}
|
||||
<option value="today">{{ __('patients.today') }}</option>
|
||||
<option value="yesterday">{{ __('patients.yesterday') }}</option>
|
||||
<option value="custom_date">{{ __('patients.custom_date') }}</option>
|
||||
<option value="custom_date_range">{{ __('patients.date_range') }}</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md" id="sDate" style="display: none;">
|
||||
<div class="form-group">
|
||||
<label>{{ __('patients.start_date') }}:</label>
|
||||
<div class="input-group">
|
||||
<input type="text" name="start_date" id="start_date" class="form-control">
|
||||
<span class="input-group-addon"><i class="icon-calender"></i></span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md" id="eDate" style="display: none;">
|
||||
<div class="form-group">
|
||||
<label>{{ __('patients.end_date') }}:</label>
|
||||
<div class="input-group">
|
||||
<input type="text" name="end_date" id="end_date" class="form-control">
|
||||
<span class="input-group-addon"><i class="icon-calender"></i></span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md">
|
||||
<label>{{ __('patients.select_patients') }}:</label>
|
||||
<div class="input-group">
|
||||
<select class="form-control" name="number[]" id="patient_number" multiple></select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md">
|
||||
<div class="form-group" style="margin-top: 25px;">
|
||||
<button type="submit" class="btn btn-success"><i class="fa fa-paper-plane"></i> {{ __('patients.submit') }}</button>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@include('flash::message')
|
||||
|
||||
|
||||
{{-- Process patient cards form --}}
|
||||
<form id="patient_cards_form" action="{{ route('patients.print_patients_cards') }}" method="POST">
|
||||
@csrf
|
||||
<div class="row">
|
||||
|
||||
|
||||
<div class="col-12 col-md" style="text-align:left; margin-bottom:10px;">
|
||||
<h5 style="color:rgb(27, 144, 223);">
|
||||
|
||||
{{ $searched_data_string ?? '' }}
|
||||
|
||||
</h5>
|
||||
</div>
|
||||
<div class="col-12 col-md" style="text-align:right; margin-bottom:10px;">
|
||||
@if (Auth::user()->can('print-patient-cards'))
|
||||
<button type="submit" id="submit-button" class="btn btn-rounded" style="background-color:purple; color:#ffffff;"><i class="fa fa-print"></i> {{ __('patients.print_cards') }}</button>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="table-responsive" style="padding-right:15px; padding-left:15px;">
|
||||
<table class="table success-table table-sm table-striped table-hover disable_pagination" style="color: white; border: 1px solid #00c292;">
|
||||
<thead >
|
||||
<tr style="background-color: #00c292; color: white;">
|
||||
<th style="color: white;">{{ __('patients.hash') }}</th>
|
||||
<th style="color: white;">{{ __('patients.patient_number') }}</th>
|
||||
<th style="color: white;">{{ __('patients.full_names') }}</th>
|
||||
<th style="color: white;">{{ __('patients.gender') }}</th>
|
||||
<th style="color: white;">{{ __('patients.age') }}</th>
|
||||
<th style="color: white;">{{ __('patients.phone_number') }}</th>
|
||||
<th style="color: white;">{{ __('patients.category') }}</th>
|
||||
<th style="color: white;">{{ __('patients.residence') }}</th>
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
||||
|
||||
|
||||
@forelse ( $patients as $key => $patient )
|
||||
|
||||
@php
|
||||
$village = \Streamline\Models\Village::find($patient->village_id);
|
||||
$patient_category = \Streamline\Models\PatientCategory::find($patient->category_id);
|
||||
@endphp
|
||||
|
||||
<tr>
|
||||
<td><input type="checkbox" value="{{ $patient->id }}" name="patients[]" class="patient_cards_checkbox"></td>
|
||||
<td>{{ $patient->number ?? '' }}</td>
|
||||
<td>{!! insurance_flag($patient->id) !!}</td>
|
||||
<td>
|
||||
@if($patient->gender == 1)
|
||||
{{ __('patients.male') }}
|
||||
@else
|
||||
{{ __('patients.female') }}
|
||||
@endif
|
||||
</td>
|
||||
<td>{{ get_patients_age($patient->date_of_birth) }}</td>
|
||||
<td>{{ $patient->phone }}</td>
|
||||
<td>{{ $patient_category->name ?? '' }}</td>
|
||||
<td>{{ $village->name ?? '' }}</td>
|
||||
</tr>
|
||||
|
||||
|
||||
@empty
|
||||
<tr>
|
||||
<td colspan="3" ></td>
|
||||
<td colspan="3" style="color:red;" >
|
||||
No Patients Found!
|
||||
</td>
|
||||
<td colspan="2" ></td>
|
||||
|
||||
</tr>
|
||||
@endforelse
|
||||
|
||||
|
||||
</tbody>
|
||||
|
||||
|
||||
</table>
|
||||
{{-- laravel pagination --}}
|
||||
<center>
|
||||
{{-- {{ $patients->links() }} --}}
|
||||
|
||||
{{ $patients->appends(Request::except('page'))->links() }}
|
||||
</center>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</form>
|
||||
|
||||
|
||||
</div>
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
<!-- Typehead Plugin JavaScript -->
|
||||
|
||||
|
||||
<script src="{{ asset('elite/bower_components/select2/select2.min.js') }}"></script>
|
||||
<script src="{{ asset('elite/bower_components/bootstrap-datepicker/bootstrap-datepicker.min.js') }}"></script>
|
||||
<script src="{{ asset('elite/bower_components/datatables/jquery.dataTables.min.js') }}"></script>
|
||||
<script src="{{ asset('elite/tables/js/dataTables.buttons.min.js') }}"></script>
|
||||
<script src="{{ asset('elite/tables/js/buttons.flash.min.js') }}"></script>
|
||||
<script src="{{ asset('elite/tables/js/jszip.min.js') }}"></script>
|
||||
<script src="{{ asset('elite/tables/js/pdfmake.min.js') }}"></script>
|
||||
<script src="{{ asset('elite/tables/js/vfs_fonts.js') }}"></script>
|
||||
<script src="{{ asset('elite/tables/js/buttons.html5.min.js') }}"></script>
|
||||
<script src="{{ asset('elite/tables/js/buttons.print.min.js') }}"></script>
|
||||
|
||||
{{-- print patient cards --}}
|
||||
{{-- <script src="https://cdnjs.cloudflare.com/ajax/libs/sweetalert/2.1.2/sweetalert.min.js"></script> --}}
|
||||
|
||||
|
||||
<script>
|
||||
document.addEventListener('DOMContentLoaded', function() {
|
||||
const checkboxes = document.querySelectorAll('.patient_cards_checkbox');
|
||||
const form = document.getElementById('patient_cards_form');
|
||||
const maxChecked = 10;
|
||||
|
||||
checkboxes.forEach(checkbox => {
|
||||
checkbox.addEventListener('change', function() {
|
||||
const checkedCount = document.querySelectorAll('.patient_cards_checkbox:checked').length;
|
||||
|
||||
if (checkedCount >= maxChecked) {
|
||||
checkboxes.forEach(box => {
|
||||
if (!box.checked) {
|
||||
box.disabled = true;
|
||||
}
|
||||
});
|
||||
} else {
|
||||
checkboxes.forEach(box => {
|
||||
box.disabled = false;
|
||||
});
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
form.addEventListener('submit', function(event) {
|
||||
const checkedCount = document.querySelectorAll('.patient_cards_checkbox:checked').length;
|
||||
|
||||
if (checkedCount === 0) {
|
||||
event.preventDefault();
|
||||
alert('Please select at least one patient.');
|
||||
}
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
||||
<script type="text/javascript">
|
||||
|
||||
var searchedDataString = "{{ $searched_data_string ?? '' }}";
|
||||
|
||||
$('.table').DataTable({
|
||||
dom: 'Bfrtip',
|
||||
pageLength: 200,
|
||||
//disable js pagination
|
||||
paging: false,
|
||||
info: false,
|
||||
buttons: [
|
||||
'copy',
|
||||
{extend: 'csv',
|
||||
message: "Patients Registered",
|
||||
title: searchedDataString,
|
||||
exportOptions: {
|
||||
columns: [ 1, 2, 3, 4, 5, 6,7]
|
||||
},
|
||||
},
|
||||
{extend: 'excel',
|
||||
message: "Patients Registered",
|
||||
title: searchedDataString,
|
||||
exportOptions: {
|
||||
columns: [ 1, 2, 3, 4, 5, 6,7]
|
||||
},
|
||||
sheetName: "Patients Registered"
|
||||
},
|
||||
{extend: 'pdf',
|
||||
message: "Patients Registered",
|
||||
title: searchedDataString,
|
||||
orientation: 'portrait',
|
||||
pageSize: 'LETTER',
|
||||
exportOptions: {
|
||||
columns: [ 1, 2, 3, 4, 5, 6,7]
|
||||
},
|
||||
customize: function (doc) {
|
||||
doc.defaultStyle.fontSize = 10;
|
||||
// doc.styles.tableHeader.alignment = 'left';
|
||||
}
|
||||
},
|
||||
{extend: 'print',
|
||||
message: "Patients Registered",
|
||||
title: searchedDataString,
|
||||
exportOptions: {
|
||||
columns: [ 1, 2, 3, 4, 5, 6,7]
|
||||
},
|
||||
customize: function (win) {
|
||||
$(win.document.body)
|
||||
.css('font-size', '10pt')
|
||||
.css('background', '#fff')
|
||||
.prepend(
|
||||
'<img src="<?php echo asset('uploads/logo/logo-sm.png'); ?>" style="position:absolute; top:0; right:0;" />'
|
||||
);
|
||||
|
||||
$(win.document.body).find('h1')
|
||||
.css('font-size', '9pt'); // Adjust font size as needed
|
||||
|
||||
$(win.document.body).find('table')
|
||||
.addClass('compact')
|
||||
.css('font-size', 'inherit');
|
||||
}
|
||||
}
|
||||
]
|
||||
});
|
||||
|
||||
|
||||
|
||||
|
||||
</script>
|
||||
|
||||
<script>
|
||||
|
||||
$('#patient_number').change(function () {
|
||||
let id = $('#patient_number').val();
|
||||
$('#patient_id').val(id);
|
||||
});
|
||||
|
||||
$('#patient_number').select2({
|
||||
placeholder: 'Search by patient details (names and number)',
|
||||
ajax: {
|
||||
url: '/patients/search_patient_by_name_number',
|
||||
dataType: 'json',
|
||||
delay: 250,
|
||||
processResults: function (data) {
|
||||
return {
|
||||
results: $.map(data, function (item) {
|
||||
return {
|
||||
text: item.first_name + " " + item.last_name + " (" + item.number + ")",
|
||||
id: item.id
|
||||
}
|
||||
})
|
||||
};
|
||||
},
|
||||
cache: true
|
||||
}
|
||||
});
|
||||
|
||||
$('#dates').change(function (e) {
|
||||
|
||||
if($(this).val() === "custom_date"){
|
||||
|
||||
$("#eDate").hide();
|
||||
$("#sDate").show();
|
||||
|
||||
}else if($(this).val() === "custom_date_range"){
|
||||
|
||||
$("#sDate").show();
|
||||
$("#eDate").show();
|
||||
}else{
|
||||
|
||||
$("#eDate").hide();
|
||||
$("#sDate").hide();
|
||||
}
|
||||
});
|
||||
|
||||
$('#end_date').datepicker({
|
||||
autoclose: true,
|
||||
todayHighlight: true,
|
||||
format: 'dd-mm-yyyy'
|
||||
});
|
||||
|
||||
$('#start_date').datepicker({
|
||||
autoclose: true,
|
||||
todayHighlight: true,
|
||||
format: 'dd-mm-yyyy'
|
||||
});
|
||||
|
||||
|
||||
|
||||
$('#staff_member').select2({
|
||||
placeholder: "-- select --"
|
||||
});
|
||||
$('#staff_member_accountant').select2({
|
||||
placeholder: "-- select --"
|
||||
});
|
||||
</script>
|
||||
|
||||
|
||||
@endpush
|
||||
|
||||
@push('styles')
|
||||
<style type="text/css">
|
||||
.color-bordered-table.success-bordered-table {
|
||||
border-top: 0px;
|
||||
}
|
||||
</style>
|
||||
@endpush
|
||||
|
||||
@@ -1,6 +1,12 @@
|
||||
@extends('layouts.main')
|
||||
|
||||
@section('content')
|
||||
|
||||
@php
|
||||
$other_patients_info_data = !empty($patient->other_patients_info) ? json_decode($patient->other_patients_info) : '';
|
||||
|
||||
@endphp
|
||||
|
||||
<div class="row bg-title">
|
||||
<div class="col-lg-3 col-md-4 col-sm-4 col-xs-12">
|
||||
<h4 class="page-title">{{ __('patients.view') }}</h4>
|
||||
@@ -42,7 +48,7 @@
|
||||
<tr>
|
||||
<th>Code</th>
|
||||
<td>
|
||||
{{ getDNS1DBarcodePNGOtherOption(sprintf("%04u", $patient->id)) }}
|
||||
{{ getDNS1DBarcodePNG(sprintf("%04u", $patient->id)) }}
|
||||
<h4>{{ sprintf("%04u", $patient->id) }}</h4>
|
||||
</td>
|
||||
</tr>
|
||||
@@ -65,7 +71,9 @@
|
||||
</div>
|
||||
|
||||
<div class="col-sm-3">
|
||||
@if (Auth::user()->can('print-patient-cards'))
|
||||
<a href="/patient_card/{{ $patient->id }}" target="_blank" class="btn btn-rounded btn-primary btn-sm float-right">{{ __('patients.print_patient_card') }}</a>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -94,6 +102,7 @@
|
||||
<th><font color="black">{{__('patients.next_of_kin')}}</font></th>
|
||||
<td>{{ $patient->next_of_kin }}</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<th><font color="black">{{ __('patients.next_of_kin_relationship') }}</font></th>
|
||||
<td>{{ get_name($patient->next_of_kin_relationship, 'id', 'name', 'family_relations') }}</td>
|
||||
@@ -102,6 +111,11 @@
|
||||
<th><font color="black">{{__('patients.phone_of_next_of_kin')}}</font></th>
|
||||
<td>{{ $patient->phone_of_next_of_kin }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th><font color="black">Country</font></th>
|
||||
<td>{{ $country->name ?? '' }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
@@ -127,10 +141,46 @@
|
||||
<th><font color="black">{{ __('patients.village') }}</font></th>
|
||||
<td>{{ get_name($patient->village_id, 'id', 'name', 'villages') }}</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<th><font color="black">Referred From</font></th>
|
||||
<td>{{ $patient->referred_from }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th><font color="black">Foreigner / Refugee </font></th>
|
||||
<td>
|
||||
|
||||
@if(!empty($other_patients_info_data))
|
||||
@if ($other_patients_info_data->non_ugandan_foreigner_or_refugee == 1)
|
||||
<span>{{ __('patients.foreigner') }} </span>
|
||||
@elseif ($other_patients_info_data->non_ugandan_foreigner_or_refugee == 2)
|
||||
<span>{{ __('patients.refugee') }} </span>
|
||||
@else
|
||||
<span></span>
|
||||
@endif
|
||||
@else
|
||||
<span></span>
|
||||
@endif
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
@if (isset($other_patients_info_data->non_ugandan_national_id_no))
|
||||
|
||||
<tr>
|
||||
<th class="highlight"> ID Number</th>
|
||||
<td>{{ $other_patients_info_data->non_ugandan_national_id_no ?? '' }}</td>
|
||||
</tr>
|
||||
|
||||
@else
|
||||
<tr>
|
||||
<th class="highlight">National ID</th>
|
||||
<td>{{ $patient->national_id ?? '' }}</td>
|
||||
</tr>
|
||||
|
||||
|
||||
@endif
|
||||
|
||||
|
||||
@php $registration_fields = !empty($patient->registration_fields)? json_decode($patient->registration_fields, true):[]; @endphp
|
||||
@foreach ($registration_fields as $key => $registration_field)
|
||||
@php $keys = explode("_",$key) @endphp
|
||||
|
||||
+22
-24
@@ -74,7 +74,9 @@
|
||||
@foreach($pre_ordered_eye_glasses as $pre_order)
|
||||
<tr id="eye_glass_row{{ $pre_order->id }}" class="eye_glass_remove">
|
||||
<td>
|
||||
@if ($pre_order->total_stock > 0 )
|
||||
<input type="checkbox" id="chk" name="eye_glass_item[]" class="eye_glass_check" value="{{ $pre_order->id }}">
|
||||
@endif
|
||||
</td>
|
||||
<td>
|
||||
@if($pre_order->insurance == 1)
|
||||
@@ -82,6 +84,10 @@
|
||||
@else
|
||||
<span style='color: orange'> {{ $pre_order->name }} </span>
|
||||
@endif
|
||||
<br/>
|
||||
@if ($pre_order->total_stock <= 0)
|
||||
<span class="badge badge-danger">{{ __('point_of_sale.out_of_stock') }}</span>
|
||||
@endif
|
||||
</td>
|
||||
<td>
|
||||
<input type='number' name='eye_glass_quantity[]' style="margin-bottom: 0px;" id="pre_order_quantity_{{$pre_order->id}}" class="form-control compulsory"/>
|
||||
@@ -118,7 +124,7 @@
|
||||
<input type="hidden" name="eye_glass_insurance_status[]" value="{{ $eye_glass_insurance_status }}">
|
||||
<input type="hidden" name="eye_glass_order_ids[]" value="{{ $pre_order->id }}">
|
||||
<td>
|
||||
<input id="pre_order_cost_sum_{{ $pre_order->id }}" class="" type="number" name="eye_glass_subtotal[]"> .UGx
|
||||
<input id="pre_order_cost_sum_{{ $pre_order->id }}" class="form-control compulsory" type="number" name="eye_glass_subtotal[]"> .UGx
|
||||
</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
@@ -275,35 +281,28 @@
|
||||
@php
|
||||
$total_stock = $prescription->pharmacy_stock;
|
||||
@endphp
|
||||
@if ($total_stock > 0 && $allergy_check != 'Allergic')
|
||||
@if ($prescription->total_stock > 0 && $allergy_check != 'Allergic')
|
||||
<input type="checkbox" name="drug_id[]" id="chk" class="prescription-check" value="{{ $prescription->id }}" />
|
||||
@endif
|
||||
</td>
|
||||
|
||||
<!-- drug -->
|
||||
<td style="border: 1px solid #ddd;">
|
||||
@php
|
||||
@php
|
||||
$insurance_color = ($prescription->insurance_coverage == 1 && patient_insurance_status($patient_id) == 1) ? "green" : "orange";
|
||||
@endphp
|
||||
@endphp
|
||||
<span style="color:{{ $insurance_color }}"> {{ $prescription->name }}</span> <br/>
|
||||
@if ($allergy_check == 'Allergic')
|
||||
<span class='allergic'>{{ __('point_of_sale.patient_is_allergic') }}</span>
|
||||
@endif
|
||||
@if ($total_stock <= 0)
|
||||
@if ($prescription->total_stock <= 0)
|
||||
<span class="badge badge-danger">{{ __('point_of_sale.out_of_stock') }}</span>
|
||||
@endif
|
||||
<span style="color:{{ $insurance_color }}"> {{ $prescription->name }}</span>
|
||||
<?php
|
||||
$pharm_comment = trim($prescription->pharmacy_comment);
|
||||
if(isset($prescription->reference_areas)){ $reference_array = explode(",", $prescription->reference_areas); } else { $reference_array = []; }
|
||||
if(isset($prescription->reference_name)){ $reference_name = explode(",", $prescription->reference_name); } else { $reference_name = []; }
|
||||
|
||||
for ($x = 0; $x < count($reference_array); $x++) {
|
||||
?>
|
||||
|
||||
<a style="font-weight:normal;" href="{{ $reference_array[$x] }}" target="blank">{{ $reference_name[$x] }}</a>
|
||||
<br>
|
||||
<?php
|
||||
}
|
||||
if (!empty($pharm_comment)):
|
||||
echo "<div style='padding: 1px; margin: 6px 1px 0px 1px; font-size: smaller' class='alert alert-info span12 margin-none well'>" . $pharm_comment . "</div>";
|
||||
endif;
|
||||
@@ -413,7 +412,7 @@
|
||||
@php
|
||||
$total_stock = $prescription->pharmacy_stock;
|
||||
@endphp
|
||||
@if ($total_stock > 0 && $allergy_check != 'Allergic')
|
||||
@if ($prescription->total_stock > 0 && $allergy_check != 'Allergic')
|
||||
<input type="checkbox" name="drug_id[]" id="chk" class="prescription-check" value="{{ $prescription->id }}" />
|
||||
@endif
|
||||
</td>
|
||||
@@ -421,25 +420,18 @@
|
||||
@php
|
||||
$insurance_color = ($prescription->insurance_coverage == 1 && patient_insurance_status($patient_id) == 1) ? "green" : "orange";
|
||||
@endphp
|
||||
<span style="color:{{ $insurance_color }}"> {{ $prescription->name }}</span> <br/>
|
||||
@if ($allergy_check == 'Allergic')
|
||||
<span class='allergic'>{{ __('point_of_sale.patient_is_allergic') }}</span>
|
||||
@endif
|
||||
@if ($total_stock <= 0)
|
||||
@if ($prescription->total_stock <= 0)
|
||||
<span class="badge badge-danger">{{ __('point_of_sale.out_of_stock') }}</span>
|
||||
@endif
|
||||
<span style="color:{{ $insurance_color }}"> {{ $prescription->name }}</span>
|
||||
<?php
|
||||
$pharm_comment = trim($prescription->pharmacy_comment);
|
||||
if(isset($prescription->reference_areas)){ $reference_array = explode(",", $prescription->reference_areas); } else { $reference_array = []; }
|
||||
if(isset($prescription->reference_name)){ $reference_name = explode(",", $prescription->reference_name); } else { $reference_name = []; }
|
||||
|
||||
for ($x = 0; $x < count($reference_array); $x++) {
|
||||
?>
|
||||
|
||||
<a style="font-weight:normal;" href="{{ $reference_array[$x] }}" target="blank">{{ $reference_name[$x] }}</a>
|
||||
<br>
|
||||
<?php
|
||||
}
|
||||
if (!empty($pharm_comment)):
|
||||
echo "<div style='padding: 1px; margin: 6px 1px 0px 1px; font-size: smaller' class='alert alert-info span12 margin-none well'>" . $pharm_comment . "</div>";
|
||||
endif;
|
||||
@@ -546,7 +538,9 @@
|
||||
@foreach($pre_ordered_sundries as $pre_order)
|
||||
<tr>
|
||||
<td>
|
||||
<input type="checkbox" name="pos_sundry_ids[]" value="{{ $pre_order->id }}" checked>
|
||||
@if ($pre_order->total_stock > 0)
|
||||
<input type="checkbox" name="pos_sundry_ids[]" value="{{ $pre_order->id }}" >
|
||||
@endif
|
||||
</td>
|
||||
<td>
|
||||
@if($pre_order->insurance == 1)
|
||||
@@ -554,6 +548,10 @@
|
||||
@else
|
||||
<span style='color: orange'> {{ $pre_order->name }} </span>
|
||||
@endif
|
||||
<br/>
|
||||
@if ($pre_order->total_stock <= 0)
|
||||
<span class="badge badge-danger">{{ __('point_of_sale.out_of_stock') }}</span>
|
||||
@endif
|
||||
</td>
|
||||
|
||||
@php
|
||||
|
||||
@@ -76,6 +76,7 @@
|
||||
<tr>
|
||||
<th>{{ __('point_of_sale.patient_names') }}</th>
|
||||
<th>{{ __('point_of_sale.items') }}</th>
|
||||
<th>{{ __('point_of_sale.totals') }}</th>
|
||||
<th>{{ __('point_of_sale.record_created_by') }}</th>
|
||||
<th>{{ __('point_of_sale.record_created_on') }}</th>
|
||||
<th></th>
|
||||
@@ -104,6 +105,32 @@
|
||||
@endif
|
||||
</ul>
|
||||
</td>
|
||||
<td>
|
||||
@php
|
||||
$treatments_array = json_decode($record->treatments, true);
|
||||
$sundries_array = json_decode($record->sundries, true);
|
||||
$eye_glasses_array = json_decode($record->eye_glasses, true);
|
||||
$services_array = json_decode($record->services, true);
|
||||
@endphp
|
||||
|
||||
<ul>
|
||||
@if(!is_null($treatments_array))
|
||||
<li>{{ ugandan_shillings(array_sum($treatments_array["subtotal"])) }}</li>
|
||||
@endif
|
||||
|
||||
@if(!is_null($eye_glasses_array))
|
||||
<li>{{ ugandan_shillings(array_sum($eye_glasses_array["subtotal"])) }}</li>
|
||||
@endif
|
||||
|
||||
@if(!is_null($sundries_array))
|
||||
<li>{{ ugandan_shillings(array_sum($sundries_array["subtotal"])) }}</li>
|
||||
@endif
|
||||
|
||||
@if(!is_null($services_array))
|
||||
<li>{{ ugandan_shillings(array_sum($services_array["subtotal"])) }}</li>
|
||||
@endif
|
||||
</ul>
|
||||
</td>
|
||||
<td>{{ get_full_name($record->created_by, 'id', 'first_name', 'last_name', 'users') }}</td>
|
||||
<td>{{ streamline_date_time($record->created_at) }}</td>
|
||||
<td><a href="/point_of_sale/print/{{ $record->id }}" class="btn btn-success btn-sm">{{ __('point_of_sale.print') }}</a></td>
|
||||
|
||||
+23
-23
@@ -176,43 +176,43 @@
|
||||
<div class="col-md-12 mt-5">
|
||||
<h4>{{ __('point_of_sale.select_items') }}</h4>
|
||||
<div class="row">
|
||||
<div class="col-md-2">
|
||||
<div class="col-md-3">
|
||||
<div class="input-group">
|
||||
<span class="input-group-addon bg-success">
|
||||
<input id="manual_drugs" type="checkbox">
|
||||
</span>
|
||||
<span class="input-group-addon bg-success">
|
||||
<input id="manual_drugs" type="checkbox">
|
||||
</span>
|
||||
<label for="manual_drugs" type="text" class="label label-success form-control" aria-label="Text input with checkbox">{{ __('point_of_sale.drugs_with_quantity') }}</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-2">
|
||||
<div class="col-md-3">
|
||||
<div class="input-group">
|
||||
<span class="input-group-addon bg-warning">
|
||||
<input id="automatic_drugs" type="checkbox">
|
||||
</span>
|
||||
<span class="input-group-addon bg-warning">
|
||||
<input id="automatic_drugs" type="checkbox">
|
||||
</span>
|
||||
<label for="automatic_drugs" type="text" class="label label-success form-control" aria-label="Text input with checkbox">{{ __('point_of_sale.drugs_with_prescription') }}</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-2">
|
||||
<div class="col-md-3">
|
||||
<div class="input-group">
|
||||
<span class="input-group-addon bg-primary">
|
||||
<input id="eye_glasses" type="checkbox">
|
||||
</span>
|
||||
<span class="input-group-addon bg-primary">
|
||||
<input id="eye_glasses" type="checkbox">
|
||||
</span>
|
||||
<label for="eye_glasses" type="text" class="label label-success form-control" aria-label="Text input with checkbox">{{ __('point_of_sale.eye_glasses') }}</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-2">
|
||||
<div class="col-md-3 ">
|
||||
<div class="input-group">
|
||||
<span class="input-group-addon bg-danger">
|
||||
<input id="sundries" type="checkbox">
|
||||
</span>
|
||||
<span class="input-group-addon bg-danger">
|
||||
<input id="sundries" type="checkbox">
|
||||
</span>
|
||||
<label for="sundries" type="text" class="label label-success form-control" aria-label="Text input with checkbox">{{ __('point_of_sale.sundries') }}</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-2">
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-3 mt-3">
|
||||
<div class="input-group">
|
||||
<span class="input-group-addon bg-info">
|
||||
<input id="services" type="checkbox">
|
||||
@@ -221,11 +221,11 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-2">
|
||||
<div class="col-md-3 mt-3">
|
||||
<div class="input-group">
|
||||
<span class="input-group-addon bg-danger">
|
||||
<input id="all" type="checkbox">
|
||||
</span>
|
||||
<span class="input-group-addon bg-danger">
|
||||
<input id="all" type="checkbox">
|
||||
</span>
|
||||
<label for="all" type="text" class="label label-success form-control" aria-label="Text input with checkbox">{{ __('point_of_sale.all') }}</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
+4
-38
@@ -47,12 +47,6 @@
|
||||
<td><b>{{ __('patient_finance.patient_category') }}</b></td>
|
||||
<td>{{ get_name($patient->category_id, "id", "name", "patient_categories") }}</td>
|
||||
</tr>
|
||||
<!-- <tr>
|
||||
<td><b>{{ __('point_of_sale.record_date') }}</b></td>
|
||||
<td colspan="2">{{ streamline_date_time_short($receipt_date) }}</td>
|
||||
<td><b>{{ __('point_of_sale.print_date') }}</b></td>
|
||||
<td colspan="2">{{ streamline_date_time_short($receipt_reprint_date) }}</td>
|
||||
</tr>-->
|
||||
</table>
|
||||
|
||||
<table class="table table-bordered">
|
||||
@@ -67,7 +61,7 @@
|
||||
|
||||
@if(isset($service_ids_array) && count($service_ids_array) > 0)
|
||||
<tr>
|
||||
<td colspan="3" class="text-center">Services</td>
|
||||
<td colspan="3" class="text-center">Services ({{ __('patient_finance.pos_order_number') }} #{{ $service_number }})</td>
|
||||
</tr>
|
||||
@for($i = 0; $i < count($service_ids_array); $i++)
|
||||
<tr>
|
||||
@@ -81,7 +75,7 @@
|
||||
|
||||
@if(isset($eye_glasses_ids_array) && count($eye_glasses_ids_array) > 0)
|
||||
<tr>
|
||||
<td colspan="3" class="text-center">Eye Glasses</td>
|
||||
<td colspan="3" class="text-center">Eye Glasses ({{ __('patient_finance.pos_order_number') }} #{{ $eye_glasses_number }})</td>
|
||||
</tr>
|
||||
@for($i = 0; $i < count($eye_glasses_ids_array); $i++)
|
||||
<tr>
|
||||
@@ -93,37 +87,9 @@
|
||||
@endfor
|
||||
@endif
|
||||
|
||||
@if(isset($procedure_ids_array) && count($procedure_ids_array) > 0)
|
||||
<tr>
|
||||
<td colspan="3" class="text-center">Procedures</td>
|
||||
</tr>
|
||||
@for($i = 0; $i < count($procedure_ids_array); $i++)
|
||||
<tr>
|
||||
<td>{{ get_name($procedure_ids_array[$i], "id", "name", "procedures") }}</td>
|
||||
<td>N/A</td>
|
||||
<td>{{ ugandan_shillings($procedure_amounts_array[$i]) }}</td>
|
||||
</tr>
|
||||
@php $total_to_pay += $procedure_amounts_array[$i]; @endphp
|
||||
@endfor
|
||||
@endif
|
||||
|
||||
@if(isset($investigation_ids_array) && count($investigation_ids_array) > 0)
|
||||
<tr>
|
||||
<td colspan="3" class="text-center">Investigations</td>
|
||||
</tr>
|
||||
@for($i = 0; $i < count($investigation_ids_array); $i++)
|
||||
<tr>
|
||||
<td>{{ get_name($investigation_ids_array[$i], "id", "name", "investigations") }}</td>
|
||||
<td>N/A</td>
|
||||
<td>{{ ugandan_shillings($investigation_amounts_array[$i]) }}</td>
|
||||
</tr>
|
||||
@php $total_to_pay += $investigation_amounts_array[$i]; @endphp
|
||||
@endfor
|
||||
@endif
|
||||
|
||||
@if(isset($treatment_item) && count($treatment_item) > 0)
|
||||
<tr>
|
||||
<td colspan="3" class="text-center">Treatments</td>
|
||||
<td colspan="3" class="text-center">Treatments ({{ __('patient_finance.pos_order_number') }} #{{ $treatment_number }})</td>
|
||||
</tr>
|
||||
@for($i = 0; $i < count($treatment_item); $i++)
|
||||
<tr>
|
||||
@@ -137,7 +103,7 @@
|
||||
|
||||
@if(isset($sundry_item) && count($sundry_item) > 0)
|
||||
<tr>
|
||||
<td colspan="3" class="text-center">Sundries</td>
|
||||
<td colspan="3" class="text-center">Sundries ({{ __('patient_finance.pos_order_number') }} #{{ $sundry_number }})</td>
|
||||
</tr>
|
||||
@for($i = 0; $i < count($sundry_item); $i++)
|
||||
<tr>
|
||||
|
||||
+8
-37
@@ -63,13 +63,12 @@
|
||||
<span style="font-weight: bolder; text-decoration: underline; display: block; font-family: monospace">{{ $hospital_information->address }}</span>
|
||||
<span class="receipt-label"><b>{{ __('patient_finance.tel') }}:</b> {{ $hospital_information->phone_number }}</span><br>
|
||||
<span class="receipt-label"><b>{{ __('patient_finance.email') }}:</b> {{ $hospital_information->email }}</span><br>
|
||||
<span class="receipt-label"><b>{{ __('patient_finance.cashier') }}:</b> {{ get_full_name($cashier, 'id', 'first_name', 'last_name', 'users') }}</span><br>
|
||||
<span class="receipt-label"><b>{{ __('patient_finance.printed_by') }}:</b> {{ get_full_name($first_printed_by, 'id', 'first_name', 'last_name', 'users') }}</span><br>
|
||||
<span class="receipt-label"><b>{{ __('patient_finance.original_print_date') }}:</b> {{ streamline_date_time_short($receipt_date) }}</span><br>
|
||||
<span class="receipt-label"><b>{{ __('patient_finance.reprint_date') }}:</b> {{ streamline_date_time_short(date('Y-m-d H:i:s')) }}</span><br>
|
||||
<span class="receipt-label"><b>{{ __('patient_finance.receipt_number') }}:</b> {{ $receipt_number }}</span><br>
|
||||
<span class="receipt-label"><b>{{ __('patient_finance.patient_name') }}</b> : {{ $patient->first_name }} {{ $patient->last_name }}</span><br>
|
||||
<span class="receipt-label"><b>{{ __('patient_finance.patient_number') }}</b> : {{ $patient->number }} </span><br>
|
||||
<span class="receipt-label"><b>{{ __('patient_finance.category') }} :</b> {{ get_name($patient->category_id, "id", "name", "patient_categories") }}</span>
|
||||
<span class="receipt-label"><b>{{ __('patient_finance.patient_category') }} :</b> {{ get_name($patient->category_id, "id", "name", "patient_categories") }}</span>
|
||||
</p>
|
||||
|
||||
<div>
|
||||
@@ -85,7 +84,7 @@
|
||||
|
||||
@if(isset($service_ids_array) && count($service_ids_array) > 0)
|
||||
<tr>
|
||||
<td colspan="3" class="text-center">Services</td>
|
||||
<td colspan="3" class="text-center">Services ({{ __('patient_finance.pos_order_number') }} #{{ $service_number }})</td>
|
||||
</tr>
|
||||
@for($i = 0; $i < count($service_ids_array); $i++)
|
||||
<tr>
|
||||
@@ -99,49 +98,21 @@
|
||||
|
||||
@if(isset($eye_glasses_ids_array) && count($eye_glasses_ids_array) > 0)
|
||||
<tr>
|
||||
<td colspan="3" class="text-center">Eye Glasses</td>
|
||||
<td colspan="3" class="text-center">Eye Glasses ({{ __('patient_finance.pos_order_number') }} #{{ $eye_glasses_number }})</td>
|
||||
</tr>
|
||||
@for($i = 0; $i < count($eye_glasses_ids_array); $i++)
|
||||
<tr>
|
||||
<td>{{ get_name($eye_glasses_ids_array[$i], "id", "name", "eye_glasses") }}</td>
|
||||
<td>{{ $eye_glasses_quantity_array[$i] }}</td>
|
||||
<td>{{ ugandan_shillings($eye_glasses_prices_array[$i] * $eye_glasses_quantity_array[$i]) }}</td>
|
||||
<td>{{ ugandan_shillings($eye_glasses_prices_array[$i] ) }}</td>
|
||||
</tr>
|
||||
@php $total_to_pay += $eye_glasses_prices_array[$i] * $eye_glasses_quantity_array[$i]; @endphp
|
||||
@endfor
|
||||
@endif
|
||||
|
||||
@if(isset($procedure_ids_array) && count($procedure_ids_array) > 0)
|
||||
<tr>
|
||||
<td colspan="3" class="text-center">Procedures</td>
|
||||
</tr>
|
||||
@for($i = 0; $i < count($procedure_ids_array); $i++)
|
||||
<tr>
|
||||
<td>{{ get_name($procedure_ids_array[$i], "id", "name", "procedures") }}</td>
|
||||
<td>N/A</td>
|
||||
<td>{{ ugandan_shillings($procedure_amounts_array[$i]) }}</td>
|
||||
</tr>
|
||||
@php $total_to_pay += $procedure_amounts_array[$i]; @endphp
|
||||
@endfor
|
||||
@endif
|
||||
|
||||
@if(isset($investigation_ids_array) && count($investigation_ids_array) > 0)
|
||||
<tr>
|
||||
<td colspan="3" class="text-center">Investigations</td>
|
||||
</tr>
|
||||
@for($i = 0; $i < count($investigation_ids_array); $i++)
|
||||
<tr>
|
||||
<td>{{ get_name($investigation_ids_array[$i], "id", "name", "investigations") }}</td>
|
||||
<td>N/A</td>
|
||||
<td>{{ ugandan_shillings($investigation_amounts_array[$i]) }}</td>
|
||||
</tr>
|
||||
@php $total_to_pay += $investigation_amounts_array[$i]; @endphp
|
||||
@php $total_to_pay += $eye_glasses_prices_array[$i]; @endphp
|
||||
@endfor
|
||||
@endif
|
||||
|
||||
@if(isset($treatment_item) && count($treatment_item) > 0)
|
||||
<tr>
|
||||
<td colspan="3" class="text-center">Treatments</td>
|
||||
<td colspan="3" class="text-center">Treatments ({{ __('patient_finance.pos_order_number') }} #{{ $treatment_number }})</td>
|
||||
</tr>
|
||||
@for($i = 0; $i < count($treatment_item); $i++)
|
||||
<tr>
|
||||
@@ -155,7 +126,7 @@
|
||||
|
||||
@if(isset($sundry_item) && count($sundry_item) > 0)
|
||||
<tr>
|
||||
<td colspan="3" class="text-center">Sundries</td>
|
||||
<td colspan="3" class="text-center">Sundries ({{ __('patient_finance.pos_order_number') }} #{{ $sundry_number }})</td>
|
||||
</tr>
|
||||
@for($i = 0; $i < count($sundry_item); $i++)
|
||||
<tr>
|
||||
|
||||
@@ -121,9 +121,6 @@
|
||||
@endif
|
||||
|
||||
@if (is_hiv_and_gbv_screening_tool_enabled())
|
||||
<script>
|
||||
alert('Please have this disabled');
|
||||
</script>
|
||||
@include('patients::triage.hiv_gbv_screening')
|
||||
@endif
|
||||
|
||||
@@ -269,7 +266,7 @@
|
||||
<td colspan="2">
|
||||
{{ Form::label('child_with_proven_infection', 'Does the child have a proven or suspected infection e.g is the child having fever, cough, diarrhoea?') }}
|
||||
</td>
|
||||
<td>{{ Form::radio('child_with_proven_infection', 0, false, ['onclick' => 'show_proven_infection_questions()']) }}
|
||||
<td>{{ Form::radio('child_with_proven_infection', 1, false, ['onclick' => 'show_proven_infection_questions()']) }}
|
||||
Yes</td>
|
||||
<td>{{ Form::radio('child_with_proven_infection', 0, false, ['onclick' => 'hide_proven_infection_questions()']) }}
|
||||
No</td>
|
||||
|
||||
@@ -76,10 +76,7 @@
|
||||
<table class="table table-hover color-table success-table table-bordered" id="symptom_table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="text-center">{{ __('triage.symptoms') }} <a data-toggle="modal"
|
||||
data-target="#symptomsmodal"
|
||||
class="label labelRight label-info pull-right">{{ __('triage.add_new') }}</a>
|
||||
</th>
|
||||
<th class="text-center">{{ __('triage.symptoms') }} <a data-toggle="modal" data-target="#symptomsmodal" class="label labelRight label-info pull-right">{{ __('triage.add_new') }}</a></th>
|
||||
<th class="text-center">{{ __('triage.duration') }}</th>
|
||||
<th class="text-center">{{ __('triage.prompt') }}</th>
|
||||
<th class="text-center">{{ __('triage.reference_text') }}</th>
|
||||
@@ -87,13 +84,13 @@
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody class='symptoms_input_fields_wrap'>
|
||||
@php
|
||||
$symptoms_array = explode(',', $triage->symptoms);
|
||||
$symptoms_duration_array = explode(',', $triage->symptom_duration);
|
||||
@php
|
||||
$symptoms_array = explode(",", $triage->symptoms);
|
||||
$symptoms_duration_array = explode(",", $triage->symptom_duration);
|
||||
|
||||
foreach ($symptoms as $key => $value) {
|
||||
$option_symptoms .= "<option value='$key'>" . str_replace('"', '', $value) . '</option>';
|
||||
}
|
||||
foreach ($symptoms as $key => $value){
|
||||
$option_symptoms .= "<option value='$key'>" . str_replace('"', "", $value) . "</option>";
|
||||
}
|
||||
|
||||
foreach ($symptoms_periods as $key => $value){
|
||||
$option_symptoms_periods .= "<option value='$key'>$value</option>";
|
||||
@@ -124,79 +121,41 @@
|
||||
$duration_array = explode(" ", $symptoms_duration_array[$i]);
|
||||
@endphp
|
||||
<tr>
|
||||
<td style='width: 20%;'>
|
||||
<select name='symptoms[]' id='symptoms_0'
|
||||
class='form-control col-sm-12 compulsory'
|
||||
onchange='showPrompt(this.value, 0)' required>@php echo $option_symptoms; @endphp</select>
|
||||
<td style="width: 20%;">
|
||||
{{ Form::select('symptoms[]', $symptoms, $symptoms_array[$i], ['id' => 'symptoms_' . $i, 'class' => 'form-control col-sm-12 compulsory initial_symptoms_select', 'onchange' => 'showPrompt(this.value, ' . $i . ')']) }}
|
||||
</td>
|
||||
<td style='width: 21%'>
|
||||
<div class='row'>
|
||||
<div class='col-sm-3'>
|
||||
<input type='text' style='display: block;' name='duration[]'
|
||||
id='symptoms_duration_0' class='col-sm-12 form-control h-100'>
|
||||
<td style="width: 21%">
|
||||
<div class="row">
|
||||
<div class="col-sm-3">
|
||||
<input type="text" style="display: block;" name="duration[]" id="duration[]" class="col-sm-12 form-control" value="{{ $duration_array[0] }}">
|
||||
</div>
|
||||
<div class='col-sm-9'>
|
||||
<select style='display: inline-block;' name='time[]'
|
||||
id='symptoms_time_0'
|
||||
class='col-sm-12 form-control select2-hidden-accessible'>@php echo $option_symptoms_periods; @endphp</select>
|
||||
<div class="col-sm-9">
|
||||
<select style="display: inline-block;" name="time[]" id="time[]" class="col-sm-12 form-control">
|
||||
<option value="{{ $duration_array[1] }}" selected>{{ $duration_array[1] }}</option>
|
||||
<option value="<?php echo __('triage.hours') ?>">{{ __('triage.hours') }}</option>
|
||||
<option value="<?php echo __('triage.days') ?>">{{ __('triage.days') }}</option>
|
||||
<option value="<?php echo __('triage.weeks') ?>">{{ __('triage.weeks') }}</option>
|
||||
<option value="<?php echo __('triage.months') ?>">{{ __('triage.months') }}</option>
|
||||
<option value="<?php echo __('triage.years') ?>">{{ __('triage.years') }}</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</td>
|
||||
<td id='symptoms_prompt_0' style='width: 30%'></td>
|
||||
<td id='symptoms_reference_0'></td>
|
||||
<td style='width: 1%;'></td>
|
||||
<td id="symptoms_prompt_{{ $i }}" style="width: 30%"></td>
|
||||
<td id="symptoms_reference_{{ $i }}"></td>
|
||||
<td style="width: 1%;"></td>
|
||||
</tr>
|
||||
@else
|
||||
@for ($i = 0; $i < count($symptoms_array); $i++)
|
||||
@php
|
||||
$duration_array = explode(' ', $symptoms_duration_array[$i]);
|
||||
@endphp
|
||||
<tr>
|
||||
<td style="width: 20%;">
|
||||
{{ Form::select('symptoms[]', $symptoms, $symptoms_array[$i], ['id' => 'symptoms_' . $i, 'class' => 'form-control col-sm-12 compulsory initial_symptoms_select', 'onchange' => 'showPrompt(this.value, ' . $i . ')']) }}
|
||||
</td>
|
||||
<td style="width: 21%">
|
||||
<div class="row m-0 d-flex justify-content-between align-items-stretch">
|
||||
<div class="col-sm-3 p-0">
|
||||
<input type="text" style="display: block;" name="duration[]"
|
||||
id="duration[]" class="col-sm-12 form-control h-100"
|
||||
value="{{ $duration_array[0] }}">
|
||||
</div>
|
||||
<div class="col-sm-9 p-0">
|
||||
<select style="display: inline-block;" name="time[]" id="time[]"
|
||||
class="w-100 form-control select-2 h-100">
|
||||
<option value="{{ $duration_array[1] }}" selected>
|
||||
{{ $duration_array[1] }}</option>
|
||||
<option value="<?php echo __('triage.hours'); ?>">{{ __('triage.hours') }}
|
||||
</option>
|
||||
<option value="<?php echo __('triage.days'); ?>">{{ __('triage.days') }}
|
||||
</option>
|
||||
<option value="<?php echo __('triage.weeks'); ?>">{{ __('triage.weeks') }}
|
||||
</option>
|
||||
<option value="<?php echo __('triage.months'); ?>">{{ __('triage.months') }}
|
||||
</option>
|
||||
<option value="<?php echo __('triage.years'); ?>">{{ __('triage.years') }}
|
||||
</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</td>
|
||||
<td id="symptoms_prompt_{{ $i }}" style="width: 30%"></td>
|
||||
<td id="symptoms_reference_{{ $i }}"></td>
|
||||
<td style="width: 1%;"></td>
|
||||
</tr>
|
||||
@endfor
|
||||
@endif
|
||||
@endfor
|
||||
@endif
|
||||
</tbody>
|
||||
</table>
|
||||
<a class="btn btn-success btn-xs" onclick="add_symptom_row()"
|
||||
id="add_row">{{ __('triage.add_row') }}</a>
|
||||
<a class="btn btn-success btn-xs" onclick="add_symptom_row()" id="add_row">{{ __('triage.add_row') }}</a>
|
||||
<hr>
|
||||
</div>
|
||||
@endif
|
||||
|
||||
@if (is_tuberculosis_screening_enabled())
|
||||
@include('patients::triage.edit.edit_tb_screening')
|
||||
@include('patients::triage.edit_tb_screening')
|
||||
@endif
|
||||
|
||||
@if (is_hiv_screening_tool_enabled())
|
||||
|
||||
+296
@@ -0,0 +1,296 @@
|
||||
<div class="row m-0 py-4 px-2" style="border: 1px solid #e4e7ea; margin: 5px">
|
||||
<div class="col-sm-12">
|
||||
<strong>INTENSIFIED TB CASE FINDING SCREEN: ({{ $age_group_display }})</strong>
|
||||
</div>
|
||||
<hr>
|
||||
<div class="col-sm-12">
|
||||
DOES THE PATIENT HAVE ANY OF THE FOLLOWING:
|
||||
<input type="radio" name='any_tb_sysmptoms' id='tb_questions_yes' class="cough_class" value="1" @if(isset($triage->any_tb_sysmptoms) && $triage->any_tb_sysmptoms == 1) checked @endif> Yes
|
||||
<input type="radio" name='any_tb_sysmptoms' id='tb_questions_no' class="cough_class" value="0" @if(isset($triage->any_tb_sysmptoms) && $triage->any_tb_sysmptoms == 0) checked @endif> No
|
||||
@if ($age_group == 5 || $age_group_display == '> 12 Years')
|
||||
{{-- adults i.e above 12 years --}}
|
||||
<ol>
|
||||
<li>
|
||||
A cough for more than two weeks ?
|
||||
</li>
|
||||
<li>
|
||||
Persistent fevers for 2 weeks or more ?
|
||||
</li>
|
||||
<li>
|
||||
Noticeable weight loss of more than 3kg ?
|
||||
</li>
|
||||
<li>
|
||||
Excessive night sweats for three weeks or more ?
|
||||
</li>
|
||||
</ol>
|
||||
@elseif($age_group == 4 || $age_group_display == '6 - 12 Years')
|
||||
{{-- between 6-12 years --}}
|
||||
<ol>
|
||||
<li>
|
||||
A cough for more than two weeks ?
|
||||
</li>
|
||||
<li>
|
||||
Persistent fevers for 2 weeks or more ?
|
||||
</li>
|
||||
<li>
|
||||
Noticeable weight loss ?
|
||||
</li>
|
||||
<li>
|
||||
Excessive night sweats for three weeks or more ?
|
||||
</li>
|
||||
</ol>
|
||||
@elseif(
|
||||
$age_group == 3 ||
|
||||
$age_group == 2 ||
|
||||
$age_group == 1 ||
|
||||
$age_group_display == '1 - 12 Months' ||
|
||||
$age_group_display == '0 - 28 Days')
|
||||
{{-- children below 5 years --}}
|
||||
<ol>
|
||||
<li>
|
||||
A cough for more than two weeks ?
|
||||
</li>
|
||||
<li>
|
||||
Persistent fevers for 2 weeks or more ?
|
||||
</li>
|
||||
<li>
|
||||
Noticeable weight loss ?
|
||||
</li>
|
||||
<li>
|
||||
Poor weight gain in the last one month ?
|
||||
<br>
|
||||
<span style="color: red">
|
||||
(weight loss or “very low weight” = where weight for age is less than -3 z-score, or
|
||||
“underweight” =
|
||||
weight for age less than -2 z-score, or “confirmed weight loss”= more than 5% since last visit,
|
||||
or “growth
|
||||
curve flattening”).
|
||||
</span>
|
||||
</li>
|
||||
<li>
|
||||
Contact with a person with pulmonary tuberculosis or chronic cough ?
|
||||
</li>
|
||||
</ol>
|
||||
@endif
|
||||
|
||||
<br>
|
||||
<table class="tb_questions_table table table-bordered" style="display: none; background-color: #f3f3f5;">
|
||||
@if ($age_group == 5 || $age_group_display == '> 12 Years')
|
||||
<tr class="cough_tb_question">
|
||||
<td>A cough for more than two weeks ?</td>
|
||||
<td>
|
||||
<input type="radio" name='cough_for_2_weeks' id='cough_for_2_weeks_yes' class="tb_screening_radios" value="1" @if(isset($triage->cough_for_2_weeks) && $triage->cough_for_2_weeks == 1) checked @endif> Yes
|
||||
<input type="radio" name='cough_for_2_weeks' id='cough_for_2_weeks_no' class="tb_screening_radios" value="0" @if(isset($triage->cough_for_2_weeks) && $triage->cough_for_2_weeks == 0) checked @endif> No
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="fever_tb_question">
|
||||
<td>Persistent fevers for 2 weeks or more ?</td>
|
||||
<td>
|
||||
<input type="radio" name='fever_for_2_weeks' id='fever_for_2_weeks_yes' class="tb_screening_radios" value="1" @if(isset($triage->fever_for_2_weeks) && $triage->fever_for_2_weeks == 1) checked @endif> Yes
|
||||
<input type="radio" name='fever_for_2_weeks' id='fever_for_2_weeks_no' class="tb_screening_radios" value="0" @if(isset($triage->fever_for_2_weeks) && $triage->fever_for_2_weeks == 0) checked @endif> No
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="weight_loss_tb_question">
|
||||
<td>Noticeable weight loss of more than 3 Kg?</td>
|
||||
<td>
|
||||
<input type="radio" name='tb_weight_loss' id='tb_weight_loss_yes' class="tb_screening_radios" value="1" @if(isset($triage->tb_weight_loss) && $triage->tb_weight_loss == 1) checked @endif> Yes
|
||||
<input type="radio" name='tb_weight_loss' id='tb_weight_loss_no' class="tb_screening_radios" value="0" @if(isset($triage->tb_weight_loss) && $triage->tb_weight_loss == 0) checked @endif> No
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="excessive_night_sweats_tb_question">
|
||||
<td>Excessive night sweats for three weeks or more ?</td>
|
||||
<td>
|
||||
<input type="radio" name='tb_excessive_night_sweats' id='tb_excessive_night_sweats_yes' class="tb_screening_radios" value="1" @if(isset($triage->tb_excessive_night_sweats) && $triage->tb_excessive_night_sweats == 1) checked @endif> Yes
|
||||
<input type="radio" name='tb_excessive_night_sweats' id='tb_excessive_night_sweats_no' class="tb_screening_radios" value="0" @if(isset($triage->tb_excessive_night_sweats) && $triage->tb_excessive_night_sweats == 0) checked @endif> No
|
||||
</td>
|
||||
</tr>
|
||||
@elseif ($age_group == 4 || $age_group_display == '6 - 12 Years')
|
||||
<tr class="cough_tb_question">
|
||||
<td>A cough for more than two weeks ?</td>
|
||||
<td>
|
||||
<input type="radio" name='cough_for_2_weeks' id='cough_for_2_weeks_yes' class="tb_screening_radios" value="1" @if(isset($triage->cough_for_2_weeks) && $triage->cough_for_2_weeks == 1) checked @endif> Yes
|
||||
<input type="radio" name='cough_for_2_weeks' id='cough_for_2_weeks_no' class="tb_screening_radios" value="0" @if(isset($triage->cough_for_2_weeks) && $triage->cough_for_2_weeks == 0) checked @endif> No
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="fever_tb_question">
|
||||
<td>Persistent fevers for 2 weeks or more ?</td>
|
||||
<td>
|
||||
<input type="radio" name='fever_for_2_weeks' id='fever_for_2_weeks_yes' class="tb_screening_radios" value="1" @if(isset($triage->fever_for_2_weeks) && $triage->fever_for_2_weeks == 1) checked @endif> Yes
|
||||
<input type="radio" name='fever_for_2_weeks' id='fever_for_2_weeks_no' class="tb_screening_radios" value="0" @if(isset($triage->fever_for_2_weeks) && $triage->fever_for_2_weeks == 0) checked @endif> No
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="weight_loss_tb_question">
|
||||
<td>Noticeable weight loss ?</td>
|
||||
<td>
|
||||
<input type="radio" name='tb_weight_loss' id='tb_weight_loss_yes' class="tb_screening_radios" value="1" @if(isset($triage->tb_weight_loss) && $triage->tb_weight_loss == 1) checked @endif> Yes
|
||||
<input type="radio" name='tb_weight_loss' id='tb_weight_loss_no' class="tb_screening_radios" value="0" @if(isset($triage->tb_weight_loss) && $triage->tb_weight_loss == 0) checked @endif> No
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="excessive_night_sweats_tb_question">
|
||||
<td>Excessive night sweats for three weeks or more ?</td>
|
||||
<td>
|
||||
<input type="radio" name='tb_excessive_night_sweats' id='tb_excessive_night_sweats_yes' class="tb_screening_radios" value="1" @if(isset($triage->tb_excessive_night_sweats) && $triage->tb_excessive_night_sweats == 1) checked @endif> Yes
|
||||
<input type="radio" name='tb_excessive_night_sweats' id='tb_excessive_night_sweats_no' class="tb_screening_radios" value="0" @if(isset($triage->tb_excessive_night_sweats) && $triage->tb_excessive_night_sweats == 0) checked @endif> No
|
||||
</td>
|
||||
</tr>
|
||||
@elseif(
|
||||
$age_group == 3 ||
|
||||
$age_group == 2 ||
|
||||
$age_group == 1 ||
|
||||
$age_group_display == '1 - 12 Months' ||
|
||||
$age_group_display == '0 - 28 Days')
|
||||
{{-- children below 5 years --}}
|
||||
<tr class="cough_tb_question">
|
||||
<td>A cough for more than two weeks ?</td>
|
||||
<td>
|
||||
<input type="radio" name='cough_for_2_weeks' id='cough_for_2_weeks_yes' class="tb_screening_radios" value="1" @if(isset($triage->cough_for_2_weeks) && $triage->cough_for_2_weeks == 1) checked @endif> Yes
|
||||
<input type="radio" name='cough_for_2_weeks' id='cough_for_2_weeks_no' class="tb_screening_radios" value="0" @if(isset($triage->cough_for_2_weeks) && $triage->cough_for_2_weeks == 0) checked @endif> No
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="fever_tb_question">
|
||||
<td>Persistent fevers for 2 weeks or more ?</td>
|
||||
<td>
|
||||
<input type="radio" name='fever_for_2_weeks' id='fever_for_2_weeks_yes' class="tb_screening_radios" value="1" @if(isset($triage->fever_for_2_weeks) && $triage->fever_for_2_weeks == 1) checked @endif> Yes
|
||||
<input type="radio" name='fever_for_2_weeks' id='fever_for_2_weeks_no' class="tb_screening_radios" value="0" @if(isset($triage->fever_for_2_weeks) && $triage->fever_for_2_weeks == 0) checked @endif> No
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="weight_loss_tb_question">
|
||||
<td>Noticeable weight loss ?</td>
|
||||
<td>
|
||||
<input type="radio" name='tb_weight_loss' id='tb_weight_loss_yes' class="tb_screening_radios" value="1" @if(isset($triage->tb_weight_loss) && $triage->tb_weight_loss == 1) checked @endif> Yes
|
||||
<input type="radio" name='tb_weight_loss' id='tb_weight_loss_no' class="tb_screening_radios" value="0" @if(isset($triage->tb_weight_loss) && $triage->tb_weight_loss == 0) checked @endif> No
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="poor_weight_gain_tb_question">
|
||||
<td>Poor weight gain in the last one month ?
|
||||
<br>
|
||||
<span style="color: red">
|
||||
(weight loss or “very low weight” = where weight for age is<br> less than -3 z-score, or
|
||||
“underweight” = weight for age less than<br> -2 z-score, or “confirmed weight loss”= more
|
||||
than 5% since last visit, or “growth curve flattening”).
|
||||
</span>
|
||||
</td>
|
||||
<td>
|
||||
<input type="radio" name='tb_poor_weight_gain' id='tb_poor_weight_gain_yes' class="tb_screening_radios" value="1" @if(isset($triage->tb_poor_weight_gain) && $triage->tb_poor_weight_gain == 1) checked @endif> Yes
|
||||
<input type="radio" name='tb_poor_weight_gain' id='tb_poor_weight_gain_no' class="tb_screening_radios" value="0" @if(isset($triage->tb_poor_weight_gain) && $triage->tb_poor_weight_gain == 0) checked @endif> No
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="contact_with_tb_person_with_tb_question">
|
||||
<td>Contact with a person with pulmonary TB or chronic cough ?</td>
|
||||
<td>
|
||||
<input type="radio" name='tb_contact_with_tb_person' id='tb_contact_with_tb_person_yes' class="tb_screening_radios" value="1" @if(isset($triage->tb_contact_with_tb_person) && $triage->tb_contact_with_tb_person == 1) checked @endif> Yes
|
||||
<input type="radio" name='tb_contact_with_tb_person' id='tb_contact_with_tb_person_no' class="tb_screening_radios" value="0" @if(isset($triage->tb_contact_with_tb_person) && $triage->tb_contact_with_tb_person == 0) checked @endif> No
|
||||
</td>
|
||||
</tr>
|
||||
@endif
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<br>
|
||||
|
||||
<div class="modal fade" id="TBActionModal" tabindex="-1" role="dialog" aria-labelledby="modalTBActionLabel1"
|
||||
style="margin-top: 20%">
|
||||
<div class="modal-dialog modal-dialog-centered" role="document">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span
|
||||
aria-hidden="true">×</span></button>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<h4 class="modal-title"><u>ACTION NEEDED: <font color=red>Possible TB</font></u></h4><br>
|
||||
<div class="possible_tb_action_for_coughing" style="display:none; font: bolder">
|
||||
@if ($age_group == 5 || $age_group_display == '> 12 Years')
|
||||
<ol>
|
||||
<li>REQUEST FOR SPUTUM TEST</li>
|
||||
<li>REFER TO CLINICIAN FOR FURTHER INVESTIGATIONS</li>
|
||||
<li style="color: red">DIRECT THE PATIENT TO DESIGNATED AREA FOR PEOPLE WITH CHRONIC COUGH
|
||||
AWAY FROM THE MAIN QUEUE TO REDUCE THE RISK OF CROSS-INFECTION</li>
|
||||
</ol>
|
||||
@elseif ($age_group == 4 || $age_group_display == '6 - 12 Years')
|
||||
<ol>
|
||||
<li>REQUEST FOR SPUTUM TEST if child can manage</li>
|
||||
<li>REFER TO CLINICIAN FOR FURTHER INVESTIGATIONS</li>
|
||||
<li style="color: red">DIRECT THE PATIENT TO DESIGNATED AREA FOR PEOPLE WITH CHRONIC COUGH
|
||||
AWAY FROM THE MAIN QUEUE TO REDUCE THE RISK OF CROSS-INFECTION</li>
|
||||
</ol>
|
||||
@elseif(
|
||||
$age_group == 3 ||
|
||||
$age_group == 2 ||
|
||||
$age_group == 1 ||
|
||||
$age_group_display == '1 - 12 Months' ||
|
||||
$age_group_display == '0 - 28 Days')
|
||||
{{-- children below 5 years --}}
|
||||
<ol>
|
||||
<li>REFER TO CLINICIAN FOR FURTHER INVESTIGATIONS</li>
|
||||
<li style="color: red">DIRECT THE PATIENT TO DESIGNATED AREA FOR PEOPLE WITH CHRONIC COUGH
|
||||
AWAY FROM THE MAIN QUEUE TO REDUCE THE RISK OF CROSS-INFECTION</li>
|
||||
</ol>
|
||||
@endif
|
||||
</div>
|
||||
<div class="possible_tb_action_for_non_coughing" style="display:none; font: bolder">
|
||||
@if ($age_group == 5 || $age_group == 4 || $age_group_display == '6 - 12 Years' || $age_group_display == '> 12 Years')
|
||||
<ol>
|
||||
<li>REFER TO CLINICIAN FOR FURTHER INVESTIGATIONS</li>
|
||||
</ol>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default btn-sm" data-dismiss="modal">Close</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@push('scripts')
|
||||
<script>
|
||||
$("#tb_questions_no").change(function() {
|
||||
$(".tb_questions_table").hide();
|
||||
$(".tb_screening_radios").removeAttr("required");
|
||||
console.log('no tb screening');
|
||||
console.log($("#tb_questions_yes").is(':checked'));
|
||||
})
|
||||
|
||||
$("#tb_questions_yes").change(function() {
|
||||
$(".tb_questions_table").show();
|
||||
$(".tb_screening_radios").attr('required', 'true');
|
||||
console.log('yes tb screening');
|
||||
console.log($("#tb_questions_yes").is(':checked'));
|
||||
})
|
||||
|
||||
$('input[name="cough_for_2_weeks"]').change(function() {
|
||||
if ($("#cough_for_2_weeks_yes").is(':checked')) {
|
||||
//$("#TBActionModal").modal("show");
|
||||
$(".possible_tb_action_for_coughing").show();
|
||||
$(".possible_tb_action_for_non_coughing").hide();
|
||||
}
|
||||
})
|
||||
|
||||
$('input[name="fever_for_2_weeks"]').change(function() {
|
||||
if ($("#cough_for_2_weeks_yes").is(":not(:checked)") && $("#fever_for_2_weeks_yes").is(':checked')) {
|
||||
//$("#TBActionModal").modal("show");
|
||||
$(".possible_tb_action_for_coughing").hide();
|
||||
$(".possible_tb_action_for_non_coughing").show();
|
||||
}
|
||||
})
|
||||
|
||||
$('input[name="tb_weight_loss"]').change(function() {
|
||||
var ageGroup = <?php echo $age_group; ?>;
|
||||
console.log(ageGroup);
|
||||
if ($("#cough_for_2_weeks_yes").is(":not(:checked)") && $("#tb_weight_loss_yes").is(':checked')) {
|
||||
//$("#TBActionModal").modal("show");
|
||||
$(".possible_tb_action_for_coughing").hide();
|
||||
$(".possible_tb_action_for_non_coughing").show();
|
||||
}
|
||||
})
|
||||
|
||||
$('input[name="tb_excessive_night_sweats"]').change(function() {
|
||||
if ($("#cough_for_2_weeks_yes").is(":not(:checked)") && $("#tb_excessive_night_sweats_yes").is(
|
||||
':checked')) {
|
||||
//$("#TBActionModal").modal("show");
|
||||
$(".possible_tb_action_for_coughing").hide();
|
||||
$(".possible_tb_action_for_non_coughing").show();
|
||||
}
|
||||
})
|
||||
</script>
|
||||
@endpush
|
||||
Reference in New Issue
Block a user