Commit fded883d authored by 陈宏杰's avatar 陈宏杰

A1重复报送问题

parent 5933e107
...@@ -3,6 +3,8 @@ package cn.quantgroup.report.mapper.master; ...@@ -3,6 +3,8 @@ package cn.quantgroup.report.mapper.master;
import cn.quantgroup.report.domain.baihang.ApplyLoanInfoZhuDai; import cn.quantgroup.report.domain.baihang.ApplyLoanInfoZhuDai;
import org.springframework.stereotype.Repository; import org.springframework.stereotype.Repository;
import java.util.List;
/** /**
* -----------------------------------------------------------------------------<br> * -----------------------------------------------------------------------------<br>
* 描述: 贷款申请信息 <br> * 描述: 贷款申请信息 <br>
...@@ -15,4 +17,6 @@ public interface ApplyLoanInfoZhuDaiMapper { ...@@ -15,4 +17,6 @@ public interface ApplyLoanInfoZhuDaiMapper {
void saveApplyLoanInfoZhuDaiLog(ApplyLoanInfoZhuDai applyLoanInfoZhuDai); void saveApplyLoanInfoZhuDaiLog(ApplyLoanInfoZhuDai applyLoanInfoZhuDai);
List<ApplyLoanInfoZhuDai> findApplyLoanInfoZhuDaiLog(String reqId);
} }
...@@ -128,9 +128,13 @@ public class BaiHangFileReportService { ...@@ -128,9 +128,13 @@ public class BaiHangFileReportService {
List<String> reportList = new ArrayList<>(); List<String> reportList = new ArrayList<>();
reportList.add("#applyInfo"); reportList.add("#applyInfo");
String reqId_log = ""; String reqId_log = "";
List<ApplyLoanInfoZhuDai> zhuDaiLogList = null;
for (int i = 0; i < applyLoanInfos.size(); i++) { for (int i = 0; i < applyLoanInfos.size(); i++) {
try { try {
ApplyLoanInfoZhuDai applyLoanInfo = applyLoanInfos.get(i); ApplyLoanInfoZhuDai applyLoanInfo = applyLoanInfos.get(i);
reqId_log = applyLoanInfo.getReqID();
zhuDaiLogList = applyLoanInfoZhuDaiMapper.findApplyLoanInfoZhuDaiLog(applyLoanInfo.getReqID());
if (CollectionUtils.isEmpty(zhuDaiLogList)) {
try { try {
ApplyLoanInfoZhuDai record = new ApplyLoanInfoZhuDai(); ApplyLoanInfoZhuDai record = new ApplyLoanInfoZhuDai();
BeanUtils.copyProperties(applyLoanInfo, record); BeanUtils.copyProperties(applyLoanInfo, record);
...@@ -139,7 +143,6 @@ public class BaiHangFileReportService { ...@@ -139,7 +143,6 @@ public class BaiHangFileReportService {
} catch (Exception e) { } catch (Exception e) {
log.error("量化派助贷TO百行报送(A1)-贷款申请信息保存记录失败", e); log.error("量化派助贷TO百行报送(A1)-贷款申请信息保存记录失败", e);
} }
reqId_log = applyLoanInfo.getReqID();
//邮箱有错误的就不传 //邮箱有错误的就不传
if (!TuoMinUtils.checkEmail(applyLoanInfo.getEmailAddress())) { if (!TuoMinUtils.checkEmail(applyLoanInfo.getEmailAddress())) {
applyLoanInfo.setEmailAddress(null); applyLoanInfo.setEmailAddress(null);
...@@ -149,6 +152,9 @@ public class BaiHangFileReportService { ...@@ -149,6 +152,9 @@ public class BaiHangFileReportService {
applyLoanInfo.setPid(sensitiveFilter(applyLoanInfo.getPid())); applyLoanInfo.setPid(sensitiveFilter(applyLoanInfo.getPid()));
reportList.add(JSON.toJSONString(applyLoanInfo)); reportList.add(JSON.toJSONString(applyLoanInfo));
atomicInteger.getAndIncrement(); atomicInteger.getAndIncrement();
} else {
log.error("量化派助贷TO百行报送(A1)-贷款申请信息重复报送, reqId_log: {} ", reqId_log);
}
} catch (Exception e) { } catch (Exception e) {
log.error("量化派助贷TO百行报送(A1)-贷款申请信息异常, reqId_log: {} ", reqId_log, e); log.error("量化派助贷TO百行报送(A1)-贷款申请信息异常, reqId_log: {} ", reqId_log, e);
} }
......
...@@ -2,30 +2,30 @@ ...@@ -2,30 +2,30 @@
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="cn.quantgroup.report.mapper.master.ApplyLoanInfoZhuDaiMapper"> <mapper namespace="cn.quantgroup.report.mapper.master.ApplyLoanInfoZhuDaiMapper">
<resultMap id="LoanInfoResultMap" type="cn.quantgroup.report.domain.baihang.ApplyLoanInfoZhuDai"> <resultMap id="applyLoanInfoZhuDaiMap" type="cn.quantgroup.report.domain.baihang.ApplyLoanInfoZhuDai">
<result column="recordId" jdbcType="VARCHAR" property="record_id"/> <result property="recordId" jdbcType="VARCHAR" column="record_id"/>
<result column="reqID" jdbcType="VARCHAR" property="req_id"/> <result property="reqID" jdbcType="VARCHAR" column="req_id"/>
<result column="opCode" jdbcType="VARCHAR" property="op_code"/> <result property="opCode" jdbcType="VARCHAR" column="op_code"/>
<result column="uploadTs" jdbcType="VARCHAR" property="upload_ts"/> <result property="uploadTs" jdbcType="VARCHAR" column="upload_ts"/>
<result column="isFinTechAgencyBusiness" jdbcType="INTEGER" property="is_fin_tech_agency_business"/> <result property="isFinTechAgencyBusiness" jdbcType="INTEGER" column="is_fin_tech_agency_business"/>
<result column="applyDate" jdbcType="VARCHAR" property="apply_date"/> <result property="applyDate" jdbcType="VARCHAR" column="apply_date"/>
<result column="applyId" jdbcType="VARCHAR" property="apply_id"/> <result property="applyId" jdbcType="VARCHAR" column="apply_id"/>
<result column="applyType" jdbcType="INTEGER" property="apply_type"/> <result property="applyType" jdbcType="INTEGER" column="apply_type"/>
<result column="name" jdbcType="VARCHAR" property="name"/> <result property="name" jdbcType="VARCHAR" column="name"/>
<result column="idType" jdbcType="INTEGER" property="id_type"/> <result property="idType" jdbcType="INTEGER" column="id_type"/>
<result column="pid" jdbcType="VARCHAR" property="pid"/> <result property="pid" jdbcType="VARCHAR" column="pid"/>
<result column="mobile" jdbcType="VARCHAR" property="mobile"/> <result property="mobile" jdbcType="VARCHAR" column="mobile"/>
<result column="emailAddress" jdbcType="VARCHAR" property="email_address"/> <result property="emailAddress" jdbcType="VARCHAR" column="email_address"/>
<result column="eduBackground" jdbcType="INTEGER" property="edu_background"/> <result property="eduBackground" jdbcType="INTEGER" column="edu_background"/>
<result column="degree" jdbcType="INTEGER" property="degree"/> <result property="degree" jdbcType="INTEGER" column="degree"/>
<result column="guaranteeType" jdbcType="INTEGER" property="guarantee_type"/> <result property="guaranteeType" jdbcType="INTEGER" column="guarantee_type"/>
<result column="loanPurpose" jdbcType="INTEGER" property="loan_purpose"/> <result property="loanPurpose" jdbcType="INTEGER" column="loan_purpose"/>
<result column="customType" jdbcType="INTEGER" property="custom_type"/> <result property="customType" jdbcType="INTEGER" column="custom_type"/>
<result column="applyAmount" jdbcType="DECIMAL" property="apply_amount"/> <result property="applyAmount" jdbcType="DECIMAL" column="apply_amount"/>
<result column="businessOrgCreditCode" jdbcType="VARCHAR" property="business_org_credit_code"/> <result property="businessOrgCreditCode" jdbcType="VARCHAR" column="business_org_credit_code"/>
<result column="livingCondition" jdbcType="INTEGER" property="living_condition"/> <result property="livingCondition" jdbcType="INTEGER" column="living_condition"/>
<result column="marriageStatus" jdbcType="INTEGER" property="marriage_status"/> <result property="marriageStatus" jdbcType="INTEGER" column="marriage_status"/>
<result column="spouseName" jdbcType="VARCHAR" property="spouse_name"/> <result property="spouseName" jdbcType="VARCHAR" column="spouse_name"/>
</resultMap> </resultMap>
<select id="saveApplyLoanInfoZhuDaiLog" parameterType="cn.quantgroup.report.domain.baihang.ApplyLoanInfoZhuDai"> <select id="saveApplyLoanInfoZhuDaiLog" parameterType="cn.quantgroup.report.domain.baihang.ApplyLoanInfoZhuDai">
...@@ -38,5 +38,11 @@ ...@@ -38,5 +38,11 @@
#{businessOrgCreditCode},#{livingCondition},#{marriageStatus},#{spouseName}) #{businessOrgCreditCode},#{livingCondition},#{marriageStatus},#{spouseName})
</select> </select>
<select id="findApplyLoanInfoZhuDaiLog" parameterType="java.lang.String" resultMap="applyLoanInfoZhuDaiMap">
select *
from apply_loan_info_zhudai
where req_id = #{reqId,jdbcType=VARCHAR}
</select>
</mapper> </mapper>
\ No newline at end of file
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