Showing
3 changed files
with
22 additions
and
9 deletions
@@ -34,6 +34,16 @@ public class OrderInfo implements Serializable { | @@ -34,6 +34,16 @@ public class OrderInfo implements Serializable { | ||
34 | //平台(web/wap/app) | 34 | //平台(web/wap/app) |
35 | private String orderType; | 35 | private String orderType; |
36 | 36 | ||
37 | + private String isNew; | ||
38 | + | ||
39 | + public String getIsNew() { | ||
40 | + return isNew; | ||
41 | + } | ||
42 | + | ||
43 | + public void setIsNew(String isNew) { | ||
44 | + this.isNew = isNew; | ||
45 | + } | ||
46 | + | ||
37 | public String getMbrName() { | 47 | public String getMbrName() { |
38 | return mbrName; | 48 | return mbrName; |
39 | } | 49 | } |
@@ -80,14 +80,15 @@ public class OrderUnionRest { | @@ -80,14 +80,15 @@ public class OrderUnionRest { | ||
80 | IOrderPushService pushService = SpringContextUtil.getBean("orderPushServiceImpl", IOrderPushService.class); | 80 | IOrderPushService pushService = SpringContextUtil.getBean("orderPushServiceImpl", IOrderPushService.class); |
81 | List<OrderInfo> orderInfoList = new ArrayList<>(); | 81 | List<OrderInfo> orderInfoList = new ArrayList<>(); |
82 | OrderInfo orderInfo = new OrderInfo(); | 82 | OrderInfo orderInfo = new OrderInfo(); |
83 | - orderInfo.setParentOrderCode("111"); | 83 | + orderInfo.setParentOrderCode("111224567231389"); |
84 | orderInfo.setOrderTime(1482391381); | 84 | orderInfo.setOrderTime(1482391381); |
85 | orderInfo.setPayment("1"); | 85 | orderInfo.setPayment("1"); |
86 | orderInfo.setOrderAmount(new BigDecimal(1)); | 86 | orderInfo.setOrderAmount(new BigDecimal(1)); |
87 | orderInfo.setShippingCost(new BigDecimal(1)); | 87 | orderInfo.setShippingCost(new BigDecimal(1)); |
88 | orderInfo.setOrderStatus("1"); | 88 | orderInfo.setOrderStatus("1"); |
89 | orderInfo.setOrderType("web"); | 89 | orderInfo.setOrderType("web"); |
90 | - orderInfo.setClientId("1010"); | 90 | + orderInfo.setClientId("3017"); |
91 | + orderInfo.setIsNew("Y"); | ||
91 | List<OrdersGood> ordersGoods = new ArrayList<>(); | 92 | List<OrdersGood> ordersGoods = new ArrayList<>(); |
92 | for(int i = 0;i<1;i++){ | 93 | for(int i = 0;i<1;i++){ |
93 | OrdersGood ordersGood = new OrdersGood(); | 94 | OrdersGood ordersGood = new OrdersGood(); |
@@ -50,6 +50,8 @@ public class OrderPushServiceImpl implements IOrderPushService{ | @@ -50,6 +50,8 @@ public class OrderPushServiceImpl implements IOrderPushService{ | ||
50 | param.put("orderShipCost",orderInfo.getShippingCost()); | 50 | param.put("orderShipCost",orderInfo.getShippingCost()); |
51 | //订单来源平台,(web,wap,app) | 51 | //订单来源平台,(web,wap,app) |
52 | param.put("orderType",orderInfo.getOrderType()); | 52 | param.put("orderType",orderInfo.getOrderType()); |
53 | + //是否是新客 | ||
54 | + param.put("isNew",orderInfo.getIsNew()); | ||
53 | //商品最终支付金额 | 55 | //商品最终支付金额 |
54 | BigDecimal proRealPay = new BigDecimal(0); | 56 | BigDecimal proRealPay = new BigDecimal(0); |
55 | //如果有多个则需要将多个商品进行分割 | 57 | //如果有多个则需要将多个商品进行分割 |
@@ -125,13 +127,13 @@ public class OrderPushServiceImpl implements IOrderPushService{ | @@ -125,13 +127,13 @@ public class OrderPushServiceImpl implements IOrderPushService{ | ||
125 | } catch (Exception e) { | 127 | } catch (Exception e) { |
126 | logger.error("common order post fail,orderCode is {}", orderInfo.getParentOrderCode()); | 128 | logger.error("common order post fail,orderCode is {}", orderInfo.getParentOrderCode()); |
127 | } | 129 | } |
128 | - JSONObject json = JSONObject.parseObject(pair.getRight()); | ||
129 | - if (((String) json.get("code")).equals("200")) { | ||
130 | - logger.info("common pushOrder success,orderCode is {}", orderInfo.getParentOrderCode()); | ||
131 | - successCodes.add(orderInfo.getParentOrderCode()); | ||
132 | - } else { | ||
133 | - logger.warn("common pushOrder fail,orderCode is {},message is {}", orderInfo.getParentOrderCode(), (String) json.get("msg")); | ||
134 | - } | 130 | +// JSONObject json = JSONObject.parseObject(pair.getRight()); |
131 | +// if (((String) json.get("code")).equals("200")) { | ||
132 | +// logger.info("common pushOrder success,orderCode is {}", orderInfo.getParentOrderCode()); | ||
133 | +// successCodes.add(orderInfo.getParentOrderCode()); | ||
134 | +// } else { | ||
135 | +// logger.warn("common pushOrder fail,orderCode is {},message is {}", orderInfo.getParentOrderCode(), (String) json.get("msg")); | ||
136 | +// } | ||
135 | } | 137 | } |
136 | } | 138 | } |
137 | } | 139 | } |
-
Please register or login to post a comment