|
|
@@ -176,6 +176,9 @@ public class PosServiceImpl implements PosService { |
|
|
} else { |
|
|
} else { |
|
|
dataMap.put(WxPayConstant.ORDER_CREATE_SN, orderCreateSN); |
|
|
dataMap.put(WxPayConstant.ORDER_CREATE_SN, orderCreateSN); |
|
|
} |
|
|
} |
|
|
|
|
|
if (StringUtils.isBlank(coListStr)) { |
|
|
|
|
|
errParam(WxPayConstant.COUPON_ORDER_LIST); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
Integer iSceneType; |
|
|
Integer iSceneType; |
|
|
try { |
|
|
try { |
|
|
@@ -219,9 +222,7 @@ public class PosServiceImpl implements PosService { |
|
|
} |
|
|
} |
|
|
JSONObject promotionCoupon = new JSONObject(); |
|
|
JSONObject promotionCoupon = new JSONObject(); |
|
|
JSONArray couponList = new JSONArray(); |
|
|
JSONArray couponList = new JSONArray(); |
|
|
if (StringUtils.isBlank(coListStr)) { |
|
|
|
|
|
errParam(WxPayConstant.COUPON_ORDER_LIST); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
JSONArray couponOrderArr = JSON.parseArray(coListStr); |
|
|
JSONArray couponOrderArr = JSON.parseArray(coListStr); |
|
|
if (couponOrderArr.size() != 1) { |
|
|
if (couponOrderArr.size() != 1) { |
|
|
String errMessage = "核销只能使用一张券"; |
|
|
String errMessage = "核销只能使用一张券"; |
|
|
@@ -316,6 +317,7 @@ public class PosServiceImpl implements PosService { |
|
|
coQ.put("cUserId", user.getId()); |
|
|
coQ.put("cUserId", user.getId()); |
|
|
coQ.put("merchantId", merchantId); |
|
|
coQ.put("merchantId", merchantId); |
|
|
List<WxCouponOrderCVo> avaCoList = couponOrderMapper.findAvailCouponOrder(coQ); |
|
|
List<WxCouponOrderCVo> avaCoList = couponOrderMapper.findAvailCouponOrder(coQ); |
|
|
|
|
|
|
|
|
JSONArray selCoArr = JSONObject.parseArray(coListStr); |
|
|
JSONArray selCoArr = JSONObject.parseArray(coListStr); |
|
|
if (config.getCoupon().equals(EnumPosCouponEnableType.SingleEnable.getCode())) { |
|
|
if (config.getCoupon().equals(EnumPosCouponEnableType.SingleEnable.getCode())) { |
|
|
if (selCoArr.size() > 1) { // 为空时,返回所有可用券列表 |
|
|
if (selCoArr.size() > 1) { // 为空时,返回所有可用券列表 |
|
|
|