public Edit ( int id ) : System.Web.Mvc.ActionResult | ||
id | int | |
return | System.Web.Mvc.ActionResult |
public ActionResult Edit(int id = 0)
{
var allCategories = from c in db.Categorys select c;
ViewBag.cate = allCategories;
Book book = db.Books.Find(id);
if (book == null)
{
return HttpNotFound();
}
return View(book);
}
AdminController::Edit ( |