Skip to content

Commit

Permalink
Fix installation part in readme
Browse files Browse the repository at this point in the history
  • Loading branch information
abogoyavlensky committed Mar 3, 2019
1 parent 3ea8d7e commit b9c1f46
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,15 @@ REST_FRAMEWORK = {
}
```

Or use it just for particular view or viewset in combination with others:
Or use it just for particular viewset in combination with others:

```python
from rest_framework.permissions import IsAuthenticated
from rest_framework.viewsets import ModelViewSet

from drf_action_permissions import DjangoActionPermissions

class MyView(APIView):
class MyView(viewsets.ModelViewSet):
permission_classes = (IsAuthenticated, DjangoActionPermissions)
perms_map_action = {
'retrieve': ['users.view_user'],
Expand Down

0 comments on commit b9c1f46

Please sign in to comment.