Skip to content
Extraits de code Groupes Projets
Valider 27219914 rédigé par Jamesie Pic's avatar Jamesie Pic
Parcourir les fichiers

Performance

parent ce5bf7f6
Aucune branche associée trouvée
Aucune étiquette associée trouvée
1 requête de fusion!12API release
...@@ -61,7 +61,7 @@ class ProposalViewSet(viewsets.ReadOnlyModelViewSet): ...@@ -61,7 +61,7 @@ class ProposalViewSet(viewsets.ReadOnlyModelViewSet):
API endpoint that allows proposals to be viewed. API endpoint that allows proposals to be viewed.
""" """
queryset = Proposal.objects.all() queryset = Proposal.objects.select_related('dossier')
serializer_class = ProposalSerializer serializer_class = ProposalSerializer
filter_backends = ( filter_backends = (
...@@ -103,7 +103,7 @@ class VoteViewSet(viewsets.ReadOnlyModelViewSet): ...@@ -103,7 +103,7 @@ class VoteViewSet(viewsets.ReadOnlyModelViewSet):
API endpoint that allows proposals to be viewed. API endpoint that allows proposals to be viewed.
""" """
queryset = Vote.objects.all() queryset = Vote.objects.select_related('representative', 'proposal')
serializer_class = VoteSerializer serializer_class = VoteSerializer
filter_backends = ( filter_backends = (
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Terminez d'abord l'édition de ce message.
Veuillez vous inscrire ou vous pour commenter