IDEMPIERE-56 / IDEMPIERE-4723 Clean up iDempiere's code (#1402)
Cleanup useless code - as the value is assigned the condition below is always true
This commit is contained in:
parent
b0e7389f0a
commit
9a977d6e16
|
@ -382,16 +382,11 @@ public final class AEnv
|
|||
{
|
||||
if (lookup == null)
|
||||
return;
|
||||
//
|
||||
MQuery zoomQuery = lookup.getZoomQuery();
|
||||
// still null means the field is empty or not selected item
|
||||
if (value == null)
|
||||
value = -1;
|
||||
|
||||
// If not already exist or exact value
|
||||
if (zoomQuery == null || value != null)
|
||||
{
|
||||
zoomQuery = new MQuery(); // ColumnName might be changed in MTab.validateQuery
|
||||
//
|
||||
MQuery zoomQuery = new MQuery(); // ColumnName might be changed in MTab.validateQuery
|
||||
String column = lookup.getColumnName();
|
||||
// Check if it is a List Reference
|
||||
if (lookup instanceof MLookup)
|
||||
|
@ -425,7 +420,6 @@ public final class AEnv
|
|||
zoomQuery.setZoomValue(value);
|
||||
zoomQuery.addRestriction(column, MQuery.EQUAL, value);
|
||||
zoomQuery.setRecordCount(1); // guess
|
||||
}
|
||||
if (value instanceof Integer && ((Integer) value).intValue() >= 0 && zoomQuery != null && zoomQuery.getZoomTableName() != null) {
|
||||
int tableId = MTable.getTable_ID(zoomQuery.getZoomTableName());
|
||||
zoom(tableId, ((Integer) value).intValue(), zoomQuery, lookup.getWindowNo());
|
||||
|
|
Loading…
Reference in New Issue