Commit c830b6a5 by luyt

feat:首页滑动

1 parent 443e547d
...@@ -248,8 +248,11 @@ Component({ ...@@ -248,8 +248,11 @@ Component({
// wx.$eventbus.emit('evt_page_index',idx) // wx.$eventbus.emit('evt_page_index',idx)
//判断当前路径 //判断当前路径
let currentUrl = this.getCurrentPageUrl(); let currentUrl = this.getCurrentPageUrl();
console.log('currentUrl: ', currentUrl);
if (currentUrl == "/pages/tab/index/index") { if (currentUrl == "/pages/tab/index/index") {
console.log(123546)
wx.pageScrollTo({ scrollTop: imgTopArr[idx] - stickyTop + 88 + 34 }); wx.pageScrollTo({ scrollTop: imgTopArr[idx] - stickyTop + 88 + 34 });
// wx.pageScrollTo({ scrollTop: imgTopArr[idx] - stickyTop });
} else { } else {
wx.pageScrollTo({ scrollTop: imgTopArr[idx] - stickyTop }); wx.pageScrollTo({ scrollTop: imgTopArr[idx] - stickyTop });
} }
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!