public ActionResult DeleteConfirmed(int id) { EnYeniGelenler enYeniGelenler = db.EnYeniGelenler.Find(id); db.EnYeniGelenler.Remove(enYeniGelenler); db.SaveChanges(); return(RedirectToAction("Index")); }
public ActionResult Edit([Bind(Include = "id,YeniGelenKitapAdı,KitapResmi,Yazarı,Özeti,Fiyatı")] EnYeniGelenler enYeniGelenler) { if (ModelState.IsValid) { db.Entry(enYeniGelenler).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(enYeniGelenler)); }
public ActionResult Create([Bind(Include = "id,YeniGelenKitapAdı,KitapResmi,Yazarı,Özeti,Fiyatı")] EnYeniGelenler enYeniGelenler) { if (ModelState.IsValid) { db.EnYeniGelenler.Add(enYeniGelenler); db.SaveChanges(); return(RedirectToAction("Index")); } return(View(enYeniGelenler)); }
// GET: EnYeniGelenler/Delete/5 public ActionResult Delete(int?id) { if (id == null) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } EnYeniGelenler enYeniGelenler = db.EnYeniGelenler.Find(id); if (enYeniGelenler == null) { return(HttpNotFound()); } return(View(enYeniGelenler)); }