djangosnippets.org: Latest snippets posted by programmerDanhttps://djangosnippets.org/users/programmerDan/2011-09-02T15:48:44.288095-05:00programmerDanApp Display Label Template Filter Workaround
2011-09-02T15:48:44.288095-05:00programmerDanhttps://djangosnippets.org/snippets/2537/<p>I have been wrestling with custom app labels and have come to the conclusion that this is the easiest workaround for the problem. Since I name most of my apps as Foo_Bar this makes them look a lot nicer. I just apply the filter to whatever app label and it …</p>
Freely redistributableAdmin Model Sorting
2011-08-08T10:55:45.717603-05:00programmerDanhttps://djangosnippets.org/snippets/2508/<p>This allows you to order the models on the index page of the administration site in a custom way.</p>
<p>This modification goes in the index method of django.contrib.admin.sites.AdminSite. I personally monkey patched it in where my models are loaded and registered with the admin site. Be careful that if you …</p>
Freely redistributable