商品列表数据源

console.log('商品列表数据源', res.data.products);
//如果是下拉刷新清空数据
// if (self.data.page == 1) {
// currentGoodsList = [];
//
let arr = self.data.goodList||[];
console.log('----------------------------------------')
console.log(arr)
console.log(self.data.goodList)
console.log('----------------------------------------')
let arr2 = arr.concat(currentGoodsList)
self.setData({
goodsList: arr2,
pageCount: res.data.pager.pageCount
},function(a,b){
console.log(a)
console.log(b)
});
//计算填充视图的高度
self.calcMessage();
console.log(currentGoodsList)
console.log(arr)

你可能感兴趣的:(商品列表数据源)