<t-navbar left-arrow title="个人信息" />
<view class="info-edit">
  <t-cell class="info-edit__cell" title="姓名">
    <t-input bind:change="onNameChange" borderless placeholder="请输入姓名" slot="note" value="{{personInfo.name}}" />
  </t-cell>
  <t-cell class="info-edit__cell" title="性别">
    <t-radio-group
      bind:change="onGenderChange"
      borderless
      defaultValue="{{personInfo.gender}}"
      options="{{genderOptions}}"
      slot="note"
      t-class="info-edit__gender"
      value="{{personInfo.gender}}"
    />
  </t-cell>
  <t-cell arrow bind:click="showPicker" data-mode="birth" note="{{personInfo.birth || ''}}" title="出生日期" />
  <t-cell class="info-edit__cell" title="身份证号">
    <t-input bind:change="onNameChange" borderless placeholder="请输入身份证号" slot="note" value="{{personInfo.name}}" />
  </t-cell>
  <t-cell class="info-edit__cell" title="手机号">
    <t-input bind:change="onNameChange" borderless placeholder="请输入手机号" slot="note" value="{{personInfo.name}}" />
  </t-cell>
  <t-cell arrow bind:click="showPicker" data-mode="birth" note="{{personInfo.birth || ''}}" title="胆道闭锁手术时间" />
  
</view>

<view class="info-edit__save">
  <t-button bind:tap="onSaveInfo" block size="medium" theme="primary">保存</t-button>
</view>

<t-date-time-picker
  auto-close
  bind:cancel="hidePicker"
  bind:change="onPickerChange"
  cancelBtn="取消"
  confirmBtn="确认"
  data-mode="birth"
  defaultValue="{{personInfo.birth}}"
  end="{{birthEnd}}"
  filter="{{birthFilter}}"
  format="YYYY-MM-DD"
  mode="date"
  popup-props="{{ { usingCustomNavbar: true } }}"
  start="{{birthStart}}"
  title="选择生日"
  value="{{personInfo.birth}}"
  visible="{{birthVisible}}"
/>

<t-picker
  bind:cancel="hidePicker"
  bind:change="onPickerChange"
  bind:close="hidePicker"
  bind:pick="onAreaPick"
  cancelBtn="取消"
  confirmBtn="确认"
  data-mode="address"
  mode="address"
  title="选择地址"
  value="{{personInfo.address}}"
  visible="{{addressVisible}}"
>
  <t-picker-item options="{{provinces}}" />
  <t-picker-item options="{{cities}}" />
</t-picker>
