Skip to content

Commit 6476a7b

Browse files
fix pagination in admin dashboard
1 parent 7a44d4a commit 6476a7b

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

routers/web/admin/ips.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,9 @@ func IPs(ctx *context.Context) {
9696
ctx.Data["Keyword"] = keyword
9797

9898
// Setup pagination
99-
ctx.Data["Page"] = context.NewPagination(int(count), setting.UI.Admin.UserPagingNum, page, 5)
99+
pager := context.NewPagination(int(count), setting.UI.Admin.UserPagingNum, page, 5)
100+
pager.AddParamFromRequest(ctx.Req)
101+
ctx.Data["Page"] = pager
100102

101103
ctx.HTML(http.StatusOK, tplIPs)
102104
}

0 commit comments

Comments
 (0)