This commit is contained in:
oneao committed 2025-12-11 22:26:28 +08:00
1 parent 57c0d98f11
commit 861b529d9b
19 files changed
+742 -66

No files matched your search

@@ -1,5 +1,5 @@
<script lang="ts" setup>
import { useRoute } from 'vue-router'
import { useRoute, useRouter } from 'vue-router'
const props = defineProps({
isLogined: {
@@ -9,6 +9,7 @@ const props = defineProps({
})
const route = useRoute()
const router = useRouter()
const menuList = [
{ name: '首页', path: '/' },
@@ -17,6 +18,10 @@ const menuList = [
{ name: '关于我们', path: '/companies' },
{ name: '联系我们', path: '/forum' },
]
function navigateTo(path: string) {
router.push(path)
}
</script>
<template>
@@ -60,7 +65,11 @@ const menuList = [
</template>
<template v-else>
<el-button type="primary" round>
<el-button
type="primary"
round
@click="navigateTo('/auth/login')"
>
登录
</el-button>
</template>