@ -64,8 +64,8 @@
<if test= "param.waybillNo != null and param.waybillNo != '' " >
and Locate(#{param.waybillNo},lww.waybill_no) > 0
</if>
<if test= "param.orderNo != null and param.orderNo != '' " >
and Locate(#{param.orderNo },lww.order_code) > 0
<if test= "param.orderCode != null and param.orderCode != '' " >
and Locate(#{param.orderCode },lww.order_code) > 0
</if>
<if test= "param.shipper != null and param.shipper != '' " >
and Locate(#{param.shipper},lww.shipper) > 0
@ -194,8 +194,8 @@
<if test= "param.waybillNo != null and param.waybillNo != '' " >
and Locate(#{param.waybillNo},lww.waybill_no) > 0
</if>
<if test= "param.orderNo != null and param.orderNo != '' " >
and Locate(#{param.orderNo },lww.order_code) > 0
<if test= "param.orderCode != null and param.orderCode != '' " >
and Locate(#{param.orderCode },lww.order_code) > 0
</if>
<if test= "param.shipper != null and param.shipper != '' " >
and Locate(#{param.shipper},lww.shipper) > 0
@ -405,24 +405,24 @@
IFNULL(sum(lstp.num),0) totalNum,
IFNULL(sum(lstp.weight),0) totalWeight,
IFNULL(sum(lstp.volume),0) totalVolume,
IFNULL(sum(lstp.system_freight_price*lstp.num ),0) systemFreightPrice,
IFNULL(sum(lstp.freight_price*lstp.num ),0) freightPrice,
IFNULL(sum(lstp.system_pickup_price*lstp.num ),0) systemPickupPrice,
IFNULL(sum(lstp.pickup_price*lstp.num ),0) pickupPrice,
IFNULL(sum(lswp.warehuse_service_fee*lstp.num ),0) warehouseServiceFee,
IFNULL(sum(lswp.warehouse_fee*lstp.num ),0) warehouseFee,
IFNULL(sum(lswp.warehouse_manage_fee*lstp.num ),0) warehouseManageFee,
IFNULL(sum(lswp.warehouse_sorting_fee*lstp.num ),0) warehouseSortingFee,
IFNULL(sum(lswp.warehouse_operating_fee*lstp.num ),0) warehouseOperatingFee,
IFNULL(sum(lsdp.system_delivery_fee*lstp.num ),0) systemDeliveryFee,
IFNULL(sum(lsdp.delivery_service_fee*lstp.num ),0) deliveryServiceFee,
IFNULL(sum(lsdp.delivery_fee*lstp.num ),0) deliveryFee,
IFNULL(sum(lsdp.delivery_loading_fee*lstp.num ),0) deliveryLoadingFee,
IFNULL(sum(lsdp.delivery_sorting_fee*lstp.num ),0) deliverySortingFee,
IFNULL(sum(lsdp.delivery_upfloor_fee*lstp.num ),0) deliveryUpfloorFee,
IFNULL(sum(lsdp.delivery_move_fee*lstp.num ),0) deliveryMoveFee,
IFNULL(sum(lsdp.delivery_other_fee*lstp.num ),0) deliveryOtherFee,
IFNULL(sum(lsdp.delivery_crossing_fee*lstp.num ),0) deliveryCrossingFee
IFNULL(sum(lstp.system_freight_price),0) systemFreightPrice,
IFNULL(sum(lstp.freight_price),0) freightPrice,
IFNULL(sum(lstp.system_pickup_price),0) systemPickupPrice,
IFNULL(sum(lstp.pickup_price),0) pickupPrice,
IFNULL(sum(lswp.wareho use_service_fee),0) warehouseServiceFee,
IFNULL(sum(lswp.warehouse_fee),0) warehouseFee,
IFNULL(sum(lswp.warehouse_manage_fee),0) warehouseManageFee,
IFNULL(sum(lswp.warehouse_sorting_fee),0) warehouseSortingFee,
IFNULL(sum(lswp.warehouse_operating_fee),0) warehouseOperatingFee,
IFNULL(sum(lsdp.system_delivery_fee),0) systemDeliveryFee,
IFNULL(sum(lsdp.delivery_service_fee),0) deliveryServiceFee,
IFNULL(sum(lsdp.delivery_fee),0) deliveryFee,
IFNULL(sum(lsdp.delivery_loading_fee),0) deliveryLoadingFee,
IFNULL(sum(lsdp.delivery_sorting_fee),0) deliverySortingFee,
IFNULL(sum(lsdp.delivery_upfloor_fee),0) deliveryUpfloorFee,
IFNULL(sum(lsdp.delivery_move_fee),0) deliveryMoveFee,
IFNULL(sum(lsdp.delivery_other_fee),0) deliveryOtherFee,
IFNULL(sum(lsdp.delivery_crossing_fee),0) deliveryCrossingFee
from logpm_statistics_trunkline_package lstp
left join logpm_statistics_warehouse_package lswp on lswp.order_info_id = lstp.order_info_id and lswp.order_package_code = lstp.order_package_code and lswp.product_id = lstp.product_id
left join logpm_statistics_distribution_package lsdp on lsdp.order_info_id = lswp.order_info_id and lsdp.order_package_code = lswp.order_package_code and lswp.product_id = lsdp.product_id
@ -438,11 +438,13 @@
IFNULL(sum(lstp.num),0) totalNum,
IFNULL(sum(lstp.weight),0) totalWeight,
IFNULL(sum(lstp.volume),0) totalVolume,
IFNULL(sum(lstp.system_freight_price),0)+IFNULL(sum(lstp.system_pickup_price),0)+IFNULL(sum(lswp.warehouse_service_fee),0)+IFNULL(sum(lsdp.delivery_service_fee),0) sysTotalFee,
IFNULL(sum(lstp.freight_price),0)+IFNULL(sum(lstp.pickup_price),0)+IFNULL(sum(lswp.warehouse_service_fee),0)+IFNULL(sum(lsdp.delivery_service_fee),0) totalFee,
IFNULL(sum(lstp.system_freight_price),0) systemFreightPrice,
IFNULL(sum(lstp.freight_price),0) freightPrice,
IFNULL(sum(lstp.system_pickup_price),0) systemPickupPrice,
IFNULL(sum(lstp.pickup_price),0) pickupPrice,
IFNULL(sum(lswp.warehuse_service_fee),0) warehouseServiceFee,
IFNULL(sum(lswp.wareho use_service_fee),0) warehouseServiceFee,
IFNULL(sum(lswp.warehouse_fee),0) warehouseFee,
IFNULL(sum(lswp.warehouse_manage_fee),0) warehouseManageFee,
IFNULL(sum(lswp.warehouse_sorting_fee),0) warehouseSortingFee,
@ -479,7 +481,7 @@
</select>
<select id= "findCreateRencilitionOrderStatus" resultType= "int" >
select max(lsoi.create_reconciliation_order_status)
select IFNULL( max(lsoi.create_reconciliation_order_status),0 )
from logpm_statistics_order_info lsoi
where 1=1
and lsoi.waybill_id = #{waybillId}