diff --git a/frontend/src/router/dynamic.ts b/frontend/src/router/dynamic.ts index edde3699..7555741d 100644 --- a/frontend/src/router/dynamic.ts +++ b/frontend/src/router/dynamic.ts @@ -24,10 +24,22 @@ const dynamicRouterList = [ ], }, { - parent: 'set', - path: '/set/assistant', - name: 'setAssistant', - component: SetAssistant, + path: '/as', + component: LayoutDsl, + name: 'as-menu', + redirect: '/as/index', + children: [ + { + path: 'index', + name: 'as', + component: SetAssistant, + meta: { + title: t('embedded.assistant_app'), + iconActive: 'embedded', + iconDeActive: 'noEmbedded', + }, + }, + ], meta: { title: t('embedded.assistant_app') }, }, ] as any[] diff --git a/frontend/src/router/watch.ts b/frontend/src/router/watch.ts index 8ad7a52c..aa8f06e4 100644 --- a/frontend/src/router/watch.ts +++ b/frontend/src/router/watch.ts @@ -39,7 +39,7 @@ export const watchRouter = (router: Router) => { if (!userStore.getUid) { await userStore.info() generateDynamicRouters(router) - isFirstDynamicPath = to?.path && ['/ds/index', '/set/assistant'].includes(to.path) + isFirstDynamicPath = to?.path && ['/ds/index', '/as/index'].includes(to.path) if (isFirstDynamicPath) { next({ ...to, replace: true }) return