- Want to pretend an object is a ModelAdmin? Check out the HaystackResultsAdmin
- Need to fake a changelist for using in the
{% pagination %}
template tag? FakeChangeListForPaginator - Need to mount a ModelAdmin for a model that doesn't exist? Make an unmanaged model: HaystackResults
- Need to mount a second modeladmin for a model which has already been added? Use a proxy model. I actually don't have an app that does this, as far as I can
grep
. - Need to change the way the admin looks without replacing a substantial number of the templates? thadminjones
- Want frontend editing using the admin to do so? Look upon the terrifying face of adminlinks
- Need to add parameters passed to the changelist without it throwing a redirect to
?e=1
? AdminlinksChangeListMixin- want to dynamically apply that to a modeladmin? AdminlinksMixin.get_queryset
- want single-field edit forms? Something like AdminlinksMixin.change_field_view maybe.
- Just need to know how to add a new view to your admin? MenuItemAdmin.get_urls and MenuItemAdmin. import_view
- Want your inlines to be able to cause filters to be added to the changelist? URLAdmin.get_list_filter
- Want your inlines to be able to add a representation of their data to a changelist by adding a column? URLAdmin.get_list_display and URLInline. get_urladmin_display_func
- Want a set of inlines to cause a bunch of checks in a middleware? churlish in general. Yes, really.
- Want to prevent slugs changing? PageAdmin.get_prepopulated_fields and PageAdmin.get_readonly_fields
- Need a fake inline? (with a fake formset, fake media and fake form ...) EditRegionInline and associated bits (
EditRegionInlineFormSet
etc) - Want editable regions, generically attached to any ModelAdmin via an inline and a GFK? EditRegionAdmin and the rest of the app.
Created
May 30, 2014 10:31
-
-
Save kezabelle/f3c82ca02c8bd3e84604 to your computer and use it in GitHub Desktop.
So you want to ruin your life by hacking the Django admin, hey?
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment