Fixed #20224 -- Update docs examples which mention __unicode__

Thanks Marc Tamlyn and Tim Graham for the review.
This commit is contained in:
Claude Paroz 2013-07-04 15:19:33 +02:00
parent 577b0f9189
commit 7442eb1a24
24 changed files with 65 additions and 24 deletions

View file

@ -162,6 +162,7 @@ Consider this set of models::
title = models.CharField(max_length=3, choices=TITLE_CHOICES)
birth_date = models.DateField(blank=True, null=True)
# On Python 3: def __str__(self):
def __unicode__(self):
return self.name