From b1c1c20ef382dd2be0f6bdf81f5d2913e749faef Mon Sep 17 00:00:00 2001 From: jiangping <jp@doumee.com> Date: 星期四, 12 十月 2023 11:12:02 +0800 Subject: [PATCH] 整理接口 --- server/platform/src/main/java/com/doumee/task/ScheduleTool.java | 19 +++++++------------ 1 files changed, 7 insertions(+), 12 deletions(-) diff --git a/server/platform/src/main/java/com/doumee/task/ScheduleTool.java b/server/platform/src/main/java/com/doumee/task/ScheduleTool.java index fe11644..71b740e 100644 --- a/server/platform/src/main/java/com/doumee/task/ScheduleTool.java +++ b/server/platform/src/main/java/com/doumee/task/ScheduleTool.java @@ -3,10 +3,12 @@ import com.doumee.biz.system.SystemDictDataBiz; import com.doumee.core.constants.Constants; +import com.doumee.core.exception.BusinessException; import com.doumee.core.utils.DateUtil; import com.doumee.dao.business.model.Goodsorder; import com.doumee.service.business.GoodsorderService; import com.doumee.service.business.WxBillService; +import lombok.extern.slf4j.Slf4j; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.scheduling.annotation.EnableScheduling; import org.springframework.scheduling.annotation.Scheduled; @@ -24,6 +26,7 @@ */ @Component @EnableScheduling +@Slf4j public class ScheduleTool { @@ -50,19 +53,11 @@ * 娓│ * @throws Exception */ -// @Scheduled(fixedDelay = 1000*60) + @Scheduled(cron = "0 0 21 * * ? ") public void getYesterdayBill() throws Exception { - - Goodsorder goodsorder = new Goodsorder(); - goodsorder.setIsdeleted(Constants.ZERO); - goodsorder.setStatus(Constants.goodsorderStatus.pay); - List<Goodsorder> list = goodsorderService.findList(goodsorder); - if (!CollectionUtils.isEmpty(list)){ - list.forEach(s->{ - goodsorderService.closerGoodsorder(s.getId()); - }); - - } + log.info("=====================寮�濮嬫瘡澶╄嚜鍔ㄧ粨绠�======================="); + goodsorderService.autoCloseOrder(); + log.info("=====================缁撴潫姣忓ぉ鑷姩缁撶畻======================="); } } -- Gitblit v1.9.3