diff --git a/frontend/src/pages/CacheEnd.vue b/frontend/src/pages/CacheEnd.vue index 8ccc20b..faf8813 100644 --- a/frontend/src/pages/CacheEnd.vue +++ b/frontend/src/pages/CacheEnd.vue @@ -5,7 +5,7 @@

{{ end1 + rankingPoints + end2 }}

- + diff --git a/frontend/src/pages/StationView.vue b/frontend/src/pages/StationView.vue index 75fb24a..453ffb8 100644 --- a/frontend/src/pages/StationView.vue +++ b/frontend/src/pages/StationView.vue @@ -51,7 +51,7 @@ data() { return { - code: "", + //code: "", cache: null, data: { cacheId: 22, @@ -165,8 +165,8 @@ setParams() { console.log("setParams: "); let params = {}; - params.cacheID = this.code.split('/')[0]; - params.stationID = this.code.split('/')[1]; + params.cacheID = this.result.split('/')[0]; + params.stationID = this.result.split('/')[1]; params.durchgefuehrterCacheID = this.cacheID; console.log(params.cacheID + " und " + params.stationID); if (localStorage.getItem('userToken')) { @@ -198,7 +198,11 @@ .then((response) => { console.log("resolve(true)"); resolve(true); - this.$router.push({path: `/station/${params.cacheID}/${params.stationID}`}); + if (response.data.cache_acces_definition === 0) { + this.$router.push({path: `/station/${params.cacheID}/${params.stationID}`}); + } else if (response.data.cache_acces_definition === 1) { + this.$router.push({path: `/CacheEnd/${params.cacheID}`}); + } }).catch((error) => { console.log("resolve(false)"); // Error