finish.vue 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201
  1. <template>
  2. <view>
  3. <view class="top_color"></view>
  4. <view class="content">
  5. <view class="title">{{name}}</view>
  6. <view class="game_box">
  7. <image :src="picture" mode="aspectFill"></image>
  8. <view class="tip">
  9. <view class="left">
  10. <view class="icon">
  11. <image src="./icon/icon.png" mode=""></image>
  12. </view>
  13. <view class="text">我的最快纪录</view>
  14. </view>
  15. <view class="right">{{completion_time}} 秒</view>
  16. </view>
  17. </view>
  18. </view>
  19. <view class="btn_box">
  20. <view class="left">
  21. <view class="btn btn_1" @click="go_detail()"></view>
  22. <view class="btn btn_2" @click="again_btn()"></view>
  23. </view>
  24. <view class="right" @click="go_personal_rank()">
  25. <view class="btn"></view>
  26. </view>
  27. </view>
  28. </view>
  29. </template>
  30. <script>
  31. export default {
  32. data() {
  33. return {
  34. title: "",
  35. picture:"",
  36. name:"",
  37. completion_time:"",
  38. page_id:"",
  39. mine_code:""
  40. };
  41. },
  42. onLoad(option) {
  43. uni.setNavigationBarTitle({
  44. title: option.title
  45. })
  46. this.name = option.name
  47. this.picture = option.picture
  48. this.title = option.title
  49. this.picture_id = option.picture_id
  50. this.$api.jigsawPuzzle_getPictureDetail({
  51. picture_id: this.picture_id,
  52. staff_num: uni.getStorageSync('user').staff_num
  53. }).then((res)=>{
  54. console.log(res.data.data)
  55. this.mine_code = res.data.data.mine_code
  56. this.completion_time = res.data.data.completion_time
  57. this.page_id = res.data.data.page_id
  58. })
  59. },
  60. methods: {
  61. go_personal_rank() {
  62. uni.navigateTo({
  63. url: "../personal_rank/personal_rank?title="+this.name+"&picture_id="+this.picture_id
  64. })
  65. },
  66. // 再来一次
  67. again_btn() {
  68. uni.redirectTo({
  69. url: "../game_play/game_play?title="+this.title+"&picture_id="+this.picture_id+"&name="+this.name+"&picture="+this.picture,
  70. })
  71. },
  72. // 查看详情 关联二维码
  73. go_detail(){
  74. uni.navigateTo({
  75. url:"../../../../../index/record/record?pageId="+this.page_id+"&mine_code="+this.mine_code
  76. })
  77. }
  78. }
  79. }
  80. </script>
  81. <style lang="scss">
  82. page {
  83. background-color: #F3F8F7;
  84. }
  85. .top_color {
  86. z-index: 1;
  87. width: 750rpx;
  88. height: 100rpx;
  89. background-color: #009fe8;
  90. position: fixed;
  91. top: 1;
  92. left: 0;
  93. }
  94. .content {
  95. position: relative;
  96. top: 20rpx;
  97. z-index: 2;
  98. width: 750rpx;
  99. background-color: #FFFFFF;
  100. border-radius: 50rpx;
  101. padding-bottom: 40rpx;
  102. .title {
  103. text-align: center;
  104. font-size: 36rpx;
  105. font-weight: 700;
  106. height: 100rpx;
  107. line-height: 100rpx;
  108. }
  109. .game_box {
  110. box-sizing: border-box;
  111. padding: 0 35rpx;
  112. image {
  113. width: 680rpx;
  114. height: 680rpx;
  115. }
  116. .tip {
  117. margin-top: 20rpx;
  118. display: flex;
  119. justify-content: space-between;
  120. align-items: center;
  121. .left {
  122. display: flex;
  123. align-items: center;
  124. .icon {
  125. margin-right: 10rpx;
  126. image {
  127. width: 28rpx;
  128. height: 28rpx;
  129. }
  130. }
  131. .text {
  132. color: #4F4F4F;
  133. font-size: 26rpx;
  134. }
  135. }
  136. .right {
  137. font-size: 28rpx;
  138. }
  139. }
  140. }
  141. }
  142. .btn_box {
  143. margin-top: 30rpx;
  144. box-sizing: border-box;
  145. padding: 35rpx;
  146. height: 260rpx;
  147. display: flex;
  148. justify-content: space-between;
  149. .left {
  150. .btn {
  151. width: 400rpx;
  152. height: 125rpx;
  153. background-size: cover;
  154. background-repeat: no-repeat;
  155. }
  156. .btn_1 {
  157. margin-bottom: 8rpx;
  158. background-image: url(./icon/detail.png);
  159. }
  160. .btn_2 {
  161. background-image: url(./icon/again.png);
  162. }
  163. }
  164. .right {
  165. width: 260rpx;
  166. height: 258rpx;
  167. background-image: url(./icon/rank.png);
  168. background-size: cover;
  169. background-repeat: no-repeat;
  170. }
  171. }
  172. </style>