#7890: tutorial code - don't know where to insert
-----------------------------+----------------------------------------------
 Reporter:  droetker         |       Owner:  nobody    
   Status:  new              |   Milestone:            
Component:  Django Web site  |     Version:  SVN       
 Keywords:                   |       Stage:  Unreviewed
Has_patch:  0                |  
-----------------------------+----------------------------------------------
 on http://www.djangoproject.com/documentation/tutorial02/
 you write:
 ----
 Customize the admin change list[[BR]]
 #...[[BR]]
 [...]But you can change that by giving that method a short_description
 attribute:

 {{{
 def was_published_today(self):
     return self.pub_date.date() == datetime.date.today()
 was_published_today.short_description = 'Published today?'
 }}}
 ----
 I'm a Python beginner, and for me it is not clear where to put the last
 line, because in the models.py this def "was_published_today" is a sub
 method of the Poll class.
 But the above code snippet in your tutorial is not intendated, it is no
 tab in front of it.

 At least I don't know where to input that...
 (Maybe you'll laugh and say 'learn python' - but the rest of your tutorial
 is EXCELLENT for absolute beginners as well...)

-- 
Ticket URL: <http://code.djangoproject.com/ticket/7890>
Django Code <http://code.djangoproject.com/>
The web framework for perfectionists with deadlines
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to