public ActionResult Edit(int id, FormCollection collection) { try { // TODO: Add update logic here var model = ExtraPayrollItems.GetById(id); TryUpdateModel(model); model.SaveOrUpDate(); return(RedirectToAction("Index")); } catch { return(View()); } }
// GET: ExtraPayrollItems/Edit/5 public ActionResult Edit(int id) { return(View(ExtraPayrollItems.GetById(id))); }