Decorating all admin views of django (1.4+)

There used to be a neat trick for Django versions prior to 1.4 to beautify all views in admin:

urlpatterns = patterns('', (r'^admin/(.*)', my_decorator(lambda *args: admin.site.root(*args))), ) 

This does not work anymore since root is deprecated. I found some alternatives, but they seem pretty verbose compared to what I had. Is there still a hook for this?

+3
source share
1 answer

Decorate each view in the URL tree

http://djangosnippets.org/snippets/2607/

+2
source

All Articles