MCPcopy Create free account
hub / github.com/aiprodcoder/MIXAPI / GetAllUsers

Function GetAllUsers

controller/user.go:246–259  ·  view source on GitHub ↗
(c *gin.Context)

Source from the content-addressed store, hash-verified

244}
245
246func GetAllUsers(c *gin.Context) {
247 pageInfo := common.GetPageQuery(c)
248 users, total, err := model.GetAllUsers(pageInfo)
249 if err != nil {
250 common.ApiError(c, err)
251 return
252 }
253
254 pageInfo.SetTotal(int(total))
255 pageInfo.SetItems(users)
256
257 common.ApiSuccess(c, pageInfo)
258 return
259}
260
261func SearchUsers(c *gin.Context) {
262 keyword := c.Query("keyword")

Callers

nothing calls this directly

Calls 6

GetPageQueryFunction · 0.92
GetAllUsersFunction · 0.92
ApiErrorFunction · 0.92
ApiSuccessFunction · 0.92
SetTotalMethod · 0.80
SetItemsMethod · 0.80

Tested by

no test coverage detected