3.10 工程代码同步master

This commit is contained in:
jl-zhoujl2
2022-03-10 14:24:13 +08:00
parent 41ab55a4ac
commit 62f6b07ee2
914 changed files with 143121 additions and 29110 deletions

View File

@ -40,13 +40,13 @@ const CosMenuLayout: React.FC<BasicLayoutProps> = (props) => {
const menuDataRef = useRef<MenuDataItem[]>([]);
useEffect(() => {
if (dispatch) {
dispatch({
type: 'user/fetchCurrent',
});
}
}, []);
// useEffect(() => {
// if (dispatch) {
// dispatch({
// type: 'user/fetchCurrent',
// });
// }
// }, []);
const authorized = useMemo(
() =>
getMatchMenu(location.pathname || '/', menuDataRef.current).pop() || {
@ -57,15 +57,12 @@ const CosMenuLayout: React.FC<BasicLayoutProps> = (props) => {
return (
<Authorized authority={authorized!.authority} noMatch={noMatch}>
<Promenu />
<div style={{marginTop:'5px'}}>
{children}
</div>
</Authorized>
<Authorized authority={authorized!.authority} noMatch={noMatch}>
<Promenu />
<div className='basicLayout-children' style={{ height: innerHeight - 240 }}>
{children}
</div>
</Authorized>
);
};