Fixed #10389, #10501, #10502, #10540, #10562, #10563, #10564, #10565, #10568, #10569, #10614, #10617, #10619 -- Fixed several typos as well as a couple minor issues in the docs, patches from timo, nih, bthomas, rduffield, UloPe, and sebleier@gmail.com.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@10242 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
Gary Wilson Jr 2009-03-31 07:01:01 +00:00
parent 184ea1c91f
commit 7372ea159a
11 changed files with 41 additions and 44 deletions

View file

@ -45,7 +45,7 @@ something like this::
self.east = east
self.south = south
self.west = west
# ... (other possibly useful methods omitted) ...
.. _Bridge: http://en.wikipedia.org/wiki/Contract_bridge
@ -203,7 +203,7 @@ parameters:
:class:`ForeignKey`). For advanced use only.
* :attr:`~django.db.models.Field.default`
* :attr:`~django.db.models.Field.editable`
* :attr:`~django.db.models.Field.serialize`: If ``False``, the field will
* :attr:`~django.db.models.Field.serialize`: If ``False``, the field will
not be serialized when the model is passed to Django's :ref:`serializers
<topics-serialization>`. Defaults to ``True``.
* :attr:`~django.db.models.Field.prepopulate_from`
@ -254,7 +254,7 @@ called when the attribute is initialized.
Useful methods
--------------
Once you've created your :class:`~django.db.models.Field` subclass and set up up
Once you've created your :class:`~django.db.models.Field` subclass and set up
the ``__metaclass__``, you might consider overriding a few standard methods,
depending on your field's behavior. The list of methods below is in
approximately decreasing order of importance, so start from the top.
@ -419,9 +419,9 @@ For example::
Same as the above, but called when the Field value must be *saved* to the
database. As the default implementation just calls ``get_db_prep_value``, you
shouldn't need to implement this method unless your custom field need a special
conversion when being saved that is not the same as the used for normal query
parameters (which is implemented by ``get_db_prep_value``).
shouldn't need to implement this method unless your custom field needs a
special conversion when being saved that is not the same as the conversion used
for normal query parameters (which is implemented by ``get_db_prep_value``).
Preprocessing values before saving
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
@ -522,7 +522,7 @@ Continuing our ongoing example, we can write the :meth:`formfield` method as::
defaults.update(kwargs)
return super(HandField, self).formfield(**defaults)
This assumes we're imported a ``MyFormField`` field class (which has its own
This assumes we've imported a ``MyFormField`` field class (which has its own
default widget). This document doesn't cover the details of writing custom form
fields.