1
0
mirror of https://github.com/ascribe/onion.git synced 2024-12-23 01:39:36 +01:00

subdomain-dependent localhashing

This commit is contained in:
diminator 2015-07-29 15:22:30 +02:00
parent f4ccd417fc
commit f5732661bd
2 changed files with 5 additions and 2 deletions

View File

@ -25,6 +25,7 @@ let RegisterPieceForm = React.createClass({
submitMessage: React.PropTypes.string, submitMessage: React.PropTypes.string,
handleSuccess: React.PropTypes.func, handleSuccess: React.PropTypes.func,
isFineUploaderActive: React.PropTypes.bool, isFineUploaderActive: React.PropTypes.bool,
enableLocalHashing: React.PropTypes.bool,
children: React.PropTypes.element, children: React.PropTypes.element,
onLoggedOut: React.PropTypes.func onLoggedOut: React.PropTypes.func
}, },
@ -32,7 +33,8 @@ let RegisterPieceForm = React.createClass({
getDefaultProps() { getDefaultProps() {
return { return {
headerMessage: getLangText('Register your work'), headerMessage: getLangText('Register your work'),
submitMessage: getLangText('Register work') submitMessage: getLangText('Register work'),
enableLocalHashing: true
}; };
}, },
@ -89,7 +91,7 @@ let RegisterPieceForm = React.createClass({
render() { render() {
let currentUser = this.state.currentUser; let currentUser = this.state.currentUser;
let enableLocalHashing = currentUser && currentUser.profile ? currentUser.profile.hash_locally : false; let enableLocalHashing = currentUser && currentUser.profile ? currentUser.profile.hash_locally : false;
enableLocalHashing = enableLocalHashing && this.props.enableLocalHashing;
return ( return (
<Form <Form
className="ascribe-form-bordered" className="ascribe-form-bordered"

View File

@ -13,6 +13,7 @@ let PrizeRegisterPiece = React.createClass({
render() { render() {
return ( return (
<RegisterPiece <RegisterPiece
enableLocalHashing={false}
headerMessage={getLangText('Submit to the prize')} headerMessage={getLangText('Submit to the prize')}
submitMessage={getLangText('Submit')}> submitMessage={getLangText('Submit')}>
<Property <Property