feat: allow configuration of staticRroues (#4746)

* feat: allow configuration of staticRroues

* chore: update deps

* chore: typo
This commit is contained in:
Vben
2024-10-27 21:58:39 +08:00
committed by GitHub
parent d7d7466524
commit fe7df5ad3b
11 changed files with 1375 additions and 1532 deletions

View File

@@ -8,7 +8,7 @@ import { startProgress, stopProgress } from '@vben/utils';
import { useTitle } from '@vueuse/core';
import { $t } from '#/locales';
import { coreRouteNames, dynamicRoutes } from '#/router/routes';
import { accessRoutes, coreRouteNames } from '#/router/routes';
import { useAuthStore } from '#/store';
import { generateAccess } from './access';
@@ -104,7 +104,7 @@ function setupAccessGuard(router: Router) {
roles: userRoles,
router,
// 则会在菜单中显示但是访问会被重定向到403
routes: dynamicRoutes,
routes: accessRoutes,
});
// 保存菜单信息和路由信息