public ActionResult Edit([Bind(Include = "CartItemId,ArticleName,Quantity")] CartItem cartItem) { if (ModelState.IsValid) { db.Entry(cartItem).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(cartItem)); }
public ActionResult Edit([Bind(Include = "CustomerId,FirstName,LastName,Adress,ZipCode,Email,PhoneNumber")] Customer customer) { if (ModelState.IsValid) { db.Entry(customer).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(customer)); }
public ActionResult Edit([Bind(Include = "ArticleId,ArticleName,Description,Price,Image,Stock")] Product product) { if (ModelState.IsValid) { db.Entry(product).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(product)); }