public ActionResult DeleteConfirmed(byte id) { AttribteValueType attribteValueType = db.AttribteValueTypes.Find(id); db.AttribteValueTypes.Remove(attribteValueType); db.SaveChanges(); return(RedirectToAction("Index")); }
public ActionResult Edit([Bind(Include = "attributeValueTypeID,valueType")] AttribteValueType attribteValueType) { if (ModelState.IsValid) { db.Entry(attribteValueType).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(attribteValueType)); }
public ActionResult Create([Bind(Include = "attributeValueTypeID,valueType")] AttribteValueType attribteValueType) { if (ModelState.IsValid) { db.AttribteValueTypes.Add(attribteValueType); db.SaveChanges(); return(RedirectToAction("Index")); } return(View(attribteValueType)); }
// GET: AttribteValueType/Edit/5 public ActionResult Edit(byte?id) { if (id == null) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } AttribteValueType attribteValueType = db.AttribteValueTypes.Find(id); if (attribteValueType == null) { return(HttpNotFound()); } return(View(attribteValueType)); }