public IActionResult Details(int appointmentId) { var model = new AppointmentDetailsModel { Appointment = _appointmentsService.GetAppointmentById(appointmentId) }; return(View(model)); }
public ActionResult PrintWorksOrderByAppointment(int?id) { if (id.HasValue) { var appointment = _appointmentsService.GetAppointmentById(id.Value); if (appointment != null) { return(RedirectToAction("WorksOrderPrint", "Reports", new { id = appointment.OrderId })); } } return(RedirectToAction("Index", "Appointments")); }