|
@@ -27,8 +27,6 @@
|
|
|
</span>
|
|
|
<?php
|
|
|
|
|
|
- use App\Models\Note;
|
|
|
-
|
|
|
$mStr = request()->input('m') ? request()->input('m') : date('m');
|
|
|
$yStr = request()->input('y') ? request()->input('y') : date('Y');
|
|
|
$rcmStartDate = $yStr . '-' . $mStr . '-' . '01';
|
|
@@ -80,19 +78,19 @@
|
|
|
<table class="table table-sm table-striped table-hover p-0 m-0 border-top" id="table-rm-matrix">
|
|
|
<thead class="bg-light">
|
|
|
<tr>
|
|
|
- <th class="border-0 pl-2">Name</th>
|
|
|
- <th class="border-0">DOB</th>
|
|
|
- <th class="border-0">RPM?</th>
|
|
|
- <th class="border-0">Cell. BP?</th>
|
|
|
- <th class="border-0">Cell. Scale?</th>
|
|
|
- <th class="border-0">Last BP</th>
|
|
|
- <th class="border-0">Last Wt</th>
|
|
|
- <th class="border-0">Last Visit</th>
|
|
|
- <th class="border-0">Interacted?</th>
|
|
|
- <th class="border-0">#Meas. Days</th>
|
|
|
- <th class="border-0">#Unstamped</th>
|
|
|
- <th class="border-0">#RPM Mins.</th>
|
|
|
- <th class="border-0">Billable</th>
|
|
|
+ <th class="border-0 pl-2" stag-title="Click to sort. Shift+Click to multi-sort.">Name</th>
|
|
|
+ <th class="border-0" stag-title="Click to sort. Shift+Click to multi-sort.">DOB</th>
|
|
|
+ <th class="border-0" stag-title="Click to sort. Shift+Click to multi-sort.">RPM?</th>
|
|
|
+ <th class="border-0" stag-title="Click to sort. Shift+Click to multi-sort.">Cell. BP?</th>
|
|
|
+ <th class="border-0" stag-title="Click to sort. Shift+Click to multi-sort.">Cell. Scale?</th>
|
|
|
+ <th class="border-0" stag-title="Click to sort. Shift+Click to multi-sort.">Last BP</th>
|
|
|
+ <th class="border-0" stag-title="Click to sort. Shift+Click to multi-sort.">Last Wt</th>
|
|
|
+ <th class="border-0" stag-title="Click to sort. Shift+Click to multi-sort.">Last Visit</th>
|
|
|
+ <th class="border-0" stag-title="Click to sort. Shift+Click to multi-sort.">Interacted?</th>
|
|
|
+ <th class="border-0" stag-title="Click to sort. Shift+Click to multi-sort.">#Meas. Days</th>
|
|
|
+ <th class="border-0" stag-title="Click to sort. Shift+Click to multi-sort.">#Unstamped</th>
|
|
|
+ <th class="border-0" stag-title="Click to sort. Shift+Click to multi-sort.">#RPM Mins.</th>
|
|
|
+ <th class="border-0" stag-title="Click to sort. Shift+Click to multi-sort.">Billable</th>
|
|
|
</tr>
|
|
|
</thead>
|
|
|
<tbody>
|
|
@@ -100,12 +98,10 @@
|
|
|
<?php
|
|
|
|
|
|
$daysDiff = -1;
|
|
|
- $mostRecentCompletedMcpNote = null;
|
|
|
if($iPatient->most_recent_completed_mcp_note_date) {
|
|
|
$careMonthLastDay = date_add(date_create($rcmStartDate), date_interval_create_from_date_string("1 month"));
|
|
|
$careMonthLastDay = date_sub($careMonthLastDay, date_interval_create_from_date_string("1 day"));
|
|
|
$daysDiff = date_diff($careMonthLastDay, date_create($iPatient->most_recent_completed_mcp_note_date))->days;
|
|
|
- $mostRecentCompletedMcpNote = Note::where('id', $iPatient->most_recent_completed_mcp_note_id)->first();
|
|
|
}
|
|
|
$lastVisitWithin90Days = ($daysDiff !== -1 && $daysDiff <= 90);
|
|
|
|
|
@@ -152,12 +148,12 @@
|
|
|
<td>
|
|
|
<div class="d-flex align-items-baseline">
|
|
|
<i class="mr-1 text-sm fa {{$lastVisitWithin90Days ? 'fa-check text-success' : 'fa-exclamation-triangle text-danger'}}"></i>
|
|
|
- @if($mostRecentCompletedMcpNote)
|
|
|
- <a href = "{{route('patients.view.notes.view.dashboard', ['patient' => $iPatient->client_uid, 'note' => $mostRecentCompletedMcpNote])}}">
|
|
|
- <span>{{$iPatient->most_recent_completed_mcp_note_date ? friendly_date($iPatient->most_recent_completed_mcp_note_date) : '-'}}</span>
|
|
|
+ @if($iPatient->most_recent_completed_mcp_note_uid)
|
|
|
+ <a href = "/patients/view/{{$iPatient->client_uid}}/notes/view/{{$iPatient->most_recent_completed_mcp_note_uid}}">
|
|
|
+ <span class="sort-data">{{$iPatient->most_recent_completed_mcp_note_date ? friendly_date($iPatient->most_recent_completed_mcp_note_date) : '-'}}</span>
|
|
|
</a>
|
|
|
@else
|
|
|
- <span>-</span>
|
|
|
+ <span class="sort-data">-</span>
|
|
|
@endif
|
|
|
</div>
|
|
|
{{--@if(!$lastVisitWithin90Days)
|
|
@@ -230,7 +226,7 @@
|
|
|
<td>
|
|
|
<div class="d-flex align-items-baseline">
|
|
|
<i class="mr-1 text-sm fa {{$iPatient->number_of_days_with_remote_measurements >= 16 ? 'fa-check text-success' : 'fa-exclamation-triangle text-danger'}}"></i>
|
|
|
- <span>{{$iPatient->number_of_days_with_remote_measurements ?: 0}}</span>
|
|
|
+ <span class="sort-data">{{$iPatient->number_of_days_with_remote_measurements ?: 0}}</span>
|
|
|
@if($iPatient->number_of_days_with_remote_measurements < 16)
|
|
|
<div moe relative class="ml-2">
|
|
|
<a href="#" start show class="text-sm">SMS</a>
|
|
@@ -259,7 +255,7 @@
|
|
|
<td>
|
|
|
<div class="d-flex align-items-baseline">
|
|
|
@if($performerRole === 'MCP')
|
|
|
- <span>{{$iPatient->rm_num_measurements_not_stamped_by_mcp}}</span>
|
|
|
+ <span class="sort-data">{{$iPatient->rm_num_measurements_not_stamped_by_mcp}}</span>
|
|
|
@if($iPatient->rm_num_measurements_not_stamped_by_mcp)
|
|
|
<a href="{{ route('practice-management.rpm_work_matrix') }}?patientUid={{$iPatient->client_uid}}&careMonthUid={{$iPatient->care_month_uid}}"
|
|
|
native target="_blank"
|
|
@@ -273,7 +269,7 @@
|
|
|
</a>
|
|
|
@endif
|
|
|
@elseif($performerRole === 'RMM')
|
|
|
- <span>{{$iPatient->rm_num_measurements_not_stamped_by_rmm}}</span>
|
|
|
+ <span class="sort-data">{{$iPatient->rm_num_measurements_not_stamped_by_rmm}}</span>
|
|
|
@if($iPatient->rm_num_measurements_not_stamped_by_rmm)
|
|
|
<a href="{{ route('practice-management.rpm_work_matrix') }}?patientUid={{$iPatient->client_uid}}&careMonthUid={{$iPatient->care_month_uid}}"
|
|
|
native target="_blank"
|
|
@@ -294,6 +290,7 @@
|
|
|
<div class="d-flex align-items-baseline">
|
|
|
<i class="mr-1 text-sm fa {{$iPatient->rm_total_time_in_seconds_by_mcp >= 1200 ? 'fa-check text-success' : 'fa-exclamation-triangle text-danger'}}"></i>
|
|
|
<span class="text-nowrap">{{round($iPatient->rm_total_time_in_seconds_by_mcp / 60)}}m {{round($iPatient->rm_total_time_in_seconds_by_mcp % 60)}}s</span>
|
|
|
+ <span class="sort-data d-none">{{$iPatient->rm_total_time_in_seconds_by_mcp}}</span>
|
|
|
</div>
|
|
|
{{--@if($iPatient->rm_total_time_in_seconds_by_mcp < 1200)
|
|
|
<div class="text-sm font-italic text-secondary">Entry mins. < 20</div>
|
|
@@ -302,6 +299,7 @@
|
|
|
<div class="d-flex align-items-baseline">
|
|
|
<i class="mr-1 text-sm fa {{$iPatient->rm_total_time_in_seconds_by_rmm_pro >= 1200 ? 'fa-check text-success' : 'fa-exclamation-triangle text-danger'}}"></i>
|
|
|
<span class="text-nowrap">{{round($iPatient->rm_total_time_in_seconds_by_rmm_pro / 60)}}m {{round($iPatient->rm_total_time_in_seconds_by_rmm_pro % 60)}}s</span>
|
|
|
+ <span class="sort-data d-none">{{$iPatient->rm_total_time_in_seconds_by_rmm_pro}}</span>
|
|
|
</div>
|
|
|
{{--@if($iPatient->rm_total_time_in_seconds_by_rmm_pro < 1200)
|
|
|
<div class="text-sm font-italic text-secondary">Entry mins. < 20</div>
|
|
@@ -345,7 +343,32 @@
|
|
|
<script>
|
|
|
(function() {
|
|
|
function init() {
|
|
|
- $('#table-rm-matrix').DataTable();
|
|
|
+ $('#table-rm-matrix').DataTable({
|
|
|
+ paging: false,
|
|
|
+ columnDefs: [
|
|
|
+ {targets: 1, type: 'date'},
|
|
|
+ {
|
|
|
+ targets: 7,
|
|
|
+ type: 'date',
|
|
|
+ render: function (data, type, row, meta) {
|
|
|
+ if(type === 'sort') {
|
|
|
+ return $(data).find('.sort-data').first().text();
|
|
|
+ }
|
|
|
+ return data;
|
|
|
+ },
|
|
|
+ },
|
|
|
+ {
|
|
|
+ targets: [9, 10, 11],
|
|
|
+ type: 'num',
|
|
|
+ render: function (data, type, row, meta) {
|
|
|
+ if(type === 'sort') {
|
|
|
+ return +($(data).find('.sort-data').first().text());
|
|
|
+ }
|
|
|
+ return data;
|
|
|
+ },
|
|
|
+ },
|
|
|
+ ]
|
|
|
+ });
|
|
|
$('#practice-remote-monitoring').removeAttr('v-cloak');
|
|
|
}
|
|
|
addMCInitializer('practice-remote-monitoring', init, '#practice-remote-monitoring');
|