mirror of
https://github.com/XiaoDaiGua-Ray/ray-template.git
synced 2025-04-06 03:57:49 +08:00
bug fixed: 修复搜索框能检索隐藏路由问题
This commit is contained in:
parent
6acc7b6500
commit
cec5166970
@ -97,7 +97,7 @@ const GlobalSeach = defineComponent({
|
|||||||
|
|
||||||
const filterArr = (options: AppMenuOption[]) => {
|
const filterArr = (options: AppMenuOption[]) => {
|
||||||
options.forEach((curr) => {
|
options.forEach((curr) => {
|
||||||
if (curr.children?.length) {
|
if (curr.children?.length && validMenuItemShow(curr)) {
|
||||||
filterArr(curr.children)
|
filterArr(curr.children)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -72,11 +72,11 @@ export const validMenuItemShow = (option: AppMenuOption) => {
|
|||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!sameLevel && !hidden) {
|
if (hidden) {
|
||||||
return true
|
return false
|
||||||
}
|
}
|
||||||
|
|
||||||
return !hidden ? true : false
|
return true
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
x
Reference in New Issue
Block a user