Use Paginator.get_page instead of Paginator.page
Avoid error on empty page
This commit is contained in:
parent
603e276bac
commit
bd43db4e21
@ -233,7 +233,7 @@ def budget_list(request):
|
||||
budgets_filtered.append(revision)
|
||||
|
||||
paginator = Paginator(budgets_filtered, 100)
|
||||
page = paginator.page(int(request.GET.get('page', '1')))
|
||||
page = paginator.get_page(int(request.GET.get('page', '1')))
|
||||
|
||||
# Categorise budgets
|
||||
budgets_action = []
|
||||
@ -603,7 +603,7 @@ def claim_list(request):
|
||||
claims_filtered.append(claim)
|
||||
|
||||
paginator = Paginator(claims_filtered, 100)
|
||||
page = paginator.page(int(request.GET.get('page', '1')))
|
||||
page = paginator.get_page(int(request.GET.get('page', '1')))
|
||||
|
||||
# Categorise claims
|
||||
claims_action = []
|
||||
|
Loading…
Reference in New Issue
Block a user