IDEMPIERE-1662 Replenish Report with Production does not differentiate IsSOTrx in M_StorageReservation / thanks to Chuck Boecking for the patch
This commit is contained in:
parent
9a3b47b3a0
commit
6cb2efc029
|
@ -252,9 +252,9 @@ public class ReplenishReport extends SvrProcess
|
|||
sql.append("QtyOnHand = (SELECT COALESCE(SUM(QtyOnHand),0) FROM M_StorageOnHand s, M_Locator l WHERE t.M_Product_ID=s.M_Product_ID");
|
||||
sql.append(" AND l.M_Locator_ID=s.M_Locator_ID AND l.M_Warehouse_ID=t.M_Warehouse_ID),");
|
||||
sql.append("QtyReserved = (SELECT COALESCE(SUM(Qty),0) FROM M_StorageReservation s WHERE t.M_Product_ID=s.M_Product_ID");
|
||||
sql.append(" AND t.M_Warehouse_ID=s.M_Warehouse_ID),");
|
||||
sql.append(" AND t.M_Warehouse_ID=s.M_Warehouse_ID AND s.IsSOTrx='Y'),");
|
||||
sql.append("QtyOrdered = (SELECT COALESCE(SUM(Qty),0) FROM M_StorageReservation s WHERE t.M_Product_ID=s.M_Product_ID");
|
||||
sql.append(" AND t.M_Warehouse_ID=s.M_Warehouse_ID)");
|
||||
sql.append(" AND t.M_Warehouse_ID=s.M_Warehouse_ID AND s.IsSOTrx='N')");
|
||||
if (p_C_DocType_ID != 0)
|
||||
sql.append(", C_DocType_ID=").append(p_C_DocType_ID);
|
||||
sql.append(" WHERE AD_PInstance_ID=").append(getAD_PInstance_ID());
|
||||
|
|
|
@ -272,9 +272,9 @@ public class ReplenishReportProduction extends SvrProcess
|
|||
sql.append("QtyOnHand = (SELECT COALESCE(SUM(QtyOnHand),0) FROM M_StorageOnHand s, M_Locator l WHERE t.M_Product_ID=s.M_Product_ID");
|
||||
sql.append(" AND l.M_Locator_ID=s.M_Locator_ID AND l.M_Warehouse_ID=t.M_Warehouse_ID),");
|
||||
sql.append("QtyReserved = (SELECT COALESCE(SUM(Qty),0) FROM M_StorageReservation s WHERE t.M_Product_ID=s.M_Product_ID");
|
||||
sql.append(" AND t.M_Warehouse_ID=s.M_Warehouse_ID),");
|
||||
sql.append(" AND t.M_Warehouse_ID=s.M_Warehouse_ID AND s.IsSOTrx='Y'),");
|
||||
sql.append("QtyOrdered = (SELECT COALESCE(SUM(Qty),0) FROM M_StorageReservation s WHERE t.M_Product_ID=s.M_Product_ID");
|
||||
sql.append(" AND t.M_Warehouse_ID=s.M_Warehouse_ID)");
|
||||
sql.append(" AND t.M_Warehouse_ID=s.M_Warehouse_ID AND s.IsSOTrx='N')");
|
||||
if (p_C_DocType_ID != 0)
|
||||
sql.append(", C_DocType_ID=").append(p_C_DocType_ID);
|
||||
sql.append(" WHERE AD_PInstance_ID=").append(getAD_PInstance_ID());
|
||||
|
|
Loading…
Reference in New Issue