ver 2
This commit is contained in:
@@ -2,13 +2,14 @@
|
||||
|
||||
<div id="app" class="flex flex-col h-screen bg-gray-300">
|
||||
<!-- MenuBar всегда фиксирован сверху -->
|
||||
<MenuBar class="w-full sticky hidden lg:block top-0 z-10"/>
|
||||
<MenuBar v-if="userStore.user" class="w-full sticky hidden lg:block top-0 z-10"/>
|
||||
<ToolBar class=" fixed visible lg:invisible bottom-0 z-10"/>
|
||||
|
||||
<!-- Контентная часть заполняет оставшееся пространство -->
|
||||
<div class="flex flex-col flex-grow">
|
||||
<!-- {{ tg_id }}-->
|
||||
<Button label="Sub" :class="checkNotif ? 'flex' : '!hidden'" @click="checkSubscribe"/>
|
||||
|
||||
<router-view />
|
||||
<div class="bg-gray-100 h-12 block lg:hidden"></div>
|
||||
</div>
|
||||
@@ -32,6 +33,7 @@ import {useDrawerStore} from '@/stores/drawerStore'
|
||||
import TransactionForm from "@/components/transactions/TransactionForm.vue";
|
||||
|
||||
|
||||
|
||||
const drawerStore = useDrawerStore();
|
||||
const visible = computed(() => drawerStore.visible);
|
||||
const closeDrawer = () => {
|
||||
@@ -73,7 +75,7 @@ const sendSubscribe = async () => {
|
||||
console.log("Push subscription:", subscription);
|
||||
|
||||
// Отправка подписки на сервер для хранения
|
||||
await apiClient.post("/push/subscribe", subscription)
|
||||
await apiClient.post("/subscriptions/subscribe", subscription)
|
||||
} catch (error) {
|
||||
console.error("Failed to subscribe to push:", error);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user