diff options
author | Otto Richter (fnetX) <git@fralix.ovh> | 2022-03-02 19:57:18 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-03-02 19:57:18 +0100 |
commit | 578f19a68242e90f539604d09a6329d253882c96 (patch) | |
tree | 2b8f4e645037b57ff78cdae7658bd96c1a4d3abf /modules | |
parent | f9b64049505c36f463fabf0e822a5306be5abc15 (diff) | |
download | gitea-578f19a68242e90f539604d09a6329d253882c96.tar.gz gitea-578f19a68242e90f539604d09a6329d253882c96.zip |
Refactor admin user filter query parameters (#18965) (#18975)
Only pass `status_filter` on admin page
Use a more general method to pass query parameters, remove hard-coded keys
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
Diffstat (limited to 'modules')
-rw-r--r-- | modules/context/pagination.go | 9 |
1 files changed, 0 insertions, 9 deletions
diff --git a/modules/context/pagination.go b/modules/context/pagination.go index 140b676786..107cbf6186 100644 --- a/modules/context/pagination.go +++ b/modules/context/pagination.go @@ -55,12 +55,3 @@ func (p *Pagination) SetDefaultParams(ctx *Context) { p.AddParam(ctx, "tab", "TabName") p.AddParam(ctx, "t", "queryType") } - -// SetUserFilterParams sets common pagination params for user filtering, e.g. the admin userlist -func (p *Pagination) SetUserFilterParams(ctx *Context) { - p.AddParamString("status_filter[is_active]", ctx.FormString("status_filter[is_active]")) - p.AddParamString("status_filter[is_admin]", ctx.FormString("status_filter[is_admin]")) - p.AddParamString("status_filter[is_restricted]", ctx.FormString("status_filter[is_restricted]")) - p.AddParamString("status_filter[is_2fa_enabled]", ctx.FormString("status_filter[is_2fa_enabled]")) - p.AddParamString("status_filter[is_prohibit_login]", ctx.FormString("status_filter[is_prohibit_login]")) -} |