public async Task <ActionResult> Edit([Bind(Include = "Id,Name,BasePrice,Dictionnary")] ProductType productType) { if (ModelState.IsValid) { db.Entry(productType).State = EntityState.Modified; await db.SaveChangesAsync(); return(RedirectToAction("Index")); } return(View(productType)); }
public async Task <ActionResult> Edit([Bind(Include = "Id,StockEnterAt,StockSelledAt,Dictionnary")] Product product) { if (ModelState.IsValid) { db.Entry(product).State = EntityState.Modified; await db.SaveChangesAsync(); return(RedirectToAction("Index")); } return(View(product)); }
public async Task <ActionResult> Edit([Bind(Include = "Id,Login,Password,Firstname,Lastname,Email,DateOfBirth")] Seller seller) { if (ModelState.IsValid) { db.Entry(seller).State = EntityState.Modified; await db.SaveChangesAsync(); return(RedirectToAction("Index")); } return(View(seller)); }
public async Task <ActionResult> Edit([Bind(Include = "Id,OrderDate,IsValidated")] Order order) { if (ModelState.IsValid) { db.Entry(order).State = EntityState.Modified; await db.SaveChangesAsync(); return(RedirectToAction("Index")); } return(View(order)); }
public async Task <ActionResult> Edit([Bind(Include = "Id,Name")] Category category) { if (ModelState.IsValid) { db.Entry(category).State = EntityState.Modified; await db.SaveChangesAsync(); return(RedirectToAction("Index")); } return(View(category)); }