|
@@ -2893,8 +2893,8 @@
|
|
w.f_planvolumn fPlanvolumn,
|
|
w.f_planvolumn fPlanvolumn,
|
|
w.f_plannetweight fPlannetweight,
|
|
w.f_plannetweight fPlannetweight,
|
|
w.f_plangrossweight fPlangrossweight,
|
|
w.f_plangrossweight fPlangrossweight,
|
|
- IFNULL(ROUND(w.f_grossweight/1000,2),0) fGrossweight,
|
|
|
|
- IFNULL(ROUND(w.f_netweight/1000,2),0) fNetweight,
|
|
|
|
|
|
+ IFNULL(ROUND(t.fGrossweight/1000,2),0) fGrossweight,
|
|
|
|
+ IFNULL(ROUND(t.fNetweight/1000,2),0) fNetweight,
|
|
w.f_grossweight fGrossweights,
|
|
w.f_grossweight fGrossweights,
|
|
w.f_storekeeper fStorekeeper,
|
|
w.f_storekeeper fStorekeeper,
|
|
w.create_by createBy,
|
|
w.create_by createBy,
|
|
@@ -2954,6 +2954,16 @@
|
|
END AS fBillstatus
|
|
END AS fBillstatus
|
|
FROM
|
|
FROM
|
|
t_warehousebills w
|
|
t_warehousebills w
|
|
|
|
+ LEFT JOIN (
|
|
|
|
+ SELECT
|
|
|
|
+ f_pid,
|
|
|
|
+ IFNULL( SUM( f_grossweight ), 0 ) AS fGrossweight,
|
|
|
|
+ IFNULL( SUM( f_netweight ), 0 ) AS fNetweight
|
|
|
|
+ FROM
|
|
|
|
+ t_warehousebillsitems
|
|
|
|
+ GROUP BY
|
|
|
|
+ f_pid
|
|
|
|
+ ) t ON t.f_pid = w.f_id
|
|
LEFT JOIN t_corps c ON c.f_id = w.f_corpid
|
|
LEFT JOIN t_corps c ON c.f_id = w.f_corpid
|
|
LEFT JOIN t_goods g ON g.f_id = w.f_goodsid
|
|
LEFT JOIN t_goods g ON g.f_id = w.f_goodsid
|
|
LEFT JOIN t_warehouse t ON t.f_id = w.f_warehouseid
|
|
LEFT JOIN t_warehouse t ON t.f_id = w.f_warehouseid
|
|
@@ -3000,8 +3010,8 @@
|
|
cntr.f_name cntrtypes,
|
|
cntr.f_name cntrtypes,
|
|
t.f_cntrtype fCntrtype,
|
|
t.f_cntrtype fCntrtype,
|
|
t.f_qty fQty,
|
|
t.f_qty fQty,
|
|
- IFNULL(ROUND(w.f_grossweight/1000,2),0) fGrossweight,
|
|
|
|
- IFNULL(ROUND(w.f_netweight/1000,2),0) fNetweight,
|
|
|
|
|
|
+ IFNULL(ROUND(t2.fGrossweight/1000,2),0) fGrossweight,
|
|
|
|
+ IFNULL(ROUND(t2.fNetweight/1000,2),0) fNetweight,
|
|
t.f_grossweight fGrossweights,
|
|
t.f_grossweight fGrossweights,
|
|
t.f_cntqty fCntqty,
|
|
t.f_cntqty fCntqty,
|
|
fleet.f_name fleetName,
|
|
fleet.f_name fleetName,
|
|
@@ -3020,6 +3030,16 @@
|
|
FROM
|
|
FROM
|
|
t_warehousebills w
|
|
t_warehousebills w
|
|
LEFT JOIN t_warehousebillsitems t ON t.f_pid = w.f_id
|
|
LEFT JOIN t_warehousebillsitems t ON t.f_pid = w.f_id
|
|
|
|
+ LEFT JOIN (
|
|
|
|
+ SELECT
|
|
|
|
+ f_pid,
|
|
|
|
+ IFNULL( SUM( f_grossweight ), 0 ) AS fGrossweight,
|
|
|
|
+ IFNULL( SUM( f_netweight ), 0 ) AS fNetweight
|
|
|
|
+ FROM
|
|
|
|
+ t_warehousebillsitems
|
|
|
|
+ GROUP BY
|
|
|
|
+ f_pid
|
|
|
|
+ ) t2 ON t2.f_pid = w.f_id
|
|
LEFT JOIN t_corps fleet ON fleet.f_id = t.f_fleet
|
|
LEFT JOIN t_corps fleet ON fleet.f_id = t.f_fleet
|
|
LEFT JOIN t_corps c ON c.f_id = w.f_corpid
|
|
LEFT JOIN t_corps c ON c.f_id = w.f_corpid
|
|
LEFT JOIN t_goods g ON g.f_id = t.f_goodsid
|
|
LEFT JOIN t_goods g ON g.f_id = t.f_goodsid
|