report.vue 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106
  1. <template>
  2. <view class="pages">
  3. <img src="../static/img/report-ico.png" alt="">
  4. <view class="title">恭喜你!答题完成</view>
  5. <view class="score u-flex">
  6. <view class="score-item">
  7. <view class="up">
  8. <text class="num">{{result.score}}</text>分
  9. </view>
  10. <view class="down">本次答题成绩</view>
  11. </view>
  12. <view class="score-item ">
  13. <view class="up">
  14. <text class="num" style="color: #FFB100;">{{result.credit}}</text>个
  15. </view>
  16. <view class="down">成功获得积分</view>
  17. </view>
  18. </view>
  19. <u-button
  20. type="primary"
  21. :plain="true"
  22. :customStyle="btnCustomStyle"
  23. shape="circle"
  24. @click="$u.route('/examination/answersheet',{type:'reLaunch',id:paperScoreId})"
  25. text="查看答题卡">
  26. </u-button>
  27. <u-button
  28. type="primary"
  29. shape="circle"
  30. @click="$u.route('/examination/typelist',{type:'reLaunch'})"
  31. :customStyle="btnCustomStyle"
  32. text="继续答题">
  33. </u-button>
  34. </view>
  35. </template>
  36. <script>
  37. export default {
  38. data() {
  39. return {
  40. btnCustomStyle:{
  41. width:'400rpx',
  42. 'margin-bottom':'20rpx'
  43. },
  44. paperScoreId:'',
  45. result:{
  46. score:'',
  47. credit:''
  48. },
  49. }
  50. },
  51. onShow() {
  52. },
  53. onLoad(page) {
  54. this.result = JSON.parse(page.result);
  55. // console.log('this.result',this.result);
  56. this.paperScoreId = this.result.paperScoreId;
  57. },
  58. methods: {
  59. }
  60. }
  61. </script>
  62. <style>
  63. page{
  64. background: url(../static/img/report-bg.png) no-repeat;
  65. background-size: 100% auto;
  66. text-align: center;
  67. padding-top: 58rpx;
  68. }
  69. </style>
  70. <style lang="scss" scoped>
  71. .title{
  72. margin: 20rpx auto 40rpx;
  73. font-size: 34rpx;
  74. font-weight: 600;
  75. color: #333333;
  76. line-height: 48rpx;
  77. }
  78. .score{
  79. margin: 40rpx 30rpx 40rpx;
  80. padding: 46rpx 20rpx 50rpx;
  81. background: #F5F9FC;
  82. border-radius: 24rpx;
  83. font-size: 26rpx;
  84. font-weight: 400;
  85. color: #999999;
  86. line-height: 36rpx;
  87. .score-item{
  88. flex: 1;
  89. .up{
  90. margin-bottom: 10rpx;
  91. }
  92. .num{
  93. font-size: 60rpx;
  94. font-weight: 600;
  95. color: #009AEF;
  96. line-height: 84rpx;
  97. margin-right: 10rpx;
  98. }
  99. & + .score-item{
  100. border-left: 1px solid #eee;
  101. }
  102. }
  103. }
  104. </style>