mirror of
https://github.com/nocobase/nocobase
synced 2024-11-15 12:40:50 +00:00
fix(select-component): invalid mode
This commit is contained in:
parent
46c736d7d3
commit
cd2340ecd0
@ -70,7 +70,10 @@ const filterOption = (input, option) => (option?.label ?? '').toLowerCase().incl
|
|||||||
const InternalSelect = connect(
|
const InternalSelect = connect(
|
||||||
(props: Props) => {
|
(props: Props) => {
|
||||||
const { objectValue, value, ...others } = props;
|
const { objectValue, value, ...others } = props;
|
||||||
const mode = props.mode || props.multiple ? 'multiple' : undefined;
|
let mode: any = props.multiple ? 'multiple' : props.mode;
|
||||||
|
if (mode === 'links') {
|
||||||
|
mode = undefined;
|
||||||
|
}
|
||||||
const toValue = (v) => {
|
const toValue = (v) => {
|
||||||
if (['multiple', 'tags'].includes(mode)) {
|
if (['multiple', 'tags'].includes(mode)) {
|
||||||
return v || [];
|
return v || [];
|
||||||
|
Loading…
Reference in New Issue
Block a user