mirror of
https://code.eliotberriot.com/funkwhale/funkwhale.git
synced 2025-10-04 00:39:16 +02:00
"[EPIC] Report option on everything - reports models
This commit is contained in:
parent
079671ef7a
commit
a6cf2ce019
22 changed files with 792 additions and 21 deletions
|
@ -6,6 +6,7 @@ from rest_framework import exceptions, mixins, permissions, response, viewsets
|
|||
from rest_framework.decorators import action
|
||||
|
||||
from funkwhale_api.common import preferences
|
||||
from funkwhale_api.moderation import models as moderation_models
|
||||
from funkwhale_api.music import models as music_models
|
||||
from funkwhale_api.music import utils as music_utils
|
||||
|
||||
|
@ -86,6 +87,15 @@ class EditViewSet(FederationMixin, mixins.RetrieveModelMixin, viewsets.GenericVi
|
|||
# serializer_class = serializers.ActorSerializer
|
||||
|
||||
|
||||
class ReportViewSet(
|
||||
FederationMixin, mixins.RetrieveModelMixin, viewsets.GenericViewSet
|
||||
):
|
||||
lookup_field = "uuid"
|
||||
authentication_classes = [authentication.SignatureAuthentication]
|
||||
renderer_classes = renderers.get_ap_renderers()
|
||||
queryset = moderation_models.Report.objects.none()
|
||||
|
||||
|
||||
class WellKnownViewSet(viewsets.GenericViewSet):
|
||||
authentication_classes = []
|
||||
permission_classes = []
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue