|
|
@@ -23,6 +23,31 @@ Component({ |
|
|
|
* 组件的方法列表 |
|
|
|
*/ |
|
|
|
methods: { |
|
|
|
getList1() { |
|
|
|
let that = this; |
|
|
|
Http.get({ |
|
|
|
url: config.api.couponChannelList, |
|
|
|
data: { |
|
|
|
pageNum: 1, |
|
|
|
pageSize: 5, |
|
|
|
targetAd: 6 |
|
|
|
} |
|
|
|
}).then(res => { |
|
|
|
that.setData({ |
|
|
|
list: res.data.list, |
|
|
|
total: res.data.total |
|
|
|
}); |
|
|
|
}) |
|
|
|
.catch(err => { |
|
|
|
console.log(err) |
|
|
|
wx.showToast({ |
|
|
|
title: err.errMsg, |
|
|
|
icon: 'none', |
|
|
|
duration: 2000, |
|
|
|
mask: false |
|
|
|
}); |
|
|
|
}) |
|
|
|
}, |
|
|
|
gotomore: function() { |
|
|
|
wx.navigateTo({ |
|
|
|
url: "/pages/bargain/bargain" |
|
|
@@ -69,30 +94,5 @@ Component({ |
|
|
|
if (app.globalData.token && app.globalData.token != null) { |
|
|
|
app.couponChannelListCallback(app.globalData.token); |
|
|
|
} |
|
|
|
}, |
|
|
|
getList1(){ |
|
|
|
let that = this; |
|
|
|
Http.get({ |
|
|
|
url: config.api.couponChannelList, |
|
|
|
data: { |
|
|
|
pageNum: 1, |
|
|
|
pageSize: 5, |
|
|
|
targetAd: 6 |
|
|
|
} |
|
|
|
}).then(res => { |
|
|
|
that.setData({ |
|
|
|
list: res.data.list, |
|
|
|
total: res.data.total |
|
|
|
}); |
|
|
|
}) |
|
|
|
.catch(err => { |
|
|
|
console.log(err) |
|
|
|
wx.showToast({ |
|
|
|
title: err.errMsg, |
|
|
|
icon: 'none', |
|
|
|
duration: 2000, |
|
|
|
mask: false |
|
|
|
}); |
|
|
|
}) |
|
|
|
} |
|
|
|
}); |