mirror of
https://github.com/QingdaoU/OnlineJudgeFE.git
synced 2025-01-01 09:31:42 +00:00
change side menu with url link
This commit is contained in:
parent
de6c78025f
commit
9b47747949
@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<el-menu default-active="1" class="vertical_menu" theme="dark" :router="true">
|
||||
<el-menu default-active="1" class="vertical_menu" theme="dark" :router="true" :unique-opened="true" :default-active="currentPath">
|
||||
<div class="logo">
|
||||
<img src="../assets/logo.svg" alt="oj admin" />
|
||||
</div>
|
||||
@ -14,6 +14,14 @@
|
||||
|
||||
<script>
|
||||
export default{
|
||||
data () {
|
||||
return {
|
||||
currentPath: ''
|
||||
}
|
||||
},
|
||||
mounted () {
|
||||
this.currentPath = this.$route.path.substring(1)
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user