| | |
| | | */ |
| | | package org.springblade.modules.device.mapper; |
| | | |
| | | import org.apache.ibatis.annotations.Param; |
| | | import org.springblade.modules.device.entity.DeviceEntity; |
| | | import org.springblade.modules.device.vo.DeviceVO; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | |
| | | * @param device |
| | | * @return |
| | | */ |
| | | List<DeviceVO> selectDevicePage(IPage page, DeviceVO device); |
| | | List<DeviceVO> selectDevicePage(IPage page, @Param("device") DeviceVO device); |
| | | |
| | | |
| | | } |
| | |
| | | |
| | | |
| | | <select id="selectDevicePage" resultMap="deviceResultMap"> |
| | | select * from sys_device where is_deleted = 0 |
| | | select * from sys_device |
| | | where is_deleted = 0 |
| | | <if test="device.name !=null and device.name !=''"> |
| | | AND name LIKE CONCAT('%',#{device.name},'%') |
| | | </if> |
| | | </select> |
| | | |
| | | |
| | |
| | | <if test="user.phone !=null and user.phone !='' "> |
| | | AND phone LIKE CONCAT('%',#{user.phone},'%') |
| | | </if> |
| | | <if test="user.roleId !=null and user.roleId !=''"> |
| | | AND FIND_IN_SET(role_id,#{user.roleId}) |
| | | </if> |
| | | <if test="user.deptId !=null and user.deptId !=''"> |
| | | AND dept_id = #{user.deptId} |
| | | </if> |
| | | ORDER BY id |
| | | </select> |
| | | |