mirror of
https://github.com/vale981/Vulcan
synced 2025-03-06 01:51:40 -05:00
ml/cjl: adding support for users logged in.
This commit is contained in:
parent
eef2b7e233
commit
4f6b7d78fd
2 changed files with 23 additions and 3 deletions
|
@ -1,5 +1,6 @@
|
|||
import React, { Component } from 'react';
|
||||
import { Accounts, STATES } from 'meteor/std:accounts-ui';
|
||||
import { Link } from 'react-router';
|
||||
|
||||
class UsersResetPassword extends Component {
|
||||
componentDidMount() {
|
||||
|
@ -8,13 +9,28 @@ class UsersResetPassword extends Component {
|
|||
}
|
||||
|
||||
render() {
|
||||
if (!this.context.currentUser) {
|
||||
return (
|
||||
<Accounts.ui.LoginForm
|
||||
formState={ STATES.PASSWORD_CHANGE }
|
||||
/>
|
||||
);
|
||||
}
|
||||
|
||||
return (
|
||||
<Accounts.ui.LoginForm
|
||||
formState={ STATES.PASSWORD_CHANGE }
|
||||
/>
|
||||
<div className='password-reset-form'>
|
||||
<div>{T9n.get('info.passwordChanged')}!</div>
|
||||
<Link to="/">
|
||||
Return Home
|
||||
</Link>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
module.exports = UsersResetPassword;
|
||||
export default UsersResetPassword;
|
||||
|
||||
UsersResetPassword.contextTypes = {
|
||||
currentUser: React.PropTypes.object
|
||||
};
|
||||
|
|
|
@ -30,3 +30,7 @@
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
.password-reset-form{
|
||||
text-align: center;
|
||||
}
|
Loading…
Add table
Reference in a new issue