Skip to content
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/Location for resource models #6335

Merged
merged 1 commit into from Oct 4, 2023
Merged

Fix based_near/Location for resource models #6335

merged 1 commit into from Oct 4, 2023

Conversation

dlpierce
Copy link
Contributor

@dlpierce dlpierce commented Sep 28, 2023

Fixes

Fixes #6277

Summary

Add form (pre)populator to handle the data sent/received from the controlled vocabulary input

Guidance for testing, such as acceptance criteria or new user interface behaviors:

  • In koppie, create/edit a work while utilizing the location field

Changes proposed in this pull request:

  • Add a prepopulator and populator for the based_near attribute of resource forms that use basic metadata
  • Add a way to automatically include those behaviors in any form that loads the basic metadata schema. This also will load other form field behaviors that match the metadata schema name.
  • Move access to Hyrax::Location service to Hyrax config

@samvera/hyrax-code-reviewers

@dlpierce dlpierce added notes-minor Release Notes: Non-breaking features notes-valkyrie Release Notes: Valkyrie specific notes-bugfix Release Notes: Fixed a bug labels Sep 28, 2023
Access location service via Hyrax config to allow easier mock responses in specs
Add form (pre)populator to handle the data sent/received from the controlled vocabulary input
Auto-include any properly named form field behaviors
@@ -14,7 +14,13 @@ def solrize
end

def full_label
Hyrax::LocationService.new.full_label(rdf_subject.to_s)
location_service.full_label(rdf_subject.to_s)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👨‍🍳 💋

@dlpierce dlpierce merged commit e363de7 into main Oct 4, 2023
4 checks passed
@dlpierce dlpierce deleted the valk-location branch October 4, 2023 16:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
notes-bugfix Release Notes: Fixed a bug notes-minor Release Notes: Non-breaking features notes-valkyrie Release Notes: Valkyrie specific
Projects
None yet
Development

Successfully merging this pull request may close these issues.

NoMethodError when editing a location value
2 participants