生日提醒重置

This commit is contained in:
2025-10-17 10:48:37 +08:00
parent a86a2fbdac
commit b67969e032
5 changed files with 21 additions and 5 deletions

View File

@@ -270,6 +270,7 @@ public class MkBirthdayGiftServiceImpl extends ServiceImpl<MkBirthdayGiftMapper,
}
// 如果生日在范围内,返回优惠券列表
if (isInRange) {
shopUserService.updateById(new ShopUser().setId(shopUser.getId()).setBirthDayRemind(1));
return buildCouponList(config);
}
} catch (Exception e) {
@@ -282,6 +283,7 @@ public class MkBirthdayGiftServiceImpl extends ServiceImpl<MkBirthdayGiftMapper,
// 判断当前月份是否等于用户生日月份
if (current.getMonthValue() == thisYearBirthday.getMonthValue()
&& (current.isEqual(thisYearBirthday) || current.isBefore(thisYearBirthday))) {
shopUserService.updateById(new ShopUser().setId(shopUser.getId()).setBirthDayRemind(1));
return buildCouponList(config);
}
}
@@ -318,4 +320,6 @@ public class MkBirthdayGiftServiceImpl extends ServiceImpl<MkBirthdayGiftMapper,
}
return resultList;
}
}