aboutsummaryrefslogtreecommitdiff
path: root/templates/gititemlog.qtpl
diff options
context:
space:
mode:
authorGabriel A. Giovanini <mail@gabrielgio.me>2025-01-26 14:53:14 +0100
committerGabriel A. Giovanini <mail@gabrielgio.me>2025-01-26 14:54:52 +0100
commitcb9036aab96895ddf03cab68f75d3356f5227968 (patch)
treebc97024b0e947a0624579552955ce7c1ea47c572 /templates/gititemlog.qtpl
parentf128f0a029430cb5ab4f89733d8297666a6b2fdf (diff)
downloadcerrado-0.0.19.tar.gz
cerrado-0.0.19.tar.bz2
cerrado-0.0.19.zip
feat: Add log paginationHEADv0.0.19master
Now it is possible to navigate through all commit from a given repository. It implements a simple navigation which will plenty for now.
Diffstat (limited to 'templates/gititemlog.qtpl')
-rw-r--r--templates/gititemlog.qtpl5
1 files changed, 5 insertions, 0 deletions
diff --git a/templates/gititemlog.qtpl b/templates/gititemlog.qtpl
index e5bfc1b..b0c8cec 100644
--- a/templates/gititemlog.qtpl
+++ b/templates/gititemlog.qtpl
@@ -3,6 +3,7 @@
{% code
type GitItemLogPage struct {
Commits []*object.Commit
+ Next *object.Commit
}
%}
@@ -13,5 +14,9 @@ type GitItemLogPage struct {
{% for _, c := range g.Commits %}
{%= Commit(name, c, false) %}
{% endfor %}
+ {% if g.Next != nil %}
+ <a href="/{%s name %}/log/{%s ref %}/?from={%s g.Next.Hash.String() %}" class="btn btn-primary">Next</a>
+ {% endif %}
+
</div>
{% endfunc %}