dongyukun
2024-11-05 e8ad669f7c97d45cd23630dc101180a130d6c17e
提交 | 用户 | 时间
ce910c 1 package com.iailab.module.data.dev.dao;
H 2
3 import com.iailab.framework.common.pojo.PageResult;
4 import com.iailab.framework.mybatis.core.mapper.BaseMapperX;
5 import com.iailab.framework.mybatis.core.query.LambdaQueryWrapperX;
6 import com.iailab.framework.tenant.core.db.dynamic.TenantDS;
7 import com.iailab.module.data.dev.controller.admin.nvr.vo.DevNvrPageReqVO;
8 import com.iailab.module.data.dev.entity.DevNvrEntity;
9 import org.apache.ibatis.annotations.Mapper;
10
11 /**
12  * @author PanZhibao
13  * @Description
14  * @createTime 2024年03月06日
15  */
16 @TenantDS
17 @Mapper
18 public interface DevNvrDao extends BaseMapperX<DevNvrEntity> {
19
20     default PageResult<DevNvrEntity> selectPage(DevNvrPageReqVO pageReqVO) {
21         return selectPage(pageReqVO, new LambdaQueryWrapperX<DevNvrEntity>()
22                 .eqIfPresent(DevNvrEntity::getBrand, pageReqVO.getBrand())
23                 .likeIfPresent(DevNvrEntity::getDevice, pageReqVO.getDevice())
24                 .likeIfPresent(DevNvrEntity::getIp, pageReqVO.getIp())
25                 .likeIfPresent(DevNvrEntity::getCode, pageReqVO.getCode())
26                 .likeIfPresent(DevNvrEntity::getName, pageReqVO.getName())
27                 .orderByDesc(DevNvrEntity::getId));
28     }
29
30 }