change retrieve function in quota
This commit is contained in:
@@ -287,6 +287,13 @@ class QuotaViewSet(BaseViewSet, SoftDeleteMixin, viewsets.ModelViewSet, DynamicS
|
||||
return Response(data, status=status.HTTP_201_CREATED)
|
||||
return Response(serializer.errors, status=status.HTTP_403_FORBIDDEN)
|
||||
|
||||
def retrieve(self, request, *args, **kwargs):
|
||||
instance = self.get_object()
|
||||
serializer = self.get_serializer(instance, context={
|
||||
"org": get_organization_by_user(request.user)
|
||||
})
|
||||
return Response(serializer.data)
|
||||
|
||||
@action(
|
||||
methods=['patch'],
|
||||
detail=True,
|
||||
|
||||
Reference in New Issue
Block a user