feat: pass fieldsChanged into the handleValuesChange callback function (#5968)

* fieldsChanged(已被改变值的字段名)将传入handleValuesChange回调函数
This commit is contained in:
Netfan
2025-04-16 11:29:01 +08:00
committed by GitHub
parent 3318d76bab
commit 0936861da1
4 changed files with 48 additions and 8 deletions

View File

@@ -42,6 +42,9 @@ const [BaseForm, baseFormApi] = useVbenForm({
fieldMappingTime: [['rangePicker', ['startTime', 'endTime'], 'YYYY-MM-DD']],
// 提交函数
handleSubmit: onSubmit,
handleValuesChange(_values, fieldsChanged) {
message.info(`表单以下字段发生变化:${fieldsChanged.join('')}`);
},
// 垂直布局label和input在不同行值为vertical
// 水平布局label和input在同一行