<el-form-item label="被叫号码" required>
<el-select
v-model.trim="callOutForm.calloutNo"
filterable
style="margin-right: 15%;width:80%;"
clearable
@blur="selectBlur"
@clear="selectClear"
@change="selectChange"
>
<el-option
v-for="item in callerNolist1"
:key="item.dictValue"
:label="item.dictValue"
:value="item.dictValue"
/>
</el-select>
</el-form-item>
// 实现select选择框可下拉单选,也可输入赋值
selectBlur(e) {
// 意见类型
if (e.target.value !== "") {
console.log(e.target.value);
this.callOutForm.calloutNo = e.target.value;
this.$forceUpdate(); // 强制更新
}
},
selectClear() {
this.callOutForm.calloutNo = "";
this.$forceUpdate();
},
selectChange(val) {
this.callOutForm.calloutNo = val;
this.$forceUpdate();
},
vue中选择框设置可编辑可选择状态
最新推荐文章于 2024-02-29 19:48:17 发布