更新退出
This commit is contained in:
@ -8,7 +8,7 @@
|
|||||||
<div class="name">姓名:{{ username }}</div>
|
<div class="name">姓名:{{ username }}</div>
|
||||||
<div class="work">单位:{{ deptName }}</div>
|
<div class="work">单位:{{ deptName }}</div>
|
||||||
</div>
|
</div>
|
||||||
<!-- <el-dropdown :hide-on-click="false">
|
<el-dropdown :hide-on-click="false">
|
||||||
<span class="el-dropdown-link">
|
<span class="el-dropdown-link">
|
||||||
<el-icon :size="20" color="#fff"> <CaretBottom /> </el-icon>
|
<el-icon :size="20" color="#fff"> <CaretBottom /> </el-icon>
|
||||||
</span>
|
</span>
|
||||||
@ -17,7 +17,7 @@
|
|||||||
<el-dropdown-item command="logout">退出登录</el-dropdown-item>
|
<el-dropdown-item command="logout">退出登录</el-dropdown-item>
|
||||||
</el-dropdown-menu>
|
</el-dropdown-menu>
|
||||||
</template>
|
</template>
|
||||||
</el-dropdown> -->
|
</el-dropdown>
|
||||||
</div>
|
</div>
|
||||||
<div @click="goToHome">
|
<div @click="goToHome">
|
||||||
<img src="@/assets/images/meun.png" />
|
<img src="@/assets/images/meun.png" />
|
||||||
@ -54,7 +54,9 @@ onMounted(() => {
|
|||||||
active.value = "LZ";
|
active.value = "LZ";
|
||||||
});
|
});
|
||||||
const logout = () => {
|
const logout = () => {
|
||||||
store.dispatch("user/logout");
|
window.opener = null;
|
||||||
|
window.open('', '_self');
|
||||||
|
window.close();
|
||||||
store.commit("app/clearTag", null, { immediate: true });
|
store.commit("app/clearTag", null, { immediate: true });
|
||||||
store.commit("permission/deleteRouter", { immediate: true });
|
store.commit("permission/deleteRouter", { immediate: true });
|
||||||
store.commit("user/deleteKeepLiiveRoute", "home");
|
store.commit("user/deleteKeepLiiveRoute", "home");
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
<template>
|
<template>
|
||||||
<!-- <el-dropdown class="avatar-container" trigger="click">
|
<el-dropdown class="avatar-container" trigger="click">
|
||||||
<div class="avatar-wrapper">
|
<div class="avatar-wrapper">
|
||||||
<el-avatar
|
<el-avatar
|
||||||
shape="circle"
|
shape="circle"
|
||||||
@ -12,7 +12,7 @@
|
|||||||
<el-dropdown-item divided @click="logout()">退出登录</el-dropdown-item>
|
<el-dropdown-item divided @click="logout()">退出登录</el-dropdown-item>
|
||||||
</el-dropdown-menu>
|
</el-dropdown-menu>
|
||||||
</template>
|
</template>
|
||||||
</el-dropdown> -->
|
</el-dropdown>
|
||||||
<UpdatePwdDialog v-model="UpdatePwdVisible"></UpdatePwdDialog>
|
<UpdatePwdDialog v-model="UpdatePwdVisible"></UpdatePwdDialog>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@ -28,13 +28,12 @@ const updatePwd = () => {
|
|||||||
const store = useStore();
|
const store = useStore();
|
||||||
|
|
||||||
const logout = () => {
|
const logout = () => {
|
||||||
store.dispatch("user/logout");
|
window.opener = null;
|
||||||
store.commit("app/clearTag", null, {
|
window.open('', '_self');
|
||||||
immediate: true
|
window.close();
|
||||||
});
|
store.commit("app/clearTag", null, { immediate: true });
|
||||||
store.commit("permission/deleteRouter", {
|
store.commit("permission/deleteRouter", { immediate: true });
|
||||||
immediate: true
|
store.commit("user/deleteKeepLiiveRoute", "home");
|
||||||
});
|
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user