IDEMPIERE-239 - smart way ; using IsActive() instead of SQL
This commit is contained in:
parent
a53fd5c08f
commit
644207b999
|
@ -455,10 +455,10 @@ public abstract class Doc
|
|||
{
|
||||
log.log(Level.SEVERE, "Resubmit - Cannot lock " + get_TableName() + "_ID="
|
||||
+ get_ID() + ", Force=" + force + ",RePost=" + repost);
|
||||
if (!p_po.isActive())
|
||||
return "Cannot post inactive document";
|
||||
if (force)
|
||||
return "Cannot Lock - ReSubmit";
|
||||
if (DB.getSQLValueStringEx(trxName, "SELECT IsActive FROM " + get_TableName() + " WHERE " + get_TableName() + "_ID=" + get_ID()).equals("N"))
|
||||
return "Impossible to post deactivated document";
|
||||
return "Cannot Lock - ReSubmit or RePost with Force";
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue