diff options
| author | Adrian Holovaty <adrian@holovaty.com> | 2007-09-14 19:28:14 +0000 |
|---|---|---|
| committer | Adrian Holovaty <adrian@holovaty.com> | 2007-09-14 19:28:14 +0000 |
| commit | 337f19828f1d3dc480464409ff0bdc1190abc1ac (patch) | |
| tree | f383ea4f7fd6fe0b41f88b3daf5a0fffb178d64f | |
| parent | d5ed482d6008c1e5826ab7426e87313e224b4f02 (diff) | |
newforms-admin: Fixed #5251 -- 'Show in Web' links now work properly again. Thanks, Florian Apolloner
git-svn-id: http://code.djangoproject.com/svn/django/branches/newforms-admin@6207 bcc190cf-cafb-0310-a4f2-bffc1f526a37
| -rw-r--r-- | django/contrib/admin/sites.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/django/contrib/admin/sites.py b/django/contrib/admin/sites.py index 9dce22e07c..8d7ec139d6 100644 --- a/django/contrib/admin/sites.py +++ b/django/contrib/admin/sites.py @@ -123,6 +123,10 @@ class AdminSite(object): return self.password_change_done(request) elif url == 'jsi18n': return self.i18n_javascript(request) + # urls starting with 'r/' are for the "show in web" links + elif url.startswith('r/'): + from django.views.defaults import shortcut + return shortcut(request, *url.split('/')[1:]) else: match = USER_CHANGE_PASSWORD_URL_RE.match(url) if match: |
