Physical Inventory creates transactions even if movement qty = zero
(fixes issue #3) https://bitbucket.org/tspc/adempiere361/issue/3/physical-inventory-creates-transactions
This commit is contained in:
parent
ad8d01291c
commit
dafa950221
|
@ -396,11 +396,16 @@ public class MInventory extends X_M_Inventory implements DocAction
|
|||
|
||||
MProduct product = line.getProduct();
|
||||
|
||||
//Get Quantity to Inventory Inernal Use
|
||||
//Get Quantity Internal Use
|
||||
BigDecimal qtyDiff = line.getQtyInternalUse().negate();
|
||||
//If Quantity to Inventory Internal Use = Zero Then is Physical Inventory Else is Inventory Internal Use
|
||||
//If Quantity Internal Use = Zero Then Physical Inventory Else Internal Use Inventory
|
||||
if (qtyDiff.signum() == 0)
|
||||
{
|
||||
qtyDiff = line.getQtyCount().subtract(line.getQtyBook());
|
||||
//If Quantity Count minus Quantity Book = Zero, then no change in Inventory
|
||||
if (qtyDiff.signum() == 0)
|
||||
continue;
|
||||
}
|
||||
|
||||
//Ignore the Material Policy when is Reverse Correction
|
||||
if(!isReversal())
|
||||
|
|
Loading…
Reference in New Issue