-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix Based Near functionality #855
Conversation
Current status of workChanges to this point fix it in Hyrax, Hyku, and for the knapsack resource models. |
index_props = DogBiscuits.config.index_properties.collect do |prop| | ||
{ prop => CatalogController.send(:index_options, prop, DogBiscuits.config.property_mappings[prop]) } | ||
end | ||
CatalogController.send(:add_index_field, config, index_props) | ||
config.add_index_field 'all_text_tsimv', label: "Item contents", highlight: true, helper_method: :render_ocr_snippets, if: :query_present? | ||
config.add_index_field 'based_near_label_tesim', itemprop: 'contentLocation', link_to_facet: 'based_near_label_sim' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This fixes the form so you don't have to hit + to open the location before searching
@@ -7,7 +7,7 @@ | |||
<%= presenter.attribute_to_html(:identifier, render_as: :linked, search_field: 'identifier_tesim') %> | |||
<% end %> | |||
<%= presenter.attribute_to_html(:keyword, render_as: :faceted) %> | |||
<%= presenter.attribute_to_html(:based_near_label, render_as: :faceted) %> | |||
<%= presenter.attribute_to_html(:based_near_label) %> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
rendering the text as faceted resulted in an empty search so I removed the facet.
@@ -3,23 +3,14 @@ | |||
|
|||
Rails.application.config.after_initialize do | |||
# Add all concerns that are migrating from ActiveFedora here | |||
CONCERNS = [ConferenceItem, Dataset, ExamPaper, GenericWork, Image, JournalArticle, PublishedWork, Thesis].freeze | |||
CONCERNS = [ConferenceItem, Dataset, Etd, ExamPaper, GenericWork, Image, JournalArticle, PublishedWork, Thesis].freeze |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@laritakr Should Oer need to be in here too?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
At this point, we should leave OER and ETD out because those two work types aren't functioning right for adventist and that's a separate ticket to fix them
Story
Refs #851
Expected Behavior Before Changes
Using based near crashes the app.
Expected Behavior After Changes
Based Near attributes save, display, and edit appropriately
Screenshots / Video
Notes