Module: Spotlight::SolrDocument::Finder::ClassMethods
- Defined in:
- app/models/concerns/spotlight/solr_document/finder.rb
Overview
Class level finder methods for documents
Instance Method Summary collapse
Instance Method Details
#find(id) ⇒ Object
11 12 13 14 |
# File 'app/models/concerns/spotlight/solr_document/finder.rb', line 11 def find(id) solr_response = index.find(id) solr_response.documents.first end |
#index ⇒ Object
16 17 18 |
# File 'app/models/concerns/spotlight/solr_document/finder.rb', line 16 def index @index ||= blacklight_config.repository_class.new(blacklight_config) end |