Commit 512f413e authored by huyuchen's avatar huyuchen

huych-工行卡号无需封装行名行号逻辑新增

parent b314766d
...@@ -58,4 +58,11 @@ public interface EkpSocialInfoMapper extends BaseMapper<EkpSocialInfo> { ...@@ -58,4 +58,11 @@ public interface EkpSocialInfoMapper extends BaseMapper<EkpSocialInfo> {
List<Map<String,String>> getAccountList(); List<Map<String,String>> getAccountList();
EkpDeptContractInfoVo selectContractInfoByDetptNo(@Param("deptNo") String deptNo); EkpDeptContractInfoVo selectContractInfoByDetptNo(@Param("deptNo") String deptNo);
/**
* 获取所有工行卡bin信息
* @param
* @return
*/
List<String> getAllIcbcCardBinInfo();
} }
...@@ -546,8 +546,22 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn ...@@ -546,8 +546,22 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn
R<EkpBankCodeSet> bankInfoQuery; R<EkpBankCodeSet> bankInfoQuery;
EkpBankCodeConfiglVo bankVo; EkpBankCodeConfiglVo bankVo;
// 组装 // 组装
//工行的卡号bin list
List<String> binList = baseMapper.getAllIcbcCardBinInfo();
for (EkpBankExcelVo excelVo : list) { for (EkpBankExcelVo excelVo : list) {
if (Common.isEmpty(excelVo.getFdRecipientBankCode())) { if (Common.isEmpty(excelVo.getFdRecipientBankCode())) {
//工行的卡号通过bin来判断,如果是工行的卡号,则不需要行名行号
// 检查长度是否足够
if (Common.isNotNull(binList) && !binList.isEmpty() && excelVo.getFdPayeeAccount().length() >= 5) {
for (String bin : binList) {
if ((bin.length() == 5 && excelVo.getFdPayeeAccount().substring(0, 5).equals(bin)) ||
(bin.length() == 6 && excelVo.getFdPayeeAccount().length() >= 6 &&
excelVo.getFdPayeeAccount().substring(0, 6).equals(bin))) {
excelVo.setFdRecipientBankCode(null);
excelVo.setFdRecipientBank(null);
}
}
}
// 查询行号 // 查询行号
bankInfoQuery = icbcTransactionFlowQueryService.querybankinfo(excelVo.getFdPayeeAccount()); bankInfoQuery = icbcTransactionFlowQueryService.querybankinfo(excelVo.getFdPayeeAccount());
if (bankInfoQuery != null && bankInfoQuery.getCode() == CommonConstants.SUCCESS && bankInfoQuery.getData() != null) { if (bankInfoQuery != null && bankInfoQuery.getCode() == CommonConstants.SUCCESS && bankInfoQuery.getData() != null) {
......
...@@ -148,4 +148,10 @@ ...@@ -148,4 +148,10 @@
where a.fd_3a37fe508071fe = #{deptNo} where a.fd_3a37fe508071fe = #{deptNo}
limit 1 limit 1
</select> </select>
<select id="getAllIcbcCardBinInfo" resultType="java.lang.String">
select
bank_code
from ekp_icbc_code_config
</select>
</mapper> </mapper>
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