Created
May 16, 2011 20:00
-
-
Save jirihradil/ad2d4474a46101e80656 to your computer and use it in GitHub Desktop.
sunspot solr, OR condition
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sunspot.search(Post) do | |
any_of do | |
with(:expired_at).greater_than(Time.now) | |
with(:expired_at, nil) | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment