mirror of
https://github.com/pure-admin/vue-pure-admin.git
synced 2025-11-09 13:53:38 +08:00
fix: update
This commit is contained in:
@@ -12,6 +12,7 @@ import NProgress from "/@/utils/progress";
|
||||
import { useTimeoutFn } from "@vueuse/core";
|
||||
import { storageSession, storageLocal } from "/@/utils/storage";
|
||||
import { usePermissionStoreHook } from "/@/store/modules/permission";
|
||||
import { useMultiTagsStoreHook } from "/@/store/modules/multiTags";
|
||||
|
||||
// 静态路由
|
||||
import homeRouter from "./modules/home";
|
||||
@@ -230,7 +231,9 @@ router.beforeEach((to, _from, next) => {
|
||||
// 刷新
|
||||
if (usePermissionStoreHook().wholeRoutes.length === 0)
|
||||
initRouter(name.username).then((router: Router) => {
|
||||
router.push(to.path);
|
||||
useMultiTagsStoreHook().getMultiTagsCache
|
||||
? router.push(to.path)
|
||||
: router.push("/");
|
||||
// 刷新页面更新标签栏与页面路由匹配
|
||||
const localRoutes = storageLocal.getItem("responsive-tags");
|
||||
const optionsRoutes = router.options?.routes;
|
||||
|
||||
Reference in New Issue
Block a user