Opened 10 years ago
Closed 10 years ago
#22737 closed New feature (needsinfo)
Ability to implicitly preappend current_app to reverse URL resolution.
Reported by: | CVi | Owned by: | nobody |
---|---|---|---|
Component: | Core (URLs) | Version: | dev |
Severity: | Normal | Keywords: | |
Cc: | Triage Stage: | Unreviewed | |
Has patch: | no | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
I want to be able to implicitly preappend the current_app as a namespace to some URL reverse-resolutions.
My suggestion would be that names starting with a colon ':' (e.g. empty string as first level namespace) implies current_app if present.
A very simple 2-line solution can be found on my github page
The question is if this breaches any philosophies of Django. There's no reason for me to create an elaborate patch including additional tests for this, if it's going to be cut down for political/design reasons. Therefore I am not ticking "has patch" just yet.
The possible use-cases for this is template reuse and making applications modular by simply splitting them up. (my use case covers both)
Change History (2)
comment:1 by , 10 years ago
comment:2 by , 10 years ago
Resolution: | → needsinfo |
---|---|
Status: | new → closed |
Closing as "needs info" until the discussion happens.
Design decisions are usually made on the django-developers mailling list. I would post this idea there to get feedback.