| | |
| | | import com.ruoyi.account.api.model.TAppUserVipDetail; |
| | | import com.ruoyi.account.service.TAppUserService; |
| | | import com.ruoyi.account.service.TAppUserVipDetailService; |
| | | import org.intellij.lang.annotations.RegExp; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.scheduling.annotation.Scheduled; |
| | | import org.springframework.stereotype.Component; |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.time.LocalDate; |
| | | import java.time.LocalDateTime; |
| | | import java.util.List; |
| | | |
| | | |
| | |
| | | |
| | | @Scheduled(fixedRate = 1000 * 60) |
| | | public void changeVipId(){ |
| | | LocalDate currentDate = LocalDate.now(); |
| | | LocalDateTime currentDate = LocalDateTime.now(); |
| | | List<TAppUserVipDetail> recentDetails = tAppUserVipDetailService.lambdaQuery() |
| | | .le(TAppUserVipDetail::getStartTime, currentDate) |
| | | .ge(TAppUserVipDetail::getEndTime, currentDate) |