class documentation
class DjangoModelPermissions(BasePermission): (source)
Known subclasses: rest_framework.permissions.DjangoModelPermissionsOrAnonReadOnly
, rest_framework.permissions.DjangoObjectPermissions
The request is authenticated using `django.contrib.auth` permissions. See: https://docs.djangoproject.com/en/dev/topics/auth/#permissions It ensures that the user is authenticated, and has the appropriate `add`/`change`/`delete` permissions on the model. This permission can only be applied against view classes that provide a `.queryset` attribute.
Method | get |
Given a model and an HTTP method, return the list of permission codes that the user is required to have. |
Method | has |
Return `True` if permission is granted, `False` otherwise. |
Class Variable | authenticated |
Undocumented |
Class Variable | perms |
Undocumented |
Method | _queryset |
Undocumented |
Inherited from BasePermission
:
Method | has |
Return `True` if permission is granted, `False` otherwise. |
Given a model and an HTTP method, return the list of permission codes that the user is required to have.