diff --git a/build.gradle b/build.gradle index 62a8c2c..58e161e 100644 --- a/build.gradle +++ b/build.gradle @@ -35,7 +35,20 @@ dependencies { //JSON Parser implementation 'com.google.code.gson:gson:2.8.5' + + //compile 'org.springframework.boot:spring-boot-starter-tomcat' + //compile 'org.springframework.boot:spring-boot-starter-security' + //compile 'org.springframework.boot:spring-boot-starter-actuator' + //compile 'org.springframework.boot:spring-boot-starter-aop' + //ompile group: 'org.springframework.boot', name: 'spring-boot-starter-mail', version: '1.2.0.RELEASE' + compile group: 'org.springframework.security', name: 'spring-security-core', version: '5.1.4.RELEASE' + //compile group: 'at.favre.lib', name: 'bcrypt', version: '{latest-version}' + + //JWT + compile 'io.jsonwebtoken:jjwt-api:0.10.5' + runtime 'io.jsonwebtoken:jjwt-impl:0.10.5', + 'io.jsonwebtoken:jjwt-jackson:0.10.5' } diff --git a/frontend/src/pages/Cache.vue b/frontend/src/pages/Cache.vue index 513310e..5d6b325 100644 --- a/frontend/src/pages/Cache.vue +++ b/frontend/src/pages/Cache.vue @@ -1,74 +1,182 @@ diff --git a/frontend/src/pages/Error404.vue b/frontend/src/pages/Error404.vue index a091bac..75cff24 100644 --- a/frontend/src/pages/Error404.vue +++ b/frontend/src/pages/Error404.vue @@ -5,7 +5,7 @@

Sorry, nothing here...(404)

Go backZur Startseite diff --git a/frontend/src/pages/Login.vue b/frontend/src/pages/Login.vue index cb0e8cc..320019d 100644 --- a/frontend/src/pages/Login.vue +++ b/frontend/src/pages/Login.vue @@ -123,11 +123,11 @@ }) .then((response) => { console.log("GET/POST http://localhost:8080/api/logout/ - response: " + response.data); - localStorage.removeItem('userToken'); - this.evalAuthentication(); }) .catch((error) => { }); + localStorage.removeItem('userToken'); + this.evalAuthentication(); }, }, }; diff --git a/frontend/src/pages/Overview.vue b/frontend/src/pages/Overview.vue index 7560bed..f3b3353 100644 --- a/frontend/src/pages/Overview.vue +++ b/frontend/src/pages/Overview.vue @@ -45,12 +45,15 @@ - - + + +
+ +
@@ -108,6 +111,13 @@ this.caches = response.data; }) }, + addCache() { + this.$router.push({ path: `/cache` }) + }, + editCache() { + }, + removeCache() { + }, startCache(cacheID) { const userToken = JSON.parse(localStorage.getItem('userToken')); let params = { cacheID: cacheID }; @@ -118,8 +128,9 @@ this.$axios.get('http://localhost:8080/api/startCache', { params }) .then((response) => { - console.log("Angefangen: " + response.data); - let stationID = response.data.aktuelleStation.id; + console.log(response.data); + // let stationID = response.data.stationen[0].id; + let stationID = this.caches.find(x => x.id === cacheID).stationen[0].id; console.log(stationID); this.$router.push({ path: `/station/${stationID}` }) }) diff --git a/frontend/src/pages/StationEdit.vue b/frontend/src/pages/StationEdit.vue index 547869f..a8e413c 100644 --- a/frontend/src/pages/StationEdit.vue +++ b/frontend/src/pages/StationEdit.vue @@ -28,7 +28,7 @@
- +
@@ -36,13 +36,13 @@