diff --git a/src/routes.tsx b/src/routes.tsx index 5cfcfc6..9763895 100644 --- a/src/routes.tsx +++ b/src/routes.tsx @@ -10,6 +10,7 @@ import EmptyLayout from '@/layout/EmptyLayout.tsx' // import ListPageLayout from '@/layout/ListPageLayout.tsx' // import { Route as DashboardImport } from '@/pages/dashboard' import { Route as LoginRouteImport } from '@/pages/login' +import { Route as RegisterRouteImport } from '@/pages/login/register' import { generateUUID } from '@/utils/uuid.ts' import { QueryClient, QueryClientProvider } from '@tanstack/react-query' import Login2 from '@/pages/login2/index.tsx' @@ -31,6 +32,7 @@ import { IRootContext, MenuItem } from './global' import { useAtomValue } from 'jotai' import { userMenuDataAtom } from '@/store/system/user.ts' import { ApiContextProvider } from '@/context.ts' +import Register from "@/pages/login/register.tsx"; const PageRootLayout = () => { return @@ -109,6 +111,10 @@ const loginRoute = LoginRouteImport.update({ getParentRoute: () => emptyRoute, } as any) +const registerRoute = RegisterRouteImport.update({ + path: '/register', + getParentRoute: () => emptyRoute, +} as any) // const login2Route = LoginRouteImport.update({ // path: '/login2', // getParentRoute: () => emptyRoute, @@ -165,7 +171,7 @@ declare module '@tanstack/react-router' { }, '/register': { - preLoaderRoute: typeof layoutNormalRoute + preLoaderRoute: typeof RegisterRouteImport parentRoute: typeof rootRoute }, // '/system/menus': { @@ -313,14 +319,9 @@ const routeTree = rootRoute.addChildren( //非Layout loginRoute, emptyRoute, + registerRoute, //login2Route, // 添加新的自定义路由 - createRoute({ - getParentRoute: () => rootRoute, - path: '/login2', - component: Login2, - }), - //不带权限Layout diff --git a/vite.config.ts b/vite.config.ts index c9d35d4..d5b5925 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -8,8 +8,8 @@ import jotaiReactRefresh from "jotai/babel/plugin-react-refresh"; //import { TanStackRouterVite } from '@tanstack/router-vite-plugin' export const downLoadUrl = "http://127.0.0.1:8000"; const proxyMap = { - '/api/v1/mdw-msg': 'http://127.0.0.1:8848', - "/api/v1/package": "http://154.88.7.8:45321", + // '/api/v1/mdw-msg': 'http://127.0.0.1:8848', + // "/api/v1/package": "http://154.88.7.8:45321", "/api/v1/movie": "http://47.113.117.106:10000", //'/api/v1/certold': 'http://192.168.31.41:8000', "/api/v1/cert": "http://127.0.0.1:8000",