退出
This commit is contained in:
parent
7f9bcd7000
commit
e4f1212a42
|
@ -1,12 +1,18 @@
|
|||
<template>
|
||||
<div>
|
||||
home组件
|
||||
</div>
|
||||
<div>
|
||||
<el-button type="info" @click="logout">退出</el-button>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
name: 'Home'
|
||||
name: 'Home',
|
||||
methods: {
|
||||
logout () {
|
||||
sessionStorage.clear()
|
||||
this.$router.push('/login')
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user