public IActionResult Add(Maintenance maintenance) { if (ModelState.IsValid) { _repository.AddMaintenance(maintenance); return(RedirectToAction("Detail", new { id = maintenance.Id })); } return(View(maintenance)); }
public IActionResult Add(Maintenance maintenance) { if (ModelState.IsValid) { _repository.AddMaintenance(maintenance); return(RedirectToAction("Detail", new { id = maintenance.Id })); } return(View(maintenance)); }