Przeglądaj źródła

Update generator-routers.ts

lex 1 rok temu
rodzic
commit
9806921c1f
1 zmienionych plików z 1 dodań i 1 usunięć
  1. 1 1
      src/router/generator-routers.ts

+ 1 - 1
src/router/generator-routers.ts

@@ -33,7 +33,7 @@ export const routerGenerator = (routerMap: any, parent?: any): any[] => {
       path:
         item.path.indexOf('/') > -1 ? item.path : `${(parent && parent.path) || ''}/${item.path}`,
       // 路由名称,建议唯一
-      name: item.name || '',
+      name: item.path || '',
       // 该路由对应页面的 组件
       component: asyncRoute[item.component],
       // meta: 页面标题, 菜单图标, 页面权限(供指令权限用,可去掉)