fix: sub-form(popover)in sub-table value mutual influence (#3164)

This commit is contained in:
katherinehhh 2023-12-10 19:21:41 +08:00 committed by GitHub
parent 7bb50fea34
commit a7176770fb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View File

@ -64,7 +64,7 @@ export const AssociationFieldProvider = observer(
setLoading(false); setLoading(false);
return; return;
} }
if (['Nester', 'PopoverNester'].includes(currentMode)) { if (['Nester'].includes(currentMode)) {
if (['belongsTo', 'hasOne'].includes(collectionField.type)) { if (['belongsTo', 'hasOne'].includes(collectionField.type)) {
field.value = {}; field.value = {};
} else if (['belongsToMany', 'hasMany'].includes(collectionField.type)) { } else if (['belongsToMany', 'hasMany'].includes(collectionField.type)) {

View File

@ -71,7 +71,7 @@ export const InternaPopoverNester = observer(
> >
<ReadPrettyInternalViewer {...titleProps} /> <ReadPrettyInternalViewer {...titleProps} />
</div> </div>
<EditOutlined style={{ display: 'inline-flex', marginLeft: '5px' }} /> <EditOutlined style={{ display: 'inline-flex', margin: '5px' }} />
</span> </span>
</PopoverWithStopPropagation> </PopoverWithStopPropagation>
{visible && ( {visible && (