public ActionResult DeleteConfirmed(int id) { Accessory3Colors accessory3Colors = db.Accessory3Colors.Find(id); db.Accessory3Colors.Remove(accessory3Colors); db.SaveChanges(); return(RedirectToAction("Index")); }
public ActionResult Edit([Bind(Include = "Accessory3ColorID,Accessory3ColorName")] Accessory3Colors accessory3Colors) { if (ModelState.IsValid) { db.Entry(accessory3Colors).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(accessory3Colors)); }
public ActionResult Create([Bind(Include = "Accessory3ColorID,Accessory3ColorName")] Accessory3Colors accessory3Colors) { if (ModelState.IsValid) { db.Accessory3Colors.Add(accessory3Colors); db.SaveChanges(); return(RedirectToAction("Index")); } return(View(accessory3Colors)); }
// GET: Accessory3Colors/Delete/5 public ActionResult Delete(int?id) { if (id == null) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } Accessory3Colors accessory3Colors = db.Accessory3Colors.Find(id); if (accessory3Colors == null) { return(HttpNotFound()); } return(View(accessory3Colors)); }