领取优惠券操作

This commit is contained in:
19991905653 2024-04-13 10:39:47 +08:00
parent e86ec29a33
commit f203d7bccc
1 changed files with 2 additions and 1 deletions

View File

@ -374,11 +374,12 @@ public class OrderService {
if (Objects.isNull(userCoupons) || userCoupons.getIsDouble().equals("true")){
throw new MsgException("该优惠券翻倍已领取");
}
modityDouble(conponsId);
return Result.success(CodeEnum.SUCCESS);
}
private void modityDouble(Integer conponsId) throws ParseException {
private void modityDouble(Integer conponsId) {
boolean lock_coin = redisUtils.lock(RedisCst.COUPONS_COIN_KEY + conponsId, 5000, TimeUnit.MILLISECONDS);
if (lock_coin) {