mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 12:05:37 +00:00
BUGFIX: Make WithinRangeFilter work with dates and related columns.
This commit is contained in:
parent
6bb1218760
commit
7036abbd75
@ -26,8 +26,9 @@ class WithinRangeFilter extends SearchFilter {
|
||||
}
|
||||
|
||||
function apply(DataQuery $query) {
|
||||
$this->model = $query->applyRelation($this->relation);
|
||||
$query->where(sprintf(
|
||||
"%s >= %s AND %s <= %s",
|
||||
"%s >= '%s' AND %s <= '%s'",
|
||||
$this->getDbName(),
|
||||
Convert::raw2sql($this->min),
|
||||
$this->getDbName(),
|
||||
|
Loading…
x
Reference in New Issue
Block a user