question_bank.vue 3.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200
  1. <template>
  2. <view style="padding: 32rpx;">
  3. <nav-bar title="我的题库通"></nav-bar>
  4. <navigator hover-class="none" url="/pages2/bank/my_question">
  5. <view class="my_question">
  6. <view class="flex">
  7. <view class="text">自购题卷<u-icon name="arrow-right"></u-icon></view>
  8. </view>
  9. <image src="/pages2/static/questionBank.png" class="my_bg"></image>
  10. </view>
  11. </navigator>
  12. <navigator hover-class="none" url="/pages2/bank/free_question">
  13. <view class="my_question">
  14. <view class="flex">
  15. <view class="text">赠送题卷<u-icon name="arrow-right"></u-icon></view>
  16. </view>
  17. <image src="/pages2/static/questionPresent.png" class="my_bg"></image>
  18. </view>
  19. </navigator>
  20. <view class="bottom">
  21. <navigator hover-class="none" url="/pages2/subject/collect">
  22. <view class="item collect">
  23. <view class="text">收藏集<u-icon name="arrow-right"></u-icon></view>
  24. <image class="img" src="/static/questionBank_collect.png"></image>
  25. </view>
  26. </navigator>
  27. <view class="item list">
  28. <navigator hover-class="none" url="/pages2/bank/question_record">
  29. <view class="list-in">
  30. <image class="img" src="/static/questionBank_record.png" ></image>
  31. <view class="text">
  32. 做题记录 <u-icon name="arrow-right"></u-icon>
  33. </view>
  34. </view>
  35. </navigator>
  36. <navigator hover-class="none" url="/pages2/subject/wrong">
  37. <view class="list-in">
  38. <image class="img" src="/static/questionBank_wrong.png"></image>
  39. <view class="text">
  40. 错题集 <u-icon name="arrow-right"></u-icon>
  41. </view>
  42. </view>
  43. </navigator>
  44. </view>
  45. </view>
  46. </view>
  47. </template>
  48. <script>
  49. // import { websocket } from '@/common/socket.js';
  50. export default {
  51. data() {
  52. return {
  53. list:[
  54. 1,2,3
  55. ],
  56. timer:null,
  57. }
  58. },
  59. onLoad(option) {
  60. this.getLock()
  61. this.timer = setInterval(this.getLock,10000)
  62. // websocket.sendMsg('doQuestion')
  63. // this.getDict()
  64. },
  65. onUnload() {
  66. clearInterval(this.timer)
  67. this.$api.lockDelLock({
  68. action:'bank'
  69. }).then(res => {
  70. })
  71. // websocket.sendMsg('delAction')
  72. },
  73. onShow(){
  74. },
  75. methods: {
  76. getLock() {
  77. this.$api.lockLockAction({
  78. action:'bank'
  79. }).then(res => {
  80. })
  81. }
  82. },
  83. }
  84. </script>
  85. <style >
  86. page {
  87. background: #fff;
  88. }
  89. </style>
  90. <style lang="scss" scope>
  91. .my_question {
  92. position:relative;
  93. display: flex;
  94. width: 686rpx;
  95. height: 240rpx;
  96. border-radius: 24rpx;
  97. padding:0 40rpx;
  98. margin-bottom:16rpx;
  99. .my_bg {
  100. position:absolute;
  101. left:0;
  102. top:0;
  103. width:100%;
  104. height:100%;
  105. }
  106. .flex {
  107. position: relative;
  108. z-index: 10;
  109. .text {
  110. padding-top:32rpx;
  111. font-size: 32rpx;
  112. font-family: PingFang SC;
  113. font-weight: bold;
  114. color: #FFFFFF;
  115. }
  116. }
  117. }
  118. .bottom {
  119. display: flex;
  120. justify-content: space-between;
  121. .item {
  122. width: 335rpx;
  123. &.collect {
  124. position: relative;
  125. font-size: 32rpx;
  126. color: #FFFFFF;
  127. height: 240rpx;
  128. border-radius: 24rpx;
  129. padding:32rpx;
  130. .text {
  131. position:relative;
  132. z-index: 10;
  133. font-size: 32rpx;
  134. font-weight: bold;
  135. color: #FFFFFF;
  136. }
  137. .img {
  138. position:absolute;
  139. left:0;
  140. top:0;
  141. width:100%;
  142. height:100%;
  143. }
  144. }
  145. &.list {
  146. .list-in {
  147. position:relative;
  148. width: 335rpx;
  149. height: 112rpx;
  150. background: #007AFF;
  151. border-radius: 24rpx;
  152. display: flex;
  153. align-items: center;
  154. font-size: 32rpx;
  155. color: #fff;
  156. &:first-of-type {
  157. margin-bottom:16rpx;
  158. }
  159. .text {
  160. padding-left:91rpx;
  161. position:relative;
  162. z-index: 10;
  163. font-size: 32rpx;
  164. font-weight: bold;
  165. color: #FFFFFF;
  166. }
  167. .img {
  168. position:absolute;
  169. left:0;
  170. top:0;
  171. width:100%;
  172. height:100%;
  173. }
  174. }
  175. }
  176. }
  177. }
  178. </style>