aboutsummaryrefslogtreecommitdiffstats
path: root/app/models/info_request.rb
diff options
context:
space:
mode:
authorMatthew Landauer <matthew@openaustralia.org>2013-03-25 16:17:03 +1100
committerMatthew Landauer <matthew@openaustralia.org>2013-03-25 16:17:03 +1100
commit060d9fe70a1de0ba9aa592d25d6e7352114aa431 (patch)
treeee1c9485ffce0e7aa956af0133c616651e2ff8fb /app/models/info_request.rb
parentd09758c79fff462906b48dda6601ced25a8865da (diff)
Inline method InfoRequest.full_search
Diffstat (limited to 'app/models/info_request.rb')
-rw-r--r--app/models/info_request.rb15
1 files changed, 0 insertions, 15 deletions
diff --git a/app/models/info_request.rb b/app/models/info_request.rb
index 156399b99..4db4dadb0 100644
--- a/app/models/info_request.rb
+++ b/app/models/info_request.rb
@@ -189,21 +189,6 @@ class InfoRequest < ActiveRecord::Base
self.comments.find(:all, :conditions => 'visible')
end
- # Central function to do all searches
- # (Not really the right place to put it, but everything can get it here, and it
- # does *mainly* find info requests, via their events, so hey)
- def InfoRequest.full_search(models, query, order, ascending, collapse, per_page, page)
- offset = (page - 1) * per_page
-
- return ::ActsAsXapian::Search.new(
- models, query,
- :offset => offset, :limit => per_page,
- :sort_by_prefix => order,
- :sort_by_ascending => ascending,
- :collapse_by_prefix => collapse
- )
- end
-
# If the URL name has changed, then all request: queries will break unless
# we update index for every event. Also reindex if prominence changes.
after_update :reindex_some_request_events