Refactor SearchBar

pull/1021/head
Yiğit FINDIKLI 2021-02-18 12:21:13 +03:00
parent 8da5caa2a3
commit 0c1f7a2527
1 changed files with 6 additions and 6 deletions

View File

@ -70,16 +70,16 @@ export default {
this.menu = data;
data.forEach((route) => {
let childRoute = route;
childRoute = childRoute.children.filter((childRoute) => {
if (childRoute.meta) {
this.routes.push(childRoute);
let childRoute = {...route};
childRoute.children = childRoute.children.filter((child) => {
if (child.meta) {
this.routes.push(child);
}
return !childRoute.meta;
return !child.meta;
})
this.routes.push(route);
this.routes.push(childRoute);
});
})
},