Fakultas Ilmu Komputer UI

Commit 87d65d86 authored by Joshua Casey's avatar Joshua Casey
Browse files

[#140655219] #26 Revised permission to disallow company from accessing student list

parent bd55bc73
......@@ -47,7 +47,7 @@ class StudentViewSet(viewsets.ModelViewSet):
if self.action == "update":
return [IsAdminOrSelfOrReadOnly(), IsAdminOrStudent()]
if self.action == "list":
return [IsAuthenticated(), IsAdminOrSupervisorOrCompany()]
return [IsAuthenticated(), IsAdminOrSupervisor()]
if self.action == "retrieve":
return [IsAuthenticated(), IsAdminOrSupervisorOrCompanyOrSelf()]
return super(StudentViewSet, self).get_permissions()
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment