コード例 #1
0
        public ActionResult Delete(SportsSide.DAL.AREA area)
        {
            var result = webApi.DeleteArea(area);

            if (result == false)
            {
                TempData["Hata"] = "Bir hata oluştu.";
                return(View(area));
            }
            return(RedirectToAction("Index", "Areas"));
        }
コード例 #2
0
        public ActionResult Edit(SportsSide.DAL.AREA model)
        {
            if (!ModelState.IsValid)
            {
                return(View(model));
            }
            var result = webApi.PutArea(model);

            if (result == false)
            {
                TempData["Hata"] = "Bir hata oluştu.";
                return(View(model));
            }
            return(RedirectToAction("Index", "Areas"));
        }