Auth: added

This commit is contained in:
2023-12-31 17:16:15 +01:00
parent 5c769bfa2f
commit dabd5ea0f0
17 changed files with 771 additions and 75 deletions

View File

@@ -20,7 +20,10 @@ export default {
},
async fetchData() {
try {
const response = await fetch(this.api_url + '/task/get')
const response = await fetch(this.api_url + '/task/get', {
credentials: 'include'
})
if (!response.ok) {
throw new Error(`HTTP error! Status: ${response.status}`)
}
@@ -36,6 +39,7 @@ export default {
try {
const response = await fetch(this.api_url + url, {
method: 'POST',
credentials: 'include',
headers: {
'Content-Type': 'application/json'
},