1
0
Fork 0
mirror of https://github.com/documize/community.git synced 2025-07-24 15:49:44 +02:00

Make bulk group member management easier

Add and Remove members separated.

Introduced user list paging size.
This commit is contained in:
McMatts 2018-08-21 15:33:54 +01:00
parent bd2e8ac165
commit 1b16be2505
9 changed files with 130 additions and 93 deletions

View file

@ -694,7 +694,12 @@ func (h *Handler) MatchUsers(w http.ResponseWriter, r *http.Request) {
}
searchText := string(body)
u, err := h.Store.User.MatchUsers(ctx, searchText, 100)
limit, _ := strconv.Atoi(request.Query(r, "limit"))
if limit == 0 {
limit = 100
}
u, err := h.Store.User.MatchUsers(ctx, searchText, limit)
if err != nil {
response.WriteServerError(w, method, err)
h.Runtime.Log.Error(method, err)