Opened 12 years ago

Closed 12 years ago

#4253 closed (invalid)

Problem with tutorial page 4

Reported by: anonymous Owned by: Jacob
Component: Documentation Version: master
Severity: Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no


In the last code-box of the 4th page of the tutorial, there is a problem. It should also include in the info_dict the parameter 'template_object_name' : "latest_poll". Otherwise, the old index.html template (renamed to poll_list.html) will not work, because it still uses 'latest_poll' instead of 'object'.

p.s. On the create new ticket page, there is a typo: "guidlines" should be "guidelines"

Change History (3)

comment:1 Changed 12 years ago by anonymous

If you add "latest_poll" as template_object_name in info_dict, it breaks poll_detail.html, which expects just "poll". So, probably it is better to add this parameter on a per-url basis, like is done with dict(info_dict, template_name='polls/results.html').

comment:2 Changed 12 years ago by anonymous

Ok, I see now that this problem was addressed in the tutorial, and I just didn't read all the way through.

But, I do think a nicer solution than renaming all of the latest_poll and poll's to 'object' is to use template_object_name...

comment:3 Changed 12 years ago by Simon G. <dev@…>

Resolution: invalid
Status: newclosed

Ok, closed as invalid. If you do want to see template_object_name used, please create a new ticket for it (and why not write it up too? :). I've also created a new ticket to get that guidelines typo fixed (#4256)

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