Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Added versionadded markers for ModelForm field ordering, added in [10…

…062].

git-svn-id: http://code.djangoproject.com/svn/django/trunk@10144 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit 6cd8e0f608583d13290d48bc348e5fe7c298878a 1 parent 214c792
@freakboy3742 freakboy3742 authored
Showing with 8 additions and 2 deletions.
  1. +8 −2 docs/topics/forms/modelforms.txt
View
10 docs/topics/forms/modelforms.txt
@@ -259,8 +259,12 @@ model fields:
2. Use the ``fields`` attribute of the ``ModelForm``'s inner ``Meta``
class. This attribute, if given, should be a list of field names
- to include in the form. The form will render the fields in the same
- order they are specified in the ``fields`` attribute.
+ to include in the form.
+
+ .. versionchanged:: 1.1
+
+ The form will render the fields in the same order they are specified in the
+ ``fields`` attribute.
3. Use the ``exclude`` attribute of the ``ModelForm``'s inner ``Meta``
class. This attribute, if given, should be a list of field names
@@ -340,6 +344,8 @@ parameter when declaring the form field::
Changing the order of fields
----------------------------
+.. versionadded:: 1.1
+
By default, a ``ModelForm`` will render fields in the same order that they are
defined on the model, with ``ManyToManyField`` instances appearing last. If
you want to change the order in which fields are rendered, you can use the
Please sign in to comment.
Something went wrong with that request. Please try again.