diff options
| author | Tim Graham <timograham@gmail.com> | 2014-03-21 20:44:34 -0400 |
|---|---|---|
| committer | Tim Graham <timograham@gmail.com> | 2014-03-22 07:56:48 -0400 |
| commit | ee4edb1eda2ac8f09eb298929282b44776930c89 (patch) | |
| tree | 385d5f30d927069256aa57d0b44ac377ac06dfcc /docs/ref/forms | |
| parent | 1c8dbb0cc268c6a2edc8268776b440f64867e6fb (diff) | |
Made ModelForms raise ImproperlyConfigured if the list of fields is not specified.
Also applies to modelform(set)_factory and generic model views.
refs #19733.
Diffstat (limited to 'docs/ref/forms')
| -rw-r--r-- | docs/ref/forms/models.txt | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/docs/ref/forms/models.txt b/docs/ref/forms/models.txt index 1d2b468553..9700c1ed38 100644 --- a/docs/ref/forms/models.txt +++ b/docs/ref/forms/models.txt @@ -34,16 +34,16 @@ Model Form Functions See :ref:`modelforms-factory` for example usage. - .. versionchanged:: 1.6 - You must provide the list of fields explicitly, either via keyword arguments ``fields`` or ``exclude``, or the corresponding attributes on the form's inner ``Meta`` class. See :ref:`modelforms-selecting-fields` for more - information. Omitting any definition of the fields to use will result in all - fields being used, but this behavior is deprecated. + information. Omitting any definition of the fields to use will result in + an :exc:`~django.core.exceptions.ImproperlyConfigured` exception. + + .. versionchanged:: 1.8 - The ``localized_fields``, ``labels``, ``help_texts``, and - ``error_messages`` parameters were added. + Previously, omitting the list of fields was allowed and resulted in + a form with all fields of the model. .. function:: modelformset_factory(model, form=ModelForm, formfield_callback=None, formset=BaseModelFormSet, extra=1, can_delete=False, can_order=False, max_num=None, fields=None, exclude=None, widgets=None, validate_max=False, localized_fields=None, labels=None, help_texts=None, error_messages=None) |
