Blogger Information
Blog 19
fans 0
comment 1
visits 43814
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
element ui select 后台赋值后无法选中的问题
好想睡懒觉的博客
Original
2108 people have browsed it

1、在el-select 加一个change 事件刷新一下就可以了,目前用得还可以 没报什么错

@change="refreshStatus"

<el-form-item>
   <el-select v-model="form.status" placeholder="请选择" @change="refreshStatus">
       <el-option
           v-for="item in status_list"
           :key="item.value"
           :label="item.label"
           :value="item.value">
       </el-option>
   </el-select>
</el-form-item>


2、在methods{} 方法加上

//select 后台赋值后无法选中的问题
refreshStatus(){
   this.$forceUpdate()
},


ok!

Statement of this Website
The copyright of this blog article belongs to the blogger. Please specify the address when reprinting! If there is any infringement or violation of the law, please contact admin@php.cn Report processing!
All comments Speak rationally on civilized internet, please comply with News Comment Service Agreement
0 comments
Author's latest blog post