Implemented User Badge Management Interface (#29798)

Co-authored-by: Diogo Vicente <diogo.m.s.vicente@tecnico.ulisboa.pt>
This commit is contained in:
Henrique Pimentel
2024-06-19 13:53:18 +01:00
committed by Henrique Pimentel
co-authored by Diogo Vicente
parent 8b86c3140a
commit f68e44daed
9 changed files with 156 additions and 18 deletions
+2 -3
View File
@@ -56,9 +56,8 @@ func RenderBadgeSearch(ctx *context.Context, opts *user_model.SearchBadgeOptions
orderBy = "`badge`.slug ASC"
default:
// in case the sortType is not valid, we set it to recent update
sortOrder = "alphabetically"
ctx.Data["SortType"] = "alphabetically"
orderBy = "`badge`.slug ASC"
ctx.Data["SortType"] = "oldest"
orderBy = "`badge`.id ASC"
}
opts.Keyword = ctx.FormTrim("q")