feat:增加设置模块
This commit is contained in:
@@ -1,12 +1,37 @@
|
||||
<template>
|
||||
<div class="common-mobile-view profile">
|
||||
个人中心
|
||||
<div>
|
||||
<span>版本号:</span>
|
||||
<span>{{ appStore.version }}</span>
|
||||
</div>
|
||||
<div class="button-container">
|
||||
<el-button type="primary" @click="viewLatestVersionClick">检查新版本</el-button>
|
||||
<el-button type="primary" @click="logoutClick">退出登录</el-button>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import { useAppStore } from '@/store/app.ts'
|
||||
import { useRouter } from 'vue-router'
|
||||
|
||||
const appStore = useAppStore()
|
||||
const router = useRouter()
|
||||
|
||||
const viewLatestVersionClick = () => {
|
||||
location.reload()
|
||||
}
|
||||
|
||||
const logoutClick = () => {
|
||||
router.push('/')
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
|
||||
<style lang="scss">
|
||||
.profile {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 10px;
|
||||
}
|
||||
</style>
|
||||
|
||||
Reference in New Issue
Block a user