You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This error was encountered in both Louisville (Hyrax v2.9.6) and UTK (Hyrax v 3.4.1). This ticket replaces a similar UTK-specific ticket.
When trying to save a work or collection with metadata which does not pass rails server-side validations, we see an empty flash message on the screen. This may be a Hyrax bug or may be Hyku-specific. See screenshots below.
If the submission error is fixed and resubmitted, there may also be another error situation with permission templates which was overridden in Louisville and reported as a bug on Hyrax.
Rationale
Even though Hyku does not have built-in server-side metadata validations, if repositories built over Hyku add validations, these validations should be handled correctly. It should not be handled in each individual repository. UTK validates that there is only one title, and Louisville validates that slugs are unique. Both repositories have encountered this error.
Expected behavior
A metadata error in a work or collection should show an error telling what is incorrect, and allow correction of the error and resubmission of the form. There should be no empty flash error boxes on the screen.
Actual behavior
blank error messages may appear because the Hyrax partial _flash_msg.html.erb is not receiving the appropriate information to display the messages.
Redisplaying the form, correcting the error, and resubmitting resulted in a permission template error.
Steps to reproduce the behavior
Create a work with metadata that fails rails validations (i.e. a second title for UTK or a duplicate slug in Louisville). Note that Hyku itself does not use rails validations on the objects, so a valid may need to be added to be able to duplicate the issue here.
Fix the error and resubmit the form without a full form refresh.
Descriptive summary
This error was encountered in both Louisville (Hyrax v2.9.6) and UTK (Hyrax v 3.4.1). This ticket replaces a similar UTK-specific ticket.
When trying to save a work or collection with metadata which does not pass rails server-side validations, we see an empty flash message on the screen. This may be a Hyrax bug or may be Hyku-specific. See screenshots below.
If the submission error is fixed and resubmitted, there may also be another error situation with permission templates which was overridden in Louisville and reported as a bug on Hyrax.
Rationale
Even though Hyku does not have built-in server-side metadata validations, if repositories built over Hyku add validations, these validations should be handled correctly. It should not be handled in each individual repository. UTK validates that there is only one title, and Louisville validates that slugs are unique. Both repositories have encountered this error.
Expected behavior
A metadata error in a work or collection should show an error telling what is incorrect, and allow correction of the error and resubmission of the form. There should be no empty flash error boxes on the screen.
Actual behavior
_flash_msg.html.erb
is not receiving the appropriate information to display the messages.Steps to reproduce the behavior
Related work
Hyrax ticket regarding permission template error
Screenshots
The text was updated successfully, but these errors were encountered: