【update】行程单查询修改

This commit is contained in:
nixj 2024-06-26 10:38:35 +08:00
parent 34c40ce2e6
commit 37630ab65c
2 changed files with 6 additions and 3 deletions

View File

@ -13,7 +13,7 @@ public class ItineraryPageQuery extends BaseQuery {
private String applicant="";// 申请人 private String applicant="";// 申请人
private String actualOrderNo=""; //申请单号 private String actualOrderNo=""; //申请单号
private List<String> userIds=new ArrayList<>(); private List<String> userIds=new ArrayList<>();
private List<Long> routeIds; private List<Long> routeIds=new ArrayList<>();
public String getActualOrderNo() { public String getActualOrderNo() {

View File

@ -46,8 +46,11 @@ public class JdbcConsumptionDetailRepositoryImpl implements JdbcConsumptionDetai
@Override @Override
public Page<ItineraryPageDto> itineraryPageQueryByDto(ItineraryPageQuery dto) { public Page<ItineraryPageDto> itineraryPageQueryByDto(ItineraryPageQuery dto) {
String query = "SELECT * FROM route_order " String query = "SELECT * FROM route_order "
+ "WHERE route_id IN (:routeIds) " + "WHERE actual_order_no IS NOT NULL ";
+ "AND actual_order_no IS NOT NULL ";
if (!dto.getRouteIds().isEmpty()) {
query+="AND route_id IN (:routeIds) ";
}
if (!dto.getUserIds().isEmpty()) { if (!dto.getUserIds().isEmpty()) {
query+="AND user_id IN (:userIds) "; query+="AND user_id IN (:userIds) ";