Add Groups
This commit is contained in:
@ -35,12 +35,20 @@ const LoginBar = React.createClass({
|
||||
e.preventDefault();
|
||||
this.props.onCreateNewUser();
|
||||
},
|
||||
handleNewGroupSubmit: function(e) {
|
||||
e.preventDefault();
|
||||
this.props.onCreateNewGroup();
|
||||
},
|
||||
render: function() {
|
||||
return (
|
||||
<form onSubmit={this.handleSubmit}>
|
||||
<FormGroup>
|
||||
<Row>
|
||||
<Col xs={4}></Col>
|
||||
<Col xs={2}></Col>
|
||||
<Col xs={2}>
|
||||
<Button bsStyle="link"
|
||||
onClick={this.handleNewGroupSubmit}>New Group</Button>
|
||||
</Col>
|
||||
<Col xs={2}>
|
||||
<Button bsStyle="link"
|
||||
onClick={this.handleNewUserSubmit}>New User</Button>
|
||||
@ -102,7 +110,7 @@ module.exports = React.createClass({
|
||||
var barContents;
|
||||
var errorAlert;
|
||||
if (!this.props.user.isUser())
|
||||
barContents = <LoginBar onLogin={this.props.onLogin} onCreateNewUser={this.props.onCreateNewUser} />;
|
||||
barContents = <LoginBar onLogin={this.props.onLogin} onCreateNewUser={this.props.onCreateNewUser} onCreateNewGroup={this.props.onCreateNewGroup} />;
|
||||
else
|
||||
barContents = <LogoutBar user={this.props.user} onLogout={this.props.onLogout} onAccountSettings={this.props.onAccountSettings}/>;
|
||||
if (this.props.error.isError())
|
||||
|
Reference in New Issue
Block a user