常用方法
常用方法
常用方法
常用方法
public ActionResult Delete(int id, FormCollection collection) { var expense = repository.GetExpense(id); try { repository.Remove(expense); repository.Save(); return(RedirectToAction("Index")); } catch { return(View(expense)); } }