mirror of
https://github.com/ascribe/onion.git
synced 2025-01-03 18:35:09 +01:00
Hide download button on the marketplace additional data form when it's not inline
This commit is contained in:
parent
dcca228669
commit
1ee9a4c7a1
@ -22,11 +22,13 @@ let FurtherDetailsFileuploader = React.createClass({
|
|||||||
submitFile: React.PropTypes.func,
|
submitFile: React.PropTypes.func,
|
||||||
isReadyForFormSubmission: React.PropTypes.func,
|
isReadyForFormSubmission: React.PropTypes.func,
|
||||||
editable: React.PropTypes.bool,
|
editable: React.PropTypes.bool,
|
||||||
multiple: React.PropTypes.bool
|
multiple: React.PropTypes.bool,
|
||||||
|
areAssetsDownloadable: React.PropTypes.bool
|
||||||
},
|
},
|
||||||
|
|
||||||
getDefaultProps() {
|
getDefaultProps() {
|
||||||
return {
|
return {
|
||||||
|
areAssetsDownloadable: true,
|
||||||
label: getLangText('Additional files'),
|
label: getLangText('Additional files'),
|
||||||
multiple: false
|
multiple: false
|
||||||
};
|
};
|
||||||
@ -89,7 +91,7 @@ let FurtherDetailsFileuploader = React.createClass({
|
|||||||
'X-CSRFToken': getCookie(AppConstants.csrftoken)
|
'X-CSRFToken': getCookie(AppConstants.csrftoken)
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
areAssetsDownloadable={true}
|
areAssetsDownloadable={this.props.areAssetsDownloadable}
|
||||||
areAssetsEditable={this.props.editable}
|
areAssetsEditable={this.props.editable}
|
||||||
multiple={this.props.multiple} />
|
multiple={this.props.multiple} />
|
||||||
</Property>
|
</Property>
|
||||||
|
@ -173,12 +173,13 @@ let MarketAdditionalDataForm = React.createClass({
|
|||||||
disabled={!this.props.editable || !piece.acl.acl_edit}>
|
disabled={!this.props.editable || !piece.acl.acl_edit}>
|
||||||
{heading}
|
{heading}
|
||||||
<FurtherDetailsFileuploader
|
<FurtherDetailsFileuploader
|
||||||
|
pieceId={piece.id}
|
||||||
label={getLangText('Marketplace Thumbnail Image')}
|
label={getLangText('Marketplace Thumbnail Image')}
|
||||||
submitFile={function () {}}
|
submitFile={function () {}}
|
||||||
setIsUploadReady={this.setIsUploadReady}
|
setIsUploadReady={this.setIsUploadReady}
|
||||||
isReadyForFormSubmission={formSubmissionValidation.atLeastOneUploadedFile}
|
isReadyForFormSubmission={formSubmissionValidation.atLeastOneUploadedFile}
|
||||||
pieceId={piece.id}
|
|
||||||
otherData={piece.other_data}
|
otherData={piece.other_data}
|
||||||
|
areAssetsDownloadable={!!isInline}
|
||||||
editable={editable} />
|
editable={editable} />
|
||||||
<Property
|
<Property
|
||||||
name='artist_bio'
|
name='artist_bio'
|
||||||
|
Loading…
Reference in New Issue
Block a user