my_question.vue 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131
  1. <template>
  2. <view style="padding: 30rpx;">
  3. <view v-for="(item, index) in list" :key="index" style="margin-bottom: 30rpx;">
  4. <navigator :url="'/pages2/bank/question_detail?id='+item.goodsId">
  5. <!-- <navigator url="/pages2/bank/detail"> -->
  6. <view class="class_item">
  7. <image class="img" :src="$method.splitImgHost(item.coverUrl, true)"></image>
  8. <view style="color: #333333;font-weight: bold;font-size: 32rpx;">
  9. {{item.goodsName}}
  10. </view>
  11. <view class=".content_box">
  12. <image src="/static/icon/wk_icon2.png" class="wk_icon"></image>
  13. 学习有效期:<text class="content"> {{$method.timestampToTime(item.studyStartTime)}} - {{$method.timestampToTime(item.studyEndTime)}} </text>
  14. </view>
  15. </view>
  16. <!-- </navigator> -->
  17. <view class="bottomBox">
  18. <view class="box_progress">
  19. <view style="width: 60%;">
  20. <u-line-progress :show-percent="false" active-color="#007AFF" :percent="item.doNum/item.totalNum"></u-line-progress>
  21. </view>
  22. <view>
  23. <!-- <navigator :url="'/pages2/bank/question_detail?id='+item.goodsId"> -->
  24. <view class="btn">进入刷题</view>
  25. <!-- </navigator> -->
  26. </view>
  27. </view>
  28. </view>
  29. </navigator>
  30. </view>
  31. </view>
  32. </template>
  33. <script>
  34. export default {
  35. data() {
  36. return {
  37. list:[]
  38. }
  39. },
  40. onLoad(option) {
  41. this.listGoodsUserQuestion();
  42. },
  43. onShow(){
  44. },
  45. methods: {
  46. listGoodsUserQuestion() {
  47. this.$api.listGoodsUserQuestion({
  48. }).then(res => {
  49. this.list = res.data.rows;
  50. })
  51. },
  52. studyIn(){
  53. this.$navTo.togo('/pages2/verify/input');
  54. },
  55. appointment(){
  56. this.$navTo.togo('/pages2/appointment/index');
  57. }
  58. },
  59. }
  60. </script>
  61. <style >
  62. page {
  63. background: #EAEEF1;
  64. }
  65. </style>
  66. <style lang="scss" scope>
  67. .box_progress{
  68. display: flex;
  69. justify-content:space-between;
  70. align-items: center;
  71. margin-top: 20rpx;
  72. .btn {
  73. width: 165rpx;
  74. height: 48rpx;
  75. background: #007AFF;
  76. border-radius: 16rpx;
  77. line-height: 48rpx;
  78. text-align: center;
  79. color:#fff;
  80. font-size: 30rpx;
  81. }
  82. }
  83. .bottomBox{
  84. background: #FFFFFF;
  85. width: 94%;
  86. border-bottom-left-radius: 24rpx;
  87. border-bottom-right-radius: 24rpx;
  88. margin: 0 auto;
  89. padding: 20rpx;
  90. }
  91. .content_box{
  92. display: flex;
  93. align-items: center;
  94. color: #999999;
  95. margin-top: 8rpx;
  96. }
  97. .content{
  98. color: #000000;
  99. margin: 0 8rpx;
  100. }
  101. .wk_icon{
  102. width: 24rpx;
  103. height: 24rpx;
  104. margin-right: 8rpx;
  105. }
  106. .class_item{
  107. width: 100%;
  108. height: 514rpx;
  109. background: #FFFFFF;
  110. box-shadow: 0rpx 10rpx 9rpx 1rpx rgba(165, 196, 239, 0.1);
  111. border-radius: 24rpx;
  112. padding: 20rpx;
  113. z-index: 999;
  114. position: relative;
  115. .img {
  116. width:100%;
  117. border-radius: 24rpx;
  118. height: 316rpx;
  119. }
  120. }
  121. </style>