예제 #1
0
        public ActionResult Delete(int id)
        {
            if (id == 0)
            {
                TempData["Danger"] = "Passed Number not valid";
                return(View());
            }
            try
            {
                _setupService.DeleteRole(id);

                TempData["Success"] = "Deleted Successfully !!";
            }
            catch (Exception e)
            {
                TempData["Danger"] = e.Message;
            }

            return(RedirectToAction("Index"));
        }