This commit is contained in:
YAS\29473
2026-01-04 11:40:37 +08:00
parent ccd2f96466
commit 2768c6597c
6 changed files with 70 additions and 27 deletions

View File

@@ -6276,30 +6276,19 @@ public class OrderBasicInfoServiceImpl implements OrderBasicInfoService {
throw new BusinessException(ReturnCodeEnum.CODE_SELECT_INFO_IS_NULL);
}
// 根据站点名称过滤
List<String> stationIdList = new ArrayList<>();
if (StringUtils.isNotBlank(dto.getStationName())) {
List<PileStationInfo> filteredStations = allStations.stream()
.filter(s -> s.getStationName() != null && s.getStationName().contains(dto.getStationName()))
.collect(Collectors.toList());
if (CollectionUtils.isEmpty(filteredStations)) {
throw new BusinessException(ReturnCodeEnum.CODE_SELECT_INFO_IS_NULL);
}
stationIdList = filteredStations.stream()
.map(s -> String.valueOf(s.getId()))
.collect(Collectors.toList());
} else {
stationIdList = allStations.stream()
.map(s -> String.valueOf(s.getId()))
.collect(Collectors.toList());
}
// 获取所有站点ID列表
List<String> stationIdList = allStations.stream()
.map(s -> String.valueOf(s.getId()))
.collect(Collectors.toList());
// 构建QueryOrderDTO
// 构建QueryOrderDTO包含启动方式和站点名称由SQL进行过滤
QueryOrderDTO queryOrderDTO = QueryOrderDTO.builder()
.stationIdList(stationIdList)
.startTime(dto.getCreateTime())
.endTime(dto.getEndTime())
.orderStatus(dto.getOrderStatus())
.startMode(dto.getStartMode())
.stationName(dto.getStationName())
.build();
// 1. 分页参数处理