Opened 15 years ago

Closed 15 years ago

#11324 closed (invalid)

Tutorial 1 - import datetime

Reported by: Timbadu Owned by: nobody
Component: Uncategorized Version: 1.0
Severity: Keywords: Tutorial 1
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

Where do I put this custom method:

class Poll(models.Model):

# ...
def unicode(self):

return self.question

class Choice(models.Model):

# ...
def unicode(self):

return self.choice

I've tried a few places with no sucess in runing the shell.

Change History (1)

comment:1 by Alex Gaynor, 15 years ago

Resolution: invalid
Status: newclosed

Please dont' use trac for asking support questions, use either #django on freenode or the django-users mailing list.

Note: See TracTickets for help on using tickets.
Back to Top