var that = this; skp = that.data.List.length var skp = that.data.List.length .log(skp) console.log(skp) now = const now = new Date(); wx.hideToast(); wx.hideToast(); (that.data.riqi === if (that.data.riqi === '今天出发') { // 转换今天现在的时间毫秒 nowTimestamp = now.getTime(); const nowTimestamp = now.getTime(); tomorrowStart = (now.getFullYear(), now.getMonth(), now.getDate() + , , , ).getTime(); const tomorrowStart = new Date(now.getFullYear(), now.getMonth(), now.getDate() + 1, 0, 0, 0).getTime(); listCollection = db.collection( const listCollection = db.collection('List') watcher = listCollection const watcher = listCollection .orderBy(, .orderBy('time', 'desc') .where({ .where({ : that.data.type, type: that.data.type, : _.gte(nowTimestamp).and(_.lt(tomorrowStart)) riqitime: _.gte(nowTimestamp).and(_.lt(tomorrowStart)) }) .skip(skp) .skip(skp) .watch({ .watch({ : onChange: function (snapshot) { post = snapshot.docs; var post = snapshot.docs; that.setData({ that.setData({ : that.data.List.concat(post).map( List: that.data.List.concat(post).map(maps => { maps.tim = that.formatTime(maps.time); maps.tim = that.formatTime(maps.time); maps.timses = that.formatTime1(maps.riqitime); maps.timses = that.formatTime1(maps.riqitime); maps.riqixiaoshi = that.riqixiaoshi(maps.time); maps.riqixiaoshi = that.riqixiaoshi(maps.time); maps; return maps; }) }); },}, : onError: function (err) {} }); }
没试过在watch上面加skip,不知道支不支持,试试楼上的方法写死看下
写死skip值,测试一下先。