物业模块删除厂商
安防模块增加厂商 设备模块逻辑优化
This commit is contained in:
@@ -4,4 +4,48 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="org.dromara.sis.mapper.SisDeviceManageMapper">
|
||||
|
||||
|
||||
<select id="selectByPage" resultType="org.dromara.sis.domain.vo.SisDeviceManageVo">
|
||||
SELECT
|
||||
a.*,
|
||||
b.factory_name factoryName,
|
||||
c.name groupName
|
||||
FROM
|
||||
sis_device_manage a
|
||||
LEFT JOIN tb_factory b ON a.factory_no = b.factory_no
|
||||
LEFT JOIN sis_device_group c ON a.group_id = c.id
|
||||
<where>
|
||||
<!-- 设备名称模糊查询 -->
|
||||
<if test="bo.deviceName != null and bo.deviceName != ''">
|
||||
AND device_name LIKE CONCAT('%', #{bo.deviceName}, '%')
|
||||
</if>
|
||||
|
||||
<!-- 设备IP精确匹配 -->
|
||||
<if test="bo.deviceIp != null and bo.deviceIp != ''">
|
||||
AND device_ip = #{bo.deviceIp}
|
||||
</if>
|
||||
|
||||
<!-- 设备端口精确匹配 -->
|
||||
<if test="bo.devicePort != null">
|
||||
AND device_port = #{bo.devicePort}
|
||||
</if>
|
||||
|
||||
<!-- 设备MAC地址精确匹配 -->
|
||||
<if test="bo.deviceMac != null and bo.deviceMac != ''">
|
||||
AND device_mac = #{bo.deviceMac}
|
||||
</if>
|
||||
|
||||
<!-- 设备类型精确匹配 -->
|
||||
<if test="bo.deviceType != null">
|
||||
AND device_type = #{bo.deviceType}
|
||||
</if>
|
||||
|
||||
<!-- 出厂编号精确匹配 -->
|
||||
<if test="bo.factoryNo != null and bo.factoryNo != ''">
|
||||
AND factory_no = #{bo.factoryNo}
|
||||
</if>
|
||||
</where>
|
||||
ORDER BY a.create_time desc
|
||||
|
||||
</select>
|
||||
</mapper>
|
||||
|
@@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="org.dromara.sis.mapper.TbFactoryMapper">
|
||||
|
||||
</mapper>
|
Reference in New Issue
Block a user