xiaoyi
2026-10-30 ae3ab0d376959cd8560e45dce24b6a8b1b39d162
src/components/form-create/components/use-api-select.tsx
@@ -246,6 +246,19 @@
          ...restAttrs
        } = attrs;
        // 人员选择器(UserSelect)默认开启模糊搜索:支持按姓名输入过滤
        const searchProps =
          option.name === 'UserSelect'
            ? {
                showSearch: true,
                optionFilterProp: 'label',
                filterOption: (input: string, opt: any) =>
                  String(opt?.label ?? '')
                    .toLowerCase()
                    .includes(String(input).toLowerCase()),
              }
            : {};
        if (props.multiple) {
          // fix:多写此步是为了解决 multiple 属性问题
          return (
@@ -255,6 +268,7 @@
              mode="multiple"
              onUpdate:value={onUpdateModelValue as any}
              value={modelValue as any}
              {...searchProps}
              {...restAttrs}
              // TODO @xingyu remote 对等实现, 还是说没作用
              // remote={props.remote}
@@ -276,6 +290,7 @@
            loading={loading.value}
            onUpdate:value={onUpdateModelValue as any}
            value={modelValue as any}
            {...searchProps}
            {...restAttrs}
            // TODO: @xingyu remote 对等实现, 还是说没作用
            // remote={props.remote}