问题描述
当用户使用元素加号点击按钮时,我需要在按钮上设置延迟(加载)
<el-button type="primary" :loading="delay_search_button" icon="el-icon-search" size="small" style="width: 14.5vh" @click="searchButton"></el-button>
methods: {
searchButton () {
this.delay_search_button = true;
setTimeout(() => {
this.delay_search_button = false;
console.log(this.delay_search_button)
},2000);
},},
但是这段代码不起作用,我做错了什么?
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)