|
|
|
@@ -2385,17 +2385,19 @@ public class WxCouponOrderServiceImpl implements WxCouponOrderService { |
|
|
|
coQ.put("merchantId", user.getMerchantId()); |
|
|
|
List<WxCouponOrderCVo> avaCoList = this.findAvailCouponOrder(user,cUser.getId(),user.getMerchantId(),null); |
|
|
|
JSONArray couponList = new JSONArray(); |
|
|
|
for(int i=0;i<avaCoList.size();i++) { |
|
|
|
WxCouponOrderCVo couponOrderCVo = avaCoList.get(i); |
|
|
|
try { |
|
|
|
JSONObject couponObj = calcOneCouponPay(couponOrderCVo, payPrice); |
|
|
|
couponList.add(couponObj); |
|
|
|
} catch (MallinkException e) { |
|
|
|
logger.error(e.getMessage(),e); |
|
|
|
} catch (Exception e) { |
|
|
|
logger.error(e.getMessage(),e); |
|
|
|
} |
|
|
|
} |
|
|
|
if(avaCoList != null && avaCoList.size() > 0){ |
|
|
|
for(int i=0;i<avaCoList.size();i++) { |
|
|
|
WxCouponOrderCVo couponOrderCVo = avaCoList.get(i); |
|
|
|
try { |
|
|
|
JSONObject couponObj = calcOneCouponPay(couponOrderCVo, payPrice); |
|
|
|
couponList.add(couponObj); |
|
|
|
} catch (MallinkException e) { |
|
|
|
logger.error(e.getMessage(),e); |
|
|
|
} catch (Exception e) { |
|
|
|
logger.error(e.getMessage(),e); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
return couponList; |
|
|
|
} |
|
|
|
|
|
|
|
|