Commit 1ea0731f542f4e17a66479d134734e0ecd31919b

Authored by ww
1 parent 2320e8ea

perf: product profile transform script add search function

... ... @@ -8,7 +8,9 @@
8 8 placeholder="请选择转换脚本"
9 9 v-model:value="selectScript.script"
10 10 style="width: 305px"
  11 + show-search
11 12 :options="selectOptions"
  13 + :filter-option="handleSearch"
12 14 allowClear
13 15 />
14 16 </div>
... ... @@ -113,6 +115,11 @@
113 115 const setFormData = (v) => {
114 116 selectScript.script = v?.scriptId;
115 117 };
  118 +
  119 + const handleSearch = (inputValue: string, option: Record<'label' | 'value', string>) => {
  120 + return option.label.includes(inputValue);
  121 + };
  122 +
116 123 defineExpose({
117 124 getFormData,
118 125 resetFormData,
... ...