|
@@ -542,12 +542,11 @@ class PatientController extends Controller
|
|
|
|
|
|
public function appointments(Request $request, Client $patient, $forPro = 'all', $status = 'all') {
|
|
|
$pros = $this->pros;
|
|
|
- $appointments = $patient->appointmentsForProByStatus('all', 'ALL');
|
|
|
+ $appointments = $patient->appointmentsForProByStatus($forPro, strtoupper($status));
|
|
|
$appointmentProIDs = $appointments->map(function($_item) {
|
|
|
return $_item->pro_id;
|
|
|
});
|
|
|
$appointmentPros = Pro::whereIn('id', $appointmentProIDs)->get();
|
|
|
- $appointments = $patient->appointmentsForProByStatus($forPro, strtoupper($status));
|
|
|
return view('app.patient.appointments',
|
|
|
compact('patient', 'pros', 'appointments', 'appointmentPros', 'forPro', 'status'));
|
|
|
}
|