IDEMPIERE-5709 - Fixed SQLFind columns not working (#1822)

This commit is contained in:
Diego Ruiz 2023-05-05 18:13:19 +02:00 committed by GitHub
parent 0553878431
commit a8882677a0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 5 deletions

View File

@ -2253,7 +2253,7 @@ public class FindWindow extends Window implements EventListener<Event>, ValueCha
if (field == null || field.isVirtualUIColumn())
continue;
isProductCategoryField = isProductCategoryField(field.getColumnName());
ColumnSQL = field.getColumnSQL(false);
ColumnSQL = field.getSearchColumnSQL() != null ? field.getSearchColumnSQL() : field.getColumnSQL(false);
if (table.getSelectedItem() != null && !table.getSelectedItem().getValue().equals(m_AD_Tab_UU))
{
if (!isCompositeExists) {
@ -2640,7 +2640,7 @@ public class FindWindow extends Window implements EventListener<Event>, ValueCha
GridField field = getTargetMField(ColumnName);
boolean isProductCategoryField = isProductCategoryField(field.getColumnName());
StringBuilder ColumnSQL = new StringBuilder(field.getSearchColumnSQL());
StringBuilder ColumnSQL = field.getSearchColumnSQL() != null ? new StringBuilder(field.getSearchColumnSQL()) : new StringBuilder(field.getColumnSQL(false));
// add encryption here if the field is encrypted.
if (field.isEncrypted()) {
@ -2660,9 +2660,7 @@ public class FindWindow extends Window implements EventListener<Event>, ValueCha
m_query.addRestriction(clause);
continue;
}
isProductCategoryField = isProductCategoryField(field.getColumnName());
ColumnSQL = new StringBuilder(field.getColumnSQL(false));
//
// Be more permissive for String columns
if (isSearchLike(field))