Commit 5838e28f authored by hongguangwu's avatar hongguangwu

MVP1.7.3-shuiyou 增减接口

parent 5f9ce6f9
...@@ -65,7 +65,7 @@ public class TSocialFriendBackLog { ...@@ -65,7 +65,7 @@ public class TSocialFriendBackLog {
@ExcelAttribute(name = "类型") @ExcelAttribute(name = "类型")
@ExcelProperty("类型") @ExcelProperty("类型")
@Schema(description = "类型") @Schema(description = "类型1社保增 2社保减 3医保增 4医保减 5推送的日志")
private Integer type; private Integer type;
/** /**
......
...@@ -74,7 +74,7 @@ public class SocialFriendConfig { ...@@ -74,7 +74,7 @@ public class SocialFriendConfig {
* @return: java.lang.String * @return: java.lang.String
**/ **/
public String pushFriendByInfo(RestTemplate restTemplate, SociaFriendYgsAddVo vo, int type, String thisTime public String pushFriendByInfo(RestTemplate restTemplate, SociaFriendYgsAddVo vo, int type, String thisTime
, TSocialFriendBackLog backLog) { , List<TSocialFriendBackLog> backLogList) {
String addId = ""; String addId = "";
String appAddUrl = urlPre; String appAddUrl = urlPre;
if (type == 1 || type == 3) { if (type == 1 || type == 3) {
...@@ -139,11 +139,21 @@ public class SocialFriendConfig { ...@@ -139,11 +139,21 @@ public class SocialFriendConfig {
setEmpInfo(json, vo, type); setEmpInfo(json, vo, type);
HttpEntity<String> formEntity = new HttpEntity<>(json.toString(), headers); HttpEntity<String> formEntity = new HttpEntity<>(json.toString(), headers);
System.out.println("推的接送=" + json); // 推的json
TSocialFriendBackLog backLog = new TSocialFriendBackLog();
backLog.setSocialId(vo.getSocialId());
backLog.setType(5);
backLog.setLogInfo(json.toString());
backLog.setCreateTime(LocalDateTime.now());
backLogList.add(backLog);
String dataResultList = restTemplate.postForObject(appAddUrl, formEntity, String.class); String dataResultList = restTemplate.postForObject(appAddUrl, formEntity, String.class);
// {"head":{"code":"00000000","description":"成功","msg":"成功","time":"2024-12-06 17:10:26","status":"Y" // {"head":{"code":"00000000","description":"成功","msg":"成功","time":"2024-12-06 17:10:26","status":"Y"
// ,"body":{"requestId":"85440b327d71466abcd9c5c81d5bb172" // ,"body":{"requestId":"85440b327d71466abcd9c5c81d5bb172"
if (Common.isNotNull(dataResultList)) { if (Common.isNotNull(dataResultList)) {
// 拉取的数据日志
backLog = new TSocialFriendBackLog();
backLog.setSocialId(vo.getSocialId());
backLog.setType(type);
backLog.setLogInfo(dataResultList); backLog.setLogInfo(dataResultList);
backLog.setCreateTime(LocalDateTime.now()); backLog.setCreateTime(LocalDateTime.now());
JSONObject dataObject = JSON.parseObject(dataResultList); JSONObject dataObject = JSON.parseObject(dataResultList);
...@@ -155,8 +165,10 @@ public class SocialFriendConfig { ...@@ -155,8 +165,10 @@ public class SocialFriendConfig {
String body = dataObject.getString("body"); String body = dataObject.getString("body");
JSONObject bodyObject = JSON.parseObject(body); JSONObject bodyObject = JSON.parseObject(body);
addId = bodyObject.getString("requestId"); addId = bodyObject.getString("requestId");
backLog.setRequestId(addId);
} }
} }
backLogList.add(backLog);
} }
return addId; return addId;
} }
......
...@@ -60,9 +60,9 @@ public interface TSocialSoldierLogService extends IService<TSocialSoldierLog> { ...@@ -60,9 +60,9 @@ public interface TSocialSoldierLogService extends IService<TSocialSoldierLog> {
TSocialSoldierLog getYsdSoldierLog(SocialSoldierYsdAddVo vo, String type, String remark); TSocialSoldierLog getYsdSoldierLog(SocialSoldierYsdAddVo vo, String type, String remark);
// 社保提交日志-税友 // 社保提交日志-税友
TSocialSoldierLog getYgsFriendLog(SociaFriendYgsAddVo vo, String type, String remark); TSocialSoldierLog getFriendLog(SociaFriendYgsAddVo vo, String type, String dispatchItem, String remark);
// 医保提交日志-税友 // 拉取提交结果日志 dispatchItem 社保、医保
TSocialSoldierLog getYsdFriendLog(SociaFriendYgsAddVo vo, String type, String remark); TSocialSoldierLog getSocialFriendLog(TSocialInfo social, String type, String dispatchItem, String remark);
// 审核社保提交日志 // 审核社保提交日志
TSocialSoldierLog getYgsSoldierAuditLog(SocialSoldierYgsAuditVo vo, String type, String remark); TSocialSoldierLog getYgsSoldierAuditLog(SocialSoldierYgsAuditVo vo, String type, String remark);
......
...@@ -236,7 +236,7 @@ public class TSocialFriendServiceImpl extends ServiceImpl<TSocialFriendMapper, T ...@@ -236,7 +236,7 @@ public class TSocialFriendServiceImpl extends ServiceImpl<TSocialFriendMapper, T
updateSocial.setYgsHandleStatus(ygsHandleStatus); updateSocial.setYgsHandleStatus(ygsHandleStatus);
// 拉取审核结果,加日志 // 拉取审核结果,加日志
if (Common.isNotNull(ygsHandleStatus)) { if (Common.isNotNull(ygsHandleStatus)) {
socialLog = tSocialSoldierLogService.getSocialSoldierLog(socialInfo, "提交", "社保" socialLog = tSocialSoldierLogService.getSocialFriendLog(socialInfo, "提交", "社保"
, getStatusName(Integer.parseInt(ygsHandleStatus))); , getStatusName(Integer.parseInt(ygsHandleStatus)));
tSocialSoldierLogService.save(socialLog); tSocialSoldierLogService.save(socialLog);
} }
...@@ -309,7 +309,7 @@ public class TSocialFriendServiceImpl extends ServiceImpl<TSocialFriendMapper, T ...@@ -309,7 +309,7 @@ public class TSocialFriendServiceImpl extends ServiceImpl<TSocialFriendMapper, T
// 拉取审核结果,加日志 // 拉取审核结果,加日志
if (Common.isNotNull(ysdHandleStatus)) { if (Common.isNotNull(ysdHandleStatus)) {
socialLog = tSocialSoldierLogService.getSocialSoldierLog(socialInfo, "提交", "医保" socialLog = tSocialSoldierLogService.getSocialFriendLog(socialInfo, "提交", "医保"
, getStatusName(Integer.parseInt(ysdHandleStatus))); , getStatusName(Integer.parseInt(ysdHandleStatus)));
tSocialSoldierLogService.save(socialLog); tSocialSoldierLogService.save(socialLog);
} }
......
...@@ -165,26 +165,26 @@ public class TSocialSoldierLogServiceImpl extends ServiceImpl<TSocialSoldierLogM ...@@ -165,26 +165,26 @@ public class TSocialSoldierLogServiceImpl extends ServiceImpl<TSocialSoldierLogM
} }
@Override @Override
public TSocialSoldierLog getYgsFriendLog(SociaFriendYgsAddVo vo, String type, String remark) { public TSocialSoldierLog getFriendLog(SociaFriendYgsAddVo vo, String type, String dispatchItem, String remark) {
TSocialSoldierLog log = new TSocialSoldierLog(); TSocialSoldierLog log = new TSocialSoldierLog();
log.setSocialId(vo.getSocialId()); log.setSocialId(vo.getSocialId());
log.setEmpName(vo.getEmpName()); log.setEmpName(vo.getEmpName());
log.setEmpIdcard(vo.getEmpIdcard()); log.setEmpIdcard(vo.getEmpIdcard());
log.setDispatchItem("社保"); log.setDispatchItem(dispatchItem);
log.setSocialHuName(vo.getSocialHouseholdName()); log.setSocialHuName(vo.getSocialHouseholdName());
// type 类型:提交;审核 // type 类型:提交;审核
log.setType(type); log.setType(type);
log.setRemark(remark); log.setRemark("【税友】" + remark);
return log; return log;
} }
@Override @Override
public TSocialSoldierLog getYsdFriendLog(SociaFriendYgsAddVo vo, String type, String remark) { public TSocialSoldierLog getYgsSoldierAuditLog(SocialSoldierYgsAuditVo vo, String type, String remark) {
TSocialSoldierLog log = new TSocialSoldierLog(); TSocialSoldierLog log = new TSocialSoldierLog();
log.setSocialId(vo.getSocialId()); log.setSocialId(vo.getSocialId());
log.setEmpName(vo.getEmpName()); log.setEmpName(vo.getEmpName());
log.setEmpIdcard(vo.getEmpIdcard()); log.setEmpIdcard(vo.getEmpIdcard());
log.setDispatchItem("保"); log.setDispatchItem("保");
log.setSocialHuName(vo.getSocialHouseholdName()); log.setSocialHuName(vo.getSocialHouseholdName());
// type 类型:提交;审核 // type 类型:提交;审核
log.setType(type); log.setType(type);
...@@ -193,12 +193,12 @@ public class TSocialSoldierLogServiceImpl extends ServiceImpl<TSocialSoldierLogM ...@@ -193,12 +193,12 @@ public class TSocialSoldierLogServiceImpl extends ServiceImpl<TSocialSoldierLogM
} }
@Override @Override
public TSocialSoldierLog getYgsSoldierAuditLog(SocialSoldierYgsAuditVo vo, String type, String remark) { public TSocialSoldierLog getYsdSoldierAuditLog(SocialSoldierYsdAuditVo vo, String type, String remark) {
TSocialSoldierLog log = new TSocialSoldierLog(); TSocialSoldierLog log = new TSocialSoldierLog();
log.setSocialId(vo.getSocialId()); log.setSocialId(vo.getSocialId());
log.setEmpName(vo.getEmpName()); log.setEmpName(vo.getEmpName());
log.setEmpIdcard(vo.getEmpIdcard()); log.setEmpIdcard(vo.getEmpIdcard());
log.setDispatchItem("保"); log.setDispatchItem("保");
log.setSocialHuName(vo.getSocialHouseholdName()); log.setSocialHuName(vo.getSocialHouseholdName());
// type 类型:提交;审核 // type 类型:提交;审核
log.setType(type); log.setType(type);
...@@ -207,16 +207,16 @@ public class TSocialSoldierLogServiceImpl extends ServiceImpl<TSocialSoldierLogM ...@@ -207,16 +207,16 @@ public class TSocialSoldierLogServiceImpl extends ServiceImpl<TSocialSoldierLogM
} }
@Override @Override
public TSocialSoldierLog getYsdSoldierAuditLog(SocialSoldierYsdAuditVo vo, String type, String remark) { public TSocialSoldierLog getSocialFriendLog(TSocialInfo social, String type, String dispatchItem, String remark) {
TSocialSoldierLog log = new TSocialSoldierLog(); TSocialSoldierLog log = new TSocialSoldierLog();
log.setSocialId(vo.getSocialId()); log.setSocialId(social.getId());
log.setEmpName(vo.getEmpName()); log.setEmpName(social.getEmpName());
log.setEmpIdcard(vo.getEmpIdcard()); log.setEmpIdcard(social.getEmpIdcard());
log.setDispatchItem("医保"); log.setDispatchItem(dispatchItem);
log.setSocialHuName(vo.getSocialHouseholdName()); log.setSocialHuName(social.getSocialHouseholdName());
// type 类型:提交;审核 // type 类型:提交;审核
log.setType(type); log.setType(type);
log.setRemark(remark); log.setRemark("【税友】" + remark);
return log; return log;
} }
......
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