<navbar home back text="付款"></navbar>
<view style="height:{{navigationBarHeight}} "></view>
<view class='content' >
  <view class='head clearfix'>
    <text class='fl'>付款给{{merChant.merchantName}}</text>
    <image class='fr' src='{{merChant.merchantImgUrl}}' mode='widthFix'></image>
  </view>
  <text class='txt1'>金额</text>
  <view class='money'>
    <text class='icon'>¥</text>
    <input bindinput="bindKeyInput" disabled='{{showInput}}' class='num' type="digit" focus placeholder="" />
    <button bindtap='startAuth' hover-class='active'>确认付款</button>
  </view>
  <view class='model' wx:if="{{showModel}}">
    <view class='zhezhao'></view>
    <view class='card-model'>
      <view class='card-top'>
        余额不足，请选择其他消费卡支付<image bindtap='showModel' class='close' src='{{wmclose}}'></image>
      </view>
      <view class='card-content'>
        <scroll-view scroll-y style="height: 500rpx;" bindscroll="scroll" scroll-into-view="{{toView}}" scroll-top="{{scrollTop}}">
          <view wx:if="{{item.flag}}" class='card-items {{item.flag?"":"opcacity"}}' wx:for="{{cardList}}" wx:key="index" data-remainingAmount='{{item.remainingAmount/100}}' data-id="{{item.id}}" data-flags="check" bindtap='check'>
            <view class='card-items-left'>
              <view class='card-items-left-img'>
                <image src='{{item.coverImg}}'></image>
              </view>
              <view class='card-items-left-text'>{{item.id}}</view>
            </view>
            <view class='card-items-right'>
              <view class='card-items-right-text'>余额:{{item.remainingAmount/100}}元</view>
              <view class='card-items-right-radio' class='icons'>
                <image wx:if="{{item.id == ids&&item.flag}}" src='{{wmyes}}'  mode='widthFix'></image>
              </view>
            </view>
          </view>
          <view  wx:if='{{item.remainingAmount/100<inputValue||!item.flag}}' class='card-items {{item.flag?"":"opcacity"}}' wx:for="{{cardList}}" wx:key="index">
            <view class='card-items-left'>
              <view class='card-items-left-img'>
                <image src='{{item.coverImg}}'></image>
              </view>
              <view class='card-items-left-text'>{{item.id}}</view>
            </view>
            <view class='card-items-right'>
              <view class='card-items-right-text'>余额:{{item.remainingAmount/100}}元</view>
            </view>
          </view>
        </scroll-view>
      </view>
      <view class='card-bottom'>
        <button type='primary' bindtap='suretoPay' data-sure='sure' class='checkcard-box' wx:if="{{arrays.length>0}}">确认付款</button>
        <button type='primary' bindtap='gotonewcard' class='checkcard-box' wx:if="{{arrays.length==0}}">购买新卡</button>
      </view>
    </view>
  </view>
</view>