分享奖励接口修改

This commit is contained in:
张松 2025-03-11 09:56:43 +08:00
parent fcb458fa73
commit 6bb75935c9
1 changed files with 1 additions and 1 deletions

View File

@ -58,7 +58,7 @@ public class ShopShareServiceImpl extends ServiceImpl<ShopShareMapper, ShopShare
@Override
public Boolean add(Long shopId, ShopShareDTO shopShareDTO) {
if (shopShareDTO.getNewCouponList() != null && !shopShareDTO.getRewardCouponList().isEmpty()) {
if (shopShareDTO.getNewCouponList() != null && !shopShareDTO.getNewCouponList().isEmpty()) {
long count = shopCouponService.count(new QueryWrapper().in(ShopCoupon::getId, shopShareDTO.getNewCouponList().stream().map(ShopShareCouponDTO::getId).toList()).eq(ShopCoupon::getShopId, shopId));
if (count != shopShareDTO.getNewCouponList().size()) {
throw new ApiNotPrintException("优惠券不存在");