Commit c160d32c authored by hongguangwu's avatar hongguangwu

MVP1.7.7-friend-改为批量

parent 526b225b
...@@ -65,7 +65,7 @@ public class TSocialFriendBackLog { ...@@ -65,7 +65,7 @@ public class TSocialFriendBackLog {
@ExcelAttribute(name = "类型") @ExcelAttribute(name = "类型")
@ExcelProperty("类型") @ExcelProperty("类型")
@Schema(description = "类型1社保增 2社保减 3医保增 4医保减 5推送的日志 6社保图片路径7医保图片路径") @Schema(description = "类型1社保增 2社保减 3医保增 4医保减 5推送的日志 6社保图片路径7医保图片路径11社保增拉取 12社保减拉取 13医保增拉取 14医保减拉取")
private Integer type; private Integer type;
/** /**
......
...@@ -112,17 +112,18 @@ public class TSocialFriendServiceImpl extends ServiceImpl<TSocialFriendMapper, T ...@@ -112,17 +112,18 @@ public class TSocialFriendServiceImpl extends ServiceImpl<TSocialFriendMapper, T
logList = new ArrayList<>(); logList = new ArrayList<>();
resultMap = new HashMap<>(); resultMap = new HashMap<>();
for (TSocialInfo socialInfo : socialList) { for (TSocialInfo socialInfo : socialList) {
backLog = new TSocialFriendBackLog();
backLog.setSocialId(socialInfo.getId());
backLog.setRequestId(socialInfo.getYgsRequestId());
backLog.setType(1);
if (Common.isNotNull(socialInfo.getDispatchType()) && CommonConstants.ONE_STRING.equals(socialInfo.getDispatchType())) {
backLog.setType(2);
}
info = resultMap.get(socialInfo.getEmpIdcard()); info = resultMap.get(socialInfo.getEmpIdcard());
if (info == null) { if (info == null) {
backLog = new TSocialFriendBackLog();
backLog.setSocialId(socialInfo.getId());
backLog.setRequestId(socialInfo.getYgsRequestId());
backLog.setType(11);
if (Common.isNotNull(socialInfo.getDispatchType()) && CommonConstants.ONE_STRING.equals(socialInfo.getDispatchType())) {
backLog.setType(12);
}
resultList = socialFriendConfig.getFriendByRequestId(restTemplate, socialInfo.getYgsRequestId() resultList = socialFriendConfig.getFriendByRequestId(restTemplate, socialInfo.getYgsRequestId()
, backLog, socialInfo.getDispatchType()); , backLog, socialInfo.getDispatchType());
logList.add(backLog);
if (resultList != null && !resultList.isEmpty()) { if (resultList != null && !resultList.isEmpty()) {
for (FriendResult result : resultList) { for (FriendResult result : resultList) {
resultMap.put(result.getIdCard(), result); resultMap.put(result.getIdCard(), result);
...@@ -130,7 +131,6 @@ public class TSocialFriendServiceImpl extends ServiceImpl<TSocialFriendMapper, T ...@@ -130,7 +131,6 @@ public class TSocialFriendServiceImpl extends ServiceImpl<TSocialFriendMapper, T
info = resultMap.get(socialInfo.getEmpIdcard()); info = resultMap.get(socialInfo.getEmpIdcard());
} }
} }
logList.add(backLog);
if (info != null && Common.isNotNull(info.getZt())) { if (info != null && Common.isNotNull(info.getZt())) {
doCore(info, socialInfo, typeFlag, user, errorMap); doCore(info, socialInfo, typeFlag, user, errorMap);
} }
...@@ -146,15 +146,15 @@ public class TSocialFriendServiceImpl extends ServiceImpl<TSocialFriendMapper, T ...@@ -146,15 +146,15 @@ public class TSocialFriendServiceImpl extends ServiceImpl<TSocialFriendMapper, T
logList = new ArrayList<>(); logList = new ArrayList<>();
resultMap = new HashMap<>(); resultMap = new HashMap<>();
for (TSocialInfo socialInfo : socialYsdList) { for (TSocialInfo socialInfo : socialYsdList) {
backLog = new TSocialFriendBackLog();
backLog.setSocialId(socialInfo.getId());
backLog.setRequestId(socialInfo.getYsdRequestId());
backLog.setType(3);
if (Common.isNotNull(socialInfo.getDispatchType()) && CommonConstants.ONE_STRING.equals(socialInfo.getDispatchType())) {
backLog.setType(4);
}
info = resultMap.get(socialInfo.getEmpIdcard()); info = resultMap.get(socialInfo.getEmpIdcard());
if (info == null) { if (info == null) {
backLog = new TSocialFriendBackLog();
backLog.setSocialId(socialInfo.getId());
backLog.setRequestId(socialInfo.getYsdRequestId());
backLog.setType(13);
if (Common.isNotNull(socialInfo.getDispatchType()) && CommonConstants.ONE_STRING.equals(socialInfo.getDispatchType())) {
backLog.setType(14);
}
resultList = socialFriendConfig.getFriendByRequestId(restTemplate, socialInfo.getYsdRequestId() resultList = socialFriendConfig.getFriendByRequestId(restTemplate, socialInfo.getYsdRequestId()
, backLog, socialInfo.getDispatchType()); , backLog, socialInfo.getDispatchType());
if (resultList != null && !resultList.isEmpty()) { if (resultList != null && !resultList.isEmpty()) {
...@@ -163,8 +163,8 @@ public class TSocialFriendServiceImpl extends ServiceImpl<TSocialFriendMapper, T ...@@ -163,8 +163,8 @@ public class TSocialFriendServiceImpl extends ServiceImpl<TSocialFriendMapper, T
} }
info = resultMap.get(socialInfo.getEmpIdcard()); info = resultMap.get(socialInfo.getEmpIdcard());
} }
logList.add(backLog);
} }
logList.add(backLog);
if (info != null && Common.isNotNull(info.getZt())) { if (info != null && Common.isNotNull(info.getZt())) {
doCore(info, socialInfo, typeFlag, user, errorMap); doCore(info, socialInfo, typeFlag, user, errorMap);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment