Reset team edit form on clicking edit button

This commit is contained in:
Yuya Ochiai 2016-07-04 00:12:58 +09:00
parent 19134b08b0
commit 17949d34ae

View file

@ -302,7 +302,8 @@ var TeamList = React.createClass({
var addTeamForm;
if (this.props.showAddTeamForm || this.state.showTeamListItemNew) {
addTeamForm = <TeamListItemNew onTeamAdd={ this.handleTeamAdd } teamIndex={ this.state.team.index } teamName={ this.state.team.name } teamUrl={ this.state.team.url } />;
addTeamForm = <TeamListItemNew key={ this.state.team.index } onTeamAdd={ this.handleTeamAdd } teamIndex={ this.state.team.index } teamName={ this.state.team.name } teamUrl={ this.state.team.url }
/>;
} else {
addTeamForm = '';
}