Testing s3 server on Heroku
This commit is contained in:
@@ -71,17 +71,15 @@ function JobsDetailPage({ match, loading, data }) {
|
||||
// Split the filename to get the name and type
|
||||
let fileName = ev.file.name;
|
||||
let fileType = ev.file.type;
|
||||
console.log("Preparing the upload");
|
||||
console.log("Preparing the upload ");
|
||||
|
||||
axios
|
||||
.post("https://localhost:5000/sign_s3", {
|
||||
fileName: fileName,
|
||||
fileType: fileType
|
||||
})
|
||||
.post("http://localhost:5000/sign_s3")
|
||||
.then(response => {
|
||||
var returnData = response.data.data.returnData;
|
||||
var signedRequest = returnData.signedRequest;
|
||||
var url = returnData.url;
|
||||
this.setState({ url: url });
|
||||
setState({ url: url });
|
||||
console.log("Recieved a signed request " + signedRequest);
|
||||
|
||||
// Put the fileType in the headers for the upload
|
||||
|
||||
Reference in New Issue
Block a user