Nested routes check added
parent
69f692e1d3
commit
067654c6c4
|
@ -46,7 +46,9 @@ export default {
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
isActiveRootmenuItem(menuitem) {
|
isActiveRootmenuItem(menuitem) {
|
||||||
return menuitem.children && !menuitem.children.some((item) => item.to === `/${this.$router.currentRoute.value.name}` || (item.children && item.children.some((it) => it.to === `/${this.$router.currentRoute.value.name}`)));
|
return (
|
||||||
|
menuitem.children && !menuitem.children.some((item) => item.to === `/${this.$router.currentRoute.value?.name?.replace('-', '/')}` || (item.children && item.children.some((it) => it.to === `/${this.$router.currentRoute.value.name}`)))
|
||||||
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue