public ActionResult Delete(int roleId) { var model = new RoleDeleteVM { Roles = _roleService.GetById(roleId), Employees = _employeeService.GetAll() }; return(View(model)); }
//Show role to delete public IActionResult Delete(int id) { var role = _roles.Read(id); if (role == null) { return(RedirectToAction("Index")); } RoleDeleteVM rdm = new RoleDeleteVM { Id = role.Id, Name = role.Name, Description = role.Description }; return(View(rdm)); }