enabled team creation for sysadmins (#3433)

Этот коммит содержится в:
David Lu
2016-06-30 08:43:46 -04:00
коммит произвёл Joram Wilander
родитель 65e18ad1f5
Коммит 1c8962cf99
5 изменённых файлов: 19 добавлений и 5 удалений

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

@@ -86,7 +86,7 @@ export default class UsersAndTeamsSettings extends AdminSettings {
helpText={
<FormattedMessage
id='admin.team.teamCreationDescription'
defaultMessage='When false, the ability to create teams is disabled. The create team button displays error when pressed.'
defaultMessage='When false, only System Administrators can create teams.'
/>
}
value={this.state.enableTeamCreation}

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

@@ -152,6 +152,16 @@ export default class SelectTeam extends React.Component {
var isSystemAdmin = Utils.isSystemAdmin(UserStore.getCurrentUser().roles);
let teamHelp = null;
if (isSystemAdmin && (global.window.mm_config.EnableTeamCreation === 'false')) {
teamHelp = (
<FormattedMessage
id='login.createTeamAdminOnly'
defaultMessage='This option is only available for System Administrators, and does not show up for other users.'
/>
);
}
let teamSignUp;
if (isSystemAdmin || (global.window.mm_config.EnableTeamCreation === 'true' && !Utils.isMobileApp())) {
teamSignUp = (
@@ -165,6 +175,9 @@ export default class SelectTeam extends React.Component {
defaultMessage='Create a new team'
/>
</Link>
<div>
{teamHelp}
</div>
</div>
);
}

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

@@ -574,7 +574,7 @@
"admin.team.siteNameDescription": "Name of service shown in login screens and UI.",
"admin.team.siteNameExample": "Ex \"Mattermost\"",
"admin.team.siteNameTitle": "Site Name:",
"admin.team.teamCreationDescription": "When false, the ability to create teams is disabled. The create team button displays error when pressed.",
"admin.team.teamCreationDescription": "When false, only System Administrators can create teams.",
"admin.team.teamCreationTitle": "Enable Team Creation: ",
"admin.team.upload": "Upload",
"admin.team.uploadDesc": "Customize your user experience by adding a custom image to your login screen. See examples at <a href='http://docs.mattermost.com/administration/config-settings.html#custom-branding' target='_blank'>docs.mattermost.com/administration/config-settings.html#custom-branding</a>.",
@@ -1028,6 +1028,7 @@
"login.changed": " Sign-in method changed successfully",
"login.create": "Create one now",
"login.createTeam": "Create a new team",
"login.createTeamAdminOnly": "This option is only available for System Administrators, and does not show up for other users.",
"login.email": "Email",
"login.find": "Find your other teams",
"login.forgot": "I forgot my password",