|
@@ -2255,7 +2255,6 @@
|
|
|
on t_t_result.result_total_id=t_w_result.result_total_id
|
|
|
GROUP BY
|
|
|
a_s_o_Material.SALE_ORDER_ID
|
|
|
-
|
|
|
) sumWeight
|
|
|
on sumWeight.SALE_ORDER_ID=ASO.SALE_ORDER_ID
|
|
|
left join (
|
|
@@ -2272,7 +2271,6 @@
|
|
|
where t_w_result.RESULT_NET_WEIGHT is null and o_order.order_status in (2,4,5)
|
|
|
GROUP BY
|
|
|
a_s_o_Material.SALE_ORDER_ID
|
|
|
-
|
|
|
) sumWeight2
|
|
|
on sumWeight2.SALE_ORDER_ID=ASO.SALE_ORDER_ID
|
|
|
left join (
|
|
@@ -2284,7 +2282,7 @@
|
|
|
on o_order.order_id=t_t_result.order_id
|
|
|
left join Tmstruck_Weight_Result t_w_result
|
|
|
on t_t_result.result_total_id=t_w_result.result_total_id
|
|
|
- where t_w_result.RESULT_NET_WEIGHT is null and o_order.order_status in (2,4,5)
|
|
|
+ where o_order.order_status in (2,4,5)
|
|
|
GROUP BY
|
|
|
a_s_o_Material.SALE_ORDER_ID
|
|
|
|
|
@@ -3641,7 +3639,8 @@
|
|
|
|
|
|
) carCount
|
|
|
on carCount.SALE_ORDER_ID=a_s_order.SALE_ORDER_ID
|
|
|
- where ASM.SALE_WAREHOUSE = '副产品库'
|
|
|
+ where (ASM.SALE_WAREHOUSE = '副产品库'
|
|
|
+ or ASM.SALE_WAREHOUSE = '钒渣库')
|
|
|
and a_s_order.SALE_ORDER_STATUS in (2,4)
|
|
|
and a_s_order.CLOSE_STATUS is null
|
|
|
and a_s_order.DELETED = #{deleted}
|