mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/per-boe/java-servers.git
synced 2025-12-09 02:46:50 +08:00
UserInfoList departId 类型更改
This commit is contained in:
@@ -32,7 +32,7 @@ public class ThirdApi {
|
||||
private String searchUserListUrl;
|
||||
|
||||
|
||||
public List<UserInfoList> getAllUserList(UserListParam userListParam, String token) {
|
||||
public List<UserInfoListVo> getAllUserList(UserListParam userListParam, String token) {
|
||||
log.info("获取用户");
|
||||
String resp = Optional.ofNullable(HttpRequest.post(searchUserListUrl).body(JSONUtil.toJsonStr(userListParam)).header("token", token).execute().body()).orElseThrow(() -> new RuntimeException("token校验失败"));
|
||||
log.info("获取用户返回值1 {}",resp);
|
||||
@@ -42,7 +42,7 @@ public class ThirdApi {
|
||||
.orElse(ListUtil.toList());
|
||||
}
|
||||
|
||||
private void getAllUserList(UserListParam userListParam, String token, List<UserInfoList> userInfoLists) {
|
||||
private void getAllUserList(UserListParam userListParam, String token, List<UserInfoListVo> userInfoLists) {
|
||||
log.info("获取用户2");
|
||||
String resp = Optional.ofNullable(HttpRequest.post(searchUserListUrl).body(JSONUtil.toJsonStr(userListParam)).header("token", token).execute().body()).orElseThrow(() -> new RuntimeException("token校验失败"));
|
||||
log.info("获取用户返回值2 {}",resp);
|
||||
@@ -50,7 +50,7 @@ public class ThirdApi {
|
||||
}
|
||||
|
||||
|
||||
private void nextPage(UserListParam userListParam, String token, List<UserInfoList> userInfoLists, UserInfoListRootBean.ResultData t) {
|
||||
private void nextPage(UserListParam userListParam, String token, List<UserInfoListVo> userInfoLists, UserInfoListRootBean.ResultData t) {
|
||||
log.info("获取用户--" + userListParam.getPageNo());
|
||||
if (t.getTotalPage() > userListParam.getPageNo()) {
|
||||
REQUEST_TASK.submit(() -> IntStream.range(userListParam.getPageNo(), t.getTotalPage()).parallel().forEach(i -> getAllUserList(userListParam.withPageNo(i + 1), token, userInfoLists))).join();
|
||||
|
||||
@@ -31,7 +31,7 @@ public class UserInfoListRootBean {
|
||||
|
||||
private int totalElement;
|
||||
private int totalPage;
|
||||
private List<UserInfoList> userInfoList;
|
||||
private List<UserInfoListVo> userInfoList;
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,41 @@
|
||||
package com.xboe.api.vo;
|
||||
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
@Data
|
||||
public class UserInfoListVo {
|
||||
|
||||
private long id;
|
||||
private String bandCode;
|
||||
private String bandDesc;
|
||||
private Boolean deleted;
|
||||
private String departId;
|
||||
private String description;
|
||||
private String domainId;
|
||||
private String departName;
|
||||
private String duty;
|
||||
private int employeeStatus;
|
||||
private String companyId;
|
||||
private String orgName;
|
||||
private Integer gender;
|
||||
private String jobName;
|
||||
private String kid;
|
||||
private int learningDuration;
|
||||
private String mobile;
|
||||
private String realName;
|
||||
private String oldDepartId;
|
||||
private String orgNamePath;
|
||||
private String orgTreeType;
|
||||
private String payrollPlaceId;
|
||||
private String payrollPlaceName;
|
||||
private long personId;
|
||||
private String positionMgrLevel;
|
||||
private String rank;
|
||||
private long sassId;
|
||||
private int status;
|
||||
private String telephoneNo;
|
||||
private String userNo;
|
||||
private String email;
|
||||
private String avatar;
|
||||
}
|
||||
@@ -85,10 +85,10 @@ public class CasesRecommendPushRecordServiceImpl implements ICasesRecommendPushR
|
||||
long tt = System.currentTimeMillis();
|
||||
for (String orgId : casesRecommendLaunch.getDeptIds()) {
|
||||
UserListParam build = UserListParam.builder().departId(orgId).pageSize(100).build();
|
||||
List<UserInfoList> allUserList = thirdApi.getAllUserList(build, token);
|
||||
List<UserInfoListVo> allUserList = thirdApi.getAllUserList(build, token);
|
||||
log.info("---------组织查询 {}", allUserList);
|
||||
if (CollectionUtil.isNotEmpty(allUserList)) {
|
||||
for (UserInfoList userInfo : allUserList) {
|
||||
for (UserInfoListVo userInfo : allUserList) {
|
||||
log.info("---------userInfo.getId() {}", userInfo.getId());
|
||||
userIds.add(String.valueOf(userInfo.getId()));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user