Documented {{{singular}}} argument for m2m relationships (fixes #664).

git-svn-id: http://code.djangoproject.com/svn/django/trunk@1025 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
Jacob Kaplan-Moss 2005-10-30 14:35:44 +00:00
parent 7e0719efa6
commit fb55717a09
1 changed files with 8 additions and 0 deletions

View File

@ -621,6 +621,14 @@ the relationship should work. All are optional:
vertically).
``limit_choices_to`` See the description under ``ForeignKey`` above.
``singular`` The singular name of the field. Use to name the ``get_*``
methods: in the example above, Django gives the ``Pizza``
objects a ``get_topping_list()`` method, where ``topping``
is the default ``singular`` value derived from the lowercase
version of the class being linked to. Use the singular
parameter to change this, which is if you want one model to
have multiple ``ManyToMany`` relationships to another model.
======================= ============================================================
One-to-one relationships