Skip to content

Commit 1aad576

Browse files
author
shuai
committed
fix: form check id
1 parent 7ed41c6 commit 1aad576

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

  • ui/src/components/SchemaForm/components

ui/src/components/SchemaForm/components/Check.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ const Index: FC<Props> = ({
3838
},
3939
};
4040
if (typeof onChange === 'function') {
41+
console.log('fieldName', fieldName, enumValues);
4142
onChange(state);
4243
}
4344
};
@@ -50,7 +51,7 @@ const Index: FC<Props> = ({
5051
inline
5152
type={type}
5253
name={fieldName}
53-
id={`form-${String(item)}`}
54+
id={`${fieldName}-${enumNames?.[index]}`}
5455
label={enumNames?.[index]}
5556
checked={fieldObject?.value?.[index] || false}
5657
feedback={fieldObject?.errorMsg}

0 commit comments

Comments
 (0)