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

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.iotryhidailyreport.vo.IotRyHiDailyReportPageReqVO;
import cn.iocoder.yudao.module.pms.dal.dataobject.iotryhidailyreport.IotRyHiDailyReportDO;
import org.apache.ibatis.annotations.Mapper;

/**
 * 瑞鹰历史日报 Mapper
 *
 * @author ruiqi
 */
@Mapper
public interface IotRyHiDailyReportMapper extends BaseMapperX<IotRyHiDailyReportDO> {

    default PageResult<IotRyHiDailyReportDO> selectPage(IotRyHiDailyReportPageReqVO reqVO) {
        return selectPage(reqVO, new LambdaQueryWrapperX<IotRyHiDailyReportDO>()
                .eqIfPresent(IotRyHiDailyReportDO::getDeptId, reqVO.getDeptId())
                .eqIfPresent(IotRyHiDailyReportDO::getProjectId, reqVO.getProjectId())
                .likeIfPresent(IotRyHiDailyReportDO::getProjectName, reqVO.getProjectName())
                .eqIfPresent(IotRyHiDailyReportDO::getTaskId, reqVO.getTaskId())
                .eqIfPresent(IotRyHiDailyReportDO::getProjectClassification, reqVO.getProjectClassification())
                .eqIfPresent(IotRyHiDailyReportDO::getRelocationDays, reqVO.getRelocationDays())
                .betweenIfPresent(IotRyHiDailyReportDO::getLatestWellDoneTime, reqVO.getLatestWellDoneTime())
                .eqIfPresent(IotRyHiDailyReportDO::getCurrentDepth, reqVO.getCurrentDepth())
                .eqIfPresent(IotRyHiDailyReportDO::getDailyFootage, reqVO.getDailyFootage())
                .eqIfPresent(IotRyHiDailyReportDO::getMonthlyFootage, reqVO.getMonthlyFootage())
                .eqIfPresent(IotRyHiDailyReportDO::getAnnualFootage, reqVO.getAnnualFootage())
                .eqIfPresent(IotRyHiDailyReportDO::getMonthlyWellCompletions, reqVO.getMonthlyWellCompletions())
                .eqIfPresent(IotRyHiDailyReportDO::getTotalCompletedWells, reqVO.getTotalCompletedWells())
                .eqIfPresent(IotRyHiDailyReportDO::getTotalConstructionWells, reqVO.getTotalConstructionWells())
                .eqIfPresent(IotRyHiDailyReportDO::getDailyPowerUsage, reqVO.getDailyPowerUsage())
                .eqIfPresent(IotRyHiDailyReportDO::getMonthlyPowerUsage, reqVO.getMonthlyPowerUsage())
                .eqIfPresent(IotRyHiDailyReportDO::getDailyFuel, reqVO.getDailyFuel())
                .eqIfPresent(IotRyHiDailyReportDO::getMonthlyFuel, reqVO.getMonthlyFuel())
                .eqIfPresent(IotRyHiDailyReportDO::getDailyOilVolume, reqVO.getDailyOilVolume())
                .eqIfPresent(IotRyHiDailyReportDO::getRemainDieselVolume, reqVO.getRemainDieselVolume())
                .betweenIfPresent(IotRyHiDailyReportDO::getProductionTime, reqVO.getProductionTime())
                .betweenIfPresent(IotRyHiDailyReportDO::getNonProductionTime, reqVO.getNonProductionTime())
                .eqIfPresent(IotRyHiDailyReportDO::getRyNptReason, reqVO.getRyNptReason())
                .betweenIfPresent(IotRyHiDailyReportDO::getDrillingWorkingTime, reqVO.getDrillingWorkingTime())
                .betweenIfPresent(IotRyHiDailyReportDO::getOtherProductionTime, reqVO.getOtherProductionTime())
                .betweenIfPresent(IotRyHiDailyReportDO::getAccidentTime, reqVO.getAccidentTime())
                .betweenIfPresent(IotRyHiDailyReportDO::getRepairTime, reqVO.getRepairTime())
                .betweenIfPresent(IotRyHiDailyReportDO::getSelfStopTime, reqVO.getSelfStopTime())
                .betweenIfPresent(IotRyHiDailyReportDO::getComplexityTime, reqVO.getComplexityTime())
                .betweenIfPresent(IotRyHiDailyReportDO::getRelocationTime, reqVO.getRelocationTime())
                .betweenIfPresent(IotRyHiDailyReportDO::getRectificationTime, reqVO.getRectificationTime())
                .betweenIfPresent(IotRyHiDailyReportDO::getWaitingStopTime, reqVO.getWaitingStopTime())
                .betweenIfPresent(IotRyHiDailyReportDO::getWinterBreakTime, reqVO.getWinterBreakTime())
                .eqIfPresent(IotRyHiDailyReportDO::getPartyaDesign, reqVO.getPartyaDesign())
                .eqIfPresent(IotRyHiDailyReportDO::getPartyaPrepare, reqVO.getPartyaPrepare())
                .eqIfPresent(IotRyHiDailyReportDO::getPartyaResource, reqVO.getPartyaResource())
                .betweenIfPresent(IotRyHiDailyReportDO::getOtherNptTime, reqVO.getOtherNptTime())
                .eqIfPresent(IotRyHiDailyReportDO::getOtherNptReason, reqVO.getOtherNptReason())
                .betweenIfPresent(IotRyHiDailyReportDO::getConstructionStartDate, reqVO.getConstructionStartDate())
                .betweenIfPresent(IotRyHiDailyReportDO::getConstructionEndDate, reqVO.getConstructionEndDate())
                .eqIfPresent(IotRyHiDailyReportDO::getProductionStatus, reqVO.getProductionStatus())
                .eqIfPresent(IotRyHiDailyReportDO::getCurrentOperation, reqVO.getCurrentOperation())
                .eqIfPresent(IotRyHiDailyReportDO::getNextPlan, reqVO.getNextPlan())
                .eqIfPresent(IotRyHiDailyReportDO::getConstructionBrief, reqVO.getConstructionBrief())
                .eqIfPresent(IotRyHiDailyReportDO::getRigStatus, reqVO.getRigStatus())
                .eqIfPresent(IotRyHiDailyReportDO::getRepairStatus, reqVO.getRepairStatus())
                .eqIfPresent(IotRyHiDailyReportDO::getPersonnel, reqVO.getPersonnel())
                .eqIfPresent(IotRyHiDailyReportDO::getTotalStaffNum, reqVO.getTotalStaffNum())
                .eqIfPresent(IotRyHiDailyReportDO::getLeaveStaffNum, reqVO.getLeaveStaffNum())
                .eqIfPresent(IotRyHiDailyReportDO::getMudDensity, reqVO.getMudDensity())
                .eqIfPresent(IotRyHiDailyReportDO::getMudViscosity, reqVO.getMudViscosity())
                .eqIfPresent(IotRyHiDailyReportDO::getLateralLength, reqVO.getLateralLength())
                .eqIfPresent(IotRyHiDailyReportDO::getWellInclination, reqVO.getWellInclination())
                .eqIfPresent(IotRyHiDailyReportDO::getAzimuth, reqVO.getAzimuth())
                .eqIfPresent(IotRyHiDailyReportDO::getDayShiftSupervisor, reqVO.getDayShiftSupervisor())
                .eqIfPresent(IotRyHiDailyReportDO::getDaySupervisors, reqVO.getDaySupervisors())
                .eqIfPresent(IotRyHiDailyReportDO::getNightShiftSupervisor, reqVO.getNightShiftSupervisor())
                .eqIfPresent(IotRyHiDailyReportDO::getNightSupervisors, reqVO.getNightSupervisors())
                .eqIfPresent(IotRyHiDailyReportDO::getExtProperty, reqVO.getExtProperty())
                .eqIfPresent(IotRyHiDailyReportDO::getSort, reqVO.getSort())
                .eqIfPresent(IotRyHiDailyReportDO::getRemark, reqVO.getRemark())
                .eqIfPresent(IotRyHiDailyReportDO::getStatus, reqVO.getStatus())
                .eqIfPresent(IotRyHiDailyReportDO::getProcessInstanceId, reqVO.getProcessInstanceId())
                .eqIfPresent(IotRyHiDailyReportDO::getAuditStatus, reqVO.getAuditStatus())
                .eqIfPresent(IotRyHiDailyReportDO::getOpinion, reqVO.getOpinion())
                .betweenIfPresent(IotRyHiDailyReportDO::getCreateTime, reqVO.getCreateTime())
                .orderByDesc(IotRyHiDailyReportDO::getId));
    }

}