public ActionResult DeleteConfirmed(decimal id) { PARTXREF pARTXREF = db.PARTXREFs.Find(id); db.PARTXREFs.Remove(pARTXREF); db.SaveChanges(); return(RedirectToAction("Index")); }
public ActionResult Edit([Bind(Include = "ID,PARTNO,PlantID")] PARTXREF pARTXREF) { if (ModelState.IsValid) { db.Entry(pARTXREF).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(pARTXREF)); }
public ActionResult Create([Bind(Include = "ID,PARTNO,PlantID")] PARTXREF pARTXREF) { if (ModelState.IsValid) { db.PARTXREFs.Add(pARTXREF); db.SaveChanges(); return(RedirectToAction("Index")); } return(View(pARTXREF)); }
// GET: PARTXREFs/Delete/5 public ActionResult Delete(decimal id) { if (id == null) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } PARTXREF pARTXREF = db.PARTXREFs.Find(id); if (pARTXREF == null) { return(HttpNotFound()); } return(View(pARTXREF)); }