// // GET: /Doctor/Patients/ public ActionResult Patients() { int doctorId = _identityProvider.GetAuthenticatedUserId(); IEnumerable <Patient> patients = _patientManagementService.ViewAllPatients(doctorId); return(View(patients)); }
// Show the patients of a single doctor. public ActionResult DoctorPatients(int doctorId) { Doctor doctor = _doctorRepository.GetDoctor(doctorId); List <Patient> patients = _patientManagementService.ViewAllPatients(doctorId); return(View(new PatientViewModel { Doctor = doctor, Patients = patients })); }