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