コード例 #1
0
 public IActionResult Create(CreateRoleVM roleVM)
 {
     if (ModelState.IsValid)
     {
         _roles.Create(roleVM.CreateRole());
         return(RedirectToAction("Index"));
     }
     return(View(roleVM));
 }
コード例 #2
0
 public IActionResult Create(CreateRoleVM role)
 {
     if (ModelState.IsValid)
     {
         _roles.Create(role.CreateRole());
         return(RedirectToAction("PersonProjectIndex", "ProjectRole"));
     }
     return(View());
 }
コード例 #3
0
 public IActionResult Create(CreateRoleVM rolevm)
 {
     if (ModelState.IsValid)
     {
         Role role = rolevm.CreateRole();
         _roles.Create(role);
         return(RedirectToAction("Index"));
     }
     return(View());
 }