index.wxml 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. <wxs src="../../utils/filter.wxs" module="filters" />
  2. <view class="editBox">
  3. <button class="resetBtn editRow" open-type="chooseAvatar" bind:chooseavatar="changeAvatar">
  4. <view class="name">头像</view>
  5. <view class="right">
  6. <image class='avatar' src='{{ userInfo.avatar}}'></image>
  7. <image class='black' src='/static/black.png'></image>
  8. </view>
  9. </button>
  10. <view class="editRow">
  11. <view class="name">昵称</view>
  12. <view class="right">
  13. <input name='nickName' type="nickname" placeholder="请输入昵称" class='nickName' maxlength="9"
  14. value='{{userInfo.nickName}}' bindblur='saveNickName'></input>
  15. <image class='black' src='/static/black.png'></image>
  16. </view>
  17. </view>
  18. <view class="editRow">
  19. <view class="name">性别</view>
  20. <view class="right" bindtap="selectGender">
  21. <view class="name">
  22. {{userInfo.gender===0?'女':'男'}}
  23. </view>
  24. <image class='black' src='/static/black.png'></image>
  25. </view>
  26. </view>
  27. <view class="editRow">
  28. <view class="name">生日</view>
  29. <view class="right">
  30. <picker mode="date" value="{{filters.formatDate( userInfo.birthday, 2) }}" bindchange="bindDateChange"
  31. end="2022-01-01">
  32. <view class="name">{{userInfo.birthday?filters.formatDate(userInfo.birthday,2):'请选择生日' }}</view>
  33. </picker>
  34. <image class='black' src='/static/black.png'></image>
  35. </view>
  36. </view>
  37. <view class="editRow mt40">
  38. <view class="name">身份</view>
  39. <view class="right" bindtap="selectProfession">
  40. <view class="name">
  41. {{userInfo.profession}}
  42. </view>
  43. <image class='black' src='/static/black.png'></image>
  44. </view>
  45. </view>
  46. <view class="editRow">
  47. <view class="name">年级</view>
  48. <view class="right">
  49. <picker value="{{gradeIndex}}" range="{{gradeArray}}" range-key="key" bindchange="bindGradeChange">
  50. <view class="name">
  51. {{filters.gradeFilter(userInfo.grade)}}
  52. </view>
  53. </picker>
  54. <image class='black' src='/static/black.png'></image>
  55. </view>
  56. </view>
  57. <view class="editRow">
  58. <view class="name">学校</view>
  59. <view class="right">
  60. <input placeholder="请输入学校" class='nickName' maxlength="18" value='{{userInfo.schoolName}}'
  61. bindblur='saveSchool'></input>
  62. <image class='black' src='/static/black.png'></image>
  63. </view>
  64. </view>
  65. <view class="editRow mt40">
  66. <view class="name">绑定手机</view>
  67. <view class="right">
  68. <view class="name">
  69. 手机号
  70. </view>
  71. <image class='black' src='/static/black.png'></image>
  72. </view>
  73. </view>
  74. <view class="switchAccount mt40">
  75. 切换账号
  76. </view>
  77. </view>