Commit f424dbbc authored by hongguangwu's avatar hongguangwu

MVP1.7.2 工行5次提交_加日志

parent 38489a1d
...@@ -49,11 +49,28 @@ public class EkpBankIcbcLog { ...@@ -49,11 +49,28 @@ public class EkpBankIcbcLog {
/** /**
* 批次号 * 批次号
*/ */
@ExcelAttribute(name = "批次号", maxLength = 36) @ExcelAttribute(name = "批次号", maxLength = 50)
@Length(max = 36, message = "批次号不能超过36个字符") @Length(max = 50, message = "批次号不能超过50个字符")
@ExcelProperty("批次号") @ExcelProperty("批次号")
@Schema(description = "批次号") @Schema(description = "批次号")
private String fdWxNo; private String fdWxNo;
/**
* 关联ID
*/
@ExcelAttribute(name = "关联ID", maxLength = 36)
@Length(max = 36, message = "关联ID不能超过36个字符")
@ExcelProperty("关联ID")
@Schema(description = "关联ID")
private String fdParentId;
/**
* 类型
*/
@ExcelAttribute(name = "类型", maxLength = 1)
@Length(max = 36, message = "类型不能超过1个字符")
@ExcelProperty("类型")
@Schema(description = "类型:1:提交;2:获取结果")
private Integer fdType;
/** /**
* 日志 * 日志
*/ */
......
...@@ -710,6 +710,8 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn ...@@ -710,6 +710,8 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn
String mdCode = main.getFdMdCode(); String mdCode = main.getFdMdCode();
R<String> returnR = submitIcbcTransactionFlow(totalAmt, totalCount, wxNo, url, mdCode); R<String> returnR = submitIcbcTransactionFlow(totalAmt, totalCount, wxNo, url, mdCode);
if (returnR.getCode() == CommonConstants.SUCCESS) { if (returnR.getCode() == CommonConstants.SUCCESS) {
// 存储日志
saveIcbcLogBaseInfoBySumbit(returnR.getData(), wxNo + "_main", fdId);
// 发放次数+1,改主表或明细表“发放状态”为“发放中” // 发放次数+1,改主表或明细表“发放状态”为“发放中”
main.setFdGrantStatus("发放中"); main.setFdGrantStatus("发放中");
main.setFdGrantNum(main.getFdGrantNum() + 1); main.setFdGrantNum(main.getFdGrantNum() + 1);
...@@ -747,6 +749,8 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn ...@@ -747,6 +749,8 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn
String mdCode = detail.getFdMdCode(); String mdCode = detail.getFdMdCode();
R<String> returnR = submitIcbcTransactionFlow(totalAmt, totalCount, wxNo, url, mdCode); R<String> returnR = submitIcbcTransactionFlow(totalAmt, totalCount, wxNo, url, mdCode);
if (returnR.getCode() == CommonConstants.SUCCESS) { if (returnR.getCode() == CommonConstants.SUCCESS) {
// 存储日志
saveIcbcLogBaseInfoBySumbit(returnR.getData(), wxNo, fdId);
// 发放次数+1,改主表或明细表“发放状态”为“发放中” // 发放次数+1,改主表或明细表“发放状态”为“发放中”
detail.setFdHandleStatus("发放中"); detail.setFdHandleStatus("发放中");
detail.setFdGrantNum(detail.getFdGrantNum() + 1); detail.setFdGrantNum(detail.getFdGrantNum() + 1);
...@@ -816,7 +820,7 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn ...@@ -816,7 +820,7 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn
responseV1 = selectIcbcTransactionFlowInfo(vo.getFdWxNo(), String.valueOf(startNum), String.valueOf(endNum)); responseV1 = selectIcbcTransactionFlowInfo(vo.getFdWxNo(), String.valueOf(startNum), String.valueOf(endNum));
if (Common.isNotNull(responseV1)) { if (Common.isNotNull(responseV1)) {
// 生成工行接口数据记录 // 生成工行接口数据记录
setIcbcLogBaseInfo(responseV1, icbcLogList, vo.getFdWxNo() + "_" + startNum + "_" + endNum); setIcbcLogBaseInfo(responseV1, icbcLogList, vo.getFdWxNo() + "_" + startNum + "_" + endNum, vo.getFdId());
// 返回码,交易成功返回0,正表示业务报错,负表示系统报错 // 返回码,交易成功返回0,正表示业务报错,负表示系统报错
if ("0".equals(responseV1.getReturn_code())) { if ("0".equals(responseV1.getReturn_code())) {
// 处理状态: 00-待提交,01-已提交 02-待授权 03-待银行处理, 04-处理成功,05-处理失败 // 处理状态: 00-待提交,01-已提交 02-待授权 03-待银行处理, 04-处理成功,05-处理失败
...@@ -935,7 +939,7 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn ...@@ -935,7 +939,7 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn
responseV1 = selectIcbcTransactionFlowInfo(vo.getFdWxNo(), "0", "1"); responseV1 = selectIcbcTransactionFlowInfo(vo.getFdWxNo(), "0", "1");
if (Common.isNotNull(responseV1)) { if (Common.isNotNull(responseV1)) {
// 生成工行接口数据记录 // 生成工行接口数据记录
setIcbcLogBaseInfo(responseV1, icbcLogList, vo.getFdWxNo()); setIcbcLogBaseInfo(responseV1, icbcLogList, vo.getFdWxNo(), vo.getFdId());
// Return_code返回码,交易成功返回0,正表示业务报错,负表示系统报错 // Return_code返回码,交易成功返回0,正表示业务报错,负表示系统报错
// Status处理状态: 00-待提交,01-已提交 02-待授权 03-待银行处理, 04-处理成功,05-处理失败 // Status处理状态: 00-待提交,01-已提交 02-待授权 03-待银行处理, 04-处理成功,05-处理失败
if ("0".equals(responseV1.getReturn_code()) && "04".equals(responseV1.getStatus()) if ("0".equals(responseV1.getReturn_code()) && "04".equals(responseV1.getStatus())
...@@ -1006,10 +1010,36 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn ...@@ -1006,10 +1010,36 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn
return R.ok(); return R.ok();
} }
private void setIcbcLogBaseInfo(JftApiPayrollQueryDetailResponseV1 responseV1, List<EkpBankIcbcLog> icbcLogList, String fdWxNo) { /**
* @Description: 发放记录日志
* @Author: hgw
* @Date: 2024/11/27 17:36
* @return: void
**/
private void saveIcbcLogBaseInfoBySumbit(String info
, String fdWxNo, String fdId) {
EkpBankIcbcLog icbcLog = new EkpBankIcbcLog();
icbcLog.setFdCreateTime(LocalDateTime.now());
icbcLog.setFdWxNo(fdWxNo);
icbcLog.setFdParentId(fdId);
icbcLog.setFdType(1);
icbcLog.setFdLog(info);
ekpBankIcbcLogService.save(icbcLog);
}
/**
* @Description: 获取结果记录入职
* @Author: hgw
* @Date: 2024/11/27 17:36
* @return: void
**/
private void setIcbcLogBaseInfo(JftApiPayrollQueryDetailResponseV1 responseV1, List<EkpBankIcbcLog> icbcLogList
, String fdWxNo, String fdId) {
EkpBankIcbcLog icbcLog = new EkpBankIcbcLog(); EkpBankIcbcLog icbcLog = new EkpBankIcbcLog();
icbcLog.setFdCreateTime(LocalDateTime.now()); icbcLog.setFdCreateTime(LocalDateTime.now());
icbcLog.setFdWxNo(fdWxNo); icbcLog.setFdWxNo(fdWxNo);
icbcLog.setFdParentId(fdId);
icbcLog.setFdType(2);
icbcLog.setFdLog(JSON.toJSONString(responseV1)); icbcLog.setFdLog(JSON.toJSONString(responseV1));
icbcLogList.add(icbcLog); icbcLogList.add(icbcLog);
} }
......
...@@ -27,12 +27,16 @@ ...@@ -27,12 +27,16 @@
<id property="fdId" column="fd_id"/> <id property="fdId" column="fd_id"/>
<result property="fdWxNo" column="fd_wx_no"/> <result property="fdWxNo" column="fd_wx_no"/>
<result property="fdLog" column="fd_log"/> <result property="fdLog" column="fd_log"/>
<result property="fdParentId" column="fd_parent_id"/>
<result property="fdType" column="fd_type"/>
<result property="fdCreateTime" column="fd_create_time"/> <result property="fdCreateTime" column="fd_create_time"/>
</resultMap> </resultMap>
<sql id="Base_Column_List"> <sql id="Base_Column_List">
a.fd_id, a.fd_id,
a.fd_wx_no, a.fd_wx_no,
a.fd_log, a.fd_log,
a.fd_parent_id,
a.fd_type,
a.fd_create_time a.fd_create_time
</sql> </sql>
......
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