Samson Mutunga преди 3 години
родител
ревизия
acc71c386d

+ 12 - 1
app/Http/Controllers/PracticeManagementController.php

@@ -49,7 +49,7 @@ use App\Models\SegmentTemplate;
 use App\Models\VisitTemplate;
 use App\Models\VisitTemplateSegmentTemplate;
 use App\Models\VisitTemplateAccess;
-
+use App\Models\ClientReviewRequest;
 class PracticeManagementController extends Controller
 {
 
@@ -4076,5 +4076,16 @@ ORDER BY c.name_last, c.name_first
         return view('app.practice-management.coverages', compact('rows', 'paginator'));
     }
 
+    public function clientReviewRequests(Request $request){
+        $pro = $this->performer->pro;
+
+        $reviewRequests = ClientReviewRequest::where('status', '!=', 'DONE');
+        if($pro->pro_type !== 'ADMIN'){
+            $reviewRequests = $reviewRequests->where('pro_id', $pro->id);
+        }
+        $reviewRequests = $reviewRequests->orderBy('created_at', 'DESC')->paginate(50);
+        return view('app.ps.review-requests.list', compact('reviewRequests'));
+    }
+
    
 }

+ 14 - 0
resources/views/app/dashboard-dna.blade.php

@@ -189,6 +189,20 @@
                                 </div>
                             </div>
 
+                            @if($pro->is_considered_for_supervising_physician)
+                            <!-- ENCOUNTERS PENDING MY REVIEW -->
+                            <div class="card mb-4">
+                                <div class="card-header pl-2">
+                                    <strong>
+                                        Charts Pending My Review
+                                    </strong>
+                                </div>
+                                <div class="card-body p-0">
+                                    @include('app.ps.dashboard.client-charts-pending-my-review')
+                                </div>
+                            </div>
+                            @endif
+
                         </div>
                         <div class="col-md-6 mcp-theme-1">
                             <div class="card mb-4">

+ 13 - 0
resources/views/app/dashboard-hcp.blade.php

@@ -311,6 +311,19 @@
                                     @include('app.mcp.dashboard.measurements-pending-stamping')
                                 </div>
                             </div>
+                            @if($pro->is_considered_for_supervising_physician)
+                            <!-- ENCOUNTERS PENDING MY REVIEW -->
+                            <div class="card mb-4">
+                                <div class="card-header pl-2">
+                                    <strong>
+                                        Charts Pending My Review
+                                    </strong>
+                                </div>
+                                <div class="card-body p-0">
+                                    @include('app.ps.dashboard.client-charts-pending-my-review')
+                                </div>
+                            </div>
+                            @endif
                         </div>
                         <div class="col-md-6 mcp-theme-1 pl-1">
                             <div class="card mb-4">

+ 13 - 0
resources/views/app/dashboard-mcp.blade.php

@@ -414,6 +414,19 @@
                                     @include('app.mcp.dashboard.measurements-pending-stamping')
                                 </div>
                             </div>
+                            @if($pro->is_considered_for_supervising_physician)
+                            <!-- ENCOUNTERS PENDING MY REVIEW -->
+                            <div class="card mb-4">
+                                <div class="card-header pl-2">
+                                    <strong>
+                                        Charts Pending My Review
+                                    </strong>
+                                </div>
+                                <div class="card-body p-0">
+                                    @include('app.ps.dashboard.client-charts-pending-my-review')
+                                </div>
+                            </div>
+                            @endif
                         </div>
                         <div class="col-md-6 mcp-theme-1 pl-1">
                             <div class="card mb-4">

+ 1 - 0
resources/views/app/patient/note/partials/flag-note-by-supervisor.blade.php

@@ -42,6 +42,7 @@
                     </div>
                 </div>
             @endif
+            <!-- Ask Josh, should any supervising physician stamp this note -->
             @if($note->isProPhysicianSupervisor($performer->pro->id)) 
                 <div moe class="ml-2">
                     <a href="#" start show class="text-success"><i class="fas fa-stamp"></i> Stamp Note</a>

+ 6 - 0
resources/views/app/patient/notes.blade.php

@@ -264,6 +264,9 @@
                 $records = $patient->notes;
                 break;
         }
+        if($performer->pro->is_considered_for_supervising_physician){
+            $records = $records->where('is_flagged_for_supervising_physician_review', true);
+        }
         ?>
         @foreach ($records as $note)
             <tr class="{{ $note->is_cancelled ? 'cancelled-item always-clickable' : '' }}">
@@ -278,6 +281,9 @@
                         <i class="fas fa-clipboard-check text-success" title="Care plan was setup on this note."></i> 
                     @endif
                     <span class="ml-1">{{ $note->is_cancelled ? '[cancelled]' : '' }}</span>
+                    @if($note->is_flagged_for_supervising_physician_review)
+                        <span class="mx-2"><i class="fas fa-flag text-danger" title="Flagged for review"></i></span>
+                    @endif
                 </td>
                 <td>
                     {{ $note->new_or_fu_or_na === 'NEW' ? 'New' : 'Follow-up' }}

+ 2 - 1
resources/views/app/ps/review-requests/list.blade.php

@@ -2,7 +2,7 @@
 @section('content')
 <div class="p-3 mcp-theme-1">
     <div class="">
-        @if(!$hideTitle)
+        @if(!@$hideTitle)
         <div class="d-flex align-items-center pb-2">
             <h4 class="font-weight-bold mb-0 mr-3">Review Requests</h4>
         </div>
@@ -31,6 +31,7 @@
 						{{$rr->client->chart_number}}
 					</a>
                     </td>
+                    <td>
                     <a native target="_blank" href="{{route('patients.view.dashboard', $rr->client)}}">
 						{{$rr->client->displayName()}}
 					</a>

+ 3 - 0
resources/views/layouts/template.blade.php

@@ -183,6 +183,9 @@
                             <a class="dropdown-item" href="{{ route('dna.myBills') }}">My Bills</a>
                             <a class="dropdown-item" href="{{ route('dna.myClinicalTeams') }}">My Clinical Teams</a>
                         @endif
+                        @if($pro->pro_type === 'ADMIN' || $pro->is_considered_for_supervising_physician)
+                        <a class="dropdown-item" href="{{ route('practice-management.client-review-requests') }}">Client Review Requests</a>
+                        @endif
                     </div>
                 </li>
 

+ 1 - 0
routes/web.php

@@ -242,6 +242,7 @@ Route::middleware('pro.auth')->group(function () {
         Route::get('notes-pending-physician-supervisor-stamping', 'PracticeManagementController@notesPendingPhysicianSupervisorStamping')->name('notes-pending-physician-supervisor-stamping');
 
         Route::get('rpm-matrix', 'PracticeManagementController@rpmMatrix')->name('rpmMatrix');
+        Route::get('client-review-requests', 'PracticeManagementController@clientReviewRequests')->name('client-review-requests');
 
         // rpm work matrix - latest patient with unstamped measurements
         Route::get('rpm-work-matrix', 'PracticeManagementController@rpm_work_matrix')->name('rpm_work_matrix');