diff options
author | Christopher Speller <crspeller@gmail.com> | 2016-02-08 07:26:10 -0500 |
---|---|---|
committer | Christopher Speller <crspeller@gmail.com> | 2016-03-14 00:38:25 -0400 |
commit | d7cdcf082fab6c0cb7c2fe4bed821bd1a8000e69 (patch) | |
tree | 49a0de30cdc2ac461e72a242ae9a5593fcd6c8b9 /web/react/components/signup_team_complete.jsx | |
parent | 08f0800adef926e8b69ebea70e4995b89f5c3f3c (diff) | |
download | chat-d7cdcf082fab6c0cb7c2fe4bed821bd1a8000e69.tar.gz chat-d7cdcf082fab6c0cb7c2fe4bed821bd1a8000e69.tar.bz2 chat-d7cdcf082fab6c0cb7c2fe4bed821bd1a8000e69.zip |
Convering client to react-router.
Diffstat (limited to 'web/react/components/signup_team_complete.jsx')
-rw-r--r-- | web/react/components/signup_team_complete.jsx | 121 |
1 files changed, 0 insertions, 121 deletions
diff --git a/web/react/components/signup_team_complete.jsx b/web/react/components/signup_team_complete.jsx deleted file mode 100644 index 16553daeb..000000000 --- a/web/react/components/signup_team_complete.jsx +++ /dev/null @@ -1,121 +0,0 @@ -// Copyright (c) 2015 Mattermost, Inc. All Rights Reserved. -// See License.txt for license information. - -import WelcomePage from './team_signup_welcome_page.jsx'; -import TeamDisplayNamePage from './team_signup_display_name_page.jsx'; -import TeamURLPage from './team_signup_url_page.jsx'; -import SendInivtesPage from './team_signup_send_invites_page.jsx'; -import UsernamePage from './team_signup_username_page.jsx'; -import PasswordPage from './team_signup_password_page.jsx'; -import BrowserStore from '../stores/browser_store.jsx'; - -import {FormattedMessage} from 'mm-intl'; - -export default class SignupTeamComplete extends React.Component { - constructor(props) { - super(props); - - this.updateParent = this.updateParent.bind(this); - - var initialState = BrowserStore.getGlobalItem(props.hash); - - if (!initialState) { - initialState = {}; - initialState.wizard = 'welcome'; - initialState.team = {}; - initialState.team.email = this.props.email; - initialState.team.allowed_domains = ''; - initialState.invites = []; - initialState.invites.push(''); - initialState.invites.push(''); - initialState.invites.push(''); - initialState.user = {}; - initialState.hash = this.props.hash; - initialState.data = this.props.data; - } - - this.state = initialState; - } - updateParent(state, skipSet) { - BrowserStore.setGlobalItem(this.props.hash, state); - - if (!skipSet) { - this.setState(state); - } - } - render() { - if (this.state.wizard === 'welcome') { - return ( - <WelcomePage - state={this.state} - updateParent={this.updateParent} - /> - ); - } - - if (this.state.wizard === 'team_display_name') { - return ( - <TeamDisplayNamePage - state={this.state} - updateParent={this.updateParent} - /> - ); - } - - if (this.state.wizard === 'team_url') { - return ( - <TeamURLPage - state={this.state} - updateParent={this.updateParent} - /> - ); - } - - if (this.state.wizard === 'send_invites') { - return ( - <SendInivtesPage - state={this.state} - updateParent={this.updateParent} - /> - ); - } - - if (this.state.wizard === 'username') { - return ( - <UsernamePage - state={this.state} - updateParent={this.updateParent} - /> - ); - } - - if (this.state.wizard === 'password') { - return ( - <PasswordPage - state={this.state} - updateParent={this.updateParent} - /> - ); - } - - return ( - <div> - <FormattedMessage - id='signup_team_complete.completed' - defaultMessage="You've already completed the signup process for this invitation or this invitation has expired." - /> - </div> - ); - } -} - -SignupTeamComplete.defaultProps = { - hash: '', - email: '', - data: '' -}; -SignupTeamComplete.propTypes = { - hash: React.PropTypes.string, - email: React.PropTypes.string, - data: React.PropTypes.string -}; |