Avatar do admina, pridani debrief informaci

This commit is contained in:
Michal Kváček
2024-01-20 22:08:49 +01:00
parent b0aa6b5628
commit 08a3cbf3d9
12 changed files with 145 additions and 74 deletions
+3 -8
View File
@@ -1,27 +1,23 @@
<script setup>
import {useRoute, useRouter} from "vue-router";
import {computed, onMounted, ref} from "vue";
import {useLoggedUserStore} from "stores/LoggedUser";
import {useAuthStore} from "stores/Auth";
const $route = useRoute();
const $router = useRouter();
const url = computed(() => $route.query.url || '/moje');
const showLoginInfo = ref(false);
onMounted(() => {
console.log(useAuthStore().getAccessToken());
useAuthStore().refreshAccessToken().then(() => {
$router.push($route.query.url)
$router.push(url.value)
}).catch(e => {
$router.push({name: "login"})
});
setTimeout(() => showLoginInfo.value = true, 1000);
setTimeout(() => $router.push(url), 10000);
setTimeout(() => $router.push(url.value), 10000);
});
</script>
@@ -29,7 +25,7 @@ onMounted(() => {
<template>
<div class="row justify-center">
<div class="col-4">
<div class="col-sm-12 col-4">
<transition
v-if="showLoginInfo"
appear
@@ -42,7 +38,6 @@ onMounted(() => {
<br>
<p class="q-my-lg">
Probíhá přihlašování. Za okamžik dojde k přesměrování. Pokud se tak nestane, klikni na tlačítko
</p>
</q-card-section>
<q-card-actions>
@@ -107,6 +107,12 @@ const togglePublicVisibility = (variables) => toggleVisibility({
<q-separator/>
<article class="q-my-lg" v-html="flight.debriefingNotes"/>
<BasicInfoBanner v-if="flight.debriegingNotes === ''">
Nezapomeň si poznamenat důležité informace pro debriefing. Tyto poznámky slouží jen pro tebe.
</BasicInfoBanner>
<q-separator/>
<ContentCardEditButton
:to="{name: 'flightEdit', params: {id: flightId, step: 'photos'}}"
label="Upravit fotografie"