<view class="vq-container">
  <block a:if="{{ !status }}">
    <view style="height:28rpx;"></view>
    <auth-popup id="authPopup" onAuthResult="authResult"/>
    <view class="auth-layout">
      <view class="title">您的拜访申请已通过，请获取访客二维码通行。</view>
      <view class="submit-btn" hover-class="btn-hover" hover-stay-time="100" onTap="authClick">获取访客二维码</view>
    </view>
  </block>
  <block a:elif="{{ status === 1 && selectIndex >= 0 }}">
    <view class="qrcode-layout">
      <van-popup
        show='{{ popupShow }}'
        position='center'
        round
        onClose="onPopupClose"
        overlay-style="background:rgba(0,0,0,0.4);"
        custom-style='height: auto;width:640rpx;'>
        <view class="popup-layout" style="padding: 56rpx 40rpx 48rpx;overflow: hidden;">
          <view class="popup-title">{{ popupTitle || '' }}</view>
          <image mode="scaleToFill" style="width:480rpx;height:480rpx;margin-top:24rpx;" src="{{ popupImagePath }}" />
          <view class="close-btn" hover-stay-time="100" onTap="onPopupClose">确定</view>
        </view>
      </van-popup>
      <view class="qrcode_head">
        <view class="head_top">
          <picker title="选择" range-key="adminName" onChange="onQrcodeSelectChange" value="{{selectIndex}}" range="{{qrcodeList}}">
            <view style="display: flex;align-items: center;">
              <view>地点：</view>
              <view>{{ qrcodeList[selectIndex].adminName }}</view>
              <van-icon name="arrow-down" size="18px" style="margin-left:20rpx;margin-top:4rpx;" />
            </view>
          </picker>
        </view>
        <view class="head_bottom">
          <view style="flex:1 1 auto;">拜访人：{{ qrcodeList[selectIndex].name	 }}</view>
          <view style="flex:1 1 auto;">受访人：{{ qrcodeList[selectIndex].visiteeName }}</view>
        </view>
      </view>
      <view class="qrcode_item" a:if="{{ qrcodeList[selectIndex].ethQrcode }}">
        <view class="item-left">单机版二维码</view>
        <view class="item-right" onTap="qrcodeSelectClick" data-type="0">
          <image mode="scaleToFill" style="width:280rpx;height:280rpx;" src="{{ qrcodeList[selectIndex].ethQrcodePath }}" />
          <canvas
            class='canvas-code'
            style='background:#fff;width:176px;height: 176px; display:block; left:-800rpx;position:absolute;'
            id='qrcode1'>
          </canvas>
        </view>
      </view>
      <view class="qrcode_item" a:if="{{ qrcodeList[selectIndex].vguangQrcode }}">
        <view class="item-left">微光互联二维码</view>
        <view class="item-right" onTap="qrcodeSelectClick" data-type="1">
          <image mode="scaleToFill" style="width:280rpx;height:280rpx;" src="{{ qrcodeList[selectIndex].vguangQrcodePath }}" />
          <canvas
            class='canvas-code'
            style='background:#fff;width:176px;height: 176px; display:block; left:-800rpx;position:absolute;'
            id='qrcode2'>
          </canvas>
        </view>
      </view>
    </view>
  </block>
</view>