-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Resolve 500 error with dissemination search/advanced (#4497)
* Include error-handling Handled search AND advanced search. - Add form error labels for start and end dates in search. - Re-render search template instead of raising validation errors. * Create error alert template * Update POST for Search/Advanced - Removed "duplicate" logic for rendering form when it is not valid. - Instead, re-uses the logic for success and only applies a search on the tables when `form.is_valid()`. * Render user selection of audit years on form error * Linting * Provide error context Now displaying list of erroneous fields in error message when the form is invalid. * Update search-alert-error.html Fixes padding issue if there are no errors.
- Loading branch information
Showing
6 changed files
with
125 additions
and
68 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
{% load humanize %} | ||
{% load sprite_helper %} | ||
<div class="usa-alert usa-alert--error"> | ||
<div class="usa-alert__body"> | ||
<h2 class="usa-alert__heading">Error</h2> | ||
<p>The information you entered is invalid. Please double-check your information for errors.</p> | ||
{% if errors %} | ||
<ul> | ||
{% for error in errors %} | ||
<li>{{ error }}</li> | ||
{% endfor %} | ||
</ul> | ||
{% endif %} | ||
</div> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters