Loading stats/admin.py +2 −2 Changes for stats/admin.py: 2 added lines, 2 removed lines. Original line number Diff line number Diff line Loading @@ -25,10 +25,10 @@ def statistics(request, election_id): overall_attendance = (total_participated / total_eligible * 100) if total_eligible > 0 else 0 stats_raw = Voter.objects.values('group').annotate( total_voters=Count('id'), total_voters=Count('id', distinct=True), voted_count=Count( 'participation', filter=Q(participation__election=election) filter=Q(participation__election=election), distinct=True ) ).order_by('group') Loading Loading
stats/admin.py +2 −2 Changes for stats/admin.py: 2 added lines, 2 removed lines. Original line number Diff line number Diff line Loading @@ -25,10 +25,10 @@ def statistics(request, election_id): overall_attendance = (total_participated / total_eligible * 100) if total_eligible > 0 else 0 stats_raw = Voter.objects.values('group').annotate( total_voters=Count('id'), total_voters=Count('id', distinct=True), voted_count=Count( 'participation', filter=Q(participation__election=election) filter=Q(participation__election=election), distinct=True ) ).order_by('group') Loading