aboutsummaryrefslogtreecommitdiff
path: root/backend/templates
diff options
context:
space:
mode:
authorAnhgelus Morhtuuzh <william@herges.fr>2025-10-02 22:54:46 +0200
committerAnhgelus Morhtuuzh <william@herges.fr>2025-10-02 22:54:46 +0200
commit0bcfe1f7df5c309f8a4ab381a6fd5b772d929542 (patch)
tree398c348d37c1f0e8d48c58b7bc7abb34fa3b1763 /backend/templates
parent6044dd841c81f0f4d206c6c8800b0fd30320cf13 (diff)
feat(backend): working pagination
Diffstat (limited to 'backend/templates')
-rw-r--r--backend/templates/home.html8
1 files changed, 5 insertions, 3 deletions
diff --git a/backend/templates/home.html b/backend/templates/home.html
index f0b9b9c..37236ba 100644
--- a/backend/templates/home.html
+++ b/backend/templates/home.html
@@ -18,10 +18,12 @@
</p>
</article>
{{ end }}
+ {{ if ne .PagesNumber 1 }}
<div class="pagination">
- <a href="">Précédent</a>
- <p>01/15</p>
- <a href="">Suivant</a>
+ {{ if ne .CurrentPage 1 }}<a href="?page={{ before .CurrentPage }}">Précédent</a>{{else}}<p></p>{{end}}
+ <p>{{ .CurrentPage }}/{{ .PagesNumber }}</p>
+ {{ if ne .CurrentPage .PagesNumber }}<a href="?page={{ next .CurrentPage }}">Suivant</a>{{else}}<p></p>{{end}}
</div>
+ {{ end }}
</article>
{{end}} \ No newline at end of file