Skip to content

Commit

Permalink
remove bulkrax_identifier from Hyku
Browse files Browse the repository at this point in the history
bulrax_identifier is not a required property. Each client should set their desired source_identifier in their application.

Issue:
- scientist-softserv/hykuup_knapsack#136
  • Loading branch information
ShanaLMoore committed Jan 29, 2024
1 parent 963fda8 commit 887fbf2
Show file tree
Hide file tree
Showing 6 changed files with 1 addition and 95 deletions.
1 change: 0 additions & 1 deletion app/indexers/collection_indexer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ class CollectionIndexer < Hyrax::CollectionIndexer
# Uncomment this block if you want to add custom indexing behavior:
def generate_solr_document
super.tap do |solr_doc|
solr_doc['bulkrax_identifier_tesim'] = object.bulkrax_identifier if object.respond_to?(:bulkrax_identifier)
solr_doc["account_cname_tesim"] = Site.instance&.account&.cname
solr_doc['account_institution_name_ssim'] = Site.instance.institution_label
end
Expand Down
1 change: 0 additions & 1 deletion app/indexers/concerns/hyku_indexing.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ module HykuIndexing
object = resource if object.kind_of?(Valkyrie::Resource)

solr_doc['account_cname_tesim'] = Site.instance&.account&.cname
solr_doc['bulkrax_identifier_tesim'] = object.bulkrax_identifier if object.respond_to?(:bulkrax_identifier)
solr_doc['account_institution_name_ssim'] = Site.instance.institution_label
# TODO: Reinstate once valkyrie fileset work is complete - https://github.com/scientist-softserv/hykuup_knapsack/issues/34
solr_doc['all_text_tsimv'] = full_text(object.file_sets.first&.id) if object.kind_of?(ActiveFedora::Base)
Expand Down
33 changes: 0 additions & 33 deletions app/services/hyrax/custom_queries/find_by_bulkrax_identifier.rb

This file was deleted.

28 changes: 0 additions & 28 deletions app/services/wings/custom_queries/find_by_bulkrax_identifier.rb

This file was deleted.

9 changes: 1 addition & 8 deletions config/initializers/wings.rb
Original file line number Diff line number Diff line change
Expand Up @@ -45,18 +45,11 @@
Hyrax::CustomQueries::FindManyByAlternateIds,
Hyrax::CustomQueries::FindModelsByAccess,
Hyrax::CustomQueries::FindCountBy,
Hyrax::CustomQueries::FindByDateRange,
Hyrax::CustomQueries::FindByBulkraxIdentifier
Hyrax::CustomQueries::FindByDateRange
].each do |handler|
Hyrax.query_service.services[0].custom_queries.register_query_handler(handler)
end

[
Wings::CustomQueries::FindByBulkraxIdentifier
].each do |handler|
Hyrax.query_service.services[1].custom_queries.register_query_handler(handler)
end

Wings::ModelRegistry.register(GenericWorkResource, GenericWork)
Wings::ModelRegistry.register(ImageResource, Image)
end
Expand Down

This file was deleted.

0 comments on commit 887fbf2

Please sign in to comment.