Selaa lähdekoodia

added util report

logicpowerhouse 4 vuotta sitten
vanhempi
commit
96f861274f

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

@@ -407,9 +407,12 @@ class PracticeManagementController extends Controller
     }
 
     public function treatmentServiceUtil(Request $request){
+        $view_treatment_service_utilization_org = DB::select(DB::raw("SELECT * FROM view_treatment_service_utilization_org ORDER BY effective_date DESC"));
         $view_treatment_service_utilization = DB::select(DB::raw("SELECT * FROM view_treatment_service_utilization ORDER BY effective_date DESC, total_hrs DESC"));
         $view_treatment_service_utilization_by_patient = DB::select(DB::raw("SELECT * FROM view_treatment_service_utilization_by_patient ORDER BY pro_lname ASC, pro_fname ASC, hcp_pro_id ASC, total_hrs DESC"));
-        return view('app.practice-management.treatment-services-util', compact('view_treatment_service_utilization',
+        return view('app.practice-management.treatment-services-util', compact(
+            'view_treatment_service_utilization_org',
+            'view_treatment_service_utilization',
             'view_treatment_service_utilization_by_patient'));
     }
 

+ 23 - 0
resources/views/app/practice-management/treatment-services-util.blade.php

@@ -10,6 +10,29 @@
     <link rel="stylesheet" type="text/css" href="https://cdn.datatables.net/1.10.23/css/jquery.dataTables.css">
     <script type="text/javascript" charset="utf8" src="https://cdn.datatables.net/1.10.23/js/jquery.dataTables.js"></script>
     <div class="p-3 mcp-theme-1">
+
+        <div class="card">
+            <div class="card-body">
+                <h1 class="report-table-header">Treatment Service Utilization - Org.</h1>
+                <table class="table table-bordered table-striped table-sm" id="table0">
+                    <thead>
+                    <tr>
+                        <th>Date</th>
+                        <th>Total hrs.</th>
+                    </tr>
+                    </thead>
+                    <tbody>
+                    @foreach($view_treatment_service_utilization_org as $x)
+                        <tr>
+                            <td>{{$x->effective_date}}</td>
+                            <td>{{$x->total_hrs}}</td>
+                        </tr>
+                    @endforeach
+                    </tbody>
+                </table>
+            </div>
+        </div>
+
         <div class="card">
             <div class="card-body">
                 <h1 class="report-table-header">Treatment Service Utilization</h1>