index.wxml 5.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130
  1. <!--index.wxml-->
  2. <view class="container">
  3. <!-- 标题 -->
  4. <tarbar id="tarbar"/>
  5. <!-- 内容 -->
  6. <view class="content">
  7. <scroll-view scroll-y="true" bindscroll="lower" scroll-with-animation="true" scroll-with-animation="true" enable-back-to-top="true">
  8. <!-- 我的 -->
  9. <view class="my {{navBtnSelectIdx == 0 ? '' : 'none'}}">
  10. <!-- 个人信息 -->
  11. <view class='message'>
  12. <view class='user'>
  13. <view class='head'>
  14. <image class="userinfo-avatar" src="{{data.users.headImgUrl}}" background-size="cover"></image>
  15. <view class='left'>
  16. <view class="student">
  17. 学号:<text>{{data.users.eid}}</text>
  18. </view>
  19. <view class="name">
  20. {{data.users.wechatName}}
  21. <text class='LV'>LV {{data.level}}</text>
  22. </view>
  23. </view>
  24. </view>
  25. <view>
  26. <view class='grade' bindtap="setgrade">
  27. {{grade}}
  28. </view>
  29. <view class='set-name'>
  30. <navigator style='font-size:28rpx;' url="../set_name/set_name" >更改昵称</navigator>
  31. </view>
  32. </view>
  33. </view>
  34. <view class='personal'>
  35. <view class="particulars">
  36. <text>登录天数</text>
  37. <text>{{data.users.loginDay}}</text>
  38. </view>
  39. <view class="particulars">
  40. <text>TV</text>
  41. <text>{{time}}</text>
  42. </view>
  43. <view class="particulars">
  44. <text>当前排名</text>
  45. <text>{{data.scoreRank}}</text>
  46. </view>
  47. <view class="particulars">
  48. <text>超过用户</text>
  49. <text>{{data.proportion}}%</text>
  50. </view>
  51. </view>
  52. </view>
  53. <!-- 答题 -->
  54. <view class="ranking">
  55. <view class="dashed"></view>
  56. <view class="ranking-con">
  57. <view class="rank">
  58. <text>勋章数量:{{rankData.userMetalNum}}枚</text>
  59. <text>第{{rankData.userMetalRank == 0 ? '1000+' : rankData.userMetalRank}}名</text>
  60. </view>
  61. <view class="rank">
  62. <text>等级:LV{{rankData.level}}</text>
  63. <text>第{{rankData.expRank === 0 ? '1000+' : rankData.expRank}}名</text>
  64. </view>
  65. <view class="rank">
  66. <text>答题量:{{rankData.userQuestionNum}}题</text>
  67. <text>第{{rankData.userQuestionRank == 0 ? '1000+' : rankData.userQuestionRank}}名</text>
  68. </view>
  69. <view class="rank">
  70. <text>答题准确率:{{rankData.userQuestionAccuracy}}%</text>
  71. <text>第{{rankData.userQuestionCorrectRank == 0 ? '1000+' : rankData.userQuestionCorrectRank}}名</text>
  72. </view>
  73. </view>
  74. <view class="particular">
  75. <navigator url="../medal_rank/medal_rank" >查看详细排行</navigator>
  76. </view>
  77. </view>
  78. <!-- 勋章 -->
  79. <view class="medal">
  80. <view class="title">
  81. <text>我的勋章</text>
  82. <text class="{{data.metalsList.length > 0 ? 'none' : ''}}">本周还没获得</text>
  83. </view>
  84. <scroll-view scroll-x="true" >
  85. <view class="img">
  86. <view wx:if="{{!data.isHave}}">
  87. <image src="../image/no_gain.png" class="no-gain"></image>
  88. <image src="{{data.currentMetals.unsoldImg}}"></image>
  89. <text>本周勋章</text>
  90. </view>
  91. <view wx:for="{{data.metalsList}}" wx:key="{{item.id}}" >
  92. <image src="{{item.img}}"></image>
  93. <text>{{item.name}}</text>
  94. </view>
  95. </view>
  96. </scroll-view>
  97. </view>
  98. <!-- 课模板 -->
  99. <view>
  100. <curriculum
  101. studyLog="{{ studyLog }}"
  102. height="{{height}}"/>
  103. </view>
  104. <!-- 上传作品 -->
  105. <chat id="upload"
  106. id="chat"
  107. productionData="{{productionData}}"
  108. title="我的作品"
  109. query="上传作品"
  110. type="2"
  111. columnType="6"
  112. bind:getHeight="onGetHeight"
  113. bind:myevent="onMyEvent"
  114. more="{{productionMore}}"/>
  115. <!-- 更改年级 -->
  116. <setGrade
  117. id="set-grade"
  118. grade="{{grade}}"/>
  119. </view>
  120. <view class="canvas-box">
  121. <canvas canvas-id="myCanvas" style="width:100%; height: {{canvasHeight}}px;"></canvas>
  122. </view>
  123. </scroll-view>
  124. </view>
  125. <view hidden="{{flag}}">
  126. <dialog bindmyevent="jurisdiction"/>
  127. </view>
  128. </view>