В админ панель добавлены итоги голосования, процент проголосовавших Мой коллега самый лучший

This commit is contained in:
Andrei Filippov committed 2024-10-30 17:19:49 +03:00
1 parent af1f9f752c
commit e3661db5cb
2 files changed
+45 -7

No files matched your search

+1 -1
View File
@@ -64,7 +64,7 @@ class GetBest(APIView):
def get(self, request):
# Группировка кандидатов по имени и подсчет каждого
count_bests = BestVote.objects.values(
'cand_name').annotate(total=Count('id'))
'department_user', 'cand_name').annotate(total=Count('id'))
return Response(count_bests)