message.vue 4.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201
  1. <template>
  2. <div class="page">
  3. <div class="page-top">
  4. <div class="icon-submit-succsss"></div>
  5. <div class="tip">上传成功</div>
  6. <template v-if="!isLoading">
  7. <div class="msg" v-if="uploadedNum === 3">已成功上传<b>3</b>条视频,我们会尽快联系您领取奖品,敬请留意!</div>
  8. <div class="msg" v-else>
  9. 已成功上传<b>{{ uploadedNum }}</b
  10. >条视频,再上传<b>{{ unUploadedNum }}</b
  11. >条视频即可获得 <span>2000元导胶一瓶</span>!
  12. </div>
  13. </template>
  14. </div>
  15. <div class="btn back" @click="onBack">返回首页</div>
  16. </div>
  17. </template>
  18. <script>
  19. import { mapGetters } from 'vuex'
  20. export default {
  21. layout: 'app-ross',
  22. data() {
  23. return {
  24. isLoading: true,
  25. videoList: [],
  26. }
  27. },
  28. computed: {
  29. ...mapGetters(['routePrefix', 'userInfo', 'authUserId']),
  30. uploadedNum() {
  31. return this.videoList.length
  32. },
  33. unUploadedNum() {
  34. return 3 - this.videoList.length
  35. },
  36. },
  37. created() {
  38. this.fetchVideoList()
  39. },
  40. methods: {
  41. // 获取当前机构已发布的视频列表
  42. async fetchVideoList() {
  43. try {
  44. this.isLoading = true
  45. if (!this.userInfo) return
  46. const { clubUserId, mobile } = this.userInfo
  47. const res = await this.$http.api.fetchOwnerVideoList({
  48. mobile: mobile,
  49. clubUserId: clubUserId,
  50. authUserId: this.authUserId,
  51. })
  52. this.videoList = res.data
  53. this.isLoading = false
  54. } catch (error) {
  55. console.log(error)
  56. }
  57. },
  58. // 返回
  59. onBack() {
  60. console.log(this.routePrefix)
  61. const path = `${this.routePrefix}/activity/challenge`
  62. this.$router.push(path)
  63. },
  64. },
  65. }
  66. </script>
  67. <style lang="scss" scoped>
  68. @media screen and (min-width: 768px) {
  69. .btn.back {
  70. width: 295px;
  71. height: 50px;
  72. background: #f3920d;
  73. border-radius: 4px 4px 4px 4px;
  74. opacity: 1;
  75. color: #fff;
  76. font-size: 16px;
  77. text-align: center;
  78. line-height: 50px;
  79. margin: 0 auto;
  80. cursor: pointer;
  81. }
  82. .page-top {
  83. display: flex;
  84. align-items: center;
  85. flex-direction: column;
  86. padding: 150px 0 64px;
  87. .icon-submit-succsss {
  88. width: 64px;
  89. height: 64px;
  90. background: url(~assets/theme-images/common/pc-icon-submit-success.png) no-repeat center;
  91. background-size: 64px;
  92. }
  93. .tip {
  94. font-size: 24px;
  95. font-weight: bold;
  96. color: #1890ff;
  97. }
  98. .msg {
  99. margin-top: 16px;
  100. font-size: 16px;
  101. b {
  102. margin: 0 2px;
  103. }
  104. span {
  105. color: #f3920d;
  106. font-weight: bold;
  107. }
  108. }
  109. }
  110. .page-content {
  111. width: 694px;
  112. margin: 0 auto;
  113. font-size: 14px;
  114. line-height: 1.8;
  115. .title {
  116. color: #666666;
  117. margin-bottom: 8px;
  118. }
  119. .content {
  120. color: #999999;
  121. text-align: justify;
  122. a {
  123. color: #f3920d;
  124. }
  125. }
  126. }
  127. }
  128. @media screen and (max-width: 768px) {
  129. .page-top {
  130. display: flex;
  131. align-items: center;
  132. flex-direction: column;
  133. padding: 20.4vw 0 12.6vw;
  134. .icon-submit-succsss {
  135. width: 12vw;
  136. height: 12vw;
  137. background: url(~assets/theme-images/common/pc-icon-submit-success.png) no-repeat center;
  138. background-size: 12vw;
  139. }
  140. .tip {
  141. font-size: 4.2vw;
  142. font-weight: bold;
  143. color: #1890ff;
  144. }
  145. .msg {
  146. width: 68.8vw;
  147. margin: 4vw auto auto;
  148. font-size: 3.4vw;
  149. text-align: center;
  150. span {
  151. color: #f3920d;
  152. font-weight: bold;
  153. }
  154. }
  155. }
  156. .page-content {
  157. width: 88.4vw;
  158. margin: 0 auto;
  159. font-size: 3vw;
  160. line-height: 2;
  161. .title {
  162. color: #666666;
  163. margin-bottom: 2.4vw;
  164. }
  165. .content {
  166. color: #999999;
  167. text-align: justify;
  168. a {
  169. color: #f3920d;
  170. }
  171. }
  172. }
  173. .btn {
  174. width: 85.6vw;
  175. height: 12vw;
  176. background: #f3920d;
  177. border-radius: 0.2vw;
  178. margin: 0 auto;
  179. color: #fff;
  180. text-align: center;
  181. line-height: 12vw;
  182. font-size: 3.6vw;
  183. margin-bottom: 24vw;
  184. }
  185. }
  186. </style>