|
|
|
@@ -374,16 +374,26 @@ export default { |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
async function uploadMinioNewMethod(url,e){ |
|
|
|
console.log(_this.uploadtype,url,e) |
|
|
|
async function uploadMinioNewMethod(url,e){ |
|
|
|
|
|
|
|
var xhr = new XMLHttpRequest(); |
|
|
|
xhr.open('PUT', url, false); |
|
|
|
xhr.setRequestHeader('Content-Type', 'text/plain') |
|
|
|
xhr.send(e.target.result); |
|
|
|
xhr.open('PUT', url, false); |
|
|
|
if(_this.uploadtype===0){ |
|
|
|
xhr.setRequestHeader('Content-Type', 'text/plain') |
|
|
|
xhr.send(e.target.result); |
|
|
|
|
|
|
|
var etagValue = xhr.getResponseHeader('etag'); |
|
|
|
etags[currentChunk] = etagValue; |
|
|
|
} |
|
|
|
else if(_this.uploadtype===1){ |
|
|
|
xhr.setRequestHeader('Content-Type', '') |
|
|
|
xhr.send(e.target.result); |
|
|
|
var etagValue = xhr.getResponseHeader('ETag'); |
|
|
|
//console.log(etagValue); |
|
|
|
etags[currentChunk] = etagValue; |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|