diff --git a/hai-cweb/src/main/java/com/cweb/controller/HighTestController.java b/hai-cweb/src/main/java/com/cweb/controller/HighTestController.java index e659e90c..f6d466c5 100644 --- a/hai-cweb/src/main/java/com/cweb/controller/HighTestController.java +++ b/hai-cweb/src/main/java/com/cweb/controller/HighTestController.java @@ -231,7 +231,7 @@ public class HighTestController { @ApiOperation(value = "测试") public ResponseData couJointDist(@RequestParam(name = "token", required = true) String token) { try { - return ResponseMsgUtil.success(HuiLianTongConfig.couJointDist(token,"20JY000251",2,"17726395120", "oArhO6XxKSvjI9wLP3cTK-iSG8yY")); + return ResponseMsgUtil.success(HuiLianTongConfig.couJointDist(token,"HF"+new Date().getTime(),"20JY000251",2,"17726395120", "oArhO6XxKSvjI9wLP3cTK-iSG8yY")); } catch (Exception e) { log.error("HighOrderController --> getOrderById() error!", e); return ResponseMsgUtil.exception(e); diff --git a/hai-service/src/main/java/com/hai/config/HuiLianTongConfig.java b/hai-service/src/main/java/com/hai/config/HuiLianTongConfig.java index 8b69f97d..ec3849f0 100644 --- a/hai-service/src/main/java/com/hai/config/HuiLianTongConfig.java +++ b/hai-service/src/main/java/com/hai/config/HuiLianTongConfig.java @@ -81,7 +81,7 @@ public class HuiLianTongConfig { * @return * @throws Exception */ - public static JSONObject couJointDist(String token,String couTypeCode,Integer distCouCount,String userPhone,String thirdUserId) throws Exception { + public static JSONObject couJointDist(String token,String orderNo,String couTypeCode,Integer distCouCount,String userPhone,String thirdUserId) throws Exception { // 券列表 List> objectList = new ArrayList<>(); Map object = new HashMap<>(); @@ -93,7 +93,7 @@ public class HuiLianTongConfig { param.put("coupons", objectList); param.put("phone", userPhone); param.put("thirdUserId", thirdUserId); - param.put("orderNo", "HF"+new Date().getTime()); + param.put("orderNo", orderNo); param.put("distOuCode", "guizhouhltcs"); Map map = new HashMap<>(); diff --git a/hai-service/src/main/java/com/hai/service/impl/HighOrderServiceImpl.java b/hai-service/src/main/java/com/hai/service/impl/HighOrderServiceImpl.java index ed338459..45ca9baa 100644 --- a/hai-service/src/main/java/com/hai/service/impl/HighOrderServiceImpl.java +++ b/hai-service/src/main/java/com/hai/service/impl/HighOrderServiceImpl.java @@ -199,14 +199,14 @@ public class HighOrderServiceImpl implements HighOrderService { throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "获取token失败"); } Map push = new HashMap<>(); - push.put("token", "data"); + push.put("token", tokenObject.getString("data")); push.put("couTypeCode", coupon.getCouponKey()); push.put("distCouCount", highChildOrder.getSaleCount()); push.put("userPhone", highUser.getPhone()); push.put("thirdUserId", highUser.getUnionId()); // 推送给高速 - JSONObject returnParam = HuiLianTongConfig.couJointDist(tokenObject.getString("data"), coupon.getCouponKey(), highChildOrder.getSaleCount(), highUser.getPhone(), highUser.getUnionId()); + JSONObject returnParam = HuiLianTongConfig.couJointDist(tokenObject.getString("data"), highOrder.getOrderNo(), coupon.getCouponKey(), highChildOrder.getSaleCount(), highUser.getPhone(), highUser.getUnionId()); if (returnParam != null && returnParam.getString("result").equals("success")) { JSONArray dataArray = returnParam.getJSONArray("data"); for (Object data : dataArray) { @@ -353,14 +353,14 @@ public class HighOrderServiceImpl implements HighOrderService { throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "获取token失败"); } Map push = new HashMap<>(); - push.put("token", "data"); + push.put("token", tokenObject.getString("data")); push.put("couTypeCode", coupon.getCouponKey()); push.put("distCouCount", highChildOrder.getSaleCount()); push.put("userPhone", highUser.getPhone()); push.put("thirdUserId", highUser.getUnionId()); // 推送给高速 - JSONObject returnParam = HuiLianTongConfig.couJointDist(tokenObject.getString("data"), coupon.getCouponKey(), highChildOrder.getSaleCount(), highUser.getPhone(), highUser.getUnionId()); + JSONObject returnParam = HuiLianTongConfig.couJointDist(tokenObject.getString("data"), order.getOrderNo(),coupon.getCouponKey(), highChildOrder.getSaleCount(), highUser.getPhone(), highUser.getUnionId()); if (returnParam != null && returnParam.getString("result").equals("success")) { JSONArray dataArray = returnParam.getJSONArray("data"); for (Object data : dataArray) { diff --git a/hai-service/src/main/java/com/hai/service/pay/impl/GoodsOrderServiceImpl.java b/hai-service/src/main/java/com/hai/service/pay/impl/GoodsOrderServiceImpl.java index 771a8728..8d672557 100644 --- a/hai-service/src/main/java/com/hai/service/pay/impl/GoodsOrderServiceImpl.java +++ b/hai-service/src/main/java/com/hai/service/pay/impl/GoodsOrderServiceImpl.java @@ -129,14 +129,14 @@ public class GoodsOrderServiceImpl implements PayService { } Map push = new HashMap<>(); - push.put("token", "data"); + push.put("token", tokenObject.getString("data")); push.put("couTypeCode", coupon.getCouponKey()); push.put("distCouCount", highChildOrder.getSaleCount()); push.put("userPhone", highUser.getPhone()); push.put("thirdUserId", highUser.getUnionId()); // 推送给高速 - JSONObject returnParam = HuiLianTongConfig.couJointDist(tokenObject.getString("data"), coupon.getCouponKey(), highChildOrder.getSaleCount(), highUser.getPhone(), highUser.getUnionId()); + JSONObject returnParam = HuiLianTongConfig.couJointDist(tokenObject.getString("data"), order.getOrderNo(),coupon.getCouponKey(), highChildOrder.getSaleCount(), highUser.getPhone(), highUser.getUnionId()); if (returnParam != null && returnParam.getString("result").equals("success")) { JSONArray dataArray = returnParam.getJSONArray("data"); for (Object data : dataArray) {