Commit 9c2b654a by 谢中龙

Merge branch '711_prod' into '711_dev_7.5.0'

711 prod

See merge request !178
parents 196d7cd6 64423d8b
......@@ -158,43 +158,33 @@ wxService.page({
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
// 可使用 0 or 已失效 1
const { currentTab, pageNo, pageSize, totalPages, invalidPageNo,invalidTotalPages } = this.data
if(currentTab == 0) {
if ( pageNo < totalPages) {
this.setData({
pageNo: pageNo + 1,
})
// status 1
this.getCouponList(this.data.pageNo,pageSize, 1)
} else {
this.setData({
noMoreCoupon: true
})
}
//scoll view 触到底部
onBottom() {
const { currentTab, pageNo, pageSize, totalPages, invalidPageNo, invalidTotalPages } = this.data
if (currentTab == 0) {
if (pageNo < totalPages) {
this.setData({
pageNo: pageNo + 1,
})
// status 1
this.getCouponList(this.data.pageNo, pageSize, 1)
} else {
this.setData({
noMoreCoupon: true
})
}
} else {
// if ( invalidPageNo < invalidTotalPages) {
// this.setData({
// invalidPageNo: invalidPageNo + 1,
// })
// // status 0
// this.getCouponList(this.data.invalidPageNo, pageSize, 0)
// } else {
// this.setData({
// noMoreCouponInvalid: true
// })
// }
this.setData({
noMoreCouponInvalid: true
})
}
},
onPullDownRefresh: function () {},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
},
})
\ No newline at end of file
......@@ -7,7 +7,7 @@
<!--bindchange="swiperTab"-->
<swiper current="{{currentTab}}" duration="300" bindchange="swiperTab">
<swiper-item>
<scroll-view scroll-y wx:if="{{couponList.length}}">
<scroll-view scroll-y wx:if="{{couponList.length}}" bindscrolltolower="onBottom">
<view class='coupon-wrap'>
<view
class='coupon-list'
......@@ -31,7 +31,6 @@
</view>
</view>
</view>
<no-more wx:if="{{noMoreCoupon}}" />
</scroll-view>
<view class='empty-wrap' wx:if="{{!couponList.length}}">
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment