public ActionResult Save(Hall hall) { if (!ModelState.IsValid) { return(View("HallAdd", hall)); } var hallId = int.Parse(Request["HallID"]); hall.HallID = hallId; if (hall.HallID == 0) { HallDAO.Create(hall); } else { HallDAO.Update(hall); } return(RedirectToAction("HallList")); }
public string Create(Hall hall) { HallDAO.Create(hall); return("Hall Created"); }