Django

Code

Changeset 1025

Show
Ignore:
Timestamp:
10/30/05 08:35:44 (3 years ago)
Author:
jacob
Message:

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

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • django/trunk/docs/model-api.txt

    r1006 r1025  
    622622 
    623623    ``limit_choices_to``     See the description under ``ForeignKey`` above. 
     624 
     625    ``singular``             The singular name of the field.  Use to name the ``get_*`` 
     626                             methods: in the example above, Django gives the ``Pizza`` 
     627                             objects a ``get_topping_list()`` method, where ``topping`` 
     628                             is the default ``singular`` value derived from the lowercase 
     629                             version of the class being linked to.  Use the singular 
     630                             parameter to change this, which is if you want one model to 
     631                             have multiple ``ManyToMany`` relationships to another model. 
    624632    =======================  ============================================================ 
    625633