|
|
|
@ -1391,12 +1391,6 @@
|
|
|
|
|
where ltad.waybill_id is not null |
|
|
|
|
and ltad.create_time > '2024-10-22 00:00:00' |
|
|
|
|
and lww.departure_warehouse_id != lww.destination_warehouse_id |
|
|
|
|
<if test="param.startTime != null "> |
|
|
|
|
and ltad.create_time >= #{param.startTime} |
|
|
|
|
</if> |
|
|
|
|
<if test="param.endTime != null "> |
|
|
|
|
and ltad.create_time <= #{param.endTime} |
|
|
|
|
</if> |
|
|
|
|
<if test="param.brandList != null and param.brandList.size() > 0"> |
|
|
|
|
and lww.brand in |
|
|
|
|
<foreach collection="param.brandList" item="item" open="(" separator="," close=")"> |
|
|
|
@ -1436,13 +1430,6 @@
|
|
|
|
|
<if test="param.destinationWarehouseName != null and param.destinationWarehouseName !='' "> |
|
|
|
|
and lww.destination_warehouse_name like concat('%',#{param.destinationWarehouseName},'%') |
|
|
|
|
</if> |
|
|
|
|
<if test="param.trainNumber != null and param.trainNumber !='' "> |
|
|
|
|
and GROUP_CONCAT(DISTINCT ltad.train_number) like concat('%',#{param.trainNumber},'%') |
|
|
|
|
GROUP_CONCAT(DISTINCT IFNULL(ltcls.load_code,ltclsm.load_code)) loadCode, |
|
|
|
|
</if> |
|
|
|
|
<if test="param.loadCode != null and param.loadCode !='' "> |
|
|
|
|
and GROUP_CONCAT(DISTINCT IFNULL(ltcls.load_code,ltclsm.load_code)) like concat('%',#{param.loadCode},'%') |
|
|
|
|
</if> |
|
|
|
|
group by ltad.order_code, |
|
|
|
|
ltad.waybill_no, |
|
|
|
|
ltad.brand, |
|
|
|
@ -1451,6 +1438,26 @@
|
|
|
|
|
lww.departure_warehouse_name, |
|
|
|
|
lww.destination_warehouse_name, |
|
|
|
|
oat.day_time |
|
|
|
|
<trim prefix="HAVING" prefixOverrides="AND"> |
|
|
|
|
<if test="param.trainNumber != null and param.trainNumber !='' "> |
|
|
|
|
and GROUP_CONCAT(DISTINCT ltad.train_number) like concat('%',#{param.trainNumber},'%') |
|
|
|
|
</if> |
|
|
|
|
<if test="param.loadCode != null and param.loadCode !='' "> |
|
|
|
|
and GROUP_CONCAT(DISTINCT IFNULL(ltcls.load_code,ltclsm.load_code)) like concat('%',#{param.loadCode},'%') |
|
|
|
|
</if> |
|
|
|
|
<if test="param.startTime != null "> |
|
|
|
|
and min(ltad.create_time) >= #{param.startTime} |
|
|
|
|
</if> |
|
|
|
|
<if test="param.endTime != null "> |
|
|
|
|
and min(ltad.create_time) <= #{param.endTime} |
|
|
|
|
</if> |
|
|
|
|
<if test="param.openTimeStart != null "> |
|
|
|
|
and min(lww.create_time) >= #{param.openTimeStart} |
|
|
|
|
</if> |
|
|
|
|
<if test="param.openTimeEnd != null "> |
|
|
|
|
and min(lww.create_time) <= #{param.openTimeEnd} |
|
|
|
|
</if> |
|
|
|
|
</trim> |
|
|
|
|
</select> |
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -1498,12 +1505,6 @@
|
|
|
|
|
where ltad.waybill_id is not null |
|
|
|
|
and ltad.create_time > '2024-10-22 00:00:00' |
|
|
|
|
and lww.departure_warehouse_id != lww.destination_warehouse_id |
|
|
|
|
<if test="param.startTime != null "> |
|
|
|
|
and ltad.create_time >= #{param.startTime} |
|
|
|
|
</if> |
|
|
|
|
<if test="param.endTime != null "> |
|
|
|
|
and ltad.create_time <= #{param.endTime} |
|
|
|
|
</if> |
|
|
|
|
<if test="param.brandList != null and param.brandList.size() > 0"> |
|
|
|
|
and lww.brand in |
|
|
|
|
<foreach collection="param.brandList" item="item" open="(" separator="," close=")"> |
|
|
|
@ -1545,7 +1546,6 @@
|
|
|
|
|
</if> |
|
|
|
|
<if test="param.trainNumber != null and param.trainNumber !='' "> |
|
|
|
|
and GROUP_CONCAT(DISTINCT ltad.train_number) like concat('%',#{param.trainNumber},'%') |
|
|
|
|
GROUP_CONCAT(DISTINCT IFNULL(ltcls.load_code,ltclsm.load_code)) loadCode, |
|
|
|
|
</if> |
|
|
|
|
<if test="param.loadCode != null and param.loadCode !='' "> |
|
|
|
|
and GROUP_CONCAT(DISTINCT IFNULL(ltcls.load_code,ltclsm.load_code)) like concat('%',#{param.loadCode},'%') |
|
|
|
@ -1558,6 +1558,27 @@
|
|
|
|
|
lww.departure_warehouse_name, |
|
|
|
|
lww.destination_warehouse_name, |
|
|
|
|
oat.day_time |
|
|
|
|
<trim prefix="HAVING" prefixOverrides="AND"> |
|
|
|
|
<if test="param.trainNumber != null and param.trainNumber !='' "> |
|
|
|
|
and GROUP_CONCAT(DISTINCT ltad.train_number) like concat('%',#{param.trainNumber},'%') |
|
|
|
|
GROUP_CONCAT(DISTINCT IFNULL(ltcls.load_code,ltclsm.load_code)) loadCode, |
|
|
|
|
</if> |
|
|
|
|
<if test="param.loadCode != null and param.loadCode !='' "> |
|
|
|
|
and GROUP_CONCAT(DISTINCT IFNULL(ltcls.load_code,ltclsm.load_code)) like concat('%',#{param.loadCode},'%') |
|
|
|
|
</if> |
|
|
|
|
<if test="param.startTime != null "> |
|
|
|
|
and min(ltad.create_time) >= #{param.startTime} |
|
|
|
|
</if> |
|
|
|
|
<if test="param.endTime != null "> |
|
|
|
|
and min(ltad.create_time) <= #{param.endTime} |
|
|
|
|
</if> |
|
|
|
|
<if test="param.openTimeStart != null "> |
|
|
|
|
and min(lww.create_time) >= #{param.openTimeStart} |
|
|
|
|
</if> |
|
|
|
|
<if test="param.openTimeEnd != null "> |
|
|
|
|
and min(lww.create_time) <= #{param.openTimeEnd} |
|
|
|
|
</if> |
|
|
|
|
</trim> |
|
|
|
|
</select> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|