Fix the "Last" page link in the search results.

Review Request #11675 — Created June 25, 2021 and submitted

Information

Review Board
release-4.0.x

Reviewers

Haystack removed a template context variable we used to grab the last
page number, for the "Last" page link in the paginator. This change
fixes that anchor.

It also fixes up the view code to use the modern version of range(),
to ensure consistency across Python 2.7 and 3.x.

Unit tests were added to ensure this doesn't regress in the future.

Verified that search results render and include all the right links
on Python 2.x and 3.x.

Unit tests passed.

Summary ID
Fix the "Last" page link in the search results.
Haystack removed a template context variable we used to grab the last page number, for the "Last" page link in the paginator. This change fixes that anchor. It also fixes up the view code to use the modern version of `range()`, to ensure consistency across Python 2.7 and 3.x. Unit tests were added to ensure this doesn't regress in the future.
7f17e2a91d1f45227c7668a6fc9dda0c411a4554
david
  1. Ship It!
  2. 
      
chipx86
Review request changed

Status: Closed (submitted)

Change Summary:

Pushed to release-4.0.x (d875b0a)
Loading...