mirror of
https://github.com/tencentmusic/supersonic.git
synced 2026-04-19 04:44:19 +08:00
(feature)(webapp) add query mode in parse tip and change query modes query to METRIC and TAG (#425)
This commit is contained in:
@@ -126,10 +126,10 @@ export const layout: RunTimeLayoutConfig = (params) => {
|
||||
rightContentRender: () => <RightContent />,
|
||||
disableContentMargin: true,
|
||||
menuHeaderRender: undefined,
|
||||
childrenRender: (dom) => {
|
||||
childrenRender: (dom: any) => {
|
||||
return (
|
||||
<div
|
||||
style={{ height: location.pathname.includes('chat') ? 'calc(100vh - 48px)' : undefined }}
|
||||
style={{ height: location.pathname.includes('chat') ? 'calc(100vh - 56px)' : undefined }}
|
||||
>
|
||||
{dom}
|
||||
{history.location.pathname !== '/chat' && !isMobile && (
|
||||
|
||||
@@ -241,7 +241,7 @@ const ToolModal: React.FC<Props> = ({ editTool, onSaveTool, onCancel }) => {
|
||||
</FormItem>
|
||||
)}
|
||||
{toolType === AgentToolTypeEnum.RULE && (
|
||||
<FormItem name="queryModes" label="查询模式">
|
||||
<FormItem name="queryTypes" label="查询模式">
|
||||
<Select
|
||||
placeholder="请选择查询模式"
|
||||
options={QUERY_MODE_LIST}
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
.agent {
|
||||
height: calc(100vh - 48px);
|
||||
height: calc(100vh - 56px);
|
||||
}
|
||||
|
||||
.agentsSection {
|
||||
padding: 20px 40px;
|
||||
background: #fff;
|
||||
height: calc(100vh - 48px);
|
||||
height: calc(100vh - 56px);
|
||||
|
||||
.sectionTitle {
|
||||
font-size: 24px;
|
||||
|
||||
@@ -11,17 +11,6 @@ export enum AgentToolTypeEnum {
|
||||
INTERPRET = 'INTERPRET'
|
||||
}
|
||||
|
||||
export enum QueryModeEnum {
|
||||
ENTITY_DETAIL = 'ENTITY_DETAIL',
|
||||
ENTITY_LIST_FILTER = 'ENTITY_LIST_FILTER',
|
||||
ENTITY_ID = 'ENTITY_ID',
|
||||
METRIC_ENTITY = 'METRIC_ENTITY',
|
||||
METRIC_FILTER = 'METRIC_FILTER',
|
||||
METRIC_GROUPBY = 'METRIC_GROUPBY',
|
||||
METRIC_MODEL = 'METRIC_MODEL',
|
||||
METRIC_ORDERBY = 'METRIC_ORDERBY'
|
||||
}
|
||||
|
||||
export const AGENT_TOOL_TYPE_LIST = [
|
||||
{
|
||||
label: '规则语义解析',
|
||||
@@ -41,38 +30,19 @@ export const AGENT_TOOL_TYPE_LIST = [
|
||||
},
|
||||
]
|
||||
|
||||
export enum QueryModeEnum {
|
||||
METRIC = 'METRIC',
|
||||
TAG = 'TAG'
|
||||
}
|
||||
|
||||
export const QUERY_MODE_LIST = [
|
||||
{
|
||||
label: '实体明细(查询维度信息)',
|
||||
value: QueryModeEnum.ENTITY_DETAIL
|
||||
label: '指标模式',
|
||||
value: QueryModeEnum.METRIC
|
||||
},
|
||||
{
|
||||
label: '实体圈选',
|
||||
value: QueryModeEnum.ENTITY_LIST_FILTER
|
||||
},
|
||||
{
|
||||
label: '实体查询(按ID查询)',
|
||||
value: QueryModeEnum.ENTITY_ID
|
||||
},
|
||||
{
|
||||
label: '指标查询(带实体)',
|
||||
value: QueryModeEnum.METRIC_ENTITY
|
||||
},
|
||||
{
|
||||
label: '指标查询(带条件)',
|
||||
value: QueryModeEnum.METRIC_FILTER
|
||||
},
|
||||
{
|
||||
label: '指标查询(按维度分组)',
|
||||
value: QueryModeEnum.METRIC_GROUPBY
|
||||
},
|
||||
{
|
||||
label: '指标查询(不带条件)',
|
||||
value: QueryModeEnum.METRIC_MODEL
|
||||
},
|
||||
{
|
||||
label: '按指标排序',
|
||||
value: QueryModeEnum.METRIC_ORDERBY
|
||||
label: '标签模式',
|
||||
value: QueryModeEnum.TAG
|
||||
}
|
||||
];
|
||||
|
||||
|
||||
Reference in New Issue
Block a user