<!--pages/kabaw/mykabaw.wxml-->
<view class="main">
  <view class="top-tab">
    <view class="tab {{lindex==0?'native':''}}" bindtap="thisone" data-index="0">待使用</view>
    <view class="tab {{lindex==1?'native':''}}" bindtap="thisone" data-index="1">已失效</view>
  </view>
  <view class="qlist" wx:if="{{lindex==0}}">
      <view class="nomore" wx:if="{{mycoupon.length==0}}">暂无数据</view>
      <view class="quan" wx:for="{{mycoupon}}" bindtap="godetail" data-way="use" data-item="{{item.everyday_coupon_id}}">
        <view class="left">
          <image src="{{item.pic_url}}" class="quan-img" mode="aspectFill"></image>
        </view>
        <view class="right">
          <view class="qname">{{item.name}}</view>
          <view class="store">店铺：{{item.shop_name}}</view>
          <!-- <view class="num">数量：10</view> -->
          <view class="use">剩余{{item.count?item.count:0}}张</view>
        </view>
        <view class="gouser">立即使用</view>
      </view>
    </view>
    <view class="qlist" wx:if="{{lindex==1}}">
      <view class="nomore" wx:if="{{mycoupon.length==0}}">暂无数据</view>
      <view class="quan" wx:for="{{mycoupon}}" bindtap="godetail" data-way="use" data-item="{{item.everyday_coupon_id}}">
        <view class="left">
          <image src="{{item.pic_url}}" class="quan-img" mode="aspectFill"></image>
        </view>
        <view class="right">
          <view class="qname">{{item.name}}</view>
          <view class="store">店铺：{{item.shop_name}}</view>
          <!-- <view class="num" >数量：10</view> -->
          <view class="use" >已使用{{item.count?item.count:0}}张</view>
          <image class="shixiao" src="../../images/shixiao.png"></image>
        </view>
        <!-- <view class="gouser"></view> -->
      </view>
    </view>
    <view class="qlist" wx:if="{{lindex==2}}">
      <view class="nomore" wx:if="{{mycoupon.length==0}}">暂无数据</view>
      <view class="quan" wx:for="{{mycoupon}}" bindtap="godetail" data-way="no" data-item="{{item.everyday_coupon_id}}">
        <view class="left" >
          <image src="{{item.pic_url}}" class="quan-img" mode="aspectFill"></image>
        </view>
        <view class="right">
          <view class="qname">{{item.name}}</view>
          <view class="store">店铺：{{item.shop_name}}</view>
          <!-- <view class="num" >数量：10</view> -->
          <view class="use" >{{item.use_limit==1?'每日限使用1次':'每日不限使用次数'}}</view>
        </view>
        <!-- <view class="gouser"></view> -->
      </view>
    </view>
</view>
