|
@@ -1,39 +1,42 @@
|
|
|
<template>
|
|
|
<div class="navbar">
|
|
|
- <hamburger id="hamburger-container" :is-active="appStore.sidebar.opened" class="hamburger-container" @toggleClick="toggleSideBar" />
|
|
|
- <breadcrumb id="breadcrumb-container" class="breadcrumb-container" v-if="!settingsStore.topNav" />
|
|
|
- <top-nav id="topmenu-container" class="topmenu-container" v-if="settingsStore.topNav" />
|
|
|
+ <hamburger id="hamburger-container" :is-active="appStore.sidebar.opened" class="hamburger-container"
|
|
|
+ @toggleClick="toggleSideBar"/>
|
|
|
+ <breadcrumb id="breadcrumb-container" class="breadcrumb-container" v-if="!settingsStore.topNav"/>
|
|
|
+ <top-nav id="topmenu-container" class="topmenu-container" v-if="settingsStore.topNav"/>
|
|
|
|
|
|
<div class="right-menu">
|
|
|
<template v-if="appStore.device !== 'mobile'">
|
|
|
-<!-- <header-search id="header-search" class="right-menu-item" />-->
|
|
|
+ <!-- <header-search id="header-search" class="right-menu-item" />-->
|
|
|
|
|
|
-<!-- <el-tooltip content="源码地址" effect="dark" placement="bottom">-->
|
|
|
-<!-- <ruo-yi-git id="ruoyi-git" class="right-menu-item hover-effect" />-->
|
|
|
-<!-- </el-tooltip>-->
|
|
|
+ <!-- <el-tooltip content="源码地址" effect="dark" placement="bottom">-->
|
|
|
+ <!-- <ruo-yi-git id="ruoyi-git" class="right-menu-item hover-effect" />-->
|
|
|
+ <!-- </el-tooltip>-->
|
|
|
|
|
|
-<!-- <el-tooltip content="文档地址" effect="dark" placement="bottom">-->
|
|
|
-<!-- <ruo-yi-doc id="ruoyi-doc" class="right-menu-item hover-effect" />-->
|
|
|
-<!-- </el-tooltip>-->
|
|
|
+ <!-- <el-tooltip content="文档地址" effect="dark" placement="bottom">-->
|
|
|
+ <!-- <ruo-yi-doc id="ruoyi-doc" class="right-menu-item hover-effect" />-->
|
|
|
+ <!-- </el-tooltip>-->
|
|
|
|
|
|
- <screenfull id="screenfull" class="right-menu-item hover-effect" />
|
|
|
+ <screenfull id="screenfull" class="right-menu-item hover-effect"/>
|
|
|
|
|
|
<el-tooltip content="主题模式" effect="dark" placement="bottom">
|
|
|
<div class="right-menu-item hover-effect theme-switch-wrapper" @click="toggleTheme">
|
|
|
- <svg-icon v-if="settingsStore.isDark" icon-class="sunny" />
|
|
|
- <svg-icon v-if="!settingsStore.isDark" icon-class="moon" />
|
|
|
+ <svg-icon v-if="settingsStore.isDark" icon-class="sunny"/>
|
|
|
+ <svg-icon v-if="!settingsStore.isDark" icon-class="moon"/>
|
|
|
</div>
|
|
|
</el-tooltip>
|
|
|
|
|
|
-<!-- <el-tooltip content="布局大小" effect="dark" placement="bottom">-->
|
|
|
-<!-- <size-select id="size-select" class="right-menu-item hover-effect" />-->
|
|
|
-<!-- </el-tooltip>-->
|
|
|
+ <!-- <el-tooltip content="布局大小" effect="dark" placement="bottom">-->
|
|
|
+ <!-- <size-select id="size-select" class="right-menu-item hover-effect" />-->
|
|
|
+ <!-- </el-tooltip>-->
|
|
|
</template>
|
|
|
<div class="avatar-container">
|
|
|
<el-dropdown @command="handleCommand" class="right-menu-item hover-effect" trigger="click">
|
|
|
<div class="avatar-wrapper">
|
|
|
- <img :src="userStore.avatar" class="user-avatar" />
|
|
|
- <el-icon><caret-bottom /></el-icon>
|
|
|
+ <img :src="userStore.avatar" class="user-avatar"/>
|
|
|
+ <el-icon>
|
|
|
+ <caret-bottom/>
|
|
|
+ </el-icon>
|
|
|
</div>
|
|
|
<template #dropdown>
|
|
|
<el-dropdown-menu>
|
|
@@ -55,19 +58,16 @@
|
|
|
</template>
|
|
|
|
|
|
<script setup>
|
|
|
-import { ElMessageBox } from 'element-plus'
|
|
|
+import {ElMessageBox} from 'element-plus'
|
|
|
import Breadcrumb from '@/components/Breadcrumb'
|
|
|
import TopNav from '@/components/TopNav'
|
|
|
import Hamburger from '@/components/Hamburger'
|
|
|
import Screenfull from '@/components/Screenfull'
|
|
|
-import SizeSelect from '@/components/SizeSelect'
|
|
|
-import HeaderSearch from '@/components/HeaderSearch'
|
|
|
-import RuoYiGit from '@/components/RuoYi/Git'
|
|
|
-import RuoYiDoc from '@/components/RuoYi/Doc'
|
|
|
import useAppStore from '@/store/modules/app'
|
|
|
import useUserStore from '@/store/modules/user'
|
|
|
import useSettingsStore from '@/store/modules/settings'
|
|
|
import usePermissionStore from '@/store/modules/permission'
|
|
|
+
|
|
|
const indexPage = computed(() => usePermissionStore().indexPage);
|
|
|
|
|
|
const appStore = useAppStore()
|
|
@@ -98,13 +98,15 @@ function logout() {
|
|
|
type: 'warning'
|
|
|
}).then(() => {
|
|
|
userStore.logOut().then(() => {
|
|
|
- location.href = indexPage.value;
|
|
|
+ location.href = '/twin' + indexPage.value;
|
|
|
// location.href = '/twin/index';
|
|
|
})
|
|
|
- }).catch(() => { });
|
|
|
+ }).catch(() => {
|
|
|
+ });
|
|
|
}
|
|
|
|
|
|
const emits = defineEmits(['setLayout'])
|
|
|
+
|
|
|
function setLayout() {
|
|
|
emits('setLayout');
|
|
|
}
|