فهرست منبع

Updates - updated dashboard

Samson Mutunga 1 سال پیش
والد
کامیت
61de6f924a

+ 7 - 0
app/Http/Controllers/RdController.php

@@ -84,6 +84,13 @@ class RdController extends Controller
         $patients = $patients->orderBy('created_at', 'DESC')->paginate(20);
         return view('app.rd.patients', compact('patients', 'filters'));
     }
+
+    public function dashboardPatients(Request $request){
+        $pro = $this->performer->pro;
+        $patients = Client::where('rd_pro_id', $pro->id)->paginate(25);
+        return view('app.rd.dashboard.patients', compact('patients'));
+    }
+
     public function clientReviewRequests(Request $request){
         $hideTitle = $request->get('hideTitle');
         $performer = $this->performer();

+ 11 - 11
resources/views/app/rd/dashboard.blade.php

@@ -36,7 +36,7 @@
                                             <th class="px-2 text-center">{{ $pro->patientsCountAsRd() }}
                                             <th>
                                             <th class="pl-2">
-                                                <a class="font-weight-normal" href="{{ route('rd.patients', ['popupmode' => 1]) }}" native
+                                                <a class="font-weight-normal" href="{{ route('rd.dashboard-patients') }}" native
                                                     target="_blank" open-in-stag-popup popup-style="tall"
                                                     title="Patients ">Patients </a>
                                             </th>
@@ -46,7 +46,7 @@
                                             <th>
                                             <th class="pl-2">
                                                 <a class="font-weight-normal"
-                                                    href="{{ route('rd.patients_awaiting_mcp_visit', ['popupmode' => 1]) }}" native
+                                                    href="{{ route('rd.patients_awaiting_mcp_visit') }}" native
                                                     target="_blank" open-in-stag-popup popup-style="tall"
                                                     title="Patients Awaiting MCP Visit">Patients Awaiting MCP Visit</a>
                                             </th>
@@ -56,7 +56,7 @@
                                             <th>
                                             <th class="pl-2">
                                                 <a class="font-weight-normal"
-                                                    href="{{ route('rd.patients_without_appointment', ['popupmode' => 1]) }}" native
+                                                    href="{{ route('rd.patients_without_appointment') }}" native
                                                     target="_blank" open-in-stag-popup popup-style="tall"
                                                     title="Patients w/o Appointment ">Patients w/o Appointment </a>
                                             </th>
@@ -66,7 +66,7 @@
                                             <th>
                                             <th class="pl-2">
                                                 <a class="font-weight-normal"
-                                                    href="{{ route('rd.encounters_pending_my_review', ['popupmode' => 1]) }}" native
+                                                    href="{{ route('rd.encounters_pending_my_review') }}" native
                                                     target="_blank" open-in-stag-popup popup-style="tall"
                                                     title="Encounters Pending My Review ">Encounters Pending My Review </a>
                                             </th>
@@ -76,7 +76,7 @@
                                             <th>
                                             <th class="pl-2">
                                                 <a class="font-weight-normal"
-                                                    href="{{ route('rd.encounters_in_progress', ['popupmode' => 1]) }}" native target="_blank"
+                                                    href="{{ route('rd.encounters_in_progress') }}" native target="_blank"
                                                     open-in-stag-popup popup-style="tall"
                                                     title="Encounters In Progress">Encounters In Progress</a>
                                             </th>
@@ -87,7 +87,7 @@
                                             <th>
                                             <th class="pl-2">
                                                 <a class="font-weight-normal"
-                                                    href="{{ route('rd.appointments_pending_confirmation', ['popupmode' => 1]) }}" native
+                                                    href="{{ route('rd.appointments_pending_confirmation') }}" native
                                                     target="_blank" open-in-stag-popup popup-style="tall"
                                                     title="Appointments Pending Confirmation">Appointments Pending
                                                     Confirmation</a>
@@ -99,7 +99,7 @@
                                             <th>
                                             <th class="pl-2">
                                                 <a class="font-weight-normal"
-                                                    href="{{ route('rd.cancelled_appointments_pending_ack', ['popupmode' => 1]) }}" native
+                                                    href="{{ route('rd.cancelled_appointments_pending_ack') }}" native
                                                     target="_blank" open-in-stag-popup popup-style="tall"
                                                     title="Cancelled Appointments Pending Ack.">Cancelled Appointments
                                                     Pending Ack.</a>
@@ -109,7 +109,7 @@
                                             <th class="px-2 text-center">{{ $pro->reportsPendingAckCountAsRd() }}
                                             <th>
                                             <th class="pl-2">
-                                                <a class="font-weight-normal" href="{{ route('rd.reports_pending_ack', ['popupmode' => 1]) }}"
+                                                <a class="font-weight-normal" href="{{ route('rd.reports_pending_ack') }}"
                                                     native target="_blank" open-in-stag-popup popup-style="tall"
                                                     title="Reports Pending Ack.">Reports Pending Ack.</a>
                                             </th>
@@ -119,7 +119,7 @@
                                             <th>
                                             <th class="pl-2">
                                                 <a class="font-weight-normal"
-                                                    href="{{ route('rd.supply_orders_pending_my_ack', ['popupmode' => 1]) }}" native
+                                                    href="{{ route('rd.supply_orders_pending_my_ack') }}" native
                                                     target="_blank" open-in-stag-popup popup-style="tall"
                                                     title="Supply Orders Pending My Ack.">Supply Orders Pending My Ack.</a>
                                             </th>
@@ -130,7 +130,7 @@
                                             <th>
                                             <th class="pl-2">
                                                 <a class="font-weight-normal"
-                                                    href="{{ route('rd.supply_orders_pending_hcp_approval', ['popupmode' => 1]) }}" native
+                                                    href="{{ route('rd.supply_orders_pending_hcp_approval') }}" native
                                                     target="_blank" open-in-stag-popup popup-style="tall"
                                                     title="Supply Orders Pending HCP Approval">Supply Orders Pending HCP
                                                     Approval</a>
@@ -141,7 +141,7 @@
                                             <th>
                                             <th class="pl-2">
                                                 <a class="font-weight-normal"
-                                                    href="{{ route('rd.client-review-requests', ['hideTitle' => true, 'popupmode' => 1]) }}"
+                                                    href="{{ route('rd.client-review-requests', ['hideTitle' => true]) }}"
                                                     native target="_blank" open-in-stag-popup popup-style="tall"
                                                     title="Charts Pending My Review">Charts Pending My Review </a>
                                             </th>

+ 3 - 0
resources/views/app/rd/dashboard/patients.blade.php

@@ -0,0 +1,3 @@
+<div class="p-3">
+    @include('app.rd.patients-table')
+</div>

+ 44 - 49
resources/views/app/rd/review-requests/list.blade.php

@@ -1,40 +1,37 @@
-@extends ('layouts.template')
-@section('content')
-<div class="p-3 mcp-theme-1">
-    <div class="">
-        @if(!@$hideTitle)
+<div class="">
+    @if (!@$hideTitle)
         <div class="d-flex align-items-center pb-2">
             <h4 class="font-weight-bold mb-0 mr-3">Review Requests</h4>
         </div>
-        @endif
-        <table class="table table-striped table-sm table-bordered">
-            <thead class="bg-light">
-                <tr>
-                    <th class="border-0 text-secondary text-nowrap">Created At</th>
-                    <th class="border-0 text-secondary text-nowrap">Chart #</th>
-                    <th class="border-0 text-secondary text-nowrap">Patient</th>
-                    <th class="border-0 text-secondary">Scoped Month Start Date</th>
-                    <th class="border-0 text-secondary">Access Start Date</th>
-                    <th class="border-0 text-secondary">Access End Date</th>
-                    <th class="border-0 text-secondary">Pro</th>
-                    <th class="border-0 text-secondary">Created By</th>
-                    <th class="border-0 text-secondary">Is Active</th>
-                    <th class="border-0 text-secondary">Status</th>
-                </tr>
-            </thead>
-            <tbody>
-                @foreach($reviewRequests as $rr)
+    @endif
+    <table class="table table-striped table-sm table-bordered">
+        <thead class="bg-light">
+            <tr>
+                <th class="border-0 text-secondary text-nowrap">Created At</th>
+                <th class="border-0 text-secondary text-nowrap">Chart #</th>
+                <th class="border-0 text-secondary text-nowrap">Patient</th>
+                <th class="border-0 text-secondary">Scoped Month Start Date</th>
+                <th class="border-0 text-secondary">Access Start Date</th>
+                <th class="border-0 text-secondary">Access End Date</th>
+                <th class="border-0 text-secondary">Pro</th>
+                <th class="border-0 text-secondary">Created By</th>
+                <th class="border-0 text-secondary">Is Active</th>
+                <th class="border-0 text-secondary">Status</th>
+            </tr>
+        </thead>
+        <tbody>
+            @foreach ($reviewRequests as $rr)
                 <tr>
                     <td class="text-nowrap">{{ friendly_date_time($rr->created_at) }}</td>
                     <td>
-                    <a native target="_blank" href="{{route('patients.view.dashboard', $rr->client)}}">
-						{{$rr->client->chart_number}}
-					</a>
+                        <a native target="_blank" href="{{ route('patients.view.dashboard', $rr->client) }}">
+                            {{ $rr->client->chart_number }}
+                        </a>
                     </td>
                     <td>
-                    <a native target="_blank" href="{{route('patients.view.dashboard', $rr->client)}}">
-						{{$rr->client->displayName()}}
-					</a>
+                        <a native target="_blank" href="{{ route('patients.view.dashboard', $rr->client) }}">
+                            {{ $rr->client->displayName() }}
+                        </a>
                     </td>
                     <td>{{ friendly_date($rr->scoped_month_start_date) }}</td>
                     <td>{{ friendly_date($rr->access_start_date) }}</td>
@@ -42,34 +39,32 @@
                     <td>{{ $rr->pro->displayName() }}</td>
                     <td>{{ $rr->createdBySession->pro->displayName() }}</td>
                     <td>
-                        @if($rr->is_active)
-                        <span class="text-success mr-2">YES
-                            @if($rr->reactivation_memo)
-                            <i class="fas fa-info-circle text-muted" title="{{ $rr->reactivation_memo }}"></i>
-                            @endif
-                        </span>
+                        @if ($rr->is_active)
+                            <span class="text-success mr-2">YES
+                                @if ($rr->reactivation_memo)
+                                    <i class="fas fa-info-circle text-muted" title="{{ $rr->reactivation_memo }}"></i>
+                                @endif
+                            </span>
                         @else
-                        <span class="text-secondary mr-2">NO
-                            @if($rr->deactivation_memo)
-                            <i class="fas fa-info-circle text-muted" title="{{ $rr->deactivation_memo }}"></i>
-                            @endif
-                        </span>
+                            <span class="text-secondary mr-2">NO
+                                @if ($rr->deactivation_memo)
+                                    <i class="fas fa-info-circle text-muted" title="{{ $rr->deactivation_memo }}"></i>
+                                @endif
+                            </span>
                         @endif
                     </td>
                     <td>
                         <span class="mr-2">{{ $rr->status ?? '--' }}
-                            @if($rr->status_memo )
-                            <i class="fas fa-info-circle text-muted" title="{{ $rr->status_memo }}"></i>
+                            @if ($rr->status_memo)
+                                <i class="fas fa-info-circle text-muted" title="{{ $rr->status_memo }}"></i>
                             @endif
                         </span>
                     </td>
                 </tr>
-                @endforeach
-            </tbody>
-        </table>
-        <div class="p-3">
-            {{$reviewRequests->withQueryString()->links()}}
-        </div>
+            @endforeach
+        </tbody>
+    </table>
+    <div class="p-3">
+        {{ $reviewRequests->withQueryString()->links() }}
     </div>
 </div>
-@endsection

+ 1 - 0
routes/web.php

@@ -218,6 +218,7 @@ Route::middleware('pro.auth')->group(function () {
 
     Route::name('rd.')->prefix('rd')->group(function () {
         Route::get('dashboard', [RdController::class, 'dashboard'])->name('dashboard');
+        Route::get('dashboard-patients', [RdController::class, 'dashboardPatients'])->name('dashboard-patients');
         Route::get('client-review-requests', [RdController::class, 'clientReviewRequests'])->name('client-review-requests');
         Route::get('patients', [RdController::class, 'patients'])->name('patients');
         Route::get('patients_awaiting_mcp_visit', [RdController::class, 'patientsAwaitingMcpVisit'])->name('patients_awaiting_mcp_visit');