IDEMPIERE-1710 Receipt create lines from not update when change locator or purchase order, invoice (#412)

This commit is contained in:
Carlos Ruiz 2020-11-26 05:53:25 +01:00 committed by GitHub
parent 333d35a504
commit 9c92286861
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 8 additions and 8 deletions

View File

@ -473,6 +473,14 @@ public abstract class CreateFromShipment extends CreateFrom
}
}
// Try to get from locator field
if (locator == null)
{
if (defaultLocator_ID > 0)
{
locator = MLocator.get(Env.getCtx(), defaultLocator_ID);
}
}
// Try to use default locator from Order Warehouse
if (locator == null && p_order != null && p_order.getM_Warehouse_ID() == getM_Warehouse_ID())
{
@ -482,14 +490,6 @@ public abstract class CreateFromShipment extends CreateFrom
locator = wh.getDefaultLocator();
}
}
// Try to get from locator field
if (locator == null)
{
if (defaultLocator_ID > 0)
{
locator = MLocator.get(Env.getCtx(), defaultLocator_ID);
}
}
// Validate Warehouse
if (locator == null || locator.getM_Warehouse_ID() != getM_Warehouse_ID())
{