add blocked filter in users list to filter banned users

fixes #2914
This commit is contained in:
Rigel Kent 2020-07-02 22:49:51 +02:00
parent 2b587cad93
commit 8491293b02
No known key found for this signature in database
GPG key ID: 5E53E96A494E452F
11 changed files with 213 additions and 32 deletions

View file

@ -518,10 +518,13 @@ paths:
get:
summary: List users
security:
- OAuth2: []
- OAuth2:
- admin
tags:
- Users
parameters:
- $ref: '#/components/parameters/usersSearch'
- $ref: '#/components/parameters/usersBlocked'
- $ref: '#/components/parameters/start'
- $ref: '#/components/parameters/count'
- $ref: '#/components/parameters/usersSort'
@ -3148,6 +3151,13 @@ components:
schema:
type: string
example: -createdAt
search:
name: search
in: query
required: false
description: Plain text search, applied to various parts of the model depending on endpoint
schema:
type: string
searchTarget:
name: searchTarget
in: query
@ -3224,6 +3234,20 @@ components:
- -dislikes
- -uuid
- -createdAt
usersSearch:
name: search
in: query
required: false
description: Plain text search that will match with user usernames or emails
schema:
type: string
usersBlocked:
name: blocked
in: query
required: false
description: Filter results down to (un)banned users
schema:
type: boolean
usersSort:
name: sort
in: query