|
|
@@ -763,7 +763,7 @@ public class WxOrderServiceImpl implements WxOrderService { |
|
|
int num = wxCouponMapper.backInventory(coupon.getId(), 1, coupon.getRemainInventory()); |
|
|
int num = wxCouponMapper.backInventory(coupon.getId(), 1, coupon.getRemainInventory()); |
|
|
if (num <= 0) { |
|
|
if (num <= 0) { |
|
|
logger.error("此券加库存失败, couponId: " + couponIdStr); |
|
|
logger.error("此券加库存失败, couponId: " + couponIdStr); |
|
|
throw new MallinkException(ErrorCode.ORDER_IS_FAIL); |
|
|
|
|
|
|
|
|
throw new MallinkException(ErrorCode.ORDER_IS_FAIL.getCode(),"券couponId:["+couponIdStr+"]库存回滚失败,更新记录条数小于等于0."); |
|
|
} |
|
|
} |
|
|
redisLock.increase(EnumCacheKey.COUPON_STOCK.getMessage()+coupon.getId(), 1); |
|
|
redisLock.increase(EnumCacheKey.COUPON_STOCK.getMessage()+coupon.getId(), 1); |
|
|
} catch (Exception e) { |
|
|
} catch (Exception e) { |
|
|
|