Skip to content

Commit

Permalink
Timestamp::from
Browse files Browse the repository at this point in the history
  • Loading branch information
usfalami committed May 27, 2024
1 parent 2e29bec commit 0b34c1e
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,12 @@
import org.usf.jquery.core.DBFilter;
import org.usf.trace.api.server.config.TraceApiTable;

import java.sql.Timestamp;
import java.time.Instant;
import java.util.ArrayList;
import java.util.Collection;

import static java.sql.Timestamp.from;
import static org.usf.jquery.core.Utils.isEmpty;
import static org.usf.trace.api.server.config.TraceApiColumn.*;

Expand All @@ -36,10 +38,10 @@ public Collection<DBFilter> filters(TraceApiTable table) {
filters.add(table.column(ENVIRONEMENT).in(getEnvironments()));
}
if(getStart() != null) {
filters.add(table.column(START).greaterOrEqual(getStart()));
filters.add(table.column(START).greaterOrEqual(from(getStart())));
}
if(getEnd() != null) {
filters.add(table.column(END).lessThan(getEnd()));
filters.add(table.column(END).lessThan(from(getEnd())));
}
return filters;
}
Expand Down

0 comments on commit 0b34c1e

Please sign in to comment.