Opened 10 years ago

Closed 10 years ago

Last modified 7 years ago

#7714 closed (fixed)

corrected documentation for {% url %} resolver

Reported by: V Owned by: nobody
Component: Documentation Version: master
Severity: Keywords: url resolver
Cc: Triage Stage: Ready for checkin
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: yes
Easy pickings: UI/UX:

Description (last modified by Malcolm Tredinnick)

there were two errors:

  1. ('^client/(\d+)/$', 'app_name.app_views.client') originally ('^client/(\d+)/$', 'app_views.client')

gives you an ImportError (ViewDoesNotExist)

  1. {% url app_name.app_views.client %} originally {% url app_views.client %}

simply doesn't work

to check I did:

  1. startapp app_name
  2. add to the main as in the docs
  3. add to app_name/ as shown above
  4. creates with view client that gives back {% url app_views.client %}

Attachments (2)

patch.txt (884 bytes) - added by Viktor <viktor.nagy@…> 10 years ago.
7714.url_tag_doc.diff (829 bytes) - added by Julien Phalip 10 years ago.
Revised Viktor's patch, adding 'project_name' to the paths

Download all attachments as: .zip

Change History (7)

Changed 10 years ago by Viktor <viktor.nagy@…>

Attachment: patch.txt added

comment:1 Changed 10 years ago by Malcolm Tredinnick

Description: modified (diff)

Unbroke description.

comment:2 Changed 10 years ago by Marc Garcia

milestone: 1.0
Patch needs improvement: set
Triage Stage: UnreviewedAccepted

I agree on that, but I think that to correct it isn't enough to add the application name, it's also needed to add the project name.

So app_views.client should be project_name.app_name.app_views.client

Changed 10 years ago by Julien Phalip

Attachment: 7714.url_tag_doc.diff added

Revised Viktor's patch, adding 'project_name' to the paths

comment:3 Changed 10 years ago by Julien Phalip

Triage Stage: AcceptedReady for checkin

comment:4 Changed 10 years ago by Jacob

Resolution: fixed
Status: newclosed

(In [8332]) Clarified a bit of the {% url %} documentation. Fixes #7714.

comment:5 Changed 7 years ago by Jacob

milestone: 1.0

Milestone 1.0 deleted

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