收藏
回答

onReachBottom 安卓端不触发

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


回答关注问题邀请回答
收藏

2 个回答

  • A  陈佳辉🏃跑步走
    A 陈佳辉🏃跑步走
    2018-10-17

    所有安卓机型 可关注非诚勿撩和鹿鹿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)



    },


    2018-10-17
    有用
    回复 1
  • 疯狂的小辣椒
    疯狂的小辣椒
    2018-10-17

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

    2018-10-17
    有用
    回复
登录 后发表内容