| | |
| | | <where> |
| | | dar.is_deleted = 0 |
| | | AND d.is_enabled = 1 |
| | | |
| | | <if test="param2.regionCode != null and param2.regionCode != ''"> |
| | | AND ( |
| | | d.final_outbound_area_code LIKE CONCAT(#{param2.regionCode}, '%') |
| | |
| | | <if test="param2.deviceId != null and param2.deviceId != ''"> |
| | | AND dar.device_id::text = #{param2.deviceId}::text |
| | | </if> |
| | | |
| | | <if test="param2.droneName != null and param2.droneName != ''"> |
| | | AND ( |
| | | dar.drone_name::text LIKE CONCAT('%', #{param2.droneName}::text, '%') |
| | |
| | | <if test="param2.areaName != null and param2.areaName != ''"> |
| | | AND dar.area_name::text LIKE CONCAT('%', #{param2.areaName}::text, '%') |
| | | </if> |
| | | ORDER BY favorited DESC, dar.alarm_time DESC |
| | | </where> |
| | | ORDER BY favorited DESC, dar.alarm_time DESC |
| | | </select> |
| | | |
| | | |