Closed yuankeyan closed 2 years ago
@umijs/preset-react": "^2.1.3“版本中,在plugin-layout/layout/layout/index.tsx中 const currentPathConfig = useMemo(() => { const { menuData } = transformRoute( props?.route?.routes || [], undefined, undefined, true, ); // 动态路由匹配 const currentPathConfig = getMatchMenu(location.pathname, menuData).pop(); return currentPathConfig || {}; },[location?.pathname, props?.route?.routes]);
currentPathConfig是当前的路由,没有经过traverseModifyRoutes转化,此时currentPathConfig.unAccessible || currentPathConfig.unaccessible是没有值的,WithExceptionOpChildren使用时,不能很好的进行权限控制,这个是不是bug?
是其他问题
@umijs/preset-react": "^2.1.3“版本中,在plugin-layout/layout/layout/index.tsx中 const currentPathConfig = useMemo(() => { const { menuData } = transformRoute( props?.route?.routes || [], undefined, undefined, true, ); // 动态路由匹配 const currentPathConfig = getMatchMenu(location.pathname, menuData).pop(); return currentPathConfig || {}; },[location?.pathname, props?.route?.routes]);
currentPathConfig是当前的路由,没有经过traverseModifyRoutes转化,此时currentPathConfig.unAccessible || currentPathConfig.unaccessible是没有值的,WithExceptionOpChildren使用时,不能很好的进行权限控制,这个是不是bug?