@@ -812,12 +812,13 class Query < ActiveRecord::Base | |||||
812 | s = [] |
|
812 | s = [] | |
813 | if from |
|
813 | if from | |
814 | if from.is_a?(Date) |
|
814 | if from.is_a?(Date) | |
815 |
from = Time.local(from.year, from.month, from.day). |
|
815 | from = Time.local(from.year, from.month, from.day).yesterday.end_of_day | |
|
816 | else | |||
|
817 | from = from - 1 # second | |||
816 | end |
|
818 | end | |
817 | if self.class.default_timezone == :utc |
|
819 | if self.class.default_timezone == :utc | |
818 | from = from.utc |
|
820 | from = from.utc | |
819 | end |
|
821 | end | |
820 | from = from - 1 |
|
|||
821 | s << ("#{table}.#{field} > '%s'" % [connection.quoted_date(from)]) |
|
822 | s << ("#{table}.#{field} > '%s'" % [connection.quoted_date(from)]) | |
822 | end |
|
823 | end | |
823 | if to |
|
824 | if to |
General Comments 0
You need to be logged in to leave comments.
Login now