layout: tabbar scrollable in profile

This commit is contained in:
Timo Volkmann 2019-04-11 12:56:23 +02:00
parent 2fe73aebc9
commit a96e1693ed
2 changed files with 16 additions and 43 deletions

11
.idea/modules.xml generated
View File

@ -1,11 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectModuleManager">
<modules>
<module fileurl="file://$PROJECT_DIR$/.idea/labswp_2019_sose_geocaching.iml" filepath="$PROJECT_DIR$/.idea/labswp_2019_sose_geocaching.iml" />
<module fileurl="file://$PROJECT_DIR$/.idea/modules/labswp_2019_sose_geocaching.iml" filepath="$PROJECT_DIR$/.idea/modules/labswp_2019_sose_geocaching.iml" />
<module fileurl="file://$PROJECT_DIR$/.idea/modules/labswp_2019_sose_geocaching.main.iml" filepath="$PROJECT_DIR$/.idea/modules/labswp_2019_sose_geocaching.main.iml" />
<module fileurl="file://$PROJECT_DIR$/.idea/modules/labswp_2019_sose_geocaching.test.iml" filepath="$PROJECT_DIR$/.idea/modules/labswp_2019_sose_geocaching.test.iml" />
</modules>
</component>
</project>

View File

@ -1,20 +1,20 @@
<template>
<q-page class="column">
<q-page class="column no-wrap">
<div class="bg-red col col-shrink" style="">
<q-tabs
v-model="tab"
class="bg-grey-2"
inline-label
align="justify"
active-bg-color="bg-grey-1"
active-color="cyan-14"
indicator-color="cyan-14"
switch-indicator
>
<q-tab name="profile" label="Profil" icon="perm_identity"/>
<q-tab name="startedCaches" label="Angefangene Caches" icon="playlist_play"/>
<q-tab name="finishedCaches" label="Beendete Caches" icon="playlist_add_check"/>
</q-tabs>
<q-tabs
v-model="tab"
class="bg-grey-2"
inline-label
align="justify"
active-bg-color="bg-grey-1"
active-color="cyan-14"
indicator-color="cyan-14"
switch-indicator
>
<q-tab name="profile" label="Profil" icon="perm_identity"/>
<q-tab name="startedCaches" label="Angefangene Caches" icon="playlist_play"/>
<q-tab name="finishedCaches" label="Beendete Caches" icon="playlist_add_check"/>
</q-tabs>
<q-separator color="grey-4"/>
</div>
@ -129,23 +129,7 @@
this.startedCaches = response.data;
});
},
startCache(cacheID) {
const userToken = JSON.parse(localStorage.getItem('userToken'));
let params = {cacheID: cacheID};
if (userToken != null) {
params.token = userToken;
}
console.log(params);
this.$axios.get('http://localhost:8080/api/startCache', {params})
.then((response) => {
console.log(response.data);
// TODO wenn cache angefangen, dann suche die letzte gefundene Station
let stationID = this.caches.find(x => x.id === cacheID).stationen[0].id;
console.log(stationID);
//this.$router.push({path: `/station/${stationID}`})
this.$router.push({path: `/station/${cacheID}/${stationID}`})
})
continueCache(cacheID) {
}
}
}