| | |
| | | * @return |
| | | */ |
| | | public List<String> getOwnerUserIds() { |
| | | String userName = SecurityUtils.getSysUser().getUsername(); |
| | | User user = userService.findByUserName(userName); |
| | | if (userName.equals("admin")){ |
| | | return null; |
| | | } |
| | | List<String> checked_list = userRecomService. |
| | | findChildren(user.getUserId()); |
| | | if (checkAgent()) { |
| | | if (checked_list.size() > 0) { |
| | | return checked_list; |
| | | } else { |
| | | checked_list.add(userName); |
| | | return checked_list; |
| | | } |
| | | } else { |
| | | return null; |
| | | } |
| | | // String userName = SecurityUtils.getSysUser().getUsername(); |
| | | // User user = userService.findByUserName(userName); |
| | | // if (userName.equals("admin")){ |
| | | // return null; |
| | | // } |
| | | // List<String> checked_list = userRecomService. |
| | | // findChildren(user.getUserId()); |
| | | // if (checkAgent()) { |
| | | // if (checked_list.size() > 0) { |
| | | // return checked_list; |
| | | // } else { |
| | | // checked_list.add(userName); |
| | | // return checked_list; |
| | | // } |
| | | // } else { |
| | | // return null; |
| | | // } |
| | | |
| | | return null; |
| | | // if (CollectionUtil.isNotEmpty(roleNames) && roleNames.contains(Constants.SECURITY_ROLE_AGENT)) { |
| | | // List<String> children = this.userRecomService.findChildren(userId.toString()); |
| | | // if (CollectionUtil.isEmpty(children)) { |