Fix bug [ 1662573 ] Search on Virtual Column fails in Lookup Record
This commit is contained in:
parent
bdee0b97e1
commit
53dcf85e0f
|
@ -618,10 +618,22 @@ public final class Find extends CDialog
|
||||||
{
|
{
|
||||||
String ColumnName = ((Component)ved).getName ();
|
String ColumnName = ((Component)ved).getName ();
|
||||||
log.fine(ColumnName + "=" + value);
|
log.fine(ColumnName + "=" + value);
|
||||||
|
|
||||||
|
// globalqss - Carlos Ruiz - 20060711
|
||||||
|
// fix a bug with virtualColumn + isSelectionColumn not yielding results
|
||||||
|
GridField field = getTargetMField(ColumnName);
|
||||||
|
String ColumnSQL = field.getColumnSQL(false);
|
||||||
|
if (value.toString().indexOf("%") != -1)
|
||||||
|
m_query.addRestriction(ColumnSQL, MQuery.LIKE, value, ColumnName, ved.getDisplay());
|
||||||
|
else
|
||||||
|
m_query.addRestriction(ColumnSQL, MQuery.EQUAL, value, ColumnName, ved.getDisplay());
|
||||||
|
/*
|
||||||
if (value.toString().indexOf("%") != -1)
|
if (value.toString().indexOf("%") != -1)
|
||||||
m_query.addRestriction(ColumnName, MQuery.LIKE, value, ColumnName, ved.getDisplay());
|
m_query.addRestriction(ColumnName, MQuery.LIKE, value, ColumnName, ved.getDisplay());
|
||||||
else
|
else
|
||||||
m_query.addRestriction(ColumnName, MQuery.EQUAL, value, ColumnName, ved.getDisplay());
|
m_query.addRestriction(ColumnName, MQuery.EQUAL, value, ColumnName, ved.getDisplay());
|
||||||
|
*/
|
||||||
|
// end globalqss patch
|
||||||
}
|
}
|
||||||
} // editors
|
} // editors
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue