fix: field component options appears in non-association interface (#1220)
This commit is contained in:
parent
a951d49f55
commit
29e83515b9
@ -11,7 +11,12 @@ export const useFieldComponentOptions = () => {
|
|||||||
const { t } = useTranslation();
|
const { t } = useTranslation();
|
||||||
|
|
||||||
const fieldComponentOptions = useMemo(() => {
|
const fieldComponentOptions = useMemo(() => {
|
||||||
if (!collectionField?.interface) return;
|
if (
|
||||||
|
!['o2o', 'oho', 'obo', 'o2m', 'linkTo', 'm2o', 'm2m']
|
||||||
|
.includes(collectionField.interface)
|
||||||
|
)
|
||||||
|
return;
|
||||||
|
|
||||||
switch (collectionField.interface) {
|
switch (collectionField.interface) {
|
||||||
case 'o2m':
|
case 'o2m':
|
||||||
return [
|
return [
|
||||||
|
Loading…
Reference in New Issue
Block a user