summaryrefslogtreecommitdiffstats
path: root/web/react/components/team_signup_choose_auth.jsx
diff options
context:
space:
mode:
author=Corey Hulen <corey@hulen.com>2015-09-21 15:11:56 -0700
committer=Corey Hulen <corey@hulen.com>2015-09-21 15:11:56 -0700
commited9a2da83b3b77e7dd0314eaa92082ac8a2a9a9c (patch)
tree3c890327d884b33ad149196ddf9879313b2b000b /web/react/components/team_signup_choose_auth.jsx
parentee5a77ec56ee13f5eb96fce6065b4b7a1845de89 (diff)
downloadchat-ed9a2da83b3b77e7dd0314eaa92082ac8a2a9a9c.tar.gz
chat-ed9a2da83b3b77e7dd0314eaa92082ac8a2a9a9c.tar.bz2
chat-ed9a2da83b3b77e7dd0314eaa92082ac8a2a9a9c.zip
Adding email to admin console
Diffstat (limited to 'web/react/components/team_signup_choose_auth.jsx')
-rw-r--r--web/react/components/team_signup_choose_auth.jsx20
1 files changed, 7 insertions, 13 deletions
diff --git a/web/react/components/team_signup_choose_auth.jsx b/web/react/components/team_signup_choose_auth.jsx
index d3107c5c7..cfd45edb3 100644
--- a/web/react/components/team_signup_choose_auth.jsx
+++ b/web/react/components/team_signup_choose_auth.jsx
@@ -1,8 +1,6 @@
// Copyright (c) 2015 Spinpunch, Inc. All Rights Reserved.
// See License.txt for license information.
-var Constants = require('../utils/constants.jsx');
-
export default class ChooseAuthPage extends React.Component {
constructor(props) {
super(props);
@@ -10,7 +8,7 @@ export default class ChooseAuthPage extends React.Component {
}
render() {
var buttons = [];
- if (this.props.services.indexOf(Constants.GITLAB_SERVICE) !== -1) {
+ if (global.window.config.AllowSignUpWithGitLab) {
buttons.push(
<a
className='btn btn-custom-login gitlab btn-full'
@@ -18,17 +16,17 @@ export default class ChooseAuthPage extends React.Component {
onClick={
function clickGit(e) {
e.preventDefault();
- this.props.updatePage('service', Constants.GITLAB_SERVICE);
+ this.props.updatePage('gitlab');
}.bind(this)
}
>
<span className='icon' />
- <span>Create new team with GitLab Account</span>
+ <span>{'Create new team with GitLab Account'}</span>
</a>
);
}
- if (this.props.services.indexOf(Constants.EMAIL_SERVICE) !== -1) {
+ if (global.window.config.AllowSignUpWithEmail) {
buttons.push(
<a
className='btn btn-custom-login email btn-full'
@@ -36,18 +34,18 @@ export default class ChooseAuthPage extends React.Component {
onClick={
function clickEmail(e) {
e.preventDefault();
- this.props.updatePage('email', '');
+ this.props.updatePage('email');
}.bind(this)
}
>
<span className='fa fa-envelope' />
- <span>Create new team with email address</span>
+ <span>{'Create new team with email address'}</span>
</a>
);
}
if (buttons.length === 0) {
- buttons = <span>No sign-up methods configured, please contact your system administrator.</span>;
+ buttons = <span>{'No sign-up methods configured, please contact your system administrator.'}</span>;
}
return (
@@ -61,10 +59,6 @@ export default class ChooseAuthPage extends React.Component {
}
}
-ChooseAuthPage.defaultProps = {
- services: []
-};
ChooseAuthPage.propTypes = {
- services: React.PropTypes.array,
updatePage: React.PropTypes.func
};