mirror of
https://github.com/go-gitea/gitea.git
synced 2026-09-16 01:43:24 +09:00
refactor: pagination/pager (#39162)
This commit is contained in:
@@ -117,7 +117,7 @@ func TestMilestonesForSpecificRepo(t *testing.T) {
|
||||
|
||||
func TestDashboardPagination(t *testing.T) {
|
||||
ctx, _ := contexttest.MockContext(t, "/", contexttest.MockContextOption{Render: templates.PageRenderer()})
|
||||
page := context.NewPagination(10, 3, 1, 3)
|
||||
page := context.NewPagerBuilder(ctx).TotalCount(10).PerPageLimit(3).CurPage(1).NavPageNum(3).Build()
|
||||
|
||||
setting.AppSubURL = "/SubPath"
|
||||
out, err := ctx.RenderToHTML("base/paginate", map[string]any{"Link": setting.AppSubURL, "Page": page})
|
||||
|
||||
Reference in New Issue
Block a user