From 79ff4ff1694cbc88d8561096e39adcaaad13969e Mon Sep 17 00:00:00 2001 From: Carlos Ruiz Date: Sun, 17 Jan 2016 18:14:45 +0100 Subject: [PATCH] IDEMPIERE-1140 Copy record uses wrong quantity when used in shipment line / receipt line - fix also UOM in case is different --- .../src/org/compiere/model/CalloutInOut.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/org.adempiere.base.callout/src/org/compiere/model/CalloutInOut.java b/org.adempiere.base.callout/src/org/compiere/model/CalloutInOut.java index dba843e84c..a7d2df2b0d 100644 --- a/org.adempiere.base.callout/src/org/compiere/model/CalloutInOut.java +++ b/org.adempiere.base.callout/src/org/compiere/model/CalloutInOut.java @@ -706,6 +706,9 @@ public class CalloutInOut extends CalloutEngine // serialized ASI - force qty yo 1 - IDEMPIERE-1140 mTab.setValue("MovementQty", Env.ONE); mTab.setValue("QtyEntered", Env.ONE); + MProduct product = MProduct.get(ctx, M_Product_ID); + if (product != null) + mTab.setValue("C_UOM_ID", product.getC_UOM_ID()); } return ""; } // asi