@@ -812,12 +812,13 class Query < ActiveRecord::Base | |||
|
812 | 812 | s = [] |
|
813 | 813 | if from |
|
814 | 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 | 818 | end |
|
817 | 819 | if self.class.default_timezone == :utc |
|
818 | 820 | from = from.utc |
|
819 | 821 | end |
|
820 | from = from - 1 | |
|
821 | 822 | s << ("#{table}.#{field} > '%s'" % [connection.quoted_date(from)]) |
|
822 | 823 | end |
|
823 | 824 | if to |
General Comments 0
You need to be logged in to leave comments.
Login now