Skip to content

Commit

Permalink
Add past contests anchor for the pagination bar pages (DMOJ#1477)
Browse files Browse the repository at this point in the history
  • Loading branch information
Ninjaclasher authored and outloudvi committed Oct 3, 2020
1 parent 24225b0 commit b94669c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions judge/views/contests.py
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,7 @@ def get_context_data(self, **kwargs):
context['future_contests'] = future
context['now'] = self._now
context['first_page_href'] = '.'
context['page_suffix'] = '#past-contests'
return context


Expand Down
2 changes: 1 addition & 1 deletion templates/contest/list.html
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ <h4>{{ _('Upcoming Contests') }}</h4>
{% endif %}

{% if past_contests %}
<h4>{{ _('Past Contests') }}</h4>
<h4 id="past-contests">{{ _('Past Contests') }}</h4>
{% if page_obj and page_obj.has_other_pages() %}
<div style="margin-bottom: 4px;">
{% include "list-pages.html" %}
Expand Down

0 comments on commit b94669c

Please sign in to comment.