summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorMalcolm Tredinnick <malcolm.tredinnick@gmail.com>2008-04-13 03:04:11 +0000
committerMalcolm Tredinnick <malcolm.tredinnick@gmail.com>2008-04-13 03:04:11 +0000
commitcfb706385b6225e9bcc028b1f8eb5aec462fc161 (patch)
tree3bfc4d4c521168ed1689525f50980794fd4b1e35 /docs
parent4efe9675c5fd5a030737d957b3588184f06117fe (diff)
queryset-refactor: Merged from trunk up to [7415].
git-svn-id: http://code.djangoproject.com/svn/django/branches/queryset-refactor@7416 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'docs')
-rw-r--r--docs/modelforms.txt1
-rw-r--r--docs/newforms.txt5
-rw-r--r--docs/tutorial04.txt2
3 files changed, 5 insertions, 3 deletions
diff --git a/docs/modelforms.txt b/docs/modelforms.txt
index 554aeb7ea0..a76d797527 100644
--- a/docs/modelforms.txt
+++ b/docs/modelforms.txt
@@ -121,6 +121,7 @@ A full example
Consider this set of models::
from django.db import models
+ from django.newforms import ModelForm
TITLE_CHOICES = (
('MR', 'Mr.'),
diff --git a/docs/newforms.txt b/docs/newforms.txt
index d07f7f9dc3..25d80fda54 100644
--- a/docs/newforms.txt
+++ b/docs/newforms.txt
@@ -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_from_instance``. 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):
diff --git a/docs/tutorial04.txt b/docs/tutorial04.txt
index 8f23fdd9e6..78f954d632 100644
--- a/docs/tutorial04.txt
+++ b/docs/tutorial04.txt
@@ -266,7 +266,7 @@ from ``polls/views.py``. We don't need them anymore -- they have been replaced
by generic views.
The ``vote()`` view is still required. However, it must be modified to match
-the new context variables. In the ``render_to_repsonse()`` call, rename the
+the new context variables. In the ``render_to_response()`` call, rename the
``poll`` context variable to ``object``.
The last thing to do is fix the URL handling to account for the use of generic