public ActionResult Supprimer(int id) { RoleServiceAPI rsa = new RoleServiceAPI(); RoleSuppression r = new RoleSuppression(rsa.Donner(id)); return(View(r)); }
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")); }