0
0
mirror of https://github.com/django/django.git synced 2024-12-01 15:42:04 +01:00

Fix a minor typo in docs/newforms.txt

git-svn-id: http://code.djangoproject.com/svn/django/trunk@7408 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
James Bennett 2008-04-08 06:28:50 +00:00
parent 7fbea577e6
commit 25c0908ffd

View File

@ -1555,8 +1555,9 @@ representing a foreign key.
The ``__unicode__`` method of the model will be called to generate
string representations of the objects for use in the field's choices;
to provide customized representations, subclass ``ModelChoiceField``
and override ``label_for_model``. This method will receive model
object, and should return a string suitable for representing it::
and override ``label_for_model``. This method will receive a model
object, and should return a string suitable for representing it. For
example::
class MyModelChoiceField(ModelChoiceField):
def label_from_instance(self, obj):