home.vue 1.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  1. <template>
  2. <view class="box">
  3. </view>
  4. </template>
  5. <script>
  6. export default {
  7. data() {
  8. return {
  9. id: ''
  10. }
  11. },
  12. onLoad(options) {
  13. this.id = options.id;
  14. },
  15. created() {
  16. this.$common.showLoading('正在加载...')
  17. },
  18. mounted() {
  19. this.getRedirectUri();
  20. },
  21. beforeDestroy() {
  22. this.$common.hidingLoading()
  23. },
  24. methods: {
  25. getRedirectUri() {
  26. this.$api.getRedirectUrl({path: '/pages/index/index', state: this.id}).then(resp => {
  27. window.location.href = resp.data;
  28. })
  29. }
  30. }
  31. }
  32. </script>
  33. <style lang="scss">
  34. page {
  35. background-color: #fff;
  36. }
  37. .box {
  38. display: flex;
  39. flex: 1;
  40. align-items: center;
  41. justify-content: center;
  42. flex-direction: column;
  43. padding: 100rpx 0;
  44. .text {
  45. color: #191919;
  46. font-size: 36rpx;
  47. font-weight: bold;
  48. margin-top: 40rpx;
  49. }
  50. .count-down-box {
  51. display: flex;
  52. flex: 1;
  53. align-items: center;
  54. justify-content: center;
  55. margin-top: 30rpx;
  56. text {
  57. margin-left: 20rpx;
  58. }
  59. }
  60. }
  61. </style>