package cn.iocoder.yudao.module.pms.dal.mysql.iotoperationmeetingattrs;

import cn.iocoder.yudao.framework.common.pojo.PageResult;
import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX;
import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX;
import cn.iocoder.yudao.module.pms.controller.admin.iotoperationmeetingattrs.vo.IotOperationMeetingAttrsPageReqVO;
import cn.iocoder.yudao.module.pms.dal.dataobject.iotoperationmeetingattrs.IotOperationMeetingAttrsDO;
import org.apache.ibatis.annotations.Mapper;

/**
 * 专业公司工作量扩展属性 Mapper
 *
 * @author ruiqi
 */
@Mapper
public interface IotOperationMeetingAttrsMapper extends BaseMapperX<IotOperationMeetingAttrsDO> {

    default PageResult<IotOperationMeetingAttrsDO> selectPage(IotOperationMeetingAttrsPageReqVO reqVO) {
        return selectPage(reqVO, new LambdaQueryWrapperX<IotOperationMeetingAttrsDO>()
                .eqIfPresent(IotOperationMeetingAttrsDO::getTemplateId, reqVO.getTemplateId())
                .eqIfPresent(IotOperationMeetingAttrsDO::getDeptId, reqVO.getDeptId())
                .eqIfPresent(IotOperationMeetingAttrsDO::getProjectId, reqVO.getProjectId())
                .eqIfPresent(IotOperationMeetingAttrsDO::getProjectClassification, reqVO.getProjectClassification())
                .eqIfPresent(IotOperationMeetingAttrsDO::getWellType, reqVO.getWellType())
                .eqIfPresent(IotOperationMeetingAttrsDO::getWellCategory, reqVO.getWellCategory())
                .eqIfPresent(IotOperationMeetingAttrsDO::getTechnique, reqVO.getTechnique())
                .likeIfPresent(IotOperationMeetingAttrsDO::getName, reqVO.getName())
                .eqIfPresent(IotOperationMeetingAttrsDO::getIdentifier, reqVO.getIdentifier())
                .eqIfPresent(IotOperationMeetingAttrsDO::getDataType, reqVO.getDataType())
                .eqIfPresent(IotOperationMeetingAttrsDO::getRequired, reqVO.getRequired())
                .eqIfPresent(IotOperationMeetingAttrsDO::getUnit, reqVO.getUnit())
                .eqIfPresent(IotOperationMeetingAttrsDO::getAccessMode, reqVO.getAccessMode())
                .eqIfPresent(IotOperationMeetingAttrsDO::getDefaultValue, reqVO.getDefaultValue())
                .eqIfPresent(IotOperationMeetingAttrsDO::getMaxValue, reqVO.getMaxValue())
                .eqIfPresent(IotOperationMeetingAttrsDO::getMinValue, reqVO.getMinValue())
                .eqIfPresent(IotOperationMeetingAttrsDO::getExtProperty, reqVO.getExtProperty())
                .eqIfPresent(IotOperationMeetingAttrsDO::getSort, reqVO.getSort())
                .eqIfPresent(IotOperationMeetingAttrsDO::getRemark, reqVO.getRemark())
                .eqIfPresent(IotOperationMeetingAttrsDO::getStatus, reqVO.getStatus())
                .betweenIfPresent(IotOperationMeetingAttrsDO::getCreateTime, reqVO.getCreateTime())
                .orderByDesc(IotOperationMeetingAttrsDO::getId));
    }

}