generated from Leo_Ding/web-template
平台管理
This commit is contained in:
parent
4f548f2f9b
commit
dfb266eef3
@ -43,9 +43,13 @@
|
||||
<a-spin />
|
||||
<template #overlay>
|
||||
<a-menu>
|
||||
<a-menu-item key="edit" @click="handleOpen">
|
||||
<!-- <a-menu-item key="edit" @click="handleOpen">
|
||||
<edit-outlined />
|
||||
{{ $t('component.RightContent.profile') }}
|
||||
</a-menu-item> -->
|
||||
<a-menu-item key="edit" @click="handleOpen">
|
||||
<LeftOutlined />
|
||||
返回平台
|
||||
</a-menu-item>
|
||||
<a-menu-item key="logout" @click="handleLogout">
|
||||
<login-outlined></login-outlined>
|
||||
@ -64,7 +68,7 @@ import { Modal } from 'ant-design-vue'
|
||||
import { storeToRefs } from 'pinia'
|
||||
import { computed, useSlots, ref } from 'vue'
|
||||
import { useRouter } from 'vue-router'
|
||||
import { LoginOutlined, SettingOutlined, EditOutlined, TranslationOutlined, BarChartOutlined } from '@ant-design/icons-vue'
|
||||
import { LoginOutlined, SettingOutlined, EditOutlined, TranslationOutlined, BarChartOutlined,LeftOutlined } from '@ant-design/icons-vue'
|
||||
import { useAppStore, useUserStore } from '@/store'
|
||||
import ActionButton from './ActionButton.vue'
|
||||
import { theme as antTheme } from 'ant-design-vue'
|
||||
@ -153,9 +157,7 @@ function handleLogout() {
|
||||
*/
|
||||
|
||||
function handleOpen() {
|
||||
router.push({
|
||||
name: 'setting',
|
||||
})
|
||||
router.replace({path:'/platForm'})
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@ -111,14 +111,9 @@ async function handleSelect(type) {
|
||||
}
|
||||
} else {
|
||||
storage.local.setItem('platform', type)
|
||||
// 加载完成
|
||||
if (appStore.complete) {
|
||||
goIndex()
|
||||
} else {
|
||||
await appStore.init({ platform: type })
|
||||
goIndex()
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
async function goIndex() {
|
||||
@ -149,13 +144,10 @@ function getFirstValidRoute() {
|
||||
async function handleChange(e) {
|
||||
storage.local.setItem('platform', 'yunying')
|
||||
storage.local.setItem('stationId', e)
|
||||
// 加载完成
|
||||
if (appStore.complete) {
|
||||
goIndex()
|
||||
} else {
|
||||
|
||||
await appStore.init({ platform: 'yunying' })
|
||||
goIndex()
|
||||
}
|
||||
|
||||
}
|
||||
</script>
|
||||
<style lang="less" scoped>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user