Skip to content

Commit

Permalink
Remove edit functions from API endpoints
Browse files Browse the repository at this point in the history
  • Loading branch information
dchiller committed Aug 10, 2023
1 parent 85d8cce commit c08380c
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 8 deletions.
4 changes: 2 additions & 2 deletions app/public/cantusdata/views/chant.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@
from rest_framework import generics


class ChantList(generics.ListCreateAPIView):
class ChantList(generics.ListAPIView):
model = Chant
queryset = Chant.objects.all()
serializer_class = ChantSerializer


class ChantDetail(generics.RetrieveUpdateDestroyAPIView):
class ChantDetail(generics.RetrieveAPIView):
model = Chant
queryset = Chant.objects.all()
serializer_class = ChantSerializer
4 changes: 2 additions & 2 deletions app/public/cantusdata/views/concordance.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@
from rest_framework import generics


class ConcordanceList(generics.ListCreateAPIView):
class ConcordanceList(generics.ListAPIView):
model = Concordance
queryset = Concordance.objects.all()
serializer_class = ConcordanceSerializer


class ConcordanceDetail(generics.RetrieveUpdateDestroyAPIView):
class ConcordanceDetail(generics.RetrieveAPIView):
model = Concordance
queryset = Concordance.objects.all()
serializer_class = ConcordanceSerializer
4 changes: 2 additions & 2 deletions app/public/cantusdata/views/folio.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
from rest_framework import generics


class FolioList(generics.ListCreateAPIView):
class FolioList(generics.ListAPIView):
model = Folio
serializer_class = FolioSerializer

Expand All @@ -29,7 +29,7 @@ def get_queryset(self):
return queryset[:1] # Make sure we return only one element


class FolioDetail(generics.RetrieveUpdateDestroyAPIView):
class FolioDetail(generics.RetrieveAPIView):
model = Folio
queryset = Folio.objects.all()
serializer_class = FolioSerializer
4 changes: 2 additions & 2 deletions app/public/cantusdata/views/manuscript.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,15 @@
from cantusdata.renderers import templated_view_renderers


class ManuscriptList(generics.ListCreateAPIView):
class ManuscriptList(generics.ListAPIView):
model = Manuscript
queryset = Manuscript.objects.filter(public=True)
serializer_class = ManuscriptListSerializer
template_name = "require.html"
renderer_classes = templated_view_renderers


class ManuscriptDetail(generics.RetrieveUpdateDestroyAPIView):
class ManuscriptDetail(generics.RetrieveAPIView):
model = Manuscript
queryset = Manuscript.objects.filter(public=True)
serializer_class = ManuscriptSerializer
Expand Down

0 comments on commit c08380c

Please sign in to comment.