I'm using django-guardian
to manage my permissions. Default each model has 3 perms: add
, change
, delete
. If I add my own permission e.g. view
, I will have all 4 in User managment tab and all 4 in model-object managment tab.
I know that is possible to filter permissions: Django admin - change permissions list
But I don't know how to filter permissions in model-object managment tab. Is it even possible?
I did some work. Maybe it's not best solution, but works:
admin_utils.py
:And now you can filter with
allowed_perms
admin.py
: