From e1d04d6ba96405159c6110883795fc603f1d2735 Mon Sep 17 00:00:00 2001 From: luogw <3132758203@qq.com> Date: Thu, 4 Jun 2026 09:07:27 +0800 Subject: [PATCH] =?UTF-8?q?bug=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/impl/QuestionInventoryDomainServiceImpl.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/main/java/com/project/question/domain/service/impl/QuestionInventoryDomainServiceImpl.java b/src/main/java/com/project/question/domain/service/impl/QuestionInventoryDomainServiceImpl.java index e5e9d97..518b1cd 100644 --- a/src/main/java/com/project/question/domain/service/impl/QuestionInventoryDomainServiceImpl.java +++ b/src/main/java/com/project/question/domain/service/impl/QuestionInventoryDomainServiceImpl.java @@ -1,5 +1,6 @@ package com.project.question.domain.service.impl; +import cn.hutool.core.date.DateUtil; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.project.base.domain.result.Result; import com.project.question.domain.entity.TaskKnowledgeClusterEntity; @@ -43,7 +44,7 @@ public class QuestionInventoryDomainServiceImpl implements QuestionInventoryDoma @Override public void checkAndReplenish(Long taskId) { TaskEntity task = taskMapper.selectById(taskId); - if (task == null || task.getEndTime().before(new Date())) { + if (task == null || DateUtil.endOfDay(task.getEndTime()).before(new Date())) { return; } int watermark = getWatermark(task); @@ -85,7 +86,7 @@ public class QuestionInventoryDomainServiceImpl implements QuestionInventoryDoma @Override public Result checkAndReplenishBoolean(Long taskId) { TaskEntity task = taskMapper.selectById(taskId); - if (task == null || task.getEndTime().before(new Date())) { + if (task == null || DateUtil.endOfDay(task.getEndTime()).before(new Date())) { return Result.success("考试任务不存在"); } int unpassed = getUnpassedCount(task);