diff --git a/portal/portal/hackathons/views.py b/portal/portal/hackathons/views.py index 15e3f31b..e4efd510 100644 --- a/portal/portal/hackathons/views.py +++ b/portal/portal/hackathons/views.py @@ -42,7 +42,11 @@ def get( "created", ): if submission.content_object not in submissions: - submissions[submission.content_object] = submission + count = models.Submission.objects.filter( + content_type=submission.content_type, + object_id=submission.object_id, + ).count() + submissions[submission.content_object] = (submission, count) context = self.get_context_data(object=self.object, submissions=submissions) diff --git a/portal/portal/templates/hackathons/leaderboard.html b/portal/portal/templates/hackathons/leaderboard.html index 040d5597..646c6ca7 100644 --- a/portal/portal/templates/hackathons/leaderboard.html +++ b/portal/portal/templates/hackathons/leaderboard.html @@ -18,6 +18,7 @@

Leaderboard

Team Name Score + Submissions @@ -28,7 +29,8 @@

Leaderboard

{{ obj.hackathon_team_id }} {{ obj.name }} - {{ submission.score|floatformat:3 }} + {{ submission.0.score|floatformat:3 }} + {{ submission.1 }} {% endfor %}