el-select的change事件绑定value
时间: 2023-10-13 10:02:05 浏览: 104
在el-select组件中,可以通过在html中添加@change="selectChange"来绑定change事件,并在对应的methods中编写selectChange方法。在selectChange方法中,参数val代表当前选中的值。根据引用的代码示例,如果el-select的v-model为selectModel,并且el-option的:value是一个对象,那么selectChange方法中的val就是当前选中的对象。<span class="em">1</span><span class="em">2</span>
#### 引用[.reference_title]
- *1* [【el-select change 事件和 remove-tag 事件参数如何绑定为对象】](https://blog.csdn.net/limuzhixing/article/details/122425621)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v92^chatsearchT3_1"}}] [.reference_item style="max-width: 50%"]
- *2* [vue绑定数字类型 value为数字的实例](https://download.csdn.net/download/weixin_38613173/13962881)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v92^chatsearchT3_1"}}] [.reference_item style="max-width: 50%"]
[ .reference_list ]
阅读全文