From 74c430e012ade8363b57949357e3cf653b944a2d Mon Sep 17 00:00:00 2001
From: jinpengyong <jpy123456>
Date: Wed, 01 Nov 2023 15:41:31 +0800
Subject: [PATCH] chore:补充提交

---
 screen-api/src/main/resources/mapper/DeviceMapper.xml |   16 ++++++++++++++++
 1 files changed, 16 insertions(+), 0 deletions(-)

diff --git a/screen-api/src/main/resources/mapper/DeviceMapper.xml b/screen-api/src/main/resources/mapper/DeviceMapper.xml
index abda196..238bf81 100644
--- a/screen-api/src/main/resources/mapper/DeviceMapper.xml
+++ b/screen-api/src/main/resources/mapper/DeviceMapper.xml
@@ -192,4 +192,20 @@
         select mac from device where organization_id = #{organizationId} order by id desc
 
     </select>
+
+    <select id="getDevices" resultType="com.moral.api.pojo.vo.device.AppDeviceVo">
+        SELECT d.id,d.`name`,d.mac,d.special_type FROM device as d
+        where 1=1
+        <if test="organizationId !=null">
+            AND organization_id = #{organizationId}
+        </if>
+           and mac LIKE "%"#{mac}"%" AND is_delete = 0
+        union
+        SELECT sd.id,sd.`name`,sd.mac,sd.special_type FROM special_device  as sd
+        WHERE 1=1
+        <if test="organizationId !=null">
+            AND organization_id = #{organizationId}
+        </if>
+          and mac LIKE "%"#{mac}"%" AND is_delete = 0
+    </select>
 </mapper>
\ No newline at end of file

--
Gitblit v1.8.0