|
|
|
@ -69,7 +69,7 @@
|
|
|
|
|
threePermissionList: [],
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
mounted(){
|
|
|
|
|
mounted() {
|
|
|
|
|
let that = this;
|
|
|
|
|
this.bus.$on('callBack', function () {
|
|
|
|
|
that.callBack();
|
|
|
|
@ -97,6 +97,15 @@
|
|
|
|
|
},
|
|
|
|
|
methods: {
|
|
|
|
|
onSelectLister(val) {
|
|
|
|
|
let i;
|
|
|
|
|
this.onePermissionList.forEach(function (data) {
|
|
|
|
|
data.subMenuList.forEach(function (dta) {
|
|
|
|
|
if(dta.id === val){
|
|
|
|
|
i = dta;
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
});
|
|
|
|
|
sessionStorage.setItem("threeLevel",JSON.stringify(i.subMenuList));
|
|
|
|
|
for (let i = 0; i < this.onePermissionList.length; i++) {
|
|
|
|
|
let item = this.onePermissionList[i];
|
|
|
|
|
for (let k = 0; k < item.subMenuList.length; k++) {
|
|
|
|
@ -210,7 +219,7 @@
|
|
|
|
|
return data.pid === one.id
|
|
|
|
|
});
|
|
|
|
|
one.subMenuList = two;
|
|
|
|
|
})
|
|
|
|
|
});
|
|
|
|
|
//展开第一个菜单
|
|
|
|
|
that.menuInit();
|
|
|
|
|
}
|
|
|
|
@ -221,24 +230,25 @@
|
|
|
|
|
let that = this;
|
|
|
|
|
that.selectedItemName = that.onePermissionList[0].subMenuList[0].id;
|
|
|
|
|
that.openName = [that.onePermissionList[0].id];
|
|
|
|
|
this.$nextTick(()=>{
|
|
|
|
|
this.$nextTick(() => {
|
|
|
|
|
this.$refs.menu.updateOpened();
|
|
|
|
|
this.$refs.menu.updateActiveName();
|
|
|
|
|
})
|
|
|
|
|
});
|
|
|
|
|
this.selectedMenu = this.onePermissionList[0].name;
|
|
|
|
|
this.selectedSubMenu = this.onePermissionList[0].subMenuList[0].name;
|
|
|
|
|
this.$router.push({path:that.onePermissionList[0].subMenuList[0].resource});
|
|
|
|
|
sessionStorage.setItem("threeLevel",JSON.stringify(this.onePermissionList[0].subMenuList[0].subMenuList));
|
|
|
|
|
this.$router.push({path: that.onePermissionList[0].subMenuList[0].resource});
|
|
|
|
|
},
|
|
|
|
|
//账户管理页面回调方法
|
|
|
|
|
callBack(){
|
|
|
|
|
callBack() {
|
|
|
|
|
let that = this;
|
|
|
|
|
this.selectedMenu = "设置管理";
|
|
|
|
|
this.selectedSubMenu = "账户管理";
|
|
|
|
|
this.selectedItemName = this.onePermissionList[0].subMenuList[0].id;
|
|
|
|
|
this.$nextTick(()=>{
|
|
|
|
|
this.$nextTick(() => {
|
|
|
|
|
that.$refs.menu.updateActiveName();
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|