From 1bc7dc676eb862f6cc9121d1c4c6852e2ca16622 Mon Sep 17 00:00:00 2001 From: chenyouting <514333061@qq.com> Date: Sat, 11 Oct 2025 11:06:07 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8E=A7=E5=88=B6=E4=B8=AD=E5=BF=83=E6=9F=A5?= =?UTF-8?q?=E8=AF=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/resources/mapper/equipment/DeviceMapper.xml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/fys-modules/fys-equipment/src/main/resources/mapper/equipment/DeviceMapper.xml b/fys-modules/fys-equipment/src/main/resources/mapper/equipment/DeviceMapper.xml index 3879bea..ed240a5 100644 --- a/fys-modules/fys-equipment/src/main/resources/mapper/equipment/DeviceMapper.xml +++ b/fys-modules/fys-equipment/src/main/resources/mapper/equipment/DeviceMapper.xml @@ -259,12 +259,12 @@ d.online_status, c.binding_time, d.create_time, - ROW_NUMBER() OVER (PARTITION BY d.id ORDER BY c.binding_time) AS row_num + ROW_NUMBER() OVER (PARTITION BY d.id ORDER BY d.id) AS row_num from device d inner join device_type dt on d.device_type = dt.id left join app_device_bind_record c on d.id = c.device_id left join app_personnel_info ap on ap.device_id = d.id - where dt.communication_mode in (0, 2) ) a where a.row_num = 1 + where dt.communication_mode in (0, 2) ORDER BY (case when d.online_status = 1 then 2 else 1 end) DESC) a where a.row_num = 1 and a.device_type = #{criteria.deviceType} @@ -295,7 +295,7 @@ and a.online_status = #{criteria.onlineStatus} - ORDER BY (case when a.online_status = 1 then 2 else 1 end) DESC +