package com.unis.module.coding.dal.mysql.crkxx;

import java.util.*;

import com.unis.framework.common.pojo.PageResult;
import com.unis.framework.mybatis.core.query.LambdaQueryWrapperX;
import com.unis.framework.mybatis.core.mapper.BaseMapperX;
import com.unis.module.coding.dal.dataobject.crkxx.CrkxxDO;
import org.apache.ibatis.annotations.Mapper;
import com.unis.module.coding.controller.admin.crkxx.vo.*;

/**
 * 出入库信息 Mapper
 *
 * @author 超级管理员
 */
@Mapper
public interface CrkxxMapper extends BaseMapperX<CrkxxDO> {

    default PageResult<CrkxxDO> selectPage(CrkxxPageReqVO reqVO) {
        return selectPage(reqVO, new LambdaQueryWrapperX<CrkxxDO>()
                .eqIfPresent(CrkxxDO::getLspzmc, reqVO.getLspzmc())
                .eqIfPresent(CrkxxDO::getLsdjbm, reqVO.getLsdjbm())
                .eqIfPresent(CrkxxDO::getCfId, reqVO.getCfId())
                .orderByDesc(CrkxxDO::getId));
    }

}