feat(network.js): Methode zum Abrufen von Anmerkungsparametern hinzugefügt
This commit is contained in:
@@ -69,7 +69,7 @@
|
||||
* Creates a GET HTTP request to `url`
|
||||
* @param {any} url
|
||||
*/
|
||||
getRequest(url, body) {
|
||||
getRequest(url) {
|
||||
const token = this.getCSRFToken()
|
||||
const options = {
|
||||
credentials: 'include',
|
||||
@@ -79,10 +79,6 @@
|
||||
}
|
||||
}
|
||||
|
||||
if (body !== undefined) {
|
||||
options.body = JSON.stringify(body);
|
||||
}
|
||||
|
||||
return fetch(url, options)
|
||||
}
|
||||
|
||||
@@ -206,4 +202,12 @@ async function logout() {
|
||||
if (res.ok)
|
||||
window.location.href = "/";
|
||||
});
|
||||
}
|
||||
|
||||
async function getAnnotationParams() {
|
||||
return fetch(`${window.location.origin}/api/Config/Annotations`, {
|
||||
credentials: 'include',
|
||||
method: 'GET'
|
||||
})
|
||||
.then(res => res.json());
|
||||
}
|
||||
Reference in New Issue
Block a user