Authored by zhengwen.ge

推送优化

@@ -68,6 +68,10 @@ public class OrderPushServiceImpl implements IOrderPushService{ @@ -68,6 +68,10 @@ public class OrderPushServiceImpl implements IOrderPushService{
68 param.put("proSortName", good.getSortName()); 68 param.put("proSortName", good.getSortName());
69 //商品分类id 69 //商品分类id
70 param.put("proSortId",good.getSortId()); 70 param.put("proSortId",good.getSortId());
  71 + //商品分摊之后的价格
  72 + param.put("proLastPrice",good.getRealPayFee());
  73 + //商品的折扣,优惠
  74 + param.put("proDiscountFee",good.getDiscountFee());
71 //商品最终支付金额 75 //商品最终支付金额
72 proRealPay = good.getRealPayFee().setScale(2, BigDecimal.ROUND_HALF_UP); 76 proRealPay = good.getRealPayFee().setScale(2, BigDecimal.ROUND_HALF_UP);
73 } else { 77 } else {
@@ -77,6 +81,9 @@ public class OrderPushServiceImpl implements IOrderPushService{ @@ -77,6 +81,9 @@ public class OrderPushServiceImpl implements IOrderPushService{
77 StringBuffer names = new StringBuffer(); 81 StringBuffer names = new StringBuffer();
78 StringBuffer cats = new StringBuffer(); 82 StringBuffer cats = new StringBuffer();
79 StringBuffer sortIds = new StringBuffer(); 83 StringBuffer sortIds = new StringBuffer();
  84 + StringBuffer discountFee = new StringBuffer();
  85 + //商品的实际金额,分摊之后的,例如用户满减了,这个金额就是分摊之后的
  86 + StringBuffer lastPrice = new StringBuffer();
80 for (int i = 0; i < goods.size(); i++) { 87 for (int i = 0; i < goods.size(); i++) {
81 skns.append(goods.get(i).getProductSkn() + "|"); 88 skns.append(goods.get(i).getProductSkn() + "|");
82 prices.append(goods.get(i).getLastPrice().setScale(2, BigDecimal.ROUND_HALF_UP).doubleValue() + "|"); 89 prices.append(goods.get(i).getLastPrice().setScale(2, BigDecimal.ROUND_HALF_UP).doubleValue() + "|");
@@ -84,15 +91,18 @@ public class OrderPushServiceImpl implements IOrderPushService{ @@ -84,15 +91,18 @@ public class OrderPushServiceImpl implements IOrderPushService{
84 names.append(goods.get(i).getProductName() + "|"); 91 names.append(goods.get(i).getProductName() + "|");
85 cats.append(goods.get(i).getSortName() + "|"); 92 cats.append(goods.get(i).getSortName() + "|");
86 sortIds.append(goods.get(i).getSortId()+"|"); 93 sortIds.append(goods.get(i).getSortId()+"|");
  94 + lastPrice.append(goods.get(i).getRealPayFee()+"|");
  95 + discountFee.append(goods.get(i).getDiscountFee()+"|");
87 proRealPay = proRealPay.add(goods.get(i).getRealPayFee()); 96 proRealPay = proRealPay.add(goods.get(i).getRealPayFee());
88 -  
89 } 97 }
90 param.put("proNo", skns.substring(0, skns.length() - 1)); 98 param.put("proNo", skns.substring(0, skns.length() - 1));
91 param.put("proPrice", prices.substring(0, prices.length() - 1)); 99 param.put("proPrice", prices.substring(0, prices.length() - 1));
92 param.put("proNum", nums.substring(0, nums.length() - 1)); 100 param.put("proNum", nums.substring(0, nums.length() - 1));
93 param.put("proName", names.substring(0, names.length() - 1)); 101 param.put("proName", names.substring(0, names.length() - 1));
94 param.put("proSortName", cats.substring(0, cats.length() - 1)); 102 param.put("proSortName", cats.substring(0, cats.length() - 1));
95 - param.put("proSortId", sortIds.substring(0, cats.length() - 1)); 103 + param.put("proSortId", sortIds.substring(0, sortIds.length() - 1));
  104 + param.put("proLastPrice",lastPrice.substring(0, lastPrice.length() - 1));
  105 + param.put("proDiscountFee",discountFee.substring(0,discountFee.length()-1));
96 } 106 }
97 param.put("proRealPay",proRealPay.doubleValue()); 107 param.put("proRealPay",proRealPay.doubleValue());
98 //渠道id 108 //渠道id
@@ -125,3 +135,4 @@ public class OrderPushServiceImpl implements IOrderPushService{ @@ -125,3 +135,4 @@ public class OrderPushServiceImpl implements IOrderPushService{
125 } 135 }
126 } 136 }
127 } 137 }
  138 +