Fixed #26020 -- Normalized header stylings in docs.

This commit is contained in:
Elif T. Kus 2016-01-03 12:56:22 +02:00 committed by Tim Graham
parent 79d0a4fdb0
commit bca9faae95
132 changed files with 1498 additions and 1464 deletions

View file

@ -210,7 +210,7 @@ Validation on a ``ModelForm``
There are two main steps involved in validating a ``ModelForm``:
1. :ref:`Validating the form <form-and-field-validation>`
1. :doc:`Validating the form </ref/forms/validation>`
2. :ref:`Validating the model instance <validating-objects>`
Just like normal form validation, model form validation is triggered implicitly
@ -234,7 +234,7 @@ validation step, right after the form's ``clean()`` method is called.
.. _overriding-modelform-clean-method:
Overriding the clean() method
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
You can override the ``clean()`` method on a model form to provide additional
validation in the same way you can on a normal form.
@ -253,7 +253,7 @@ attribute that gives its methods access to that specific model instance.
validation, you must call the parent class's ``clean()`` method.
Interaction with model validation
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
As part of the validation process, ``ModelForm`` will call the ``clean()``
method of each field on your model that has a corresponding field on your form.
@ -268,7 +268,7 @@ on the model's ``clean()`` hook.
.. _considerations-regarding-model-errormessages:
Considerations regarding model's ``error_messages``
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Error messages defined at the
:attr:`form field <django.forms.Field.error_messages>` level or at the