fix: Merge form data with group data in EditModal
- Updated the logic in EditModal to merge the existing form data with the first item in groupData if available. This change ensures that relevant data from groupData is incorporated into the form, improving data accuracy and user experience during editing.
This commit is contained in:
parent
43707cb9a3
commit
f565b2d119
|
|
@ -679,7 +679,7 @@ export const EditModal: React.FC<EditModalProps> = ({ className }) => {
|
|||
(targetComponent as any)?.componentConfig?.columnName ||
|
||||
targetComponentId;
|
||||
|
||||
const currentFormData = groupData.length > 0 ? groupData[0] : formData;
|
||||
const currentFormData = groupData.length > 0 ? { ...formData, ...groupData[0] } : formData;
|
||||
const targetValue = currentFormData[fieldKey];
|
||||
|
||||
let isMatch = false;
|
||||
|
|
|
|||
Loading…
Reference in New Issue