沙钢智慧能源系统后端代码
houzhongjian
2024-10-09 97edd72e5e6dbb134cedae4b72c95be8c948c5ec
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
package com.iailab.module.shasteel.dal.mysql.demo;
 
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.module.shasteel.controller.admin.demo.vo.DemoPageReqVO;
import com.iailab.module.shasteel.dal.dataobject.demo.DemoDO;
import org.apache.ibatis.annotations.Mapper;
 
/**
 * @author Houzhongjian
 * @Description
 * @createTime 2024年09月05日
 */
@Mapper
public interface DemoMapper extends BaseMapperX<DemoDO> {
 
    default PageResult<DemoDO> selectPage(DemoPageReqVO reqVO) {
        return selectPage(reqVO, new LambdaQueryWrapperX<DemoDO>()
                .likeIfPresent(DemoDO::getCode, reqVO.getCode())
                .likeIfPresent(DemoDO::getName, reqVO.getName())
                .orderByDesc(DemoDO::getId));
    }
}