public ActionResult Edit([Bind(Include = "ID,Firstname,MiddleName,Lastname,EmailAddress,Phone,Address1,Address2,City,State,ZipCode")] Customer customer) { if (ModelState.IsValid) { db.Entry(customer).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(customer)); }
public ActionResult Edit([Bind(Include = "ID,ProdName,ProdDescription,Price,ProdAttributes")] Product product) { if (ModelState.IsValid) { db.Entry(product).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(product)); }