From f1eb322a40a9155a1f6ba545596e758987d0a1c0 Mon Sep 17 00:00:00 2001
From: yinzuomei <576302893@qq.com>
Date: Thu, 21 Jul 2022 09:03:12 +0800
Subject: [PATCH] guoqi
---
.../src/main/resources/mapper/IcPolicyDao.xml | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/epmet-module/epmet-heart/epmet-heart-server/src/main/resources/mapper/IcPolicyDao.xml b/epmet-module/epmet-heart/epmet-heart-server/src/main/resources/mapper/IcPolicyDao.xml
index 9ab37dc06a..0bf133236c 100644
--- a/epmet-module/epmet-heart/epmet-heart-server/src/main/resources/mapper/IcPolicyDao.xml
+++ b/epmet-module/epmet-heart/epmet-heart-server/src/main/resources/mapper/IcPolicyDao.xml
@@ -53,8 +53,8 @@
ip.TITLE,
ip.CONTENT,
(
- case when ip.END_DATE < now() then '1'
- when ip.END_DATE >= now() then '0'
+ case when ip.END_DATE < DATE_FORMAT(now(),'%Y-%m-%d') then '1'
+ when ip.END_DATE >= DATE_FORMAT(now(),'%Y-%m-%d') then '0'
end
)as expiredFlag
FROM
@@ -70,10 +70,10 @@
and ip.CONTENT like concat('%',#{content},'%')
- and ip.END_DATE < now()
+ and ip.END_DATE < DATE_FORMAT(now(),'%Y-%m-%d')
- and ip.END_DATE >= now()
+ and ip.END_DATE >= DATE_FORMAT(now(),'%Y-%m-%d')
order by ip.CREATED_TIME desc