Kaydet (Commit) 3ffbd545 authored tarafından LeeHanYeong's avatar LeeHanYeong Kaydeden (comit) Tim Graham

Removed incorrect reference to ModelChoiceField in Field.choices docs.

üst 941b0a5b
...@@ -170,10 +170,11 @@ ones: ...@@ -170,10 +170,11 @@ ones:
) )
The first element in each tuple is the value that will be stored in the The first element in each tuple is the value that will be stored in the
database. The second element will be displayed by the default form widget database. The second element is displayed by the field's form widget.
or in a :class:`~django.forms.ModelChoiceField`. Given a model instance,
the display value for a choices field can be accessed using the Given a model instance, the display value for a field with ``choices`` can
``get_FOO_display()`` method. For example:: be accessed using the :meth:`~django.db.models.Model.get_FOO_display`
method. For example::
from django.db import models from django.db import models
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment