【fix】更改行程单查询接口为null为空时的判断逻辑
This commit is contained in:
parent
428990b6e8
commit
21470758cf
|
@ -54,6 +54,9 @@ public class JdbcConsumptionDetailRepositoryImpl implements JdbcConsumptionDetai
|
|||
}
|
||||
|
||||
Map<String, Object> params = new HashMap<>();
|
||||
if (dto.getActualOrderNo()!=null&&dto.getActualOrderNo().isEmpty()){
|
||||
dto.setActualOrderNo(null);
|
||||
}
|
||||
params.put("actualOrderNo", dto.getActualOrderNo());
|
||||
params.put("userIds", dto.getUserIds());
|
||||
PageRequest pageRequest = PageRequest
|
||||
|
|
|
@ -89,9 +89,12 @@ public class ManageServiceImpl implements ManageService {
|
|||
|
||||
@Override
|
||||
public PageResult<ItineraryPageDto> itineraryPageQuery(ItineraryPageQuery dto) {
|
||||
List<User> users=jdbcUserRepository.findAllByNameContains(dto.getApplicant());
|
||||
if (users==null||users.isEmpty()){
|
||||
return null;
|
||||
List<User> users=new ArrayList<>();
|
||||
if (dto.getApplicant()!=null&&!dto.getApplicant().isEmpty()){
|
||||
users=jdbcUserRepository.findAllByNameContains(dto.getApplicant());
|
||||
if (users==null||users.isEmpty()){
|
||||
return null;
|
||||
}
|
||||
}
|
||||
dto.setUserIds(users.stream().map(User::getEmployeeNo).toList());
|
||||
Page<ItineraryPageDto> page= jdbcConsumptionDetailRepository.itineraryPageQueryByDto(dto);
|
||||
|
|
Loading…
Reference in New Issue