mirror of
https://gitlab.com/signalytic/client-external/streamline/streamline-emr.git
synced 2026-09-11 18:51:31 +00:00
resolved conflicts
This commit is contained in:
+115
@@ -0,0 +1,115 @@
|
||||
@extends('layouts.main')
|
||||
|
||||
@push('styles')
|
||||
<link href="{{ asset('elite/bower_components/select2/select2.min.css') }}" rel="stylesheet" />
|
||||
@endpush
|
||||
|
||||
@section('content')
|
||||
<div class="row bg-title">
|
||||
<div class="col-md-6">
|
||||
<h4 class="page-title">Select Patient and Episode</h4>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<ol class="breadcrumb">
|
||||
<li><a href="{{ route('home') }}">Dashboard</a></li>
|
||||
<li class="active">Patient Timeline</li>
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="white-box">
|
||||
{{ Form::open(['route' => 'audit_trail.select_patient_and_episode', 'method' => 'ANY', 'role' => 'search']) }}
|
||||
|
||||
{{ Form::hidden('patient_id', 0, ['id' => 'patient_id']) }}
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-3">
|
||||
<div class="form-group">
|
||||
<select class="patient_full_name form-control" style="width:100%;" name="patient_full_name" id="patient_full_name"></select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<button type="submit" class="btn btn-success pull-right"><span class="glyphicon glyphicon-search"></span> Search</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{{ Form::close() }}
|
||||
|
||||
<hr>
|
||||
|
||||
@if($patient_searched)
|
||||
<h4>{{ $patient->first_name }} {{ $patient->last_name }} ({{ $patient->number }})</h4>
|
||||
<br>
|
||||
|
||||
@if(count($patient_episodes_details) > 0)
|
||||
@php
|
||||
$current_column = 1;
|
||||
$current_item = 1;
|
||||
@endphp
|
||||
|
||||
@foreach($patient_episodes_details as $episode)
|
||||
@if($current_column == 1)
|
||||
<div class="row">
|
||||
@endif
|
||||
|
||||
<div class="col-md-4">
|
||||
<a href="/audit_trail/patient_timeline/{{ $patient->id }}/{{ $episode['id'] }}" class="btn btn-success btn-rounded btn-outline col-md-12">{{ $episode['created_at'] }}</a>
|
||||
</div>
|
||||
|
||||
@if($current_column == 3 || $current_item == count($patient_episodes_details))
|
||||
</div><br>
|
||||
@php $current_column = 1; @endphp
|
||||
@else
|
||||
@php $current_column++; @endphp
|
||||
@endif
|
||||
|
||||
@php
|
||||
$current_item++;
|
||||
@endphp
|
||||
@endforeach
|
||||
@else
|
||||
<h4><span style="color: red">Patient has no episodes</span></h4>
|
||||
@endif
|
||||
@endif
|
||||
</div>
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
<script src="{{ asset('elite/bower_components/select2/select2.min.js') }}"></script>
|
||||
|
||||
<script type="text/javascript">
|
||||
$('.patient_full_name').change(function() {
|
||||
let id = $('#patient_full_name').val();
|
||||
$('#patient_id').val(id);
|
||||
|
||||
$.ajax({
|
||||
method: 'GET',
|
||||
url: "/patients/update_patient_info/" + id,
|
||||
success: function(response){
|
||||
$('#patient_info').html(response).show();
|
||||
},
|
||||
error: function (error) {
|
||||
console.log(error);
|
||||
}
|
||||
});
|
||||
}).select2({
|
||||
placeholder: "<?php echo "Search by patient name or 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 + ") " + item.phone,
|
||||
id: item.id
|
||||
}
|
||||
})
|
||||
};
|
||||
},
|
||||
cache: true
|
||||
}
|
||||
});
|
||||
</script>
|
||||
@endpush
|
||||
Reference in New Issue
Block a user