2020-11-19 19:39:22 +01:00
|
|
|
import API from "./api"
|
2020-11-12 13:24:45 +01:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Uploads an attachment to the server.
|
|
|
|
*/
|
2021-05-04 12:32:22 +02:00
|
|
|
export const uploadAttachment = async data => {
|
2020-11-19 19:39:22 +01:00
|
|
|
return await API.post({
|
2020-11-12 13:24:45 +01:00
|
|
|
url: "/api/attachments/upload",
|
|
|
|
body: data,
|
|
|
|
json: false,
|
|
|
|
})
|
|
|
|
}
|