Enable the 'stem' part of the matched URL to be passed to the view
|Reported by:||medhat||Owned by:||Adrian Holovaty|
|Cc:||Triage Stage:||Design decision needed|
|Has patch:||yes||Needs documentation:||no|
|Needs tests:||no||Patch needs improvement:||no|
Currently, when django is doing url matching, and it reaches a point where the urls.py file is including another urls.py, it will discard the part that was mathced so far, and then begin matching inside the included urls.py. This patch will enable passing that discarded part (here called stem) to the view that will be eventually called.
This will be useful in the case where one view is called by many url patterns from many urls.py files. It will enable the view to know where it was called from.
This patch is fully backwards compatible.
Change History (8)
comment:1 Changed 10 years ago by
|Patch needs improvement:||unset|
|Triage Stage:||Unreviewed → Design decision needed|