修改赠券问题哦

dev-discount
袁野 3 years ago
parent 5a548fb2d0
commit 121de813d9
  1. 17
      hai-service/src/main/java/com/hai/config/HuiLianTongUnionCardConfig.java
  2. 2
      hai-service/src/main/java/com/hai/service/impl/HltUnionCardVipServiceImpl.java

@ -106,7 +106,7 @@ public class HuiLianTongUnionCardConfig {
Map<String , String> map = new HashMap<>();
map.put("phone" , phone);
// 签名码
String signCode = CommonSysConst.getSysConfig().getHuiLianTongUnionCardSignCode();
String signCode = CommonSysConst.getSysConfig().getHltMembershipLevelSignCode();
map.put("appId", signCode);
Map<String,Object> dataMap = new HashMap<>();
@ -197,7 +197,7 @@ public class HuiLianTongUnionCardConfig {
private static JSONObject requestMembership(String method,Map<String,Object> param) throws Exception {
// 签名码
String signCode = CommonSysConst.getSysConfig().getHuiLianTongUnionCardSignCode();
String signCode = CommonSysConst.getSysConfig().getHltMembershipLevelSignCode();
Map<String,Object> map = new LinkedHashMap<>();
map.put("accessCode", CommonSysConst.getSysConfig().getHltMembershipLevelAccessCode());
@ -229,5 +229,18 @@ public class HuiLianTongUnionCardConfig {
return JSONObject.parseObject(decodeData);
}
/**
* 解析响应的参数
* @param param 参数
* @return
*/
public static JSONObject resolveResponseMembership(String param) {
String data = param.replace("\\n", "");
String decodeData = DesUtil.decode(CommonSysConst.getSysConfig().getHltMembershipLevelSignCode(), data, Charset.forName("UTF-8"));
return JSONObject.parseObject(decodeData);
}
}

@ -66,7 +66,7 @@ public class HltUnionCardVipServiceImpl implements HltUnionCardVipService {
BsCompany bsCompany = bsCompanyService.selectCompanyByRegion(region.getRegionId().toString());
JSONObject consumptionRecord = HuiLianTongUnionCardConfig.TCheckEMsgUnionCardVipRights(phone);
JSONObject cardInfoObject = HuiLianTongUnionCardConfig.resolveResponse(consumptionRecord.getString("data"));
JSONObject cardInfoObject = HuiLianTongUnionCardConfig.resolveResponseMembership(consumptionRecord.getString("data"));
HighUser highUser = highUserService.findByPhone(phone);

Loading…
Cancel
Save