Commit c038fc55 authored by fangxinjiang's avatar fangxinjiang

Merge remote-tracking branch 'origin/MVP1.7.21' into MVP1.7.21

parents db96e3f8 a4b2e783
...@@ -58,7 +58,7 @@ public interface IcbcTransactionFlowQueryService extends IService<EkpSocialInfo> ...@@ -58,7 +58,7 @@ public interface IcbcTransactionFlowQueryService extends IService<EkpSocialInfo>
// 工行非税支付 // 工行非税支付
// type 0 对公; 1 对私. // type 0 对公; 1 对私.
R<String> submitIcbcToNoTax(String totalAmt, String totalCount, String wxNo R<String> submitIcbcToNoTax(String title, String totalAmt, String totalCount, String wxNo
, List<EkpBankExcelNoTaxVo> detailList, int type, String fdId, String packageName); , List<EkpBankExcelNoTaxVo> detailList, int type, String fdId, String packageName);
R submitSearch(); R submitSearch();
......
...@@ -916,6 +916,7 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn ...@@ -916,6 +916,7 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn
// 非扣税表名称 // 非扣税表名称
String tableName = "ekp_75edcee9b5e4b198035a"; String tableName = "ekp_75edcee9b5e4b198035a";
String wxNoPre = "FKS"; String wxNoPre = "FKS";
String title = "非扣税";
String redisKey = "SUBMIT_NO_TAX_BANK_" + fdId; String redisKey = "SUBMIT_NO_TAX_BANK_" + fdId;
if (Common.isNotNull(redisUtil.get(redisKey))) { if (Common.isNotNull(redisUtil.get(redisKey))) {
return R.failed("数据锁定中,请耐心等待!"); return R.failed("数据锁定中,请耐心等待!");
...@@ -942,19 +943,20 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn ...@@ -942,19 +943,20 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn
return R.failed("数据错误,无金额!"); return R.failed("数据错误,无金额!");
} }
if (Common.isNotNull(main.getFdPayType()) && "报销".equals(main.getFdPayType())) { if (Common.isNotNull(main.getFdPayType()) && "报销".equals(main.getFdPayType())) {
if ("行政报销".equals(main.getFdCustomerName())) { if ("行政报销".equals(main.getFdAttaName())) {
wxNoPre = "XZBX"; wxNoPre = "XZBX";
tableName = "ekp_6f55b508bcf492cae93d"; tableName = "ekp_6f55b508bcf492cae93d";
} else if ("业务报销".equals(main.getFdCustomerName())) { } else if ("业务报销".equals(main.getFdAttaName())) {
wxNoPre = "YWBX"; wxNoPre = "YWBX";
tableName = "ekp_a2b51052cb1324b5f92f"; tableName = "ekp_a2b51052cb1324b5f92f";
} else if ("项目报销".equals(main.getFdCustomerName())) { } else if ("项目报销".equals(main.getFdAttaName())) {
wxNoPre = "XMBX"; wxNoPre = "XMBX";
tableName = "ekp_a185e090a77a14211ab0"; tableName = "ekp_a185e090a77a14211ab0";
} else if ("差旅费报销".equals(main.getFdCustomerName())) { } else if ("差旅费报销".equals(main.getFdAttaName())) {
wxNoPre = "CLFBX"; wxNoPre = "CLFBX";
tableName = "ekp_af0fda0b28888440fa17"; tableName = "ekp_af0fda0b28888440fa17";
} }
title = main.getFdAttaName();
} }
int count = ekpBankGrantDetailService.getCountByIdAndMain(fdId); int count = ekpBankGrantDetailService.getCountByIdAndMain(fdId);
String totalAmt = String.valueOf(BigDecimalUtils.safeMultiply(main.getFdMoney(), new BigDecimal("100"), 0)); String totalAmt = String.valueOf(BigDecimalUtils.safeMultiply(main.getFdMoney(), new BigDecimal("100"), 0));
...@@ -986,7 +988,7 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn ...@@ -986,7 +988,7 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn
packageName = main.getFdSettlementNo() + CommonConstants.DOWN_LINE_STRING ; packageName = main.getFdSettlementNo() + CommonConstants.DOWN_LINE_STRING ;
} }
packageName += DateUtil.getThisTime(); packageName += DateUtil.getThisTime();
R<String> returnR = icbcTransactionFlowQueryService.submitIcbcToNoTax(totalAmt, totalCount, wxNo, detailList, noTaxPayType, fdId, packageName); R<String> returnR = icbcTransactionFlowQueryService.submitIcbcToNoTax(title, totalAmt, totalCount, wxNo, detailList, noTaxPayType, fdId, packageName);
if (returnR.getCode() == CommonConstants.SUCCESS) { if (returnR.getCode() == CommonConstants.SUCCESS) {
String serialNo = returnR.getData(); String serialNo = returnR.getData();
// 存储日志 // 存储日志
...@@ -1028,15 +1030,16 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn ...@@ -1028,15 +1030,16 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn
return R.failed("未找到主表数据!"); return R.failed("未找到主表数据!");
} }
if (Common.isNotNull(main.getFdPayType()) && "报销".equals(main.getFdPayType())) { if (Common.isNotNull(main.getFdPayType()) && "报销".equals(main.getFdPayType())) {
if ("行政报销".equals(main.getFdCustomerName())) { if ("行政报销".equals(main.getFdAttaName())) {
wxNoPre = "XZBXMX"; wxNoPre = "XZBXMX";
} else if ("业务报销".equals(main.getFdCustomerName())) { } else if ("业务报销".equals(main.getFdAttaName())) {
wxNoPre = "YWBXMX"; wxNoPre = "YWBXMX";
} else if ("项目报销".equals(main.getFdCustomerName())) { } else if ("项目报销".equals(main.getFdAttaName())) {
wxNoPre = "XMBXMX"; wxNoPre = "XMBXMX";
} else if ("差旅费报销".equals(main.getFdCustomerName())) { } else if ("差旅费报销".equals(main.getFdAttaName())) {
wxNoPre = "CLFBXMX"; wxNoPre = "CLFBXMX";
} }
title = main.getFdAttaName();
} }
} }
String totalAmt = String.valueOf(BigDecimalUtils.safeMultiply(detail.getFdMoney(), new BigDecimal("100"), 0)); String totalAmt = String.valueOf(BigDecimalUtils.safeMultiply(detail.getFdMoney(), new BigDecimal("100"), 0));
...@@ -1069,7 +1072,7 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn ...@@ -1069,7 +1072,7 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn
noTaxPayType = CommonConstants.ONE_INT; noTaxPayType = CommonConstants.ONE_INT;
} }
List<EkpBankExcelNoTaxVo> detailList = ekpBankGrantDetailService.getEkpBankExcelVoByIdAndDetailNoTax(fdId); List<EkpBankExcelNoTaxVo> detailList = ekpBankGrantDetailService.getEkpBankExcelVoByIdAndDetailNoTax(fdId);
R<String> returnR = icbcTransactionFlowQueryService.submitIcbcToNoTax(totalAmt, totalCount, wxNo, detailList, noTaxPayType, fdId, packageName); R<String> returnR = icbcTransactionFlowQueryService.submitIcbcToNoTax(title, totalAmt, totalCount, wxNo, detailList, noTaxPayType, fdId, packageName);
if (returnR.getCode() == CommonConstants.SUCCESS) { if (returnR.getCode() == CommonConstants.SUCCESS) {
String serialNo = returnR.getData(); String serialNo = returnR.getData();
// 存储日志 // 存储日志
......
...@@ -847,7 +847,7 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn ...@@ -847,7 +847,7 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn
// 工行非税支付 // 工行非税支付
// 改造自上面的demo接口:executePayment // 改造自上面的demo接口:executePayment
// type 0 对公; 1 对私. // type 0 对公; 1 对私.
public R<String> submitIcbcToNoTax(String totalAmt, String totalCount, String wxNo public R<String> submitIcbcToNoTax(String title, String totalAmt, String totalCount, String wxNo
, List<EkpBankExcelNoTaxVo> detailList, int type, String fdId, String packageName) { , List<EkpBankExcelNoTaxVo> detailList, int type, String fdId, String packageName) {
// 获取当前时间 // 获取当前时间
LocalTime currentTime = LocalTime.now(); LocalTime currentTime = LocalTime.now();
...@@ -890,9 +890,9 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn ...@@ -890,9 +890,9 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn
for (EkpBankExcelNoTaxVo detail : detailList) { for (EkpBankExcelNoTaxVo detail : detailList) {
// 0 对公 // 0 对公
if (CommonConstants.ZERO_INT == type) { if (CommonConstants.ZERO_INT == type) {
rdDetail = buildPayRecordDuiGong(detail); rdDetail = buildPayRecordDuiGong(detail, wxNo);
} else { } else {
rdDetail = buildPayRecordDuiSi(detail); rdDetail = buildPayRecordDuiSi(detail, wxNo);
} }
rd.add(rdDetail); rd.add(rdDetail);
} }
...@@ -929,11 +929,11 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn ...@@ -929,11 +929,11 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn
return R.ok(response.getSerialNo()); return R.ok(response.getSerialNo());
} else { } else {
// 失败 // 失败
return R.failed("工行【非扣税】支付指令提交失败"); return R.failed("工行【"+title+"】支付指令提交失败!");
} }
} catch (Exception e) { } catch (Exception e) {
log.error("工行【非扣税】支付指令提交失败", e); log.error("工行【"+title+"】支付指令提交失败!!", e);
throw new RuntimeException("【非扣税】支付指令提交失败", e); throw new RuntimeException("【"+title+"】支付指令提交失败", e);
} }
} }
...@@ -1115,7 +1115,7 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn ...@@ -1115,7 +1115,7 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn
} }
// 对公 // 对公
private MybankEnterprisePayPayentRequestV2.MybankEnterprisePayPayentRequestRdV2 buildPayRecordDuiGong(EkpBankExcelNoTaxVo detail) { private MybankEnterprisePayPayentRequestV2.MybankEnterprisePayPayentRequestRdV2 buildPayRecordDuiGong(EkpBankExcelNoTaxVo detail, String wxNo) {
MybankEnterprisePayPayentRequestV2.MybankEnterprisePayPayentRequestRdV2 payRecord = MybankEnterprisePayPayentRequestV2.MybankEnterprisePayPayentRequestRdV2 payRecord =
new MybankEnterprisePayPayentRequestV2.MybankEnterprisePayPayentRequestRdV2(); new MybankEnterprisePayPayentRequestV2.MybankEnterprisePayPayentRequestRdV2();
...@@ -1125,6 +1125,7 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn ...@@ -1125,6 +1125,7 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn
} }
//业务唯一编号:相同指令不重复 //业务唯一编号:相同指令不重复
payRecord.setUniBusiId(fdId); payRecord.setUniBusiId(fdId);
payRecord.setRefNo(wxNo + CommonConstants.DOWN_LINE_STRING + detail.getFdSerialNumber());
//指令顺序号:每笔指令的序号,本包内不重复 //指令顺序号:每笔指令的序号,本包内不重复
payRecord.setiSeqNo(detail.getFdSerialNumber()); payRecord.setiSeqNo(detail.getFdSerialNumber());
//预约日期 //预约日期
...@@ -1208,7 +1209,7 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn ...@@ -1208,7 +1209,7 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn
return payRecord; return payRecord;
} }
private MybankEnterprisePayPayentRequestV2.MybankEnterprisePayPayentRequestRdV2 buildPayRecordDuiSi(EkpBankExcelNoTaxVo detail) { private MybankEnterprisePayPayentRequestV2.MybankEnterprisePayPayentRequestRdV2 buildPayRecordDuiSi(EkpBankExcelNoTaxVo detail, String wxNo) {
MybankEnterprisePayPayentRequestV2.MybankEnterprisePayPayentRequestRdV2 payRecord = MybankEnterprisePayPayentRequestV2.MybankEnterprisePayPayentRequestRdV2 payRecord =
new MybankEnterprisePayPayentRequestV2.MybankEnterprisePayPayentRequestRdV2(); new MybankEnterprisePayPayentRequestV2.MybankEnterprisePayPayentRequestRdV2();
String fdId = detail.getFdId(); String fdId = detail.getFdId();
...@@ -1217,6 +1218,7 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn ...@@ -1217,6 +1218,7 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn
} }
//业务唯一编号:相同指令不重复 //业务唯一编号:相同指令不重复
payRecord.setUniBusiId(fdId); payRecord.setUniBusiId(fdId);
payRecord.setRefNo(wxNo + CommonConstants.DOWN_LINE_STRING + detail.getFdSerialNumber());
//指令顺序号:每笔指令的序号,本包内不重复 //指令顺序号:每笔指令的序号,本包内不重复
payRecord.setiSeqNo(detail.getFdSerialNumber()); payRecord.setiSeqNo(detail.getFdSerialNumber());
//预约日期 //预约日期
......
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