| | |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import javax.validation.Valid; |
| | | import java.util.ArrayList; |
| | | import java.util.Arrays; |
| | | import java.util.List; |
| | | import java.util.stream.Collectors; |
| | | |
| | | /** |
| | | * <p> |
| | |
| | | } |
| | | |
| | | /** |
| | | * 根据ID查询运维用户信息 |
| | | * @return 用户列表 |
| | | */ |
| | | @GetMapping("/logan/inner/xpOperationsUser/queryByIds") |
| | | R<List<XpOperationsUser>> queryByIds(@RequestParam String operationsUserId) { |
| | | List<Long> ids = Arrays.stream(operationsUserId.split(",")) |
| | | .map(Long::parseLong) |
| | | .collect(Collectors.toList()); |
| | | List<XpOperationsUser> operationsUser = xpOperationsUserService.listByIds(ids); |
| | | for (XpOperationsUser xpOperationsUser : operationsUser) { |
| | | XpOperationsRole role = xpOperationsRoleMapper.selectOne(new QueryWrapper<XpOperationsRole>().eq("operations_user_id", xpOperationsUser.getId())); |
| | | SysRole sysRole = sysRoleService.getById(role.getRoleId()); |
| | | xpOperationsUser.setRoleName(sysRole.getRoleName()); |
| | | xpOperationsUser.setPhoneNumber(SensitiveDataCryptoUtil.decryptIfPossible(xpOperationsUser.getPhoneNumber())); |
| | | } |
| | | |
| | | return R.ok(operationsUser); |
| | | } |
| | | |
| | | /** |
| | | * 根据昵称查询运维用户信息 |
| | | * |
| | | * @param nickName 昵称 |