| | |
| | | public List<UserWorkspaceVo> findUserWorkspace(Map<String, Object> resJsonData, |
| | | UserWorkspaceCondition condition, Pageable pageable) { |
| | | |
| | | UserWorkspace userWorkspace = this.findMyWorkspace(this.webAppUtil.getLoginId()); //로그인한 아이디 |
| | | UserWorkspace userWorkspace = this.findMyWorkspace(this.webAppUtil.getLoginId()); |
| | | Workspace myWorkspace = userWorkspace.getWorkspace(); |
| | | condition.setPage(pageable.getPageNumber() * pageable.getPageSize()); |
| | | condition.setPageSize(pageable.getPageSize()); |
| | | condition.setWorkspaceId(myWorkspace.getId()); |
| | | condition.setAccount(CommonUtil.encryptAES128(condition.getAccount())); |
| | | condition.setAccount(CommonUtil.encryptAES128(condition.getAccount())); //계정 암호화(필수 동작) |
| | | |
| | | List<Map<String, Object>> results = this.userWorkspaceMapper.find(condition); |
| | | Long totalCount = this.userWorkspaceMapper.count(condition); |
| | | int totalPage = (int) Math.ceil((totalCount - 1) / pageable.getPageSize()) + 1; |
| | | List<UserWorkspaceVo> userWorkspaceVos = ConvertUtil.convertListToListClass(results, UserWorkspaceVo.class); |
| | | List<UserWorkspaceVo> userWorkspaceVos = ConvertUtil.convertListToListClass(results, UserWorkspaceVo.class); //UserWorkspace의 데이터를 리스트 형식으로 복사해서 UserWorkspaceVo에 담기 |
| | | |
| | | for (UserWorkspaceVo userWorkspaceVo : userWorkspaceVos) { |
| | | userWorkspaceVo.setAccount(CommonUtil.decryptAES128(userWorkspaceVo.getAccount())); |