public ActionResult DeleteConfirmed(int id) { IlceDetay ilce = _ilceService.GetDetayById(id); _ilceService.Delete(id); return(RedirectToAction("Index")); }
// GET: EczaneNobet/Ilce/Details/5 public ActionResult Details(int id) { if (id < 0) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } IlceDetay ilce = _ilceService.GetDetayById(id); if (ilce == null) { return(HttpNotFound()); } return(View(ilce)); }
// GET: EczaneNobet/Ilce/Edit/5 public ActionResult Edit(int id) { if (id < 0) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } IlceDetay ilce = _ilceService.GetDetayById(id); if (ilce == null) { return(HttpNotFound()); } ViewBag.SehirId = new SelectList(_sehirService.GetList(), "Id", "Adi", ilce.SehirId); return(View(ilce)); }