Ticket #15988: 15990.patch

File 15990.patch, 993 bytes (added by Aymeric Augustin, 14 years ago)
  • docs/topics/forms/modelforms.txt

     
    197197
    198198.. versionchanged:: 1.2
    199199
    200 The first time you call ``is_valid()`` or access the ``errors`` attribute of a
    201 ``ModelForm`` has always triggered form validation, but as of Django 1.2, it
    202 will also trigger :ref:`model validation <validating-objects>`. This has the
    203 side-effect of cleaning the model you pass to the ``ModelForm`` constructor.
     200Calling ``is_valid()`` or accessing the ``errors`` attribute of a ``ModelForm``
     201has always triggered form validation. As of Django 1.2, it also triggers
     202:ref:`model validation <validating-objects>`. This has the side-effect of
     203cleaning the model you pass to the ``ModelForm`` constructor.
    204204For instance, calling ``is_valid()`` on your form will convert any date fields
    205205on your model to actual date objects.
    206206
Back to Top