mirror of
https://github.com/nocobase/nocobase
synced 2024-11-15 06:55:50 +00:00
fix: add new collection linakge disabled (#2198)
This commit is contained in:
parent
f567f887de
commit
5a8f3d1ae3
@ -1,7 +1,7 @@
|
||||
import { useMemo } from 'react';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
import { useCompile, useGetFilterOptions } from '../../../schema-component';
|
||||
import { FieldOption, Option } from '../type';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
|
||||
interface GetOptionsParams {
|
||||
depth: number;
|
||||
@ -27,7 +27,7 @@ const getChildren = (
|
||||
label: compile(option.title),
|
||||
depth,
|
||||
// TODO: 现在是通过组件的名称来过滤能够被选择的选项,这样的坏处是不够精确,后续可以优化
|
||||
disabled: schema?.['x-component'] !== option.schema?.['x-component'],
|
||||
disabled: schema && schema?.['x-component'] !== option.schema?.['x-component'],
|
||||
};
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user