diff options
author | Corey Hulen <corey@hulen.com> | 2016-11-24 05:26:45 -0800 |
---|---|---|
committer | Harrison Healey <harrisonmhealey@gmail.com> | 2016-11-24 08:26:45 -0500 |
commit | b212acf312ad640455fa715427ac19e6930dc61d (patch) | |
tree | 8fb977e00bef33587c3199ad3617417b27fb6b8a /webapp/components/admin_console/users_and_teams_settings.jsx | |
parent | 0f07a2d288bada5e08cd9a63047ee85ef60738f5 (diff) | |
download | chat-b212acf312ad640455fa715427ac19e6930dc61d.tar.gz chat-b212acf312ad640455fa715427ac19e6930dc61d.tar.bz2 chat-b212acf312ad640455fa715427ac19e6930dc61d.zip |
PLT-4429 disabling at_all at_channel metions mentions when channel has more than 1k users (#4627)
* PLT-4429 disabling explicit mentions when channel has more than 1k users
* Fixing test case
* Adding setting to the admin console
* Fixing bad translation
Diffstat (limited to 'webapp/components/admin_console/users_and_teams_settings.jsx')
-rw-r--r-- | webapp/components/admin_console/users_and_teams_settings.jsx | 22 |
1 files changed, 21 insertions, 1 deletions
diff --git a/webapp/components/admin_console/users_and_teams_settings.jsx b/webapp/components/admin_console/users_and_teams_settings.jsx index dd19005c8..2cb5b4e51 100644 --- a/webapp/components/admin_console/users_and_teams_settings.jsx +++ b/webapp/components/admin_console/users_and_teams_settings.jsx @@ -32,6 +32,7 @@ export default class UsersAndTeamsSettings extends AdminSettings { config.TeamSettings.RestrictCreationToDomains = this.state.restrictCreationToDomains; config.TeamSettings.RestrictDirectMessage = this.state.restrictDirectMessage; config.TeamSettings.MaxChannelsPerTeam = this.parseIntNonZero(this.state.maxChannelsPerTeam, Constants.DEFAULT_MAX_CHANNELS_PER_TEAM); + config.TeamSettings.MaxNotificationsPerChannel = this.parseIntNonZero(this.state.maxNotificationsPerChannel, Constants.DEFAULT_MAX_NOTIFICATIONS_PER_CHANNEL); return config; } @@ -43,7 +44,8 @@ export default class UsersAndTeamsSettings extends AdminSettings { maxUsersPerTeam: config.TeamSettings.MaxUsersPerTeam, restrictCreationToDomains: config.TeamSettings.RestrictCreationToDomains, restrictDirectMessage: config.TeamSettings.RestrictDirectMessage, - maxChannelsPerTeam: config.TeamSettings.MaxChannelsPerTeam + maxChannelsPerTeam: config.TeamSettings.MaxChannelsPerTeam, + maxNotificationsPerChannel: config.TeamSettings.MaxNotificationsPerChannel }; } @@ -132,6 +134,24 @@ export default class UsersAndTeamsSettings extends AdminSettings { onChange={this.handleChange} /> <TextSetting + id='maxNotificationsPerChannel' + label={ + <FormattedMessage + id='admin.team.maxNotificationsPerChannelTitle' + defaultMessage='Max Notifications Per Channel:' + /> + } + placeholder={Utils.localizeMessage('admin.team.maxNotificationsPerChannelExample', 'Ex "1000"')} + helpText={ + <FormattedMessage + id='admin.team.maxNotificationsPerChannelDescription' + defaultMessage='Maximum total number of users in a channel before users typing messages, @all, @here, and @channel no longer send notifications because of performance.' + /> + } + value={this.state.maxNotificationsPerChannel} + onChange={this.handleChange} + /> + <TextSetting id='restrictCreationToDomains' label={ <FormattedMessage |