From 54c0125835e850b97793601ac45ee62fa1c4b12e Mon Sep 17 00:00:00 2001
From: jinpengyong <jpy123456>
Date: Fri, 27 Oct 2023 09:36:24 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/wb' into qa
---
screen-api/src/main/resources/mapper/AlarmInfoMapper.xml | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/screen-api/src/main/resources/mapper/AlarmInfoMapper.xml b/screen-api/src/main/resources/mapper/AlarmInfoMapper.xml
index 96d10d7..9251add 100644
--- a/screen-api/src/main/resources/mapper/AlarmInfoMapper.xml
+++ b/screen-api/src/main/resources/mapper/AlarmInfoMapper.xml
@@ -53,7 +53,8 @@
<select id="selectNewestData" resultType="java.util.Map">
select ai.id alarmInfoId,ai.alarm_time,ai.index,ai.alarm_type,ai.alarm_information,d.id deviceId,d.name deviceName,d.longitude,d.latitude
from alarm_info ai, device d
- where ai.alarm_time = (SELECT max(DATE_FORMAT(alarm_time,'%Y-%m-%d')) from alarm_info limit 1) and d.id = ai.device_id and ai.device_id in
+ where
+ DATE_FORMAT(ai.alarm_time,'%Y-%m-%d') = (SELECT DATE_FORMAT(max( alarm_time),'%Y-%m-%d') from alarm_info limit 1) and d.id = ai.device_id and ai.device_id in
(select t.id from device t
inner JOIN monitor_point p on p.id = t.monitor_point_id and p.is_delete = 0
--
Gitblit v1.8.0