marketingPortal/pages/dashboard.vue

101 lines
2.2 KiB
Vue
Raw Normal View History

2025-02-16 13:10:19 +01:00
<template>
<v-app full-height>
2025-05-22 22:28:32 +02:00
<v-navigation-drawer v-model="drawer" :location="mdAndDown ? 'bottom' : undefined">
2025-03-31 18:27:00 +02:00
<v-img v-if="!mdAndDown" src="/logo.jpg" height="75" class="my-6" />
2025-02-16 13:10:19 +01:00
<v-list color="primary" lines="two">
2025-05-22 22:28:32 +02:00
<v-list-item v-for="(item, index) in menu" :key="index" :to="item.to" :title="item.title"
:prepend-icon="item.icon" />
2025-02-16 13:10:19 +01:00
</v-list>
<template #append>
<v-list lines="two">
2025-05-22 22:28:32 +02:00
<v-list-item title="Logged in" prepend-icon="mdi-account" />
<v-list-item @click="logOut" title="Log out" prepend-icon="mdi-logout" base-color="error" />
2025-02-16 13:10:19 +01:00
</v-list>
</template>
</v-navigation-drawer>
<v-app-bar v-if="mdAndDown" elevation="2">
<template #prepend>
2025-03-31 18:27:00 +02:00
<v-app-bar-nav-icon variant="text" @click.stop="drawer = !drawer" />
2025-02-16 13:10:19 +01:00
</template>
2025-03-31 18:27:00 +02:00
<v-img src="/logo.jpg" height="50" />
2025-02-16 13:10:19 +01:00
<template #append>
2025-05-22 22:28:32 +02:00
<v-btn @click="logOut" class="mr-3" variant="text" color="error" icon="mdi-logout" />
2025-02-16 13:10:19 +01:00
</template>
</v-app-bar>
<v-main>
<router-view />
</v-main>
</v-app>
</template>
<script setup>
definePageMeta({
layout: false,
});
const { mdAndDown } = useDisplay();
2025-03-14 01:10:03 +01:00
2025-03-31 18:27:00 +02:00
const drawer = ref(false);
2025-05-22 22:28:32 +02:00
const menu = ref([
2025-03-31 03:24:02 +02:00
{
to: "/dashboard/interest-eoi-queue",
icon: "mdi-tray-full",
title: "EOI Queue",
},
2025-03-14 01:10:03 +01:00
{
to: "/dashboard/interest-analytics",
icon: "mdi-view-dashboard",
title: "Analytics",
},
{
to: "/dashboard/interest-berth-list",
icon: "mdi-table",
title: "Berth List",
},
{
to: "/dashboard/interest-berth-status",
icon: "mdi-sail-boat",
title: "Berth Status",
},
{
to: "/dashboard/interest-list",
icon: "mdi-view-list",
title: "Interest List",
},
{
to: "/dashboard/interest-status",
icon: "mdi-account-check",
title: "Interest Status",
},
{
to: "/dashboard/site",
icon: "mdi-view-dashboard",
title: "Site Analytics",
},
{
to: "/dashboard/data",
icon: "mdi-finance",
title: "Data Analytics",
},
2025-05-22 22:28:32 +02:00
]);
2025-03-14 01:10:03 +01:00
2025-02-16 13:10:19 +01:00
const logOut = async () => {
return navigateTo("/login");
};
2025-04-14 22:00:18 +02:00
onMounted(() => {
if (mdAndDown.value) {
return;
}
drawer.value = true;
})
2025-02-16 13:10:19 +01:00
</script>