Skip to content

Commit

Permalink
Rename paths
Browse files Browse the repository at this point in the history
  • Loading branch information
kovacspe committed Nov 11, 2023
1 parent 9a53d58 commit e4275d2
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions competition/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -488,8 +488,8 @@ def remove_vote(self, request, pk=None):
self.get_object().set_vote(Vote.NONE)
return Response('Hlas Odobraný.', status=status.HTTP_200_OK)

@action(methods=['get'], detail=True, url_path='download-solution')
def download_solution(self, request, pk=None):
@action(methods=['get'], detail=True, url_path='file-solution')
def file_solution(self, request, pk=None):
"""Stiahne riešenie"""
solution = self.get_object()
file = solution.solution
Expand All @@ -500,8 +500,8 @@ def download_solution(self, request, pk=None):
file, content_type='application/pdf',
)

@action(methods=['get'], detail=True, url_path='download-corrected')
def download_corrected(self, request, pk=None):
@action(methods=['get'], detail=True, url_path='file-corrected')
def file_corrected(self, request, pk=None):
"""Stiahne opravenú verziu riešenia"""
solution = self.get_object()
file = solution.corrected_solution
Expand Down

0 comments on commit e4275d2

Please sign in to comment.