Forráskód Böngészése

Handouts remove source duplication

Vijayakrishnan 3 éve
szülő
commit
22ff3def02

+ 0 - 6
app/Http/Controllers/PatientController.php

@@ -323,12 +323,6 @@ class PatientController extends Controller
         return view('app.patient.handouts', compact('patient', 'handouts'));
     }
 
-    public function handoutsPopup(Request $request, Client $patient )
-    {
-        $handouts = Handout::where('is_active', true)->get();
-        return view('app.patient.handouts-popup', compact('patient', 'handouts'));
-    }
-
     public function settings(Request $request, Client $patient )
     {
         return view('app.patient.settings', compact('patient'));

+ 0 - 4
resources/views/app/patient/handouts-popup.blade.php

@@ -1,4 +0,0 @@
-<div class="border-top mt-3 p-3">
-    @include('app.patient.handouts-list')
-</div>
-

+ 1 - 2
resources/views/app/patient/handouts.blade.php

@@ -1,5 +1,4 @@
-@extends ('layouts.patient')
-
+@extends(request()->input('popupmode') ? 'layouts.popup' : 'layouts.patient')
 @section('inner-content')
     @include('app.patient.handouts-list')
 @endsection

+ 1 - 1
resources/views/app/patient/note/dashboard.blade.php

@@ -2444,7 +2444,7 @@
                                  open-in-stag-popup
                                  title="Handouts"
                                  popup-style="wide overflow-visible"
-                                 href="/patients/view/{{$patient->uid}}/handouts-popup?noteUid={{$note->uid}}">
+                                 href="/patients/view/{{$patient->uid}}/handouts?noteUid={{$note->uid}}">
                                 <span>Handouts</span>
                             </div>
                         </div>

+ 0 - 1
routes/web.php

@@ -396,7 +396,6 @@ Route::middleware('pro.auth')->group(function () {
             });
             Route::get('generic-bills', 'PatientController@genericBills')->name('generic-bills');
             Route::get('handouts', 'PatientController@handouts')->name('handouts');
-            Route::get('handouts-popup', 'PatientController@handoutsPopup')->name('handouts-popup');
             Route::get('rm-setup', 'PatientController@rmSetup')->name('rm-setup');
             Route::get('settings', 'PatientController@settings')->name('settings');
             Route::get('sms-reminders', 'PatientController@smsReminders')->name('sms-reminders');