Commit f5228c68 by 吕明尚

修改定时任务

parent be18f5c3
package share.web.controller.system;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.web.bind.annotation.*;
import share.common.annotation.Log;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import share.common.core.controller.BaseController;
import share.common.core.domain.AjaxResult;
import share.common.core.page.TableDataInfo;
import share.common.enums.BusinessType;
import share.common.utils.poi.ExcelUtil;
import share.system.domain.SPack;
import share.system.service.IPackService;
import javax.servlet.http.HttpServletResponse;
import java.util.List;
/**
......
......@@ -498,6 +498,7 @@ public class RedisTask {
Long consumerId = jsonObject.getLong("consumerId");
//判断当前的日期是否在第3天和第2天中
long expire = (expirationTime.getTime() - new Date().getTime()) / 1000 / 60;
logger.debug("当前时间还剩:" + expire);
if (THREE_DAY < expire && expire < FOUR_DAY) {
SConsumer sConsumer = sConsumerService.getById(consumerId);
logger.debug("手机号为:{}的用户年度权益会员将在3天后失效", sConsumer.getPhone());
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment