update actions to fix build warning

This commit is contained in:
2022-04-26 16:59:22 +01:00
parent 19be69389e
commit bc200eb421
2 changed files with 69 additions and 0 deletions
+33
View File
@@ -904,3 +904,36 @@ export const createAccount = (formValues) => {
console.log("this serror", error);
});
};
export const uploadFiles = (formValues) => {
var data = formValues;
var queryUrl = "/api/uploads";
var config = {
method: "post",
url: queryUrl,
data: data,
};
// const config = {
// method: "post",
// url: queryUrl,
// data: data,
// headers: { "content-type": "multipart/form-data" },
// onUploadProgress: (event) => {
// console.log(
// `Current progress:`,
// Math.round((event.loaded * 100) / event.total)
// );
// },
// };
console.log(config);
return axios(config)
.then((res) => {
// console.log("posted ", res.data);
return res.data;
})
.catch((error) => {
console.log("this serror", error);
});
};