Sometimes I need to UNREGISTER some ModelAdmins from the admin site, because I don't want them to be there as they are, eg. if I'm using the Sites framework, and I dont want it to appear in the admin. It's no big deal to e.g. call admin.site.unregister(Site) to do so. In most cases I put it in admin.py of some related app that I have made, but sometimes I end up putting it in a place that hasn't much to do with the original app; another possibility would be making a "dummy app" and put it there...
Does anybody know a more descent place where these calls can live?
views:
14answers:
1
+2
A:
You could put it in urls.py or wherever you call admin.autodiscover().
Collin Anderson
2010-06-15 21:10:47
Thanks, seems to be a good place!
lazerscience
2010-06-15 21:26:38