<!--pages/userCenter.axml-->
<view class="page-memberOfOwn">
  <view class="own-content">
    <view class="user-info">
      <view class="user-avatar">
        <image class="avatar" mode="widthFix" src="{{avatar}}"></image>
      </view>
      <view class="user-name-content">
        <view class="user-id">{{memberCardNo}}</view>
      </view>
      <!--	<view class='qr-code pr'>
				<image src='/assets/imgs/711_11.png' catchTap='handleGoWxCard' />
			</view>-->
    </view>
    <view class="user-qr-code">
      <canvas id="barcode" binderror="canvasIdErrorCallback"/>
      <view class='wx-pay-code' catchTap="onTapWxPay">支付宝支付</view>
    </view>
  </view>
  <view class="form-info">
    <form onSubmit="formSubmit">
      <view class="picker">
        <view class="form-label">姓名</view>
        <view class="right-input">
          <input
            class="form-input"
            name="name"
            maxlength="20"
            value="{{memberInfo.name}}"
            placeholder="用户姓名"
          />
        </view>
      </view>
      <view class="picker">
        <view class="form-label">手机号</view>
        <view class="right-input">
          <input
            class="form-input"
            name="mobile"
            disabled
            value="{{memberInfo.mobile}}"
            placeholder="请输入手机号"
          />
        </view>
      </view>
      <picker
        onChange="bindPickerChange"
        name="sex"
        value="{{index}}"
        range="{{array}}"
      >
        <view class="picker">
          <view class="form-label">性别</view>
          <view class="right-input form-input">{{array[index]}}</view>
        </view>
      </picker>
      <!-- WX2MY: 属性mode=date时，不被支持，请调整。属性start、end、bindchange为mode=date的关联属性，不被支持。 -->
      <picker
        mode="date"
        value="{{date}}"
        start=""
        end=""
        name="birthday"
        disabled="{{memberInfo.birthday}}"
        onChange="bindDateChange"
      >
        <view class="picker">
          <view class="form-label">生日</view>
          <view class="right-input">
            <view class="form-input" a:if="{{date == ''}}">请选择生日</view>
            <view class="form-input" a:else>{{date}}</view>
            <view class="birthday-desc">*生日信息一经填写，不可调整</view>
          </view>
        </view>
      </picker>
      <view class="picker">
        <view class="form-label">邮箱</view>
        <view class="right-input">
          <input
            class="form-input"
            name="email"
            value="{{memberInfo.email}}"
            placeholder="请输入邮箱"
          />
        </view>
      </view>
      <view class="picker-address">
        <view class="form-label">地址</view>
        <view class="right-input">
          <!--<view wx:if="{{memberInfo.address}}">{{memberInfo.address}}</view>-->
          <view>
            <textarea
              onBlur="bindTextAreaBlur"
              placeholder="请填写真实收件地址"
              placeholder-style="color:#999;font-size:13px;"
              name="address"
              auto-height
              maxlength="30"
              value="{{memberInfo.address}}"
            />
          </view>
        </view>
      </view>
      <button
        type="primary"
        class="btn-primary"
        form-type="submit"
        style="background-color: rgb(2, 186, 112);"
      >确认</button>
    </form>
  </view>
</view>