summaryrefslogtreecommitdiffstats
path: root/webapp
diff options
context:
space:
mode:
Diffstat (limited to 'webapp')
-rw-r--r--webapp/components/admin_console/users_and_teams_settings.jsx22
-rw-r--r--webapp/i18n/en.json3
-rw-r--r--webapp/utils/constants.jsx1
3 files changed, 25 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
diff --git a/webapp/i18n/en.json b/webapp/i18n/en.json
index a8d2e88e0..d0df67e68 100644
--- a/webapp/i18n/en.json
+++ b/webapp/i18n/en.json
@@ -807,6 +807,9 @@
"admin.team.maxChannelsDescription": "Maximum total number of channels per team, including both active and deleted channels.",
"admin.team.maxChannelsExample": "Ex \"100\"",
"admin.team.maxChannelsTitle": "Max Channels Per Team:",
+ "admin.team.maxNotificationsPerChannelTitle" : "Max Notifications Per Channel:",
+ "admin.team.maxNotificationsPerChannelExample" : "Ex \"1000\"",
+ "admin.team.maxNotificationsPerChannelDescription" : "Maximum total number of users in a channel before users typing messages, @all, @here, and @channel no longer send notifications because of performance.",
"admin.team.maxUsersDescription": "Maximum total number of users per team, including both active and inactive users.",
"admin.team.maxUsersExample": "E.g.: \"25\"",
"admin.team.maxUsersTitle": "Max Users Per Team:",
diff --git a/webapp/utils/constants.jsx b/webapp/utils/constants.jsx
index 4fbf807f9..b3cafe254 100644
--- a/webapp/utils/constants.jsx
+++ b/webapp/utils/constants.jsx
@@ -821,6 +821,7 @@ export const Constants = {
DEFAULT_MAX_USERS_PER_TEAM: 50,
MIN_TEAMNAME_LENGTH: 2,
DEFAULT_MAX_CHANNELS_PER_TEAM: 2000,
+ DEFAULT_MAX_NOTIFICATIONS_PER_CHANNEL: 1000,
MAX_TEAMNAME_LENGTH: 15,
MIN_USERNAME_LENGTH: 3,
MAX_USERNAME_LENGTH: 22,