package com.iailab.module.data.channel.modbus.dao; import com.iailab.framework.common.pojo.PageResult; import com.iailab.framework.mybatis.core.mapper.BaseMapperX; import com.iailab.framework.mybatis.core.query.LambdaQueryWrapperX; import com.iailab.framework.tenant.core.db.dynamic.TenantDS; import com.iailab.module.data.channel.modbus.entity.ChannelModBusTagEntity; import com.iailab.module.data.channel.modbus.vo.ModBusTagPageReqVO; import org.apache.ibatis.annotations.Mapper; import org.apache.ibatis.annotations.Param; import java.util.List; /** * @author lirm * @Description * @createTime 2024年08月27日 */ @TenantDS @Mapper public interface ChannelModBusTagDao extends BaseMapperX { default PageResult selectPage(ModBusTagPageReqVO reqVO) { return selectPage(reqVO, new LambdaQueryWrapperX() .likeIfPresent(ChannelModBusTagEntity::getTagName, reqVO.getTagName()) .likeIfPresent(ChannelModBusTagEntity::getAddress, reqVO.getAddress()) .likeIfPresent(ChannelModBusTagEntity::getTagDesc, reqVO.getTagDesc()) .likeIfPresent(ChannelModBusTagEntity::getDevice, reqVO.getDevice()) .orderByDesc(ChannelModBusTagEntity::getCreateTime)); } }