| Class | ActsAsFerret::SharedIndex |
| In: |
lib/shared_index.rb
|
| Parent: | LocalIndex |
build a ferret query matching only the record with the given id and class
# File lib/shared_index.rb, line 6
6: def query_for_record(id, class_name)
7: returning bq = Ferret::Search::BooleanQuery.new do
8: bq.add_query(Ferret::Search::TermQuery.new(:id, id.to_s), :must)
9: bq.add_query(Ferret::Search::TermQuery.new(:class_name, class_name), :must)
10: end
11: end