perf: Adjust the assistant menu position

This commit is contained in:
fit2cloud-chenyw
2026-01-09 18:12:04 +08:00
committed by fit2cloud-chenyw
parent f759dce8c1
commit fc6a740a3f
2 changed files with 17 additions and 5 deletions
+16 -4
View File
@@ -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[]
+1 -1
View File
@@ -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