Skip to content

Commit

Permalink
Merge pull request #824 from WesternFriend/fix-memorials-pagination-q…
Browse files Browse the repository at this point in the history
…uery

Include previous query in memorials pagination
  • Loading branch information
brylie authored Jul 28, 2023
2 parents 67c365a + 82161fb commit b7908b4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions memorials/templates/memorials/memorial_index_page.html
Original file line number Diff line number Diff line change
Expand Up @@ -91,15 +91,15 @@ <h2 class="d-flex w-100">

<div class="list-group-item d-flex w-100 justify-content-center mt-2">
{% if memorials.has_previous %}
<a href="?page={{ memorials.previous_page_number }}" class="btn btn-outline-primary btn-sm me-2">previous</a>
<a href="?page={{ memorials.previous_page_number }}&{{ request.GET.urlencode }}" class="btn btn-outline-primary btn-sm me-2">previous</a>
{% endif %}

<span class="current">
Page {{ memorials.number }} of {{ memorials.paginator.num_pages }}
</span>

{% if memorials.has_next %}
<a href="?page={{ memorials.next_page_number }}" class="btn btn-outline-primary btn-sm ms-2">next</a>
<a href="?page={{ memorials.next_page_number }}&{{ request.GET.urlencode }}" class="btn btn-outline-primary btn-sm ms-2">next</a>
{% endif %}
</div>
</div>
Expand Down

0 comments on commit b7908b4

Please sign in to comment.