mirror of
https://github.com/ascribe/onion.git
synced 2024-11-15 01:25:17 +01:00
otherdata POST and fineuploader_session OK
This commit is contained in:
parent
dbbf9fd233
commit
c6bc34c2f7
@ -25,7 +25,8 @@ var ReactS3FineUploader = React.createClass({
|
||||
bitcoinId: React.PropTypes.string
|
||||
}),
|
||||
createBlobRoutine: React.PropTypes.shape({
|
||||
url: React.PropTypes.string
|
||||
url: React.PropTypes.string,
|
||||
bitcoinId: React.PropTypes.string
|
||||
}),
|
||||
submitKey: React.PropTypes.func,
|
||||
autoUpload: React.PropTypes.bool,
|
||||
@ -264,7 +265,8 @@ var ReactS3FineUploader = React.createClass({
|
||||
credentials: 'include',
|
||||
body: JSON.stringify({
|
||||
'filename': file.name,
|
||||
'key': file.key
|
||||
'key': file.key,
|
||||
'bitcoin_id': this.props.createBlobRoutine.bitcoinId
|
||||
})
|
||||
})
|
||||
.then((res) => {
|
||||
|
@ -520,7 +520,8 @@ let FileUploader = React.createClass({
|
||||
bitcoinId: this.props.edition.bitcoin_id
|
||||
}}
|
||||
createBlobRoutine={{
|
||||
url: apiUrls.blob_otherdatas
|
||||
url: apiUrls.blob_otherdatas,
|
||||
bitcoinId: this.props.edition.bitcoin_id
|
||||
}}
|
||||
validation={{
|
||||
itemLimit: 100000,
|
||||
@ -532,7 +533,10 @@ let FileUploader = React.createClass({
|
||||
session={{
|
||||
endpoint: AppConstants.serverUrl + 'api/blob/otherdatas/fineuploader_session/',
|
||||
customHeaders: {
|
||||
'X-CSRFToken': getCookie('csrftoken')
|
||||
'X-CSRFToken': getCookie('csrftoken')
|
||||
},
|
||||
params: {
|
||||
'pk': this.props.edition.other_data.id
|
||||
}
|
||||
}}/>
|
||||
);
|
||||
|
Loading…
Reference in New Issue
Block a user