解决h5不触发swiper的change事件
This commit is contained in:
parent
e6bd059d9f
commit
0a2ca00069
|
@ -131,7 +131,14 @@ export default {
|
|||
this.switchTab(this.tabIndex);
|
||||
}
|
||||
if (this.getTabIndex != this.tabIndex) {
|
||||
// #ifdef H5
|
||||
setTimeout(() => {
|
||||
this.tabIndex = this.getTabIndex;
|
||||
}, 10);
|
||||
// #endif
|
||||
// #ifndef H5
|
||||
this.tabIndex = this.getTabIndex;
|
||||
// #endif
|
||||
}
|
||||
},
|
||||
onReady() {},
|
||||
|
|
|
@ -119,7 +119,14 @@ export default {
|
|||
this.switchTab(this.tabIndex);
|
||||
}
|
||||
if (this.orderTabIndex != this.tabIndex) {
|
||||
// #ifdef H5
|
||||
setTimeout(() => {
|
||||
this.tabIndex = this.orderTabIndex;
|
||||
}, 10);
|
||||
// #endif
|
||||
// #ifndef H5
|
||||
this.tabIndex = this.orderTabIndex;
|
||||
// #endif
|
||||
}
|
||||
},
|
||||
onReady() {},
|
||||
|
|
Loading…
Reference in New Issue