mirror of
https://github.com/django/django.git
synced 2025-08-04 10:59:45 +00:00
Corrected docs for return type of Field.formfield().
This commit is contained in:
parent
35e649b197
commit
17677d510f
1 changed files with 3 additions and 3 deletions
|
@ -1897,9 +1897,9 @@ Field API reference
|
|||
:class:`~django.forms.ModelForm`.
|
||||
|
||||
By default, if both ``form_class`` and ``choices_form_class`` are
|
||||
``None``, it uses :class:`~django.forms.CharField`; if
|
||||
``choices_form_class`` is given, it returns
|
||||
:class:`~django.forms.TypedChoiceField`.
|
||||
``None``, it uses :class:`~django.forms.CharField`. If the field has
|
||||
:attr:`~django.db.models.Field.choices` and ``choices_form_class``
|
||||
isn't specified, it uses :class:`~django.forms.TypedChoiceField`.
|
||||
|
||||
See :ref:`specifying-form-field-for-model-field` for usage.
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue