|
@@ -5,6 +5,24 @@
|
|
@extends ('layouts.patient')
|
|
@extends ('layouts.patient')
|
|
|
|
|
|
@section('inner-content')
|
|
@section('inner-content')
|
|
|
|
+
|
|
|
|
+ <?php
|
|
|
|
+ $shortCutsObject = [];
|
|
|
|
+ foreach ($pro->shortcuts as $shortcut) {
|
|
|
|
+
|
|
|
|
+ // %replaceables%
|
|
|
|
+ $shortcut->text = str_replace("%AGE%", $patient->age_in_years, $shortcut->text);
|
|
|
|
+ $shortcut->text = str_replace("%GENDER%", $patient->sex, $shortcut->text);
|
|
|
|
+ $shortcut->text = str_replace("%NAME%", $patient->displayName(), $shortcut->text);
|
|
|
|
+
|
|
|
|
+ $shortCutsObject[] = [
|
|
|
|
+ "name" => $shortcut->shortcut,
|
|
|
|
+ "value" => $shortcut->text
|
|
|
|
+ ];
|
|
|
|
+ }
|
|
|
|
+ ?>
|
|
|
|
+ <script>window.userShortcuts = <?= json_encode($shortCutsObject); ?>;</script>
|
|
|
|
+
|
|
@if($patient->has_mcp_done_onboarding_visit !== 'YES')
|
|
@if($patient->has_mcp_done_onboarding_visit !== 'YES')
|
|
<div class="pt-2 d-flex align-items-start">
|
|
<div class="pt-2 d-flex align-items-start">
|
|
<h6 class="my-0 text-secondary d-flex align-items-start">
|
|
<h6 class="my-0 text-secondary d-flex align-items-start">
|
|
@@ -66,7 +84,7 @@
|
|
</div>
|
|
</div>
|
|
@else
|
|
@else
|
|
|
|
|
|
- <div class="">
|
|
|
|
|
|
+ <div id="care-month-container">
|
|
<div class="pt-2 d-flex align-items-start">
|
|
<div class="pt-2 d-flex align-items-start">
|
|
<h6 class="my-0 text-secondary d-flex align-items-start">
|
|
<h6 class="my-0 text-secondary d-flex align-items-start">
|
|
<a href="/patients/view/{{ $patient->uid }}/care-months" class="small text-decoration-none mr-3">
|
|
<a href="/patients/view/{{ $patient->uid }}/care-months" class="small text-decoration-none mr-3">
|
|
@@ -196,7 +214,7 @@
|
|
|
|
|
|
<div class="row mb-3">
|
|
<div class="row mb-3">
|
|
<div class="col-12">
|
|
<div class="col-12">
|
|
- <div class="mt-0 pb-1">
|
|
|
|
|
|
+ <div class="mt-0">
|
|
<div class="d-flex align-items-center mb-2">
|
|
<div class="d-flex align-items-center mb-2">
|
|
<h6 class="my-0 font-weight-bold text-dark">Measurements</h6>
|
|
<h6 class="my-0 font-weight-bold text-dark">Measurements</h6>
|
|
<span class="mx-2 text-secondary">|</span>
|
|
<span class="mx-2 text-secondary">|</span>
|
|
@@ -219,11 +237,108 @@
|
|
</div>
|
|
</div>
|
|
</form>
|
|
</form>
|
|
</div>
|
|
</div>
|
|
- {{--<span class="mx-2 text-secondary">|</span>
|
|
|
|
- <a start show class="py-0 font-weight-normal"
|
|
|
|
- href="/patients/view/{{ $patient->uid }}/measurements">
|
|
|
|
- View All
|
|
|
|
- </a>--}}
|
|
|
|
|
|
+ @if(0 && $pro->pro_type === 'ADMIN')
|
|
|
|
+ <span class="mx-2 text-secondary">|</span>
|
|
|
|
+ <div moe>
|
|
|
|
+ <a start show class="py-0 font-weight-normal text-secondary">+ BP BDT Measurement</a>
|
|
|
|
+ <form url="/api/bdtMeasurement/create">
|
|
|
|
+ <div class="mb-2">
|
|
|
|
+ <input autofocus type="text" class="form-control form-control-sm" name="imei" value="987987987983" placeholder="imei">
|
|
|
|
+ </div>
|
|
|
|
+ <div class="mb-2">
|
|
|
|
+ <input type="text" class="form-control form-control-sm" name="ts" value="1600727786754" placeholder="ts">
|
|
|
|
+ </div>
|
|
|
|
+ <div class="mb-2">
|
|
|
|
+ <input type="text" class="form-control form-control-sm" name="batteryVoltage" value="6308" placeholder="batteryVoltage">
|
|
|
|
+ </div>
|
|
|
|
+ <div class="mb-2">
|
|
|
|
+ <input type="text" class="form-control form-control-sm" name="signalStrength" value="85" placeholder="signalStrength">
|
|
|
|
+ </div>
|
|
|
|
+ <div class="mb-2">
|
|
|
|
+ <input type="text" class="form-control form-control-sm" name="valueTare" value="" placeholder="valueTare">
|
|
|
|
+ </div>
|
|
|
|
+ <div class="mb-2">
|
|
|
|
+ <input type="text" class="form-control form-control-sm" name="valueWeight" value="" placeholder="valueWeight">
|
|
|
|
+ </div>
|
|
|
|
+ <div class="mb-2">
|
|
|
|
+ <input type="text" class="form-control form-control-sm" name="valueSystolic" value="20700" placeholder="valueSystolic">
|
|
|
|
+ </div>
|
|
|
|
+ <div class="mb-2">
|
|
|
|
+ <input type="text" class="form-control form-control-sm" name="valueDiastolic" value="9700" placeholder="valueDiastolic">
|
|
|
|
+ </div>
|
|
|
|
+ <div class="mb-2">
|
|
|
|
+ <input type="text" class="form-control form-control-sm" name="valuePulse" value="64" placeholder="valuePulse">
|
|
|
|
+ </div>
|
|
|
|
+ <div class="mb-2">
|
|
|
|
+ <input type="text" class="form-control form-control-sm" name="valueUnit" value="" placeholder="valueUnit">
|
|
|
|
+ </div>
|
|
|
|
+ <div class="mb-2">
|
|
|
|
+ <input type="text" class="form-control form-control-sm" name="valueIrregular" value="0" placeholder="valueIrregular">
|
|
|
|
+ </div>
|
|
|
|
+ <div class="mb-2">
|
|
|
|
+ <input type="text" class="form-control form-control-sm" name="rssi" value="71" placeholder="rssi">
|
|
|
|
+ </div>
|
|
|
|
+ <div class="mb-2">
|
|
|
|
+ <input type="text" class="form-control form-control-sm" name="deviceId" value="86011204403081" placeholder="deviceId">
|
|
|
|
+ </div>
|
|
|
|
+ <input type="hidden" name="secret" value="LTZS20QAFE">
|
|
|
|
+ <div class="d-flex align-items-center">
|
|
|
|
+ <button class="btn btn-sm btn-primary mr-2" submit>Save</button>
|
|
|
|
+ <button class="btn btn-sm btn-default mr-2 border" cancel>Cancel</button>
|
|
|
|
+ </div>
|
|
|
|
+ </form>
|
|
|
|
+ </div>
|
|
|
|
+ <span class="mx-2 text-secondary">|</span>
|
|
|
|
+ <div moe>
|
|
|
|
+ <a start show class="py-0 font-weight-normal text-secondary">+ Weight BDT Measurement</a>
|
|
|
|
+ <form url="/api/bdtMeasurement/create">
|
|
|
|
+ <div class="mb-2">
|
|
|
|
+ <input autofocus type="text" class="form-control form-control-sm" name="imei" value="987987987984" placeholder="imei">
|
|
|
|
+ </div>
|
|
|
|
+ <div class="mb-2">
|
|
|
|
+ <input type="text" class="form-control form-control-sm" name="ts" value="1600727786754" placeholder="ts">
|
|
|
|
+ </div>
|
|
|
|
+ <div class="mb-2">
|
|
|
|
+ <input type="text" class="form-control form-control-sm" name="batteryVoltage" value="6308" placeholder="batteryVoltage">
|
|
|
|
+ </div>
|
|
|
|
+ <div class="mb-2">
|
|
|
|
+ <input type="text" class="form-control form-control-sm" name="signalStrength" value="85" placeholder="signalStrength">
|
|
|
|
+ </div>
|
|
|
|
+ <div class="mb-2">
|
|
|
|
+ <input type="text" class="form-control form-control-sm" name="valueTare" value="0" placeholder="valueTare">
|
|
|
|
+ </div>
|
|
|
|
+ <div class="mb-2">
|
|
|
|
+ <input type="text" class="form-control form-control-sm" name="valueWeight" value="61400" placeholder="valueWeight">
|
|
|
|
+ </div>
|
|
|
|
+ <div class="mb-2">
|
|
|
|
+ <input type="text" class="form-control form-control-sm" name="valueSystolic" value="" placeholder="valueSystolic">
|
|
|
|
+ </div>
|
|
|
|
+ <div class="mb-2">
|
|
|
|
+ <input type="text" class="form-control form-control-sm" name="valueDiastolic" value="" placeholder="valueDiastolic">
|
|
|
|
+ </div>
|
|
|
|
+ <div class="mb-2">
|
|
|
|
+ <input type="text" class="form-control form-control-sm" name="valuePulse" value="" placeholder="valuePulse">
|
|
|
|
+ </div>
|
|
|
|
+ <div class="mb-2">
|
|
|
|
+ <input type="text" class="form-control form-control-sm" name="valueUnit" value="1" placeholder="valueUnit">
|
|
|
|
+ </div>
|
|
|
|
+ <div class="mb-2">
|
|
|
|
+ <input type="text" class="form-control form-control-sm" name="valueIrregular" value="" placeholder="valueIrregular">
|
|
|
|
+ </div>
|
|
|
|
+ <div class="mb-2">
|
|
|
|
+ <input type="text" class="form-control form-control-sm" name="rssi" value="78" placeholder="rssi">
|
|
|
|
+ </div>
|
|
|
|
+ <div class="mb-2">
|
|
|
|
+ <input type="text" class="form-control form-control-sm" name="deviceId" value="86528404866623" placeholder="deviceId">
|
|
|
|
+ </div>
|
|
|
|
+ <input type="hidden" name="secret" value="LTZS20QAFE">
|
|
|
|
+ <div class="d-flex align-items-center">
|
|
|
|
+ <button class="btn btn-sm btn-primary mr-2" submit>Save</button>
|
|
|
|
+ <button class="btn btn-sm btn-default mr-2 border" cancel>Cancel</button>
|
|
|
|
+ </div>
|
|
|
|
+ </form>
|
|
|
|
+ </div>
|
|
|
|
+ @endif
|
|
</div>
|
|
</div>
|
|
<table class="table table-striped table-sm table-bordered mt-2 mb-0">
|
|
<table class="table table-striped table-sm table-bordered mt-2 mb-0">
|
|
<thead>
|
|
<thead>
|
|
@@ -236,12 +351,27 @@
|
|
</tr>
|
|
</tr>
|
|
</thead>
|
|
</thead>
|
|
<tbody>
|
|
<tbody>
|
|
- @foreach($patient->measurements as $measurement)
|
|
|
|
- @if(!empty($measurement->label) && !in_array($measurement->label, $vitalLabels))
|
|
|
|
|
|
+ @php $measurementsInCareMonth = $patient->measurementsInCareMonth($careMonth); @endphp
|
|
|
|
+ @foreach($measurementsInCareMonth as $measurement)
|
|
|
|
+ @if(1 || !empty($measurement->label) && !in_array($measurement->label, $vitalLabels))
|
|
<tr>
|
|
<tr>
|
|
<td class="px-2">{{ friendly_date_time($measurement->created_at) }}</td>
|
|
<td class="px-2">{{ friendly_date_time($measurement->created_at) }}</td>
|
|
<td class="px-2">{{ $measurement->label }}</td>
|
|
<td class="px-2">{{ $measurement->label }}</td>
|
|
- <td class="px-2">{{ $measurement->value }}</td>
|
|
|
|
|
|
+ <td class="px-2">
|
|
|
|
+ @if(empty($measurement->client_bdt_measurement_id))
|
|
|
|
+ {{ $measurement->value }}
|
|
|
|
+ @else
|
|
|
|
+ @if($measurement->label === 'BP')
|
|
|
|
+ {{ $measurement->clientBDTMeasurement->measurement->systolic_bp_in_mm_hg }}/{{ $measurement->clientBDTMeasurement->measurement->diastolic_bp_in_mm_hg }} mmHg
|
|
|
|
+ @elseif($measurement->label === 'SBP')
|
|
|
|
+ {{ $measurement->clientBDTMeasurement->measurement->systolic_bp_in_mm_hg }} mmHg
|
|
|
|
+ @elseif($measurement->label === 'DBP')
|
|
|
|
+ {{ $measurement->clientBDTMeasurement->measurement->diastolic_bp_in_mm_hg }} mmHg
|
|
|
|
+ @elseif($measurement->label === 'Wt. (lbs.)')
|
|
|
|
+ {{ $measurement->clientBDTMeasurement->measurement->weight_in_pounds }} lbs
|
|
|
|
+ @endif
|
|
|
|
+ @endif
|
|
|
|
+ </td>
|
|
<td></td>
|
|
<td></td>
|
|
<td></td>
|
|
<td></td>
|
|
|
|
|
|
@@ -302,66 +432,14 @@
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
- <hr class="m-negator mt-4 mb-3">
|
|
|
|
|
|
+ {{-- BDT Measurements --}}
|
|
|
|
+ {{-- <hr class="m-negator mt-4 mb-3">
|
|
|
|
|
|
<div class="row mb-3">
|
|
<div class="row mb-3">
|
|
- {{-- BDT Measurements --}}
|
|
|
|
<div class="col-12">
|
|
<div class="col-12">
|
|
<div class="d-flex align-items-center">
|
|
<div class="d-flex align-items-center">
|
|
<h6 class="my-0 text-secondary font-weight-bold text-dark lh-24px">Cellular Measurements</h6>
|
|
<h6 class="my-0 text-secondary font-weight-bold text-dark lh-24px">Cellular Measurements</h6>
|
|
</div>
|
|
</div>
|
|
- {{--<div class="mt-2 pb-1">
|
|
|
|
- <table class="table table-sm border-0 m-0">
|
|
|
|
- <tbody>
|
|
|
|
- @foreach($patient->deviceMeasurements as $measurement)
|
|
|
|
- <tr>
|
|
|
|
- <td class="text-black p-0 border-0">
|
|
|
|
- <div class="pb-1 d-flex align-items-center">
|
|
|
|
- <span class="text-secondary mr-2">{{ $measurement->measurement->device_category }}:</span>
|
|
|
|
- @if($measurement->measurement->device_category === 'WEIGHT')
|
|
|
|
- <b class="text-nowrap">{{ round(($measurement->measurement->value_weight / 1000)*2.20462, 1) }} lb</b>
|
|
|
|
- @elseif($measurement->measurement->device_category === 'BP')
|
|
|
|
- <b class="text-nowrap">{{ $measurement->measurement->systolic_bp_in_mm_hg }}/{{ $measurement->measurement->diastolic_bp_in_mm_hg }} mmHg</b>
|
|
|
|
- @endif
|
|
|
|
- <span class="font-weight-normal text-secondary ml-2 text-sm">({{ friendly_date_time_short($measurement->measurement->created_at, true) }})</span>
|
|
|
|
- <span class="ml-2 text-sm {{$measurement->status === 'NEW' ? 'text-info' : ($measurement->status === 'ACCEPTED' ? 'text-success' : 'text-sacondary')}}">{{$measurement->status}}</span>
|
|
|
|
- <span>
|
|
|
|
- <span moe class="ml-2" relative>
|
|
|
|
- <a href="#" start show><i class="on-hover-opaque font-size-11 fa fa-edit text-primary"></i></a>
|
|
|
|
- <form url="/api/clientBdtMeasurement/updateStatus" right>
|
|
|
|
- <input type="hidden" name="uid" value="{{ $measurement->uid }}">
|
|
|
|
- <div class="mb-2">
|
|
|
|
- <select name="status" class="form-control form-control-sm" required>
|
|
|
|
- <option value="">-- select --</option>
|
|
|
|
- <option {{$measurement->status === 'NEW' ? 'selected' : '' }} value="NEW">NEW</option>
|
|
|
|
- <option {{$measurement->status === 'ACCEPTED' ? 'selected' : '' }} value="ACCEPTED">ACCEPTED</option>
|
|
|
|
- <option {{$measurement->status === 'REJECTED' ? 'selected' : '' }} value="REJECTED">REJECTED</option>
|
|
|
|
- </select>
|
|
|
|
- </div>
|
|
|
|
- <div class="mb-2">
|
|
|
|
- <input type="text" name="statusMemo" placeholder="Status memo" class="form-control form-control-sm">
|
|
|
|
- </div>
|
|
|
|
- <div class="d-flex align-items-center">
|
|
|
|
- <button class="btn btn-sm btn-primary mr-2" submit>Save</button>
|
|
|
|
- <button class="btn btn-sm btn-default mr-2 border" cancel>Cancel</button>
|
|
|
|
- </div>
|
|
|
|
- </form>
|
|
|
|
- </span>
|
|
|
|
- </span>
|
|
|
|
- </div>
|
|
|
|
- </td>
|
|
|
|
- </tr>
|
|
|
|
- @endforeach
|
|
|
|
- @if(!$patient->deviceMeasurements || count($patient->deviceMeasurements) === 0)
|
|
|
|
- <tr>
|
|
|
|
- <td class="text-secondary p-0 border-0">
|
|
|
|
- No measurements
|
|
|
|
- </td>
|
|
|
|
- </tr>
|
|
|
|
- @endif
|
|
|
|
- </tbody>
|
|
|
|
- </table>
|
|
|
|
- </div>--}}
|
|
|
|
<table class="table table-striped table-sm table-bordered mt-2 mb-0">
|
|
<table class="table table-striped table-sm table-bordered mt-2 mb-0">
|
|
@if($patient->measurements && count($patient->measurements))
|
|
@if($patient->measurements && count($patient->measurements))
|
|
<thead>
|
|
<thead>
|
|
@@ -426,7 +504,7 @@
|
|
@endif
|
|
@endif
|
|
</table>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
- </div>
|
|
|
|
|
|
+ </div> --}}
|
|
|
|
|
|
<hr class="m-negator mt-4 mb-3">
|
|
<hr class="m-negator mt-4 mb-3">
|
|
|
|
|
|
@@ -501,7 +579,7 @@
|
|
<div class="mb-2">
|
|
<div class="mb-2">
|
|
<div class="row">
|
|
<div class="row">
|
|
<div class="col-12">
|
|
<div class="col-12">
|
|
- <input type="text" name="contentText" class="form-control form-control-sm" rows="5" placeholder="Reviewed/managed patient measurements" value="Reviewed/managed patient measurements">
|
|
|
|
|
|
+ <div cm-rte data-content="Reviewed/managed patient measurements" data-name="contentText"></div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
@@ -534,7 +612,7 @@
|
|
<th class="px-2 text-secondary border-bottom-0">Effective Date</th>
|
|
<th class="px-2 text-secondary border-bottom-0">Effective Date</th>
|
|
<th class="px-2 text-secondary border-bottom-0">Time</th>
|
|
<th class="px-2 text-secondary border-bottom-0">Time</th>
|
|
<th class="px-2 text-secondary border-bottom-0">Created</th>
|
|
<th class="px-2 text-secondary border-bottom-0">Created</th>
|
|
- {{--<th class="px-2 text-secondary border-bottom-0 w-50">Details</th>--}}
|
|
|
|
|
|
+ <th class="px-2 text-secondary border-bottom-0 w-50">Details</th>
|
|
<th class="px-2 text-secondary border-bottom-0 delete-column"> </th>
|
|
<th class="px-2 text-secondary border-bottom-0 delete-column"> </th>
|
|
</tr>
|
|
</tr>
|
|
</thead>
|
|
</thead>
|
|
@@ -551,10 +629,10 @@
|
|
<td class="px-2">
|
|
<td class="px-2">
|
|
{{friendly_date_time($entry->created_at)}}
|
|
{{friendly_date_time($entry->created_at)}}
|
|
</td>
|
|
</td>
|
|
- {{--<td class="px-2">
|
|
|
|
- <div class="text-secondary text-s">{!! $entry->content_text !!}</div>
|
|
|
|
- --}}{{--<div class="text-secondary text-sm">{{$entry->content_detail}}</div>--}}{{--
|
|
|
|
- </td>--}}
|
|
|
|
|
|
+ <td class="px-2">
|
|
|
|
+ <div class="text-secondary in-table-markup">{!! $entry->content_text !!}</div>
|
|
|
|
+<!-- <div class="text-secondary text-sm">{{$entry->content_detail}}</div>-->
|
|
|
|
+ </td>
|
|
<td class="px-2 text-center delete-column">
|
|
<td class="px-2 text-center delete-column">
|
|
@if(!$activeRMBill)
|
|
@if(!$activeRMBill)
|
|
<div moe relative>
|
|
<div moe relative>
|
|
@@ -1206,5 +1284,54 @@
|
|
|
|
|
|
</div>
|
|
</div>
|
|
|
|
|
|
|
|
+ <script>
|
|
|
|
+ (function() {
|
|
|
|
+ function init() {
|
|
|
|
+ $('#care-month-container [cm-rte]').each(function() {
|
|
|
|
+
|
|
|
|
+ $(this).wrap(
|
|
|
|
+ $('<div class="border-left border-right rte-holder"/>')
|
|
|
|
+ .attr('data-shortcuts', '')
|
|
|
|
+ );
|
|
|
|
+
|
|
|
|
+ // give a unique id to this editor instance
|
|
|
|
+ var editorID = Math.ceil(Math.random() * 99999), fieldName = $(this).attr('data-name');
|
|
|
|
+
|
|
|
|
+ var el = this;
|
|
|
|
+ var existingContent = $(el).attr('data-content');
|
|
|
|
+ var quill = new Quill(el, {
|
|
|
|
+ theme: 'snow',
|
|
|
|
+ modules: stagQuillConfig
|
|
|
|
+ });
|
|
|
|
+
|
|
|
|
+ var toolbar = $(quill.container).prev('.ql-toolbar');
|
|
|
|
+
|
|
|
|
+ // add button for new shortcut
|
|
|
|
+ var newSCButton = $('<button class="btn bg-white btn-sm btn-default text-primary w-auto px-2 border py-0 ' +
|
|
|
|
+ 'text-sm add-shortcut" data-editor-id="' + editorID + '">+ Shortcut</button>');
|
|
|
|
+ toolbar.append(newSCButton);
|
|
|
|
+
|
|
|
|
+ quill.root.innerHTML = existingContent;
|
|
|
|
+
|
|
|
|
+ $('<input type="hidden" name="' + fieldName + '">').val(existingContent).insertAfter(el);
|
|
|
|
+
|
|
|
|
+ quill.on('text-change', function(delta, oldDelta, source) {
|
|
|
|
+ $(el).next('[name="' + fieldName + '"]').val(quill.root.innerHTML);
|
|
|
|
+ });
|
|
|
|
+
|
|
|
|
+ $(quill.container)
|
|
|
|
+ .find('.ql-editor[contenteditable]')
|
|
|
|
+ .attr('data-field', fieldName)
|
|
|
|
+ .attr('data-editor-id', editorID)
|
|
|
|
+ .attr('with-shortcuts', 1);
|
|
|
|
+
|
|
|
|
+ })
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ addMCInitializer('care-month-dashboard', init, '#care-month-container');
|
|
|
|
+
|
|
|
|
+ }).call(window);
|
|
|
|
+ </script>
|
|
|
|
+
|
|
@endif
|
|
@endif
|
|
@endsection
|
|
@endsection
|