compatible with old enums (#5219)

* compatible with old enums\

* add id
This commit is contained in:
heheer
2025-07-16 13:09:16 +08:00
committed by GitHub
parent 4e2ab1f63b
commit f000fbb19d
12 changed files with 40 additions and 7 deletions

View File

@@ -341,7 +341,13 @@ export const toolSetData2FlowNodeIO = ({
};
export const formatEditorVariablePickerIcon = (
variables: { key: string; label: string; type?: `${VariableInputEnum}`; required?: boolean }[]
variables: {
id: string;
key: string;
label: string;
type?: `${VariableInputEnum}`;
required?: boolean;
}[]
): EditorVariablePickerType[] => {
return variables.map((item) => ({
...item,

View File

@@ -1,6 +1,7 @@
import type { WorkflowIOValueTypeEnum } from '@fastgpt/global/core/workflow/constants';
export type EditorVariablePickerType = {
id: string;
key: string;
label: string;
required?: boolean;