Commit 8c476625 authored by huyuchen's avatar huyuchen

huych-商险到期提醒修改

parent 97b3c9fb
...@@ -13,61 +13,56 @@ public class EKPEntryPushParam { ...@@ -13,61 +13,56 @@ public class EKPEntryPushParam {
/** /**
* 来款单位 * 来款单位
*/ */
private String fd_3aa453180cc7f0; private String fd_recipName;
/** /**
* 来款银行账号 * 来款银行账号
*/ */
private String fd_3aa4531865bada; private String fd_recipAccountNo;
/**
* 是否银企直连读取
*/
private String fd_3b57f8de9df354;
/** /**
* 来款单位开户行名 * 来款单位开户行名
*/ */
private String fd_3b88c420e5ca80; private String fd_recipBkName;
/** /**
* 入账日期 * 入账日期
*/ */
private String fd_3aa4531d3b86e0; private String fd_date;
/** /**
* 到款单位 * 到款单位
*/ */
private String fd_3aa45319a4cde4; private String fd_receiveBkName;
/** /**
* 到款银行账号 * 到款银行账号
*/ */
private String fd_3b62f3470beb30; private String fd_receiveBkNo;
/** /**
* 财务备注 * 财务备注
*/ */
private String fd_3b1b88110cb39e; private String fd_remark;
/** /**
* 入账金额 * 入账金额
*/ */
private String fd_3b208d364c2b70; private String fd_receiveMoney;
/** /**
* 入账日期(精确) * 入账日期(精确)
*/ */
private String fd_3cddecabdd3dc0; private String fd_daReal;
/** /**
* 数据同步时间 * 数据同步时间
*/ */
private String fd_3aa4531c687958; private String fd_daTime;
/** /**
* 系统交易流水号 * 系统交易流水号
*/ */
private String fd_3b573843db30ce; private String fd_onlySequence;
} }
...@@ -24,4 +24,7 @@ public class EkpEntryProperties { ...@@ -24,4 +24,7 @@ public class EkpEntryProperties {
String entryDocSubject; String entryDocSubject;
String entryFdFlowId;
} }
...@@ -79,10 +79,10 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn ...@@ -79,10 +79,10 @@ public class IcbcTransactionFlowIssueServiceImpl extends ServiceImpl<EkpSocialIn
bizContent.setOprType("1"); bizContent.setOprType("1");
bizContent.setTotalAmt("1"); bizContent.setTotalAmt("1");
bizContent.setTotalCount("1"); bizContent.setTotalCount("1");
bizContent.setAppSerialno("WX06"); bizContent.setAppSerialno("WX003");
bizContent.setFileCheckSign("1"); bizContent.setFileCheckSign("1");
bizContent.setLocalFilepath("D:/icbcFile/020101190_WX06_0_20240819.xls"); bizContent.setLocalFilepath("D:/icbcFile/020101190_WX003_0_20240827.xls");
bizContent.setFileMdcode(getMdCode("D:/icbcFile/020101190_WX06_0_20240819.xls")); bizContent.setFileMdcode(getMdCode("D:/icbcFile/020101190_WX003_0_20240827.xls"));
bizContent.setFileType("1"); bizContent.setFileType("1");
bizContent.setNotifyUrl(null); bizContent.setNotifyUrl(null);
bizContent.setAppRemark("备注"); bizContent.setAppRemark("备注");
......
package com.yifu.cloud.plus.v1.ekp.service.impl; package com.yifu.cloud.plus.v1.ekp.service.impl;
import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONObject; import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.fasterxml.jackson.databind.ObjectMapper; import com.fasterxml.jackson.databind.ObjectMapper;
...@@ -118,26 +117,20 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn ...@@ -118,26 +117,20 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn
} }
public R getIcbcTransactionFlowNew() throws IcbcApiException { public R getIcbcTransactionFlowNew() throws IcbcApiException {
//1、网关公钥
// String APIGW_PUBLIC_KEY = "MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCwFgHD4kzEVPdOj03ctKM7KV+16bWZ5BMNgvEeuEQwfQYkRVwI9HFOGkwNTMn5hiJXHnlXYCX+zp5r6R52MY0O7BsTCLT7aHaxsANsvI9ABGx3OaTVlPB59M6GPbJh0uXvio0m1r/lTW3Z60RU6Q3oid/rNhP3CiNgg0W6O3AGqwIDAQAB";
// //2、appid
// String APP_ID = "10000000000000223600";
// //3、密钥对认证方式,公钥在API平台登记,此处为私钥
// String MY_PRIVATE_KEY = "73382de53fcbf8aa3b00d07f9808b18e89d1b6b33c9759829eee5cbf1947dbdb";
// DefaultIcbcClient client = new DefaultIcbcClient("10000000000000223600", IcbcConstants.SIGN_TYPE_CA_SM_ICBC, MY_PRIVATE_KEY,
// IcbcConstants.CHARSET_UTF8, IcbcConstants.FORMAT_JSON, null,
// null, null, "1.2.156.10197.1.301", null);
// String ca_sm_path = "D:/icbcFile/ahwx.y.1302.cer"; // String ca_sm_path = "D:/icbcFile/ahwx_y_1302.cer";
// String ca_sm_icbc_path = "D:/icbcFile/API_GATEWAY_ICBC_SM_REAL.cer"; // String ca_sm_icbc_path = "D:/icbcFile/API_GATEWAY_ICBC_SM_REAL.cer";
URL resource = IcbcTransactionFlowQueryServiceImpl.class.getClassLoader().getResource("ahwx.y.1302.cer"); // 获取当前类加载器
URL resource1 = IcbcTransactionFlowQueryServiceImpl.class.getClassLoader().getResource("API_GATEWAY_ICBC_SM_REAL.cer"); ClassLoader classLoader = Thread.currentThread().getContextClassLoader();
// String ca_sm_path = "/file/ahwx.y.1302.cer"; // 获取资源的URL
// String ca_sm_icbc_path = "/file/API_GATEWAY_ICBC_SM_REAL.cer"; URL resourceUrl = classLoader.getResource("file/ahwx_y_1302.cer");
URL resourceUrl1 = classLoader.getResource("file/API_GATEWAY_ICBC_SM_REAL.cer");
String ca_sm = IcbcSignature.getCAInfoStr(resourceUrl.getPath());
String ca_sm_icbc = IcbcSignature.getCAInfoStr(resourceUrl1.getPath());
String ca_sm = IcbcSignature.getCAInfoStr(resource.getPath()); // String ca_sm = IcbcSignature.getCAInfoStr(ca_sm_path);
String ca_sm_icbc = IcbcSignature.getCAInfoStr(resource1.getPath()); // String ca_sm_icbc = IcbcSignature.getCAInfoStr(ca_sm_icbc_path);
log.error("文件地址:" + resource.getPath() + "转化后的编码" + ca_sm); // log.error("文件地址:" + resourceUrl.getPath() + "转化后的编码" + ca_sm);
// DefaultIcbcClient(appid, 签名类型, SM2企业私钥, 编码格式, 数据格式, null, null, null, SM2 cer公钥串, null) // DefaultIcbcClient(appid, 签名类型, SM2企业私钥, 编码格式, 数据格式, null, null, null, SM2 cer公钥串, null)
DefaultIcbcClient client = new DefaultIcbcClient(icbcConfigProperties.getAppId(), IcbcConstants.SIGN_TYPE_CA_SM_ICBC, DefaultIcbcClient client = new DefaultIcbcClient(icbcConfigProperties.getAppId(), IcbcConstants.SIGN_TYPE_CA_SM_ICBC,
icbcConfigProperties.getAppPrivateKey(), IcbcConstants.CHARSET_UTF8, IcbcConstants.FORMAT_JSON, null, icbcConfigProperties.getAppPrivateKey(), IcbcConstants.CHARSET_UTF8, IcbcConstants.FORMAT_JSON, null,
...@@ -165,8 +158,7 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn ...@@ -165,8 +158,7 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn
request.setServiceUrl(icbcConfigProperties.getServerUrl()); request.setServiceUrl(icbcConfigProperties.getServerUrl());
request.setBizContent(bizContent); request.setBizContent(bizContent);
MybankEnterpriseTradeQhisdResponseV1 response = client.execute(request); MybankEnterpriseTradeQhisdResponseV1 response = client.execute(request);
log.error("response:" + JSON.toJSONString(response)); if(response.isSuccess()) {
if(!response.isSuccess()) {
//查询当天的所有入账记录数据 //查询当天的所有入账记录数据
List<String> serioList = baseMapper.getAllserioNo(); List<String> serioList = baseMapper.getAllserioNo();
List<MybankEnterpriseTradeQhisdResponseV1.MybankEnterpriseTradeQhisdResponseRdV1> list = response.getRd(); List<MybankEnterpriseTradeQhisdResponseV1.MybankEnterpriseTradeQhisdResponseRdV1> list = response.getRd();
...@@ -177,7 +169,7 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn ...@@ -177,7 +169,7 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn
List<MybankEnterpriseTradeQhisdResponseV1.MybankEnterpriseTradeQhisdResponseRdV1> insertList = List<MybankEnterpriseTradeQhisdResponseV1.MybankEnterpriseTradeQhisdResponseRdV1> insertList =
list.stream().filter(e-> e.getDrcrf().equals("2") && !serioList.contains(e)).collect(Collectors.toList()); list.stream().filter(e-> e.getDrcrf().equals("2") && !serioList.contains(e)).collect(Collectors.toList());
//封装数据 //封装数据
if (insertList.isEmpty()) { if (!insertList.isEmpty()) {
for (MybankEnterpriseTradeQhisdResponseV1.MybankEnterpriseTradeQhisdResponseRdV1 entry : insertList) { for (MybankEnterpriseTradeQhisdResponseV1.MybankEnterpriseTradeQhisdResponseRdV1 entry : insertList) {
EKPEntryPushParam pushParam = new EKPEntryPushParam(); EKPEntryPushParam pushParam = new EKPEntryPushParam();
initValue(entry,pushParam,bankName,bankNo); initValue(entry,pushParam,bankName,bankNo);
...@@ -186,6 +178,7 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn ...@@ -186,6 +178,7 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn
if (StringUtils.isBlank(body)){ if (StringUtils.isBlank(body)){
sendToEkp(pushParam); sendToEkp(pushParam);
} }
break;
} }
} }
} }
...@@ -203,7 +196,9 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn ...@@ -203,7 +196,9 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn
MultiValueMap<String,Object> wholeForm = new LinkedMultiValueMap<>(); MultiValueMap<String,Object> wholeForm = new LinkedMultiValueMap<>();
wholeForm.add("docSubject",ekpEntryProperties.getEntryDocSubject()); wholeForm.add("docSubject",ekpEntryProperties.getEntryDocSubject());
wholeForm.add("docCreator", "{\"LoginName\":\"admin\"}"); wholeForm.add("docCreator", "{\"LoginName\":\"admin\"}");
wholeForm.add("docStatus", ekpEntryProperties.getEntryDocStatus());
wholeForm.add("fdModelId", ekpEntryProperties.getEntryFdModelId()); wholeForm.add("fdModelId", ekpEntryProperties.getEntryFdModelId());
wholeForm.add("fdFlowId", ekpEntryProperties.getEntryFdFlowId());
wholeForm.add("formValues", formValues); wholeForm.add("formValues", formValues);
HttpHeaders headers = new HttpHeaders(); HttpHeaders headers = new HttpHeaders();
//如果EKP对该接口启用了Basic认证,那么客户端需要加入 //如果EKP对该接口启用了Basic认证,那么客户端需要加入
...@@ -229,7 +224,7 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn ...@@ -229,7 +224,7 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn
} }
public R querybankinfo() { public R querybankinfo() {
String ca_sm_path = "D:/icbcFile/ahwx.y.1302.cer"; String ca_sm_path = "D:/icbcFile/ahwx_y_1302.cer";
String ca_sm_icbc_path = "D:/icbcFile/API_GATEWAY_ICBC_SM_REAL.cer"; String ca_sm_icbc_path = "D:/icbcFile/API_GATEWAY_ICBC_SM_REAL.cer";
String ca_sm = IcbcSignature.getCAInfoStr(ca_sm_path); String ca_sm = IcbcSignature.getCAInfoStr(ca_sm_path);
...@@ -386,17 +381,16 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn ...@@ -386,17 +381,16 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn
public void initValue(MybankEnterpriseTradeQhisdResponseV1.MybankEnterpriseTradeQhisdResponseRdV1 entry, public void initValue(MybankEnterpriseTradeQhisdResponseV1.MybankEnterpriseTradeQhisdResponseRdV1 entry,
EKPEntryPushParam pushParam,String bankName,String bankNo) { EKPEntryPushParam pushParam,String bankName,String bankNo) {
pushParam.setFd_3aa453180cc7f0(entry.getRecipName()); pushParam.setFd_recipName(entry.getRecipName());
pushParam.setFd_3aa4531865bada(entry.getRecipAccountNo()); pushParam.setFd_recipAccountNo(entry.getRecipAccountNo());
pushParam.setFd_3b57f8de9df354("是"); pushParam.setFd_recipBkName(entry.getRecipBkName());
pushParam.setFd_3b88c420e5ca80(entry.getRecipBkName1()); pushParam.setFd_date(entry.getBusiDate() + " " + entry.getBusiTime());
pushParam.setFd_3aa4531d3b86e0(entry.getDate()); pushParam.setFd_receiveBkName(bankName);
pushParam.setFd_3aa45319a4cde4(bankName); pushParam.setFd_receiveBkNo(bankNo);
pushParam.setFd_3b62f3470beb30(bankNo); pushParam.setFd_remark(entry.getSummary());
pushParam.setFd_3b1b88110cb39e(entry.getSummary()); pushParam.setFd_receiveMoney(String.valueOf(entry.getCreditAmount()/100.0));
pushParam.setFd_3b208d364c2b70(entry.getCreditAmount().toString()); pushParam.setFd_daReal(entry.getBusiDate() + " " + entry.getBusiTime());
pushParam.setFd_3cddecabdd3dc0(entry.getBusiTime()); pushParam.setFd_daTime(entry.getBusiDate() + " " + entry.getBusiTime());
pushParam.setFd_3aa4531c687958(DateUtil.getThisTime()); pushParam.setFd_onlySequence(entry.getOnlySequence());
pushParam.setFd_3b573843db30ce(entry.getOnlySequence());
} }
} }
...@@ -107,6 +107,8 @@ security: ...@@ -107,6 +107,8 @@ security:
entry: entry:
entryUrl: http://36.7.147.29:27007/api/sys-modeling/appModelRestService/addModel entryUrl: http://36.7.147.29:27007/api/sys-modeling/appModelRestService/addModel
entryFdModelId: 18050b5cee8b79c234bf64d412294f23 entryFdModelId: 18050b5cee8b7f8e56879448e4f23aad
entryFdFlowId: 191919ae533d080b60e6e784c55a3c8b
entryDocStatus: 20
entryLoginName: admin entryLoginName: admin
entryDocSubject: 入账明细推送ekp接口 entryDocSubject: 入账明细推送ekp接口
\ No newline at end of file
-----BEGIN CERTIFICATE-----
MIICSTCCAeygAwIBAgIGAJuAEtYAMAwGCCqBHM9VAYN1BQAwQTELMAkGA1UEBhMCY24xGzAZBgNVBAoMEnNtMmNvci5pY2JjLmNvbS5jbjEVMBMGA1UEAwwMc20ycm9vdGNhY29yMB4XDTIzMTIyMTA5NTAxNloXDTI4MTIyMTE1NTk1OVowVDELMAkGA1UEBhMCY24xGzAZBgNVBAoMEnNtMmNvci5pY2JjLmNvbS5jbjENMAsGA1UECwwEMTMwMjEZMBcGA1UEAwwQYWh3eC55LjEzMDIuMDIwMTBZMBMGByqGSM49AgEGCCqBHM9VAYItA0IABGEC1fF2rHTWfipQhOr+8SfvXDBiazIrImcsPH5aGaYMFK2RIXv0AF2xe2ZgAzcWRbgop0cAjaBHXpzSfIlnfl6jgbowgbcwHwYDVR0jBBgwFoAUDD6RRlIIkxjZ0/0x6S8mKdW3D2YwCQYDVR0TBAIwADBdBgNVHR8EVjBUMFKgUKBOpEwwSjEQMA4GA1UEAwwHY3JsNDE3MDEMMAoGA1UECwwDY3JsMRswGQYDVQQKDBJzbTJjb3IuaWNiYy5jb20uY24xCzAJBgNVBAYTAmNuMAsGA1UdDwQEAwIHgDAdBgNVHQ4EFgQUd0LHEI6l7Faq6/9GObNld3SH7xswDAYIKoEcz1UBg3UFAANJADBGAiEA68uRM5zYzMhaheAG+fw3AtkRFE5146+Qw6GVP93WojwCIQDzsIL3duLRtTot8ciVuKUQkI+GrXAg7nWnd2M2o9oRBw==
-----END CERTIFICATE-----
\ No newline at end of file
...@@ -127,9 +127,15 @@ public class TInsurancesWarnController { ...@@ -127,9 +127,15 @@ public class TInsurancesWarnController {
return insuranceDetailService.getExpireInsuranceWarn(); return insuranceDetailService.getExpireInsuranceWarn();
} }
@Operation(description = "商险到期个人总数提醒")
@PostMapping("/getUserInsuranceMessageWarnCount")
public R<Integer> getUserInsuranceMessageWarnCount(@RequestParam String userName) {
return insuranceDetailService.getUserInsuranceMessageWarnCount(userName);
}
@Operation(description = "每天刷新商险到期提醒信息") @Operation(description = "每天刷新商险到期提醒信息")
@PostMapping("/innner/createInsuranceAlert")
@Inner @Inner
@PostMapping("/inner/createInsuranceAlert")
public void createInsuranceAlert() { public void createInsuranceAlert() {
insuranceWarnService.createInsuranceAlert(); insuranceWarnService.createInsuranceAlert();
} }
......
...@@ -525,6 +525,8 @@ public interface TInsuranceDetailService extends IService<TInsuranceDetail> { ...@@ -525,6 +525,8 @@ public interface TInsuranceDetailService extends IService<TInsuranceDetail> {
R<Integer> getExpireInsuranceWarn(); R<Integer> getExpireInsuranceWarn();
R<Integer> getUserInsuranceMessageWarnCount(String userName);
R<Object> batchexpireIgnore(List<String> ids); R<Object> batchexpireIgnore(List<String> ids);
R<Object> expireIgnore(TBusinessInsuranceVo vo); R<Object> expireIgnore(TBusinessInsuranceVo vo);
......
...@@ -8036,4 +8036,12 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap ...@@ -8036,4 +8036,12 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
// List<String> domainIds = getExportCondition(searchVo); // List<String> domainIds = getExportCondition(searchVo);
return R.ok(baseMapper.noPageCountDiy(searchVo)); return R.ok(baseMapper.noPageCountDiy(searchVo));
} }
@Override
public R<Integer> getUserInsuranceMessageWarnCount(String userName) {
InsuranceSearchVo searchVo = new InsuranceSearchVo();
searchVo.setCreateName(userName);
searchVo.setExpireIgnoreFlag(CommonConstants.ONE_STRING);
return R.ok(baseMapper.noPageCountDiy(searchVo));
}
} }
...@@ -1939,10 +1939,10 @@ ...@@ -1939,10 +1939,10 @@
,a.INSURANCE_HANDLE_CITY_NAME ,a.INSURANCE_HANDLE_CITY_NAME
from from
t_insurance_alert a t_insurance_alert a
<include refid="expire_sql_where"/>
LEFT JOIN view_insurance_replace r on a.id=r.TO_INSURANCE_DETAIL_ID LEFT JOIN view_insurance_replace r on a.id=r.TO_INSURANCE_DETAIL_ID
LEFT JOIN view_insurance_replace r2 on a.id=r2.FROM_INSURANCE_DETAIL_ID LEFT JOIN view_insurance_replace r2 on a.id=r2.FROM_INSURANCE_DETAIL_ID
LEFT JOIN t_insurance_refund rf on rf.INS_DETAIL_ID=a.id LEFT JOIN t_insurance_refund rf on rf.INS_DETAIL_ID=a.id
<include refid="expire_sql_where"/>
group by a.id group by a.id
order by a.CREATE_TIME desc order by a.CREATE_TIME desc
<if test="param != null and param.limitStart != null"> <if test="param != null and param.limitStart != null">
......
...@@ -52,6 +52,7 @@ ...@@ -52,6 +52,7 @@
a.EMP_NAME, a.EMP_NAME,
a.EMP_IDCARD_NO, a.EMP_IDCARD_NO,
a.DEPT_NO, a.DEPT_NO,
a.DEPT_NAME,
a.POST, a.POST,
a.INSURANCE_COMPANY_NAME, a.INSURANCE_COMPANY_NAME,
a.INSURANCE_TYPE_NAME, a.INSURANCE_TYPE_NAME,
......
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