diff options
Diffstat (limited to 'pkg/handler/git/handler.go')
-rw-r--r-- | pkg/handler/git/handler.go | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/pkg/handler/git/handler.go b/pkg/handler/git/handler.go index 6225b1a..436d364 100644 --- a/pkg/handler/git/handler.go +++ b/pkg/handler/git/handler.go @@ -130,7 +130,7 @@ func (g *GitHandler) Summary(w http.ResponseWriter, r *http.Request) error { return err } - commits, err := g.gitService.ListCommits(name, "", 10) + commits, _, err := g.gitService.ListCommits(name, "", "", 10) if err != nil { return err } @@ -324,8 +324,9 @@ func (g *GitHandler) Log(w http.ResponseWriter, r *http.Request) error { ext.SetHTML(w) name := r.PathValue("name") ref := r.PathValue("ref") + from := r.URL.Query().Get("from") - commits, err := g.gitService.ListCommits(name, ref, 1000) + commits, next, err := g.gitService.ListCommits(name, ref, from, 100) if err != nil { return err } @@ -335,6 +336,7 @@ func (g *GitHandler) Log(w http.ResponseWriter, r *http.Request) error { Ref: ref, GitItemBase: &templates.GitItemLogPage{ Commits: commits, + Next: next, }, } templates.WritePageTemplate(w, gitList, r.Context()) |