coupon.wxml 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. <view class="container">
  2. <header text="我的优惠券"></header>
  3. <scroll-view
  4. class="content"
  5. scroll-y="true"
  6. bindscrolltolower="onReachBottom"
  7. lower-threshold="50"
  8. refresher-enabled="true"
  9. refresher-triggered="{{refreshing}}"
  10. bindrefresherrefresh="onPullDownRefresh"
  11. >
  12. <!-- 有数据 -->
  13. <block wx:if="{{couponList.length > 0}}">
  14. <view class="card-box" wx:for="{{couponList}}" wx:key="index" bindtap="goPage">
  15. <image class="card-img" src="/static/image/yhq.png" mode="aspectFit"/>
  16. <view class="card-cont">
  17. <view class="card-cont-lf">{{item.typeText}}</view>
  18. <view class="card-cont-ri">
  19. <view>
  20. <view>{{item.name}}</view>
  21. <view class="pop-time">{{item.expireTime}}到期</view>
  22. </view>
  23. <view>
  24. <image class="card-cont-status" src="{{item.statusImg}}" mode="aspectFit"/>
  25. </view>
  26. </view>
  27. </view>
  28. </view>
  29. </block>
  30. <!-- 空状态 -->
  31. <van-empty wx:if="{{!loadingMore && couponList.length === 0}}" description="暂无数据" />
  32. </scroll-view>
  33. <!-- 分页到底提示 -->
  34. <view wx:if="{{!loadingMore && noMore && couponList.length > 0}}" class="loading">
  35. 没有更多数据了
  36. </view>
  37. </view>