[GH-9639] Add plugin API for SearchUsers method (#9793)
* fixes 9639 * Adding conversion.
Этот коммит содержится в:
коммит произвёл
Christopher Speller
родитель
acd2deaca3
Коммит
8cd0f284d5
@@ -316,6 +316,15 @@ func (api *PluginAPI) SearchChannels(teamId string, term string) ([]*model.Chann
|
||||
return *channels, err
|
||||
}
|
||||
|
||||
func (api *PluginAPI) SearchUsers(search *model.UserSearch) ([]*model.User, *model.AppError) {
|
||||
pluginSearchUsersOptions := &model.UserSearchOptions{
|
||||
IsAdmin: true,
|
||||
AllowInactive: search.AllowInactive,
|
||||
Limit: search.Limit,
|
||||
}
|
||||
return api.app.SearchUsers(search, pluginSearchUsersOptions)
|
||||
}
|
||||
|
||||
func (api *PluginAPI) AddChannelMember(channelId, userId string) (*model.ChannelMember, *model.AppError) {
|
||||
// For now, don't allow overriding these via the plugin API.
|
||||
userRequestorId := ""
|
||||
|
||||
Ссылка в новой задаче
Block a user