fix: fix the problem of closing multiple tabs

This commit is contained in:
vben
2020-11-01 12:27:15 +08:00
parent 4c658f4868
commit 275ad9f14e
4 changed files with 5 additions and 11 deletions

View File

@@ -28,10 +28,6 @@ export function genRouteModule(moduleList: AppRouteModule[]) {
const flatList = (toRaw(router.getRoutes()).filter(
(item) => item.children.length === 0
) as unknown) as AppRouteRecordRaw[];
try {
(router as any) = null;
} catch (error) {}
flatList.forEach((item) => {
item.path = `${layout ? layout.path : ''}${item.path}`;
});