moved getFile() and no download when managing

This commit is contained in:
2024-04-18 16:47:25 +02:00
parent 7394a23b45
commit 14c5423328
5 changed files with 43 additions and 8 deletions

View File

@ -21,4 +21,13 @@ export async function uploadBibTex(file){
export async function postResearch(data){
return restPost("/research", data)
}
}
export async function fetchResearches(){
return restGet("/researches")
}
export async function getFile(url){
const restURL = import.meta.env.VITE_CLYDE_MODE === 'container' ? "http://localhost:8000": import.meta.env.DEV ? "http://localhost:5173" : "https://clyde.herisson.ovh/api"
await fetch(restURL + "/"+url, {method: "GET"})
}