fix: 配置字段,显示一对一的关联表的筛选项
This commit is contained in:
parent
8c71fbd5a2
commit
7f43de4e23
@ -483,7 +483,7 @@ const getItem = (
|
|||||||
getCollectionFields,
|
getCollectionFields,
|
||||||
processedCollections: string[],
|
processedCollections: string[],
|
||||||
) => {
|
) => {
|
||||||
if (field.interface === 'm2o') {
|
if (['m2o', 'obo'].includes(field.interface)) {
|
||||||
if (processedCollections.includes(field.target)) return null;
|
if (processedCollections.includes(field.target)) return null;
|
||||||
|
|
||||||
const subFields = getCollectionFields(field.target);
|
const subFields = getCollectionFields(field.target);
|
||||||
@ -535,7 +535,7 @@ const getItem = (
|
|||||||
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 = ['m2o'];
|
const interfaces = ['m2o', 'obo'];
|
||||||
const groups = fields
|
const groups = fields
|
||||||
?.filter((field) => {
|
?.filter((field) => {
|
||||||
return interfaces.includes(field.interface);
|
return interfaces.includes(field.interface);
|
||||||
|
Loading…
Reference in New Issue
Block a user