El-Select组件实现模糊查询与失焦赋值
(也适用allow-create
创建新的条目)
<el-select v-model="selectForm.name" placeholder=" " clearable filterable @blur="$event => selectFormBlur($event, 'chargemanCode')"><el-option v-for="item in option" :key="item.code" :value="item.code" :label="item.name"></el-option>
</el-select>selectFormBlur(e, name) {if (e.target.value.trim() !== '') { this.$set(this.selectForm, name, e.target.value);}
},