Module: Hyrax::ResourceIndexer

Included in:
AdministrativeSetIndexer, PcdmCollectionIndexer, ValkyrieFileSetIndexer, ValkyrieWorkIndexer
Defined in:
app/indexers/hyrax/resource_indexer.rb

Overview

Indexes properties common to Hyrax::Resource types

Instance Method Summary collapse

Instance Method Details

#to_solrObject



7
8
9
10
11
12
13
# File 'app/indexers/hyrax/resource_indexer.rb', line 7

def to_solr
  super.tap do |index_document|
    index_document[:has_model_ssim] = resource.class.name
    index_document[:human_readable_type_tesim] = resource.human_readable_type
    index_document[:alternate_ids_sim] = resource.alternate_ids.map(&:to_s)
  end
end