<!-- 申请开店 -->
<!--pages/openAShop/openAShop.wxml-->

<view class="apple-for-ashop">
  <view wx:if="{{auditRemarks}}" class="audit-remark">审核失败：{{auditRemarks}}</view>
  <!-- 店铺信息 -->
  <form class="msg-box">
    <view class="msg-tit">
      <view class="shop-icon">
        <image src="../../images/icon/shop-icon.png"></image>
      </view>
      <view class="shop-msg-tit">店铺信息</view>
    </view>
    <!-- 店铺名称 -->
    <view class="msg-cont-box">
      <label class="cont-txt">
        <text class="red">*</text>店铺名称</label>
      <input type="text" class="cont-int" bindinput="bindShopNameInt" value="{{shopNameValue}}" maxlength="10" placeholder="输入店铺名称，2-10字"></input>
    </view>

    <!-- 店铺描述 -->
    <view class="msg-cont-box">
      <label class="cont-txt align-top">
        <text class="red">*</text>店铺描述</label>
      <textarea type="text" bindinput="bindShopDescribeInt" value="{{shopDescribeValue}}" class="cont-int cont-textarea" maxlength="200" placeholder="填写店铺描述，10-200字"></textarea>
    </view>
    <!-- logo -->
    <view class="msg-cont-box">
      <label class="cont-txt">
        <text class="red">*</text>店铺Logo</label>
      <!-- 上传文件 -->
      <view class="upload-files align-top">
        <view class="upload-tips">上传店铺Logo</view>
        <!-- 预览图片 -->
        <view class="preview-img-box preview-logo" wx:if="{{logoImg.url}}">
          <image class="preview-img" src="{{logoImg.url}}" mode="aspectFill" data-idx="{{idx}}"></image>
          <!-- 删除 -->
          <image bindtap="removeImage" class="preview-img-del" data-type="logoImg" src="../../images/icon/close2.png"></image>
        </view>
        <!-- 上传 -->
        <view class="upload-icon upload-logo" wx:if="{{!logoImg.url}}" bindtap="getUploadImg" data-type="logoImg">+</view>
      </view>
      <!-- 上传文件end -->
    </view>

    <!-- 店铺地址 -->
    <view class="msg-cont-box addr" bindtap="translate">
      <label class="cont-txt">
        <text class="red">*</text>所在地区</label>
      <!-- 展示 -->
      <view class="pca">{{province}} {{city}} {{area}}</view>
      <!-- <view class="pca">广东省 广州市 番禺区</view> -->
      <view class='arrow'>
        <image src='../../images/icon/more.png'></image>
      </view>
      <!-- 弹框 -->
      <view class="animation-element-wrapper" animation="{{animation}}" style="visibility:{{show ? 'visible':'hidden'}}" catchtap="hiddenFloatView">
        <view class="animation-element" catchtap="nono">
          <text class="right-bt" catchtap="hiddenFloatView">确定</text>
          <view class="line"></view>
          <picker-view indicator-style="height: 50rpx;" value="{{value}}" bindchange="bindChange" catchtap="nono">
            <!--省-->
            <picker-view-column>
              <view wx:for="{{provArray}}" wx:key="index">
                {{item.areaName}}
              </view>
            </picker-view-column>
            <!--地级市-->
            <picker-view-column>
              <view wx:for="{{cityArray}}" wx:key="index">
                {{item.areaName}}
              </view>
            </picker-view-column>
            <!--区县-->
            <picker-view-column>
              <view wx:for="{{areaArray}}" wx:key="index">
                {{item.areaName}}
              </view>
            </picker-view-column>
          </picker-view>
        </view>
      </view>

    </view>

    <!-- 详细地址 -->
    <view class="msg-cont-box">
      <label class="cont-txt">
        <text class="red">*</text>详细地址</label>
      <input type="text" bindinput="bindShopAddrInt" value="{{shopAddrValue}}" class="cont-int" placeholder="请手动填写详细地址，不得少于5字"></input>
    </view>

    <!-- 经纬度(调用微信地图获取) -->
    <view class="msg-cont-box wx-map clearfix">
      <view class="cont-txt ">
        <text class="red">*</text>地理位置</view>
      <!-- <view class="show-location" wx:if="{{latitude}}">{{'纬度:' + latitude + ' 经度:' + longitude}}</view> -->
      <view class="show-location" wx:if="{{latitude}}">
        <view>{{ mapAddress}}</view>
      </view>
      <view class="map" bindtap="chooseLocation">点击获取位置</view>
    </view>

    <!-- 店铺联系电话 -->
    <view class="msg-cont-box">
      <text class="cont-txt" space="emsp"><text class="red">*</text>店铺电话</text>
      <input type="text" bindinput="bindShopOwnerPhoneInt" value="{{shopOwnerPhoneValue}}" class="cont-int" placeholder="请填写店铺联系电话"></input>
    </view>

    <!-- 店铺营业执照(选填) -->
    <view class="msg-cont-box">
      <label class="cont-txt"><text class="red">*</text>营业执照</label>
      <view class="upload-files">
        <view class="upload-tips">上传营业执照</view>
        <!-- 预览图片 -->
        <view class="preview-img-box" wx:if="{{bussLicenImg.url}}">
          <image class="preview-img" src="{{bussLicenImg.url}}" mode="aspectFill"></image>
          <!-- 删除 -->
          <image bindtap="removeImage" class="preview-img-del" data-type="bussLicenImg" src="../../images/icon/close2.png"></image>
        </view>
        <!-- 上传 -->
        <view class="upload-icon" wx:if="{{!bussLicenImg.url}}" bindtap="getUploadImg" data-type="bussLicenImg">+</view>
      </view>
    </view>

    <!-- 申请人身份证正反面 -->
    <view class="msg-cont-box">
      <text class="cont-txt" space="emsp"><text class="red">*</text>身份证件</text>
      <view class="upload-files">
        <view class="upload-tips">上传身份证正反两面</view>
        <!-- 正面预览图片 -->
        <view class="card-upload">
          <view class="preview-img-box" wx:if="{{idcardFrontImg.url}}">
            <image class="preview-img" src="{{idcardFrontImg.url}}" mode="aspectFill" data-idx="{{idx}}"></image>
            <!-- 删除 -->
            <image bindtap="removeImage" class="preview-img-del" data-type="idcardFrontImg" src="../../images/icon/close2.png"></image>
          </view>
          <!-- 上传 -->
          <view class="upload-icon" wx:if="{{!idcardFrontImg.url}}" bindtap="getUploadImg" data-type="idcardFrontImg">+</view>
          <view class="card-txt">正面</view>
        </view>

        <!-- 反面预览图片 -->
        <view class="card-upload">
          <view class="preview-img-box" wx:if="{{idcardBackImg.url}}">
            <image class="preview-img" src="{{idcardBackImg.url}}" mode="aspectFill" data-idx="{{idx}}"></image>
            <!-- 删除 -->
            <image bindtap="removeImage" class="preview-img-del" data-type="idcardBackImg" src="../../images/icon/close2.png"></image>
          </view>
          <!-- 上传 -->
          <view class="upload-icon" wx:if="{{!idcardBackImg.url}}" bindtap="getUploadImg" data-type="idcardBackImg">+</view>
          <view class="card-txt">反面</view>
        </view>

      </view>
    </view>

  </form>


  <!-- 申请人信息 -->
  <!-- <form class="msg-box">
    <view class="msg-tit">
      <view class="shop-icon"><image src="../../images/icon/user-icon.png"></image></view>
      <view class="shop-msg-tit">店主信息</view>
    </view>
    <!-- 申请人姓名 -->
  <!-- <view class="msg-cont-box">
      <text class="cont-txt"space="emsp"><text class="red">*</text>姓  名</text>
      <input type="text" bindinput="bindShopOwnerInt" class="cont-int" placeholder="请填写申请人姓名"></input>
    </view> -->

  <!-- </form> -->



  <!-- 提交申请 -->
  <view class="apply-btn">
    <view class="btn" bindtap="submitApply">
      提交申请
    </view>
    <view class="foot-tips">
      <text class="red">*</text>为必填信息。申请人必须保证以上所填信息的真实性。如有虚假信息，因此而产生的所有后果均由申请人承担。</view>
  </view>

</view>