Commit b8a51563 authored by KeYong's avatar KeYong

修改物联报表附件查询逻辑

parent df163094
...@@ -1603,16 +1603,15 @@ ...@@ -1603,16 +1603,15 @@
<select id="getAlarmDetailByDate" resultType="Map"> <select id="getAlarmDetailByDate" resultType="Map">
SELECT SELECT
wlesa.equipment_specific_id, wlesa.equipment_specific_id,
wlesa.equipment_specific_name AS specificName, wlesa.equipment_specific_name AS specificName,
wlesa.location AS location, wlesa.location AS location,
wlesa.equipment_specific_index_name, wlesa.equipment_specific_index_name,
concat(wlesa.equipment_specific_name, wlesa.equipment_specific_index_name) AS alamContent, concat(wlesa.equipment_specific_name, wlesa.equipment_specific_index_name) AS alamContent,
wlesa.frequency AS alarmNum, IFNULL(SUM(wlesa.frequency), 0) AS alarmNum,
DATE_FORMAT(wlesa.create_date, '%Y-%m-%d %H:%i:%s') AS createDate DATE_FORMAT(wlesa.update_date, '%Y-%m-%d %H:%i:%s') AS createDate
FROM FROM
`wl_equipment_specific_alarm` `wlesa` `wl_equipment_specific_alarm` `wlesa`
LEFT JOIN f_fire_fighting_system AS sys ON FIND_IN_SET(sys.id, wlesa.system_ids)
<where> <where>
<if test="bizOrgCode != null and bizOrgCode != ''">AND <if test="bizOrgCode != null and bizOrgCode != ''">AND
wlesa.biz_org_code like concat (#{bizOrgCode},'%') wlesa.biz_org_code like concat (#{bizOrgCode},'%')
...@@ -1623,6 +1622,6 @@ ...@@ -1623,6 +1622,6 @@
AND find_in_set(#{sysId}, wlesa.system_ids) AND find_in_set(#{sysId}, wlesa.system_ids)
</if> </if>
</where> </where>
ORDER BY wlesa.create_date DESC ORDER BY wlesa.update_date DESC
</select> </select>
</mapper> </mapper>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment