<el-select v-model="item.memo" placeholder="" clearable allow-create filterable :filter-method="dataFilter" style="width: 100px">
<el-option v-for="it in channelList" :key="it.rid" :label="it.prop_val" :value="it.rid" />
</el-select>
allow-create 可以创建新的条目 filterable和:filter-method 开启搜索功能和自定义方法
dataFilter(val) {
if (val) {
let value = val.toUpperCase();
this.channelList = this.channelCopy.filter((item) => {
if(item.py.indexOf(value)>-1 || item.administration_name.indexOf(value)>-1){
return true
}
})
} else {
this.channelList = this.channelCopy;
}
},