mirror of
https://github.com/csunny/DB-GPT.git
synced 2025-09-12 12:37:14 +00:00
feat(web): Add DAG variables to web flow (#1981)
Co-authored-by: Fangyin Cheng <staneyffer@gmail.com> Co-authored-by: 谨欣 <echo.cmy@antgroup.com> Co-authored-by: yanzhiyong <932374019@qq.com> Co-authored-by: 严志勇 <yanzhiyong@tiansuixiansheng.com>
This commit is contained in:
@@ -12,6 +12,7 @@ export type IFlowUpdateParam = {
|
||||
uid?: string;
|
||||
flow_data?: IFlowData;
|
||||
state?: FlowState;
|
||||
variables?: IVariableItem[];
|
||||
};
|
||||
|
||||
export type IFlowRefreshParams = {
|
||||
@@ -169,8 +170,9 @@ export type IFlowDataViewport = {
|
||||
};
|
||||
|
||||
export type IFlowData = {
|
||||
nodes: Array<IFlowDataNode>;
|
||||
edges: Array<IFlowDataEdge>;
|
||||
nodes: IFlowDataNode[];
|
||||
edges: IFlowDataEdge[];
|
||||
variables?: IVariableItem[];
|
||||
viewport: IFlowDataViewport;
|
||||
};
|
||||
|
||||
@@ -200,3 +202,54 @@ export type IUploadFileResponse = {
|
||||
bucket: string;
|
||||
uri?: string;
|
||||
};
|
||||
|
||||
export type IGetKeysRequestParams = {
|
||||
user_name?: string;
|
||||
sys_code?: string;
|
||||
category?: string;
|
||||
};
|
||||
|
||||
export type IGetKeysResponseData = {
|
||||
key: string;
|
||||
label: string;
|
||||
description: string;
|
||||
value_type: string;
|
||||
category: string;
|
||||
scope: string;
|
||||
scope_key: string | null;
|
||||
};
|
||||
|
||||
export type IGetVariablesByKeyRequestParams = {
|
||||
key: string;
|
||||
scope: string;
|
||||
scope_key?: string;
|
||||
user_name?: string;
|
||||
sys_code?: string;
|
||||
page?: number;
|
||||
page_size?: number;
|
||||
};
|
||||
|
||||
export type IGetVariablesByKeyResponseData = {
|
||||
items: IVariableItem[];
|
||||
total_count: number;
|
||||
total_pages: number;
|
||||
page: number;
|
||||
page_size: number;
|
||||
};
|
||||
|
||||
export type IVariableItem = {
|
||||
key: string;
|
||||
label: string;
|
||||
description: string | null;
|
||||
value_type: string;
|
||||
category: string;
|
||||
scope: string;
|
||||
scope_key: string | null;
|
||||
name: string;
|
||||
value: string;
|
||||
enabled: boolean;
|
||||
user_name: string | null;
|
||||
sys_code: string | null;
|
||||
id: number;
|
||||
[key: string]: any;
|
||||
};
|
||||
|
Reference in New Issue
Block a user