(file,relative_path,callback)
| 8 | } |
| 9 | |
| 10 | export const UploadFile = (file,relative_path,callback) => { |
| 11 | const formData = new FormData(); |
| 12 | formData.append("file", file); |
| 13 | axios.post(UrlBase + `/file/?path=${relative_path}`, formData).then((response) => { |
| 14 | callback(response); |
| 15 | }); |
| 16 | } |
| 17 | |
| 18 | export const DeleteFile = (relative_path,callback) => { |
| 19 | axios.delete(UrlBase + `/file/?path=${relative_path}`).then((response) => { |