image.png
    image.png

    分页加载的方法 是在请求的时候限制一下取到数据的个数:
    let urls = /1.1/classes/JobCook?limit=10&skip=1
    this.$u.get(urls).then(res=>{
    console.log(res);
    this.joblists = res.results
    })

    在限制数据的数量后 用onReachBottom 将之前的代码放进去就行
    onReachBottom() {
    console.log(‘触底了’);
    },

    下拉刷新的原理是通用的采用:
    onPullDownRefresh() {
    console.log(‘下拉刷新’);
    p=0
    this.joblist=[]
    this.loadData()
    },

    代码如下:
    image.png

    leanclond的文档:【https://leancloud.cn/docs/rest_api.html#hash-1876900988】