[Answered ]-Needed django users and subusers with limited permissions

2👍

You will use Django Permissions.

https://docs.djangoproject.com/en/1.11/topics/auth/default/#topic-authorization

myuser.groups.set([group_list])
myuser.groups.add(group, group, ...)
myuser.groups.remove(group, group, ...)
myuser.groups.clear()
myuser.user_permissions.set([permission_list])
myuser.user_permissions.add(permission, permission, ...)
myuser.user_permissions.remove(permission, permission, ...)
myuser.user_permissions.clear()

and you will use included decorators or you will create custom decorators.

https://docs.djangoproject.com/en/1.11/ref/contrib/auth/#django.contrib.auth.models.User.is_staff

Custom Decorator:
How to write a custom decorator in django?

Leave a comment