-
Notifications
You must be signed in to change notification settings - Fork 124
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
5594-single-membership-error-messages #6089
Conversation
before this commit, the flash message would show an error above the form AND there would be another error messa ge that showed within the form. these messages would be for the same reason. instead, this commit shows unique error m essages above the form only. ref: #5594 co-authored-by: rob <rob@scientist.com>
now that we are passing the GenericWorkForm instead of the SimpleForm::FormBuilder to the error partials in flash_msg.html.erb, #object is no longer an available method
… in the translation file
…_message_types`. this reduces the duplication of knowledge between the work form helper and flash message. it will also allow for better future debugging. co-authored-by: jeremy <jeremy.n.friesen@gmail.com>
74bd469
to
72a92dd
Compare
…k for the new selector.
…rb_spec.rb:138" we are now rendering form edit errors from the flash message, not the form partial.
the valkyrie form initialization is nested way down in the disposable gem. https://github.com/apotonick/disposable/blob/v0.6.3/lib/disposable/twin/changed.rb\#L25
300a5e4
to
9e78b4f
Compare
…matted. also update the flash_msg spec
@@ -97,112 +97,5 @@ def form_file_set_select_for(parent:) | |||
hash[presenter.title_or_label] = presenter.id | |||
end | |||
end | |||
|
|||
## | |||
# This helper retrieves errors based on form type. |
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.
since we're no longer rendering error messages from "app/views/hyrax/base/_form.html.erb", these methods are no longer called.
…rently. although Hyrax::GenericWorkForm could not be found in koppie when I ran the specs locally with ruby v3.2.1, it was found in the ci pipeline with ruby v2.7.x. I do not know the reason for the difference, but instead of handling the koppie app one way, and hyrax another....we will just search for one version of the class and fall back to the other.
"spec/services/hyrax/collections/collection_member_service_spec.rb:203" is failing in the I ran the pipeline in ci again, and again it has failed. 😞 |
Fixes
errors
for <GenericWork> when adding work to two collections of same single membership type (nurax-pg) #5594Summary
move and consolidate the "work form edit" related errors to the flash message.
Demo
Guidance for testing, such as acceptance criteria or new user interface behaviors:
Type of change (for release notes)
Detailed Description
before this change, the flash message would show an error above the form AND there would be another error message that showed within the form. these messages would be for the same reason. instead, this commit shows unique error messages above the form only.
@samvera/hyrax-code-reviewers