예제 #1
0
        public ActionResult Supprimer(int id)
        {
            RoleServiceAPI  rsa = new RoleServiceAPI();
            RoleSuppression r   = new RoleSuppression(rsa.Donner(id));

            return(View(r));
        }
예제 #2
0
        public ActionResult Supprimer(int id, RoleSuppression r)
        {
            RoleServiceAPI  rsa = new RoleServiceAPI();
            RoleSuppression rr  = new RoleSuppression(rsa.Donner(id));

            if (ModelState.IsValid)
            {
                //RoleServiceAPI rsa = new RoleServiceAPI();
                bool b = rsa.Supprimer(id);
                if (b)
                {
                    return(RedirectToAction("Index"));
                }
            }
            return(View("Error"));
        }