public ActionResult Create(CreateViewModel cvm) { if (ModelState.IsValid) // required fields entered? { _adapter.SaveCreateViewModel(cvm); return RedirectToAction("Create", "Restricted"); } return View(); }
public ActionResult Delete(RetrieveViewModel rvm) { CreateViewModel cvm = new CreateViewModel(); if (ModelState.IsValid) // required fields entered? { cvm = _adapter.GetCreateViewModel(rvm); if (cvm == null) // not found return View(); else return View("DeleteBridge", cvm); } return View(); }
public ActionResult DeleteByCoords(CreateViewModel cvm) { _adapter.DropBridge(cvm); return RedirectToAction("Delete", "Restricted"); }
public ActionResult Update(CreateViewModel cvm) { if (ModelState.IsValid) // required fields entered? { _adapter.UpdateCreateViewModel(cvm); return View("Retrieve"); } return View(); }