fix(subTable): fix 'association filedName in collectionName not found' error (#5402)

This commit is contained in:
Zeke Zhang 2024-10-13 12:31:44 +08:00 committed by GitHub
parent 6219bcbac5
commit 22ab8f1e78
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1509,7 +1509,8 @@ export const useAssociationNames = (dataSource?: string) => {
['hasOne', 'hasMany', 'belongsTo', 'belongsToMany', 'belongsToArray'].includes(collectionField.type);
// 根据联动规则中条件的字段获取一些 appends
if (s['x-linkage-rules']) {
// 需要排除掉子表格和子表单中的联动规则
if (s['x-linkage-rules'] && !isSubMode(s)) {
const collectAppends = (obj) => {
const type = Object.keys(obj)[0] || '$and';
const list = obj[type];