Opened 8 years ago

Closed 8 years ago

Last modified 5 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@…> 8 years ago.
7714.url_tag_doc.diff (829 bytes) - added by Julien Phalip 8 years ago.
Revised Viktor's patch, adding 'project_name' to the paths

Download all attachments as: .zip

Change History (7)

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

Attachment: patch.txt added

comment:1 Changed 8 years ago by Malcolm Tredinnick

Description: modified (diff)
Needs documentation: unset
Needs tests: unset
Patch needs improvement: unset

Unbroke description.

comment:2 Changed 8 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 8 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 8 years ago by Julien Phalip

Triage Stage: AcceptedReady for checkin

comment:4 Changed 8 years ago by Jacob

Resolution: fixed
Status: newclosed

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

comment:5 Changed 5 years ago by Jacob

milestone: 1.0

Milestone 1.0 deleted

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