예제 #1
0
        public IActionResult GetAllUsersWithRoles()
        {
            AdminDataAccess        adm   = new AdminDataAccess();
            List <UserPositionDTO> users = adm.GetUsersWithRoles();

            if (users == null)
            {
                return(BadRequest("Неверный запрос"));
            }
            UserMapper mapper = new UserMapper();

            return(Ok(mapper.ConvertUserPositionDTOsToUserWithRolesOutputModels(users)));
        }