IDEMPIERE-2322 Cannot search Date+Time with time portion
This commit is contained in:
parent
54a5e2dbd3
commit
06bc792db5
|
@ -1145,7 +1145,7 @@ class Restriction implements Serializable
|
|||
if (Code instanceof String)
|
||||
sb.append(DB.TO_STRING(Code.toString()));
|
||||
else if (Code instanceof Timestamp)
|
||||
sb.append(DB.TO_DATE((Timestamp)Code));
|
||||
sb.append(DB.TO_DATE((Timestamp)Code, false));
|
||||
else
|
||||
sb.append(Code);
|
||||
|
||||
|
@ -1157,7 +1157,7 @@ class Restriction implements Serializable
|
|||
if (Code_to instanceof String)
|
||||
sb.append(DB.TO_STRING(Code_to.toString()));
|
||||
else if (Code_to instanceof Timestamp)
|
||||
sb.append(DB.TO_DATE((Timestamp)Code_to));
|
||||
sb.append(DB.TO_DATE((Timestamp)Code_to, false));
|
||||
else
|
||||
sb.append(Code_to);
|
||||
}
|
||||
|
|
|
@ -1662,8 +1662,10 @@ public class FindWindow extends Window implements EventListener<Event>, ValueCha
|
|||
{
|
||||
if (valueTo != null && valueTo.toString().length() > 0) {
|
||||
// range
|
||||
StringBuilder msglog = new StringBuilder(ColumnName).append(">=").append(value).append("<=").append(valueTo);
|
||||
if (log.isLoggable(Level.FINE)) log.fine(msglog.toString());
|
||||
if (log.isLoggable(Level.FINE)) {
|
||||
StringBuilder msglog = new StringBuilder(ColumnName).append(">=").append(value).append("<=").append(valueTo);
|
||||
log.fine(msglog.toString());
|
||||
}
|
||||
|
||||
GridField field = getTargetMField(ColumnName);
|
||||
StringBuilder ColumnSQL = new StringBuilder(field.getColumnSQL(false));
|
||||
|
@ -1671,8 +1673,10 @@ public class FindWindow extends Window implements EventListener<Event>, ValueCha
|
|||
ColumnName, wed.getDisplay(), wedTo.getDisplay(), true, 0);
|
||||
appendCode(code, ColumnName, MQuery.BETWEEN, value.toString(), valueTo.toString(), "AND", "", "");
|
||||
} else {
|
||||
StringBuilder msglog = new StringBuilder(ColumnName).append("=").append(value);
|
||||
if (log.isLoggable(Level.FINE)) log.fine(msglog.toString());
|
||||
if (log.isLoggable(Level.FINE)) {
|
||||
StringBuilder msglog = new StringBuilder(ColumnName).append("=").append(value);
|
||||
log.fine(msglog.toString());
|
||||
}
|
||||
|
||||
// globalqss - Carlos Ruiz - 20060711
|
||||
// fix a bug with virtualColumn + isSelectionColumn not yielding results
|
||||
|
@ -1723,8 +1727,10 @@ public class FindWindow extends Window implements EventListener<Event>, ValueCha
|
|||
}
|
||||
} else if (valueTo != null && valueTo.toString().length() > 0) {
|
||||
// filled upper limit without filling lower limit
|
||||
StringBuilder msglog = new StringBuilder(ColumnName).append("<=").append(valueTo);
|
||||
if (log.isLoggable(Level.FINE)) log.fine(msglog.toString());
|
||||
if (log.isLoggable(Level.FINE)) {
|
||||
StringBuilder msglog = new StringBuilder(ColumnName).append("<=").append(valueTo);
|
||||
log.fine(msglog.toString());
|
||||
}
|
||||
|
||||
GridField field = getTargetMField(ColumnName);
|
||||
StringBuilder ColumnSQL = new StringBuilder(field.getColumnSQL(false));
|
||||
|
|
Loading…
Reference in New Issue