Files
supersonic/webapp/packages/supersonic-fe/config/routes.ts
williamhliu 6951eada9d add chat plugin and split query to parse and execute (#25)
* [feature](webapp) add drill down dimensions and metric period compare and modify layout

* [feature](webapp) add drill down dimensions and metric period compare and modify layout

* [feature](webapp) gitignore add supersonic-webapp

* [feature](webapp) gitignore add supersonic-webapp

* [feature](webapp) add chat plugin and split query to parse and execute

* [feature](webapp) add chat plugin and split query to parse and execute

* [feature](webapp) add chat plugin and split query to parse and execute

---------

Co-authored-by: williamhliu <williamhliu@tencent.com>
2023-08-05 22:17:42 +08:00

63 lines
1.2 KiB
TypeScript

export const ROUTE_AUTH_CODES = {};
const ENV_KEY = {
CHAT: 'chat',
SEMANTIC: 'semantic',
};
const { APP_TARGET } = process.env;
const ROUTES = [
{
path: '/chat',
name: 'chat',
component: './Chat',
envEnableList: [ENV_KEY.CHAT],
},
{
path: '/chatSetting/:modelId?/:menuKey?',
name: 'chatSetting',
component: './SemanticModel/ChatSetting',
envEnableList: [ENV_KEY.CHAT],
},
{
path: '/chatPlugin',
name: 'chatPlugin',
component: './ChatPlugin',
envEnableList: [ENV_KEY.CHAT],
},
{
path: '/semanticModel/:modelId?/:menuKey?',
name: 'semanticModel',
component: './SemanticModel/ProjectManager',
envEnableList: [ENV_KEY.SEMANTIC],
},
{
path: '/Metric',
name: 'metric',
component: './SemanticModel/Metric',
envEnableList: [ENV_KEY.SEMANTIC],
},
{
path: '/login',
name: 'login',
layout: false,
hideInMenu: true,
component: './Login',
},
{
path: '/',
redirect: APP_TARGET === 'inner' ? '/semanticModel' : '/chat',
envRedirect: {
[ENV_KEY.CHAT]: '/chat',
[ENV_KEY.SEMANTIC]: '/semanticModel',
},
},
{
path: '/401',
component: './401',
},
];
export default ROUTES;