1
0
mirror of https://github.com/ascribe/onion.git synced 2024-06-30 13:41:57 +02:00

reset cyland register form

"no votes yet" for judge
This commit is contained in:
diminator 2015-08-25 11:11:22 +02:00
parent 2d10887e1b
commit a07b4cc35c
2 changed files with 7 additions and 9 deletions

View File

@ -94,6 +94,13 @@ let AccordionListItemPrize = React.createClass({
</div>); </div>);
} }
else { else {
if (this.state.currentUser.is_judge){
return (
<div className="react-rating-caption pull-right">
No votes yet
</div>
);
}
// jury and no rating yet // jury and no rating yet
return ( return (
<div className="react-rating-caption pull-right"> <div className="react-rating-caption pull-right">

View File

@ -77,15 +77,6 @@ let CylandRegisterPiece = React.createClass({
} }
}, },
// This is done to update the container when the user clicks on the prev or next
// button to update the URL parameter (and therefore to switch pieces)
componentWillReceiveProps(nextProps) {
if(this.props.params.pieceId !== nextProps.params.pieceId) {
PieceActions.updatePiece({});
PieceActions.fetchOne(nextProps.params.pieceId);
}
},
componentWillUnmount() { componentWillUnmount() {
PieceListStore.unlisten(this.onChange); PieceListStore.unlisten(this.onChange);
UserStore.unlisten(this.onChange); UserStore.unlisten(this.onChange);