|
|
@ -1,10 +1,10 @@
|
|
|
|
import { Suspense } from 'react';
|
|
|
|
// import { Suspense } from 'react';
|
|
|
|
import LayoutCom from './components/layout-com';
|
|
|
|
import LayoutCom from './components/layout-com';
|
|
|
|
import { Routes, Route, Link } from 'react-router-dom';
|
|
|
|
import { Routes, Route, Link } from 'react-router-dom';
|
|
|
|
|
|
|
|
|
|
|
|
import routeList from './route';
|
|
|
|
import routeList from './route';
|
|
|
|
import Login from '@/page/login';
|
|
|
|
import Login from '@/page/login';
|
|
|
|
import { MenuProps, Spin, ConfigProvider } from 'antd';
|
|
|
|
import { MenuProps } from 'antd';
|
|
|
|
import { useTran } from './hooks';
|
|
|
|
import { useTran } from './hooks';
|
|
|
|
import { STR_MAP } from './config/i18n/locales/constants';
|
|
|
|
import { STR_MAP } from './config/i18n/locales/constants';
|
|
|
|
import IconFont from './components/icon';
|
|
|
|
import IconFont from './components/icon';
|
|
|
@ -21,36 +21,10 @@ const App = () => {
|
|
|
|
{ label: <Link to={'/thread-poll/index'}>{useTran(STR_MAP.THREAD_POOL)}</Link>, key: '/thread-poll/index' },
|
|
|
|
{ label: <Link to={'/thread-poll/index'}>{useTran(STR_MAP.THREAD_POOL)}</Link>, key: '/thread-poll/index' },
|
|
|
|
],
|
|
|
|
],
|
|
|
|
},
|
|
|
|
},
|
|
|
|
{
|
|
|
|
|
|
|
|
// label: <Link to={'/tenant'}>{useTran(STR_MAP.LOG_MANAGE)}</Link>,
|
|
|
|
|
|
|
|
label: <Link to={'/tenant'}>租户管理</Link>,
|
|
|
|
|
|
|
|
key: STR_MAP.TENANT_MANAGE,
|
|
|
|
|
|
|
|
icon: <IconFont type="icon-hot-for-ux"></IconFont>,
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
// label: <Link to={'/item'}>{useTran(STR_MAP.PROJECT_MANAGE)}</Link>,
|
|
|
|
|
|
|
|
label: <Link to={'/item'}>项目管理</Link>,
|
|
|
|
|
|
|
|
key: STR_MAP.PROJECT_MANAGE,
|
|
|
|
|
|
|
|
icon: <IconFont type="icon-hot-for-ux"></IconFont>,
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
// label: <Link to={'/user'}>{useTran(STR_MAP.USE_RIGHT)}</Link>,
|
|
|
|
|
|
|
|
label: <Link to={'/user'}>用户权限</Link>,
|
|
|
|
|
|
|
|
key: STR_MAP.USE_RIGHT,
|
|
|
|
|
|
|
|
icon: <IconFont type="icon-hot-for-ux"></IconFont>,
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
// label: <Link to={'/log'}>{useTran(STR_MAP.LOG_MANAGE)}</Link>,
|
|
|
|
|
|
|
|
label: <Link to={'/log'}>日志管理</Link>,
|
|
|
|
|
|
|
|
key: STR_MAP.LOG_MANAGE,
|
|
|
|
|
|
|
|
icon: <IconFont type="icon-hot-for-ux"></IconFont>,
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
];
|
|
|
|
];
|
|
|
|
|
|
|
|
|
|
|
|
return (
|
|
|
|
return (
|
|
|
|
<ConfigProvider>
|
|
|
|
<LayoutCom sideMenuList={sideMenuList} isSider={true} isHeader={true}>
|
|
|
|
<Suspense fallback={<Spin size="small" />}>
|
|
|
|
|
|
|
|
<LayoutCom sideMenuList={sideMenuList} isSider={true}>
|
|
|
|
|
|
|
|
<Routes>
|
|
|
|
<Routes>
|
|
|
|
<Route path="/Login" Component={Login}></Route>
|
|
|
|
<Route path="/Login" Component={Login}></Route>
|
|
|
|
{routeList.map(item => (
|
|
|
|
{routeList.map(item => (
|
|
|
@ -58,8 +32,6 @@ const App = () => {
|
|
|
|
))}
|
|
|
|
))}
|
|
|
|
</Routes>
|
|
|
|
</Routes>
|
|
|
|
</LayoutCom>
|
|
|
|
</LayoutCom>
|
|
|
|
</Suspense>
|
|
|
|
|
|
|
|
</ConfigProvider>
|
|
|
|
|
|
|
|
);
|
|
|
|
);
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|