MM-23015: Enable or disable group mentions (#14010)

* MM-23015: Enable or disable group mentions + show them in suggestion list


Co-authored-by: Catalin Tomai <catalin.tomai@mattermost.com>
Этот коммит содержится в:
catalintomai
2020-04-13 11:37:29 -07:00
коммит произвёл GitHub
родитель 0bfb063c78
Коммит b90f4f46e2
15 изменённых файлов: 777 добавлений и 102 удалений

Просмотреть файл

@@ -196,6 +196,15 @@ func (a *App) GetGroupsByTeam(teamId string, opts model.GroupSearchOpts) ([]*mod
return groups, int(count), nil
}
func (a *App) GetGroupsAssociatedToChannelsByTeam(teamId string, opts model.GroupSearchOpts) (map[string][]*model.GroupWithSchemeAdmin, *model.AppError) {
groupsAssociatedByChannelId, err := a.Srv().Store.Group().GetGroupsAssociatedToChannelsByTeam(teamId, opts)
if err != nil {
return nil, err
}
return groupsAssociatedByChannelId, nil
}
func (a *App) GetGroups(page, perPage int, opts model.GroupSearchOpts) ([]*model.Group, *model.AppError) {
return a.Srv().Store.Group().GetGroups(page, perPage, opts)
}