Opened 17 years ago

Closed 17 years ago

#6902 closed (duplicate)

reverse url mapping in admin templates

Reported by: mariarchi Owned by: nobody
Component: Uncategorized Version: newforms-admin
Severity: Keywords: nfa-someday, urls, dry
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

It would be nice to have reverse url mapping inside the admin templates insted of hard-coded ones.
At the moment, if one wants to add something to the block {% userlinks %}, he has to modify almost every template to do this? which is quite time-consuming and violates the DRY principle. If reverse url mapping was used, all templates could inherit that block (and other blocks with links) from the base template, which would be much more convenient.

However, there is no url configuration file for the admin "views" and adding one will require quite big structural changes (which might be useful, though - this way admin panel will be even more customizable).

The easy way to do this is using generated absolute links, instead of hardcoded relative ones. For example, the link to the documentation will be url(name_of_the_admin_panel_url) + 'doc/'

Change History (1)

comment:1 by Brian Rosner, 17 years ago

Resolution: duplicate
Status: newclosed
Version: SVNnewforms-admin

Duplicate of #6470.

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