Browse Source

管网场景修改

wangyangyang 3 years ago
parent
commit
fb78e2fa9a
1 changed files with 2 additions and 2 deletions
  1. 2 2
      sms_water/src/main/resources/mapper/HomePageReportMapper.xml

+ 2 - 2
sms_water/src/main/resources/mapper/HomePageReportMapper.xml

@@ -175,11 +175,11 @@
         from (
             select
             s.id as "sceneId"
-            ,sum( if(dp.PARM_TYPE IN
+            ,if(sum( if(dp.PARM_TYPE IN
                 <foreach collection="parmTypes" item="item" open="(" close=")" separator=",">
                     #{item}
                 </foreach>
-                and ad.id is not null,1,0) ) AS "alarmNumber"
+                and ad.id is not null,1,0) )>0,1,0 )AS "alarmNumber"
             from sms_scene_type st
             left join sms_scene s on s.SCENE_TYPE_ID =st.id and PARENT_SCENE_ID ='0'
             left join sms_device_parm dp on dp.PARENT_SCENE_ID =s.ID