|
|
@@ -149,14 +149,37 @@ public interface IotRyDailyReportMapper extends BaseMapperX<IotRyDailyReportDO>
|
|
|
|
|
|
// 单独处理 projectClassification 条件
|
|
|
if ("1".equals(projectClassification)) {
|
|
|
- // 当值为 "1" 时,查询 project_classification 为 "1" 或空字符串的记录
|
|
|
+ // 当值为 "1" 时,查询 project_classification 为 "1" 或空字符串的记录 钻井
|
|
|
queryWrapper.and(wrapper -> wrapper
|
|
|
.eq(IotRyDailyReportDO::getProjectClassification, "1")
|
|
|
.or().eq(IotRyDailyReportDO::getProjectClassification, "")
|
|
|
);
|
|
|
+ // 查询非生产时效
|
|
|
+ if ("Y".equals(reqVO.getNonProductFlag())) {
|
|
|
+ queryWrapper.and(wrapper -> wrapper
|
|
|
+ .gt(IotRyDailyReportDO::getAccidentTime, BigDecimal.ZERO)
|
|
|
+ .or()
|
|
|
+ .gt(IotRyDailyReportDO::getRepairTime, BigDecimal.ZERO)
|
|
|
+ .or()
|
|
|
+ .gt(IotRyDailyReportDO::getSelfStopTime, BigDecimal.ZERO)
|
|
|
+ .or()
|
|
|
+ .gt(IotRyDailyReportDO::getComplexityTime, BigDecimal.ZERO)
|
|
|
+ .or()
|
|
|
+ .gt(IotRyDailyReportDO::getRelocationTime, BigDecimal.ZERO)
|
|
|
+ .or()
|
|
|
+ .gt(IotRyDailyReportDO::getRectificationTime, BigDecimal.ZERO)
|
|
|
+ .or()
|
|
|
+ .gt(IotRyDailyReportDO::getWaitingStopTime, BigDecimal.ZERO)
|
|
|
+ .or()
|
|
|
+ .gt(IotRyDailyReportDO::getWinterBreakTime, BigDecimal.ZERO)
|
|
|
+ );
|
|
|
+ }
|
|
|
} else {
|
|
|
- // 其他情况:有值则精确匹配,无值则不添加条件(保持原逻辑)
|
|
|
+ // 其他情况:有值则精确匹配,无值则不添加条件(保持原逻辑) 修井
|
|
|
queryWrapper.eqIfPresent(IotRyDailyReportDO::getProjectClassification, projectClassification);
|
|
|
+ if ("Y".equals(reqVO.getNonProductFlag())) {
|
|
|
+ queryWrapper.and(wrapper -> wrapper.gt(IotRyDailyReportDO::getNonProductionTime, BigDecimal.ZERO));
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
return selectPage(reqVO, queryWrapper);
|