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