-
Notifications
You must be signed in to change notification settings - Fork 517
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
BUG: Fix authority and jump issue (#1276)
- Loading branch information
Showing
15 changed files
with
167 additions
and
100 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
import { Navigate, useRoutes } from 'react-router-dom' | ||
|
||
import Layout from '../scenes/_layout' | ||
import ClusterInfo from '../scenes/cluster_info' | ||
import LaunchModel from '../scenes/launch_model' | ||
import Login from '../scenes/login/login' | ||
import RegisterModel from '../scenes/register_model' | ||
import RunningModels from '../scenes/running_models' | ||
|
||
const routes = [ | ||
{ | ||
path: '/', | ||
element: <Layout />, | ||
children: [ | ||
{ | ||
path: '/', | ||
element: <Navigate to="launch_model/llm" replace />, | ||
}, | ||
{ | ||
path: 'launch_model/:Modeltype/:subType?', | ||
element: <LaunchModel />, | ||
}, | ||
{ | ||
path: 'running_models/:runningModelType', | ||
element: <RunningModels />, | ||
}, | ||
{ | ||
path: 'register_model', | ||
element: <RegisterModel />, | ||
}, | ||
{ | ||
path: 'cluster_info', | ||
element: <ClusterInfo />, | ||
}, | ||
], | ||
}, | ||
{ | ||
path: '/login', | ||
element: <Login />, | ||
}, | ||
{ | ||
path: '*', | ||
element: <Navigate to="launch_model/llm" replace />, | ||
}, | ||
] | ||
const WraperRoutes = () => { | ||
let element = useRoutes(routes) | ||
return element | ||
} | ||
|
||
export default WraperRoutes |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.