<!--pages/addAddress/addAddress.wxml-->
<view class="page-add-address">
  <view class="form-section">
    <form bindsubmit="formSubmit">
      <view class="form">
        <view class="form-label">姓名</view>
        <input class="form-input" value="{{params.name}}" placeholder-class="placeholder-picker" name="name" placeholder="请输入收货人真实姓名" />
      </view>
      <view class="form">
        <view class="form-label">电话</view>
        <input class="form-input" value="{{params.phone}}"  placeholder-class="placeholder-picker" name="phone" placeholder="请输入收货人手机号" type="number" maxlength="11" />
      </view>
      <view class="form">
        <view class="form-label">地区</view>
        <picker mode="multiSelector" bindchange="bindMultiPickerChange" bindcolumnchange="bindMultiPickerColumnChange" value="{{multiIndex}}" range="{{citys}}">
              <view class="form-picker" wx:if="{{cityView}}">
                {{cityView}}
              </view>
              <view  wx:if="{{!cityView}}">
                <input class='form-input' placeholder-class="placeholder-picker" type="text" disabled placeholder="请选择地区" />
              </view>
        </picker>
      </view>
      <view class="form">
        <view class="form-label">详细地址</view>
        <input class="form-input" value="{{params.address}}"  placeholder-class="placeholder-picker" name="address" placeholder="请输入街道、楼牌号" />
      </view>
      <view class="default-address" bindtap="settingDefaultAddress">
        <view class="{{isSelect ? 'theme-color' : ''}} circle-radio"  >
          <image wx:if="{{isSelect}}" class="tick-success" src="/assets/imgs/7_1_0/tick-success.png" mode="widthFix"></image>
        </view>
        <text class="setting-default">设为默认地址</text>
      </view>
      <view class="address-bottom">
        <button form-type="submit" class="address-btn theme-color">{{addressId ? '保存并使用' : '保存收货地址'}}</button>
      </view>
    </form>
  </view>
</view>
