fix 修复 五级路由缓存无效问题

This commit is contained in:
疯狂的狮子Li 2023-11-10 16:35:58 +08:00
parent 5dbb255323
commit 9b68b27168
2 changed files with 8 additions and 0 deletions

View File

@ -101,6 +101,10 @@ function filterChildren(childrenMap, lastRouter = false) {
}
if (lastRouter) {
el.path = lastRouter.path + '/' + el.path
if (el.children && el.children.length) {
children = children.concat(filterChildren(el.children, el))
return
}
}
children = children.concat(el)
})

View File

@ -98,6 +98,10 @@ function filterChildren(childrenMap, lastRouter = false) {
}
if (lastRouter) {
el.path = lastRouter.path + '/' + el.path
if (el.children && el.children.length) {
children = children.concat(filterChildren(el.children, el))
return
}
}
children = children.concat(el)
})