Cant show 5 by 5 with paginator of Django
I'm using paginator of Django 5.1, the paginator work well but cant show dat 4 by 4 I want to show data 4 by 4
views.py
def tipomaterial(request):
tipomaterial = TipoMaterial.objects.all().order_by('nombre')
#paginador de 4 en 4
paginator = Paginator(tipomaterial, 4)
page_number = request.GET.get('page', 1)
pgtm = paginator.get_page(page_number)
return render(request, 'tipomaterial.html',
{ 'tipomaterial': tipomaterial,
'pgtm': pgtm
})
tipomaterial.html
<main class="container py-5">
<br/><br/>
<hr>
<span class="step-links">
{% if pgtm.has_previous %}
<a href="?page={{ pgtm.previous_page_number }}">Previous</a>
{% endif %}
<span class="current">
Page {{ pgtm.number }} of {{ pgtm.paginator.num_pages }}.
</span>
{% if pgtm.has_next %}
<a href="?page={{ pgtm.next_page_number }}">Next</a>
{% endif %}
</span>
image enter image description here
Help please