Changeset 4625
- Timestamp:
- 02/26/07 15:40:15 (2 years ago)
- Files:
-
- django/trunk/docs/model-api.txt (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
django/trunk/docs/model-api.txt
r4596 r4625 498 498 class Foo(models.Model): 499 499 gender = models.CharField(maxlength=1, choices=GENDER_CHOICES) 500 501 For each field on your model which has ``choices`` set, Django will 502 add a method to retrieve the human-readable name for the field's 503 current value; see `get_FOO_display`_ in the database API 504 documentation. 505 506 .. _get_FOO_display: ../db_api/#get-foo-display 500 507 501 508 Finally, note that choices can be any iterable object -- not necessarily a
