mirror of
https://gitee.com/nocobase/nocobase.git
synced 2025-05-05 05:29:26 +08:00
fix: exclude 'attachmentURL' from associated form item filter (#6809)
This commit is contained in:
parent
5c2bd3c496
commit
db88e8301f
@ -599,9 +599,9 @@ const associationFieldToMenu = (
|
|||||||
export const useFilterAssociatedFormItemInitializerFields = () => {
|
export const useFilterAssociatedFormItemInitializerFields = () => {
|
||||||
const { name, fields } = useCollection_deprecated();
|
const { name, fields } = useCollection_deprecated();
|
||||||
const { getCollectionFields } = useCollectionManager_deprecated();
|
const { getCollectionFields } = useCollectionManager_deprecated();
|
||||||
const interfaces = ['o2o', 'oho', 'obo', 'm2o', 'm2m'];
|
const excludedInterfaces = ['attachmentURL'];
|
||||||
return fields
|
return fields
|
||||||
?.filter((field) => field.target && field.uiSchema && interfaces.includes(field.interface))
|
?.filter((field) => field.target && field.uiSchema && !excludedInterfaces.includes(field.interface))
|
||||||
.map((field) => associationFieldToMenu(field, field.name, name, getCollectionFields, []))
|
.map((field) => associationFieldToMenu(field, field.name, name, getCollectionFields, []))
|
||||||
.filter(Boolean);
|
.filter(Boolean);
|
||||||
};
|
};
|
||||||
|
Loading…
x
Reference in New Issue
Block a user