From c363540ce0469e6754329c1be5e56a63ec1d344f Mon Sep 17 00:00:00 2001 From: jinpengyong <jpy123456> Date: Mon, 27 Dec 2021 15:40:41 +0800 Subject: [PATCH] 行业贡献率 --- screen-api/src/main/resources/mapper/AlarmInfoMapper.xml | 18 ++++++++++++++++++ 1 files changed, 18 insertions(+), 0 deletions(-) diff --git a/screen-api/src/main/resources/mapper/AlarmInfoMapper.xml b/screen-api/src/main/resources/mapper/AlarmInfoMapper.xml index 187b2e5..d49905f 100644 --- a/screen-api/src/main/resources/mapper/AlarmInfoMapper.xml +++ b/screen-api/src/main/resources/mapper/AlarmInfoMapper.xml @@ -32,6 +32,24 @@ limit #{start},#{size} </select> + <select id="selectDataByConditionWithoutPage" 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.device_id in + <foreach collection="deviceIds" item="deviceId" index="index" open="(" close=")" separator=","> + #{deviceId} + </foreach> + and d.id = ai.device_id + <if test="index != null"> + and ai.index = #{index} + </if> + <if test="alarmType != null"> + and ai.alarm_type = #{alarmType} + </if> + and alarm_time between #{startTime} and #{endTime} + ORDER by ai.create_time DESC + </select> + <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 -- Gitblit v1.8.0