diff --git a/src/components/Form/src/hooks/useFormEvents.ts b/src/components/Form/src/hooks/useFormEvents.ts index 8a77cc63734..2112b7cc694 100644 --- a/src/components/Form/src/hooks/useFormEvents.ts +++ b/src/components/Form/src/hooks/useFormEvents.ts @@ -111,6 +111,10 @@ export function useFormEvents({ * @description: Set form value */ async function setFieldsValue(values: Recordable): Promise { + if (Object.keys(values).length === 0) { + return; + } + const fields = getAllFields(); // key 支持 a.b.c 的嵌套写法