Move patch forms in patch-list and detail page to a new template file
patch-forms.html and move them to the top of the patch-list page to
improve their discoverability.
Refactor forms.py, __init__.py, patch.py, and test_bundles.py files so
that the shared bundle form in patch-forms.html works for both the
patch-list and patch-detail pages. In particular, the changes normalize
the behavior of the error and update messages of the patch forms and
updates tests to reflect the changes. Overall, these changes make patch
forms ready for change and more synchronized in their behavior. More
specifically:
- Previously patch forms changes were separated between the patch-detail
and patch-list pages. Thus, desired changes to the patch forms
required changes to patch-list.html, submission.html, and forms.py.
So, the most important benefit to this change is that forms.py and
patch-forms.html become the two places to adjust the forms to handle
form validation and functionality as well as UI changes.
- Previously the patch forms in patch-list.html handled error and
update messages through views in patch.py, whereas the patch forms in
submission.html handled the messages with forms.py. Now, with a single
patch forms component in patch-forms.html, forms.py is set to handle
the messages and handle form validation for both pages.