Showing
4 changed files
with
2 additions
and
10 deletions
project/apps/core/tests.py
deleted
100644 → 0
@@ -2,6 +2,7 @@ from rest_framework import viewsets, filters | @@ -2,6 +2,7 @@ from rest_framework import viewsets, filters | ||
2 | from django_filters.rest_framework import DjangoFilterBackend | 2 | from django_filters.rest_framework import DjangoFilterBackend |
3 | from rest_framework.permissions import IsAuthenticated | 3 | from rest_framework.permissions import IsAuthenticated |
4 | 4 | ||
5 | + | ||
5 | from core.permissions import CustomModelPermissions | 6 | from core.permissions import CustomModelPermissions |
6 | from organismo.filters import OrganismoFilter | 7 | from organismo.filters import OrganismoFilter |
7 | from organismo.models import Organismo | 8 | from organismo.models import Organismo |
@@ -10,7 +11,7 @@ from organismo.serializers import OrganismoSerializer | @@ -10,7 +11,7 @@ from organismo.serializers import OrganismoSerializer | ||
10 | 11 | ||
11 | class OrganismoViewSet(viewsets.ReadOnlyModelViewSet): | 12 | class OrganismoViewSet(viewsets.ReadOnlyModelViewSet): |
12 | queryset = Organismo.objects.all() | 13 | queryset = Organismo.objects.all() |
13 | - # permission_classes = (IsAuthenticated, CustomModelPermissions) | 14 | + permission_classes = (IsAuthenticated, CustomModelPermissions) |
14 | serializer_class = OrganismoSerializer | 15 | serializer_class = OrganismoSerializer |
15 | filter_backends = (DjangoFilterBackend, filters.OrderingFilter) | 16 | filter_backends = (DjangoFilterBackend, filters.OrderingFilter) |
16 | filterset_class = OrganismoFilter | 17 | filterset_class = OrganismoFilter |
project/apps/organismo/tests.py
deleted
100644 → 0
project/apps/usuario/tests.py
deleted
100644 → 0
-
Please register or login to post a comment