<view>
  <navbar home back color="{{typeLsit.sy_top_f.styleClass}}" background="{{typeLsit.sy_top.styleClass}}" text="个人信息"></navbar>
  <!-- <view style="height:{{navigationBarHeight}} "></view> -->
  <view class="container">
    <view class="avatar">
      <text>我的头像</text>
      <view class="right">
        <button class="avatarBtn" open-type="chooseAvatar" bind:chooseavatar="onChooseAvatar">
          <image class="avatarCover" src="{{avatarUrl}}"></image>
        </button>
        <image class="next" src="/assets/images/next.png"></image>
      </view>
    </view>

    <form bindsubmit="formSubmit" class="form">
      <view class="item">
        <text>微信昵称</text>
        <view class="right">
          <input type="nickname" name='nickname' class="input" placeholder="请输入昵称" value='{{nickName}}' />
          <image class="next" src="/assets/images/next.png"></image>
        </view>
      </view>

      <view class="item">
        <text>真实姓名</text>
        <view class="right">
          <input name='username' class="input" placeholder="请输入姓名" value='{{username}}' />
          <image class="next" src="/assets/images/next.png"></image>
        </view>
      </view>

      <view class="item">
        <text>性别</text>
        <view class="right">
          <picker range="{{sexArry}}" value="{{gender}}" bindchange="bindGenderChange">
            <view wx:if="{{sexFlag==1}}" class="input greyFont">
              请选择性别
            </view>
            <view wx:if="{{sexFlag==2}}" class="input">
              {{sexArry[gender]}}
            </view>
          </picker>
          <image class="next" src="/assets/images/next.png"></image>
        </view>
      </view>

      <view class="item">
        <text>出生年月</text>
        <view class="right">
          <picker mode="date" value="{{date}}" start="1930-09-01" end="{{dateEnd}}" bindchange="bindDateChange">
            <input wx:if="{{dateFlag==1}}" class='input' placeholder='请选择生日' disabled />
            <view wx:if="{{dateFlag==2}}" class="input">{{date}}</view>
          </picker>
          <image class="next" src="/assets/images/next.png"></image>
        </view>
      </view>

      <view class="item">
        <text>身高</text>
        <view class="right">
          <input name='height' class="input" placeholder="请输入身高" value='{{height}}' /><text>cm</text>
          <image class="next" src="/assets/images/next.png"></image>
        </view>
      </view>

      <view class="item">
        <text>体重</text>
        <view class="right">
          <input name='weight' class="input" placeholder="请输入体重" value='{{weight}}' /><text>kg</text>
          <image class="next" src="/assets/images/next.png"></image>
        </view>
      </view>

      <view class='itemAdress' bindtap='setAddress'>
        <text>家庭住址</text>
        <view class="right">
          <view class='input' wx:if="{{address}}">{{address}}</view>
          <view class='input greyFont' wx:if="{{!address}}">请选择地址</view>
          <image class="next" src="/assets/images/next.png"></image>
        </view>
      </view>

      <view class='item' bindtap="goSetChildren">
        <text>我的子女信息</text>
        <view class="right">
          <view class="input greyFont">前往设置</view>
          <image class="next" src="/assets/images/next.png"></image>
        </view>
      </view>

      <view class='item' bindtap="goSetAdress">
        <text>收货地址</text>
        <view class="right">
          <view class="input greyFont">前往设置</view>
          <image class="next" src="/assets/images/next.png"></image>
        </view>
      </view>

      <button class="submit" type="primary" form-type='submit'>确定</button>
      <!-- <button class="submit" type="primary" bindtap="test">测试</button> -->
    </form>
  </view>
</view>