fix: page structure

umi
Dawn1Ocean 2024-03-28 11:29:34 +08:00
parent 860d85fc8b
commit 6095375771
6 changed files with 10 additions and 10 deletions

View File

@ -7,7 +7,7 @@ export default defineConfig({
initialState: {}, initialState: {},
request: {}, request: {},
layout: { layout: {
title: '@umijs/max', title: 'EVA Tea',
}, },
routes: [ routes: [
{ {
@ -20,14 +20,14 @@ export default defineConfig({
component: './Home', component: './Home',
}, },
{ {
name: '权限演示', name: '主席团管理',
path: '/access', path: '/admin',
component: './Access', component: './Admin',
}, },
{ {
name: ' CRUD 示例', name: '日志',
path: '/table', path: '/log',
component: './Table', component: './Log',
}, },
], ],
npmClient: 'pnpm', npmClient: 'pnpm',

View File

@ -4,14 +4,14 @@
import React from 'react'; import React from 'react';
export async function getRoutes() { export async function getRoutes() {
const routes = {"1":{"path":"/","redirect":"/home","parentId":"ant-design-pro-layout","id":"1"},"2":{"name":"首页","path":"/home","parentId":"ant-design-pro-layout","id":"2"},"3":{"name":"权限演示","path":"/access","parentId":"ant-design-pro-layout","id":"3"},"4":{"name":" CRUD 示例","path":"/table","parentId":"ant-design-pro-layout","id":"4"},"ant-design-pro-layout":{"id":"ant-design-pro-layout","path":"/","isLayout":true}} as const; const routes = {"1":{"path":"/","redirect":"/home","parentId":"ant-design-pro-layout","id":"1"},"2":{"name":"首页","path":"/home","parentId":"ant-design-pro-layout","id":"2"},"3":{"name":"主席团管理","path":"/admin","parentId":"ant-design-pro-layout","id":"3"},"4":{"name":"日志","path":"/log","parentId":"ant-design-pro-layout","id":"4"},"ant-design-pro-layout":{"id":"ant-design-pro-layout","path":"/","isLayout":true}} as const;
return { return {
routes, routes,
routeComponents: { routeComponents: {
'1': React.lazy(() => import( './EmptyRoute')), '1': React.lazy(() => import( './EmptyRoute')),
'2': React.lazy(() => import(/* webpackChunkName: "p__Home__index" */'@/pages/Home/index.tsx')), '2': React.lazy(() => import(/* webpackChunkName: "p__Home__index" */'@/pages/Home/index.tsx')),
'3': React.lazy(() => import(/* webpackChunkName: "p__Access__index" */'@/pages/Access/index.tsx')), '3': React.lazy(() => import(/* webpackChunkName: "p__Admin__index" */'@/pages/Admin/index.tsx')),
'4': React.lazy(() => import(/* webpackChunkName: "p__Table__index" */'@/pages/Table/index.tsx')), '4': React.lazy(() => import(/* webpackChunkName: "p__Log__index" */'@/pages/Log/index.tsx')),
'ant-design-pro-layout': React.lazy(() => import(/* webpackChunkName: "umi__plugin-layout__Layout" */'/home/dean/Coding/EVA Tea/Notify-Admin/src/.umi/plugin-layout/Layout.tsx')), 'ant-design-pro-layout': React.lazy(() => import(/* webpackChunkName: "umi__plugin-layout__Layout" */'/home/dean/Coding/EVA Tea/Notify-Admin/src/.umi/plugin-layout/Layout.tsx')),
}, },
}; };