1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253 |
- <?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="com.zy.bms.mapper.ubi.UbiInfoStateMapper">
- <select id="listPage" resultType="com.zy.bms.pojo.vo.UbiDeviceListVo">
- SELECT
- t1.open_num,
- t1.username,
- t1.password,
- t1.sn,
- t1.create_time,
- t1.group_id,
- t2.*
- FROM
- device_base t1
- LEFT JOIN
- ubi_info_state t2 ON t1.open_num = t2.open_num
- WHERE
- t1.type = "gnss"
- <if test="io.openNum != null and io.openNum != ''">
- AND t1.open_num LIKE CONCAT('%',#{io.openNum},'%')
- </if>
- <if test="io.groupId != null and io.groupId > -1">
- AND t1.group_id = #{io.groupId}
- </if>
- <if test="io.status != null and io.status > -1">
- AND t2.status = #{io.status}
- </if>
- </select>
- <select id="getDetail" resultType="com.zy.bms.pojo.vo.UbiDeviceDetailVo">
- SELECT
- *
- FROM
- ubi_info_state
- WHERE
- open_num = #{openNum}
- </select>
- <select id="listByGroupIdWx" resultType="com.zy.bms.pojo.vo.UbiDeviceListVo">
- SELECT
- t1.open_num,
- t2.freq,
- t2.update_time
- FROM
- device_base t1
- LEFT JOIN
- ubi_info_state t2 ON t1.open_num = t2.open_num
- WHERE
- t1.type = "gnss" AND t1.group_id = #{group}
- </select>
- </mapper>
|