mirror of
https://gitee.com/beijing_hongye_huicheng/lilishop-ui.git
synced 2025-12-18 00:45:54 +08:00
左侧菜单选中设置
This commit is contained in:
@@ -1,5 +1,3 @@
|
||||
|
||||
|
||||
<template>
|
||||
<div class="ivu-shrinkable-menu">
|
||||
<!-- 一级菜单 -->
|
||||
@@ -38,6 +36,9 @@ export default {
|
||||
navList() {
|
||||
return this.$store.state.app.navList;
|
||||
},
|
||||
currNav() {
|
||||
return this.$store.state.app.currNav;
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
// 监听路由变化
|
||||
@@ -45,15 +46,10 @@ export default {
|
||||
handler: function (val, oldVal) {
|
||||
console.log(val);
|
||||
}
|
||||
},
|
||||
menuList: {
|
||||
handler: function (val, oldVal) {
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
changeMenu(name) { //二级路由点击
|
||||
console.log(name)
|
||||
this.$router.push({
|
||||
name: name
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user