From 010f4ba252db180fc7fea4d7cb1b84a0bca7479f Mon Sep 17 00:00:00 2001
From: jinpengyong <jpy123456>
Date: Fri, 11 Aug 2023 16:37:43 +0800
Subject: [PATCH] Merge branch 'dev' of http://blit.7drlb.com:8888/r/moral into wb

---
 screen-api/src/main/resources/mapper/HistoryFiveMinutelyMapper.xml |   13 ++++++-------
 1 files changed, 6 insertions(+), 7 deletions(-)

diff --git a/screen-api/src/main/resources/mapper/HistoryFiveMinutelyMapper.xml b/screen-api/src/main/resources/mapper/HistoryFiveMinutelyMapper.xml
index 4e0901b..0de8ee6 100644
--- a/screen-api/src/main/resources/mapper/HistoryFiveMinutelyMapper.xml
+++ b/screen-api/src/main/resources/mapper/HistoryFiveMinutelyMapper.xml
@@ -12,13 +12,12 @@
         h.value->'$.a01008' AS windDir
         FROM history_five_minutely_${timeUnits} h ,
         `device` AS d
-        WHERE d.mac = h.mac
-        AND d.mac IN
-        (SELECT mac FROM device WHERE monitor_point_id IN
-            <foreach item="monitorPointId" collection="monitorPointIds" index="index" open="(" separator="," close=")">
-                #{monitorPointId}
-            </foreach>
-        )
+        WHERE d.is_delete = '0'
+        AND d.mac = h.mac
+        AND d.monitor_point_id IN
+        <foreach item="monitorPointId" collection="monitorPointIds" index="index" open="(" separator="," close=")">
+            #{monitorPointId}
+        </foreach>
         AND h.time = (SELECT max(time) FROM history_five_minutely_${timeUnits})
     </select>
 

--
Gitblit v1.8.0