mirror of
https://github.com/nocobase/nocobase
synced 2024-11-15 08:36:44 +00:00
fix: issue with fuzzy search support for association fields with string-type title field (#5611)
This commit is contained in:
parent
c4653cb784
commit
666c92d524
@ -82,8 +82,12 @@ const InternalRemoteSelect = connect(
|
|||||||
|
|
||||||
const operator = useMemo(() => {
|
const operator = useMemo(() => {
|
||||||
if (targetField?.interface) {
|
if (targetField?.interface) {
|
||||||
const initialOperator = getInterface(targetField.interface)?.filterable?.operators[0].value || '$includes';
|
const targetInterface = getInterface(targetField.interface);
|
||||||
return initialOperator !== '$eq' ? initialOperator : '$includes';
|
const initialOperator = targetInterface?.filterable?.operators[0].value || '$includes';
|
||||||
|
if (targetField.type === 'string') {
|
||||||
|
return '$includes';
|
||||||
|
}
|
||||||
|
return initialOperator;
|
||||||
}
|
}
|
||||||
return '$includes';
|
return '$includes';
|
||||||
}, [targetField]);
|
}, [targetField]);
|
||||||
|
Loading…
Reference in New Issue
Block a user