Browse Source

sql判断添加

gao.qiang 2 years ago
parent
commit
e310ef5fe7

+ 3 - 0
business-service/src/main/resources/mapper/service/MsgAlarmMapper.xml

@@ -232,6 +232,9 @@
             <if test="isLock != null and isLock != 0">
                 and a.is_lock=#{isLock}
             </if>
+            <if test="lineDir != null and lineDir != 0">
+                and a.line_dir =#{lineDir}
+            </if>
             <if test="beginAlarmTime != null and beginAlarmTime != ''">
                 and date_format(a.alarm_time,'%Y-%m-%d %H:%i:%S') &gt;= date_format(#{beginAlarmTime},'%Y-%m-%d %H:%i:%S')
             </if>