Anonymous user
Boston Python Workshop/Saturday/Web app project: Difference between revisions
Boston Python Workshop/Saturday/Web app project (view source)
Revision as of 20:34, 5 March 2011
, 13 years ago→Playing with the API
Line 290:
def __unicode__(self):
return self.choice
Save the models.py file.
It's important to add __unicode__() methods to your models, not only for your own sanity when dealing with the interactive prompt, but also because objects' representations are used throughout Django's automatically-generated admin.
|