html52.com
我爱小程序-开发者交流社区

onReachBottom 安卓端不触发

线上项目刚出现的问题,求官方解答


网友回复

A 跑步走?:

所有安卓机型 可关注非诚勿撩和鹿鹿Lite 两款小程序 ios可以滑动,安卓滑不了了

//上滑加载更多

onReachBottom: function () {

var that = this;


var systemp = that.data.systemmsg

if (systemp.indexOf("iOS") != -1) {

wx.pageScrollTo({

scrollTop: 0,

duration: 0

})

} else {

wx.pageScrollTo({

scrollTop: 0,

duration: 300

})

}


num++;

if (num < that.data.peoplelist.length) {


that.setData({

isShowId: that.data.peoplelist[num],

// huashow: false,

});

var token = wx.getStorageSync('token');

var user_id = that.data.peoplelist[num - 1].id;


if (token == '') {

that.setData({

videoplay: false,

status: 1

})

//that.markAsRead();

} else {

server.post(server.like_reject_others, {

token: token,

user_id: user_id,

status: 2,

}).then(res => {

if (res.data.key == 1000) {


that.setData({

videoplay: false,

status: 1

})

//that.markAsRead();

} else if (res.data.key == 1001) {

that.setData({

videoplay: false,

status: 1

})

//that.markAsRead();


} else if (res.data.key == 1200) {

that.setData({


modal2Hidden: true,

modalHiddenb: true,

})

} else if (res.data.key == 1245) {

wx.showModal({

content: res.data.message,

showCancel: false,

});

return false;

} else {

wx.showModal({

content: res.data.message,

showCancel: false,

});


//that.markAsRead()

}

})

}

var systemp= that.data.systemmsg

if (systemp.indexOf("iOS") != -1)  {

wx.pageScrollTo({

scrollTop: 0,

duration: 0

})

}else{

wx.pageScrollTo({

scrollTop: 0,

duration: 300

})

}

} else {


num = that.data.peoplelist.length - 1

that.reloadCurrent();

// feedbackApi.showToast({ title: '没有更多了呦!' })


var systemp = that.data.systemmsg


if (systemp.indexOf("iOS") != -1) {

wx.pageScrollTo({

scrollTop: 0,

duration: 0

})

} else {

wx.pageScrollTo({

scrollTop: 0,

duration: 300

})

}


}

console.log(num)

console.log(that.data.peoplelist.length)



},


娇华:

你好,请提供一下出现问题的机型和微信版本,以及能复现问题的简单代码片段(https://developers.weixin.qq.com/miniprogram/dev/devtools/minicode.html)。

评论 抢沙发

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址

真正的个人免签约支付接口

云免签H5支付