提交修改

dev-discount
袁野 3 years ago
parent 9d5252170b
commit 350038be3e
  1. 19
      hai-service/src/main/java/com/hai/config/CommonSysConfig.java
  2. 27
      hai-service/src/main/java/com/hai/config/HuiLianTongUnionCardConfig.java
  3. 1
      hai-service/src/main/java/com/hai/dao/HighDiscountPackageRecordMapperExt.java
  4. 2
      hai-service/src/main/java/com/hai/service/impl/HltUnionCardVipServiceImpl.java
  5. 9
      hai-service/src/main/resources/dev/commonConfig.properties
  6. 3
      hai-service/src/main/resources/prod-9401/commonConfig.properties
  7. 3
      hai-service/src/main/resources/prod/commonConfig.properties

@ -31,6 +31,9 @@ public class CommonSysConfig {
private String HuiLianTongUnionCardAccessCode;
private String HuiLianTongUnionCardSignCode;
private String HltMembershipLevelAccessCode;
private String HltMembershipLevelSignCode;
private String unionPayUrl;
private String unionPayChannelid;
private String unionPayMerid;
@ -350,4 +353,20 @@ public class CommonSysConfig {
public void setCzOrderNotify(String czOrderNotify) {
this.czOrderNotify = czOrderNotify;
}
public String getHltMembershipLevelAccessCode() {
return HltMembershipLevelAccessCode;
}
public void setHltMembershipLevelAccessCode(String hltMembershipLevelAccessCode) {
HltMembershipLevelAccessCode = hltMembershipLevelAccessCode;
}
public String getHltMembershipLevelSignCode() {
return HltMembershipLevelSignCode;
}
public void setHltMembershipLevelSignCode(String hltMembershipLevelSignCode) {
HltMembershipLevelSignCode = hltMembershipLevelSignCode;
}
}

@ -113,8 +113,8 @@ public class HuiLianTongUnionCardConfig {
dataMap.put("phone" , phone);
dataMap.put("appId", signCode);
// Md5加密
dataMap.put("sign", WxUtils.generateSignature(map, "621=@=HSG!Business#Controller!" , WXPayConstants.SignType.MD5));
return request("tetcextra/TCheckEMsgVipRights" , dataMap);
dataMap.put("sign", WxUtils.generateSignature(map, "chg;l;l23e2!~%^&22ovndfgf*@11212ouower=@=HSG!Business#Controller!" , WXPayConstants.SignType.MD5));
return requestMembership("etcextra/checkEMsgUnionCardVipRights" , dataMap);
} catch (Exception e) {
throw ErrorHelp.genException(SysCode.System, ErrorCode.REQUEST_TIMED_OUT, "");
@ -195,6 +195,29 @@ public class HuiLianTongUnionCardConfig {
return HttpsUtils.doPost(CommonSysConst.getSysConfig().getHuiLianTongUnionCardUrl(), JSON.toJSONString(map));
}
private static JSONObject requestMembership(String method,Map<String,Object> param) throws Exception {
// 签名码
String signCode = CommonSysConst.getSysConfig().getHuiLianTongUnionCardSignCode();
Map<String,Object> map = new LinkedHashMap<>();
map.put("accessCode", CommonSysConst.getSysConfig().getHltMembershipLevelAccessCode());
map.put("requestId", new Date().getTime());
map.put("method", method);
// DES加密
map.put("data", DesUtil.encode(JSONObject.toJSONString(param), Charset.forName("UTF-8"),signCode).replace("\\n", ""));
// 数据签名字符串
String str = (MapUtils.getString(map,"accessCode")+signCode);
str +=(MapUtils.getString(map,"requestId")+signCode) ;
str += (MapUtils.getString(map,"method") + signCode);
str += (MapUtils.getString(map,"data") + signCode);
// MD5加密
map.put("sign", MD5Util.MD5Encode(str, "UTF-8").toUpperCase());
return HttpsUtils.doPost(CommonSysConst.getSysConfig().getHuiLianTongUnionCardUrl(), JSON.toJSONString(map));
}
/**
* 解析响应的参数
* @param param 参数

@ -21,7 +21,6 @@ public interface HighDiscountPackageRecordMapperExt {
" status = 1 " +
" AND sales_type = 2 " +
" AND user_id = #{userId} " +
" AND using_attribution = #{usingAttribution} " +
" AND DATE_FORMAT(created_time, '%Y%m') = DATE_FORMAT(CURDATE(), '%Y%m'); "
)
/**

@ -103,7 +103,7 @@ public class HltUnionCardVipServiceImpl implements HltUnionCardVipService {
Map<String,Object> map = new HashMap<>();
map.put("companyId", bsCompany.getId());
map.put("usingAttribution", 1);
map.put("usingAttribution", equityLevel);
map.put("salesType", 2);
map.put("status", 1);

@ -20,8 +20,13 @@ huiliantongAppsecret=FA28E95ACABFA4B2B8E25857437B07F1
# ????????
HuiLianTongUnionCardUrl=http://hltgz.com:4010/api/v2/execute.json
HuiLianTongUnionCardAccessCode=19741F626EE446939CE6D448B0FB0EE8
HuiLianTongUnionCardSignCode=7854B96C
HuiLianTongUnionCardAccessCode=6FCAE1470CEF465988351BB65ABAA8AE
HuiLianTongUnionCardSignCode=F8E91A3C
HltMembershipLevelAccessCode = 9766699A55D640BB97FD8674CF13CCB4
HltMembershipLevelSignCode = C9B28C9A
# ??????
unionPayUrl=https://open.eycard.cn:8443/WorthTech_Access_AppPaySystemV2/apppayacc

@ -19,6 +19,9 @@ HuiLianTongUnionCardUrl=http://hltgz.com:4010/api/v2/execute.json
HuiLianTongUnionCardAccessCode=6FCAE1470CEF465988351BB65ABAA8AE
HuiLianTongUnionCardSignCode=F8E91A3C
HltMembershipLevelAccessCode = 9766699A55D640BB97FD8674CF13CCB4
HltMembershipLevelSignCode = C9B28C9A
unionPayUrl=https://open.eycard.cn:8443/WorthTech_Access_AppPaySystemV2/apppayacc
unionPayChannelid=D01X00000801226
unionPayMerid=83169055983W000

@ -19,6 +19,9 @@ HuiLianTongUnionCardUrl=http://hltgz.com:4010/api/v2/execute.json
HuiLianTongUnionCardAccessCode=6FCAE1470CEF465988351BB65ABAA8AE
HuiLianTongUnionCardSignCode=F8E91A3C
HltMembershipLevelAccessCode = 9766699A55D640BB97FD8674CF13CCB4
HltMembershipLevelSignCode = C9B28C9A
unionPayUrl=https://open.eycard.cn:8443/WorthTech_Access_AppPaySystemV2/apppayacc
unionPayChannelid=D01X00000801226
unionPayMerid=83169055983W000

Loading…
Cancel
Save