ZZJ
2022-07-15 5c0c6ad7ac6f28e970532af9936de638830f1161
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
<template>
  <div class="registerSuccess">
    <Header> </Header>
    <div class="container">
      <div class="title"><span class="iconfont">&#xe605;</span>注册成功</div>
      <div class="name" v-if="info">登录名: {{ info.name }}</div>
      <div class="phone" v-if="info">绑定手机: {{ info.phone }}</div>
      <div class="jump">
        {{ time }}s后跳转到登录页,点此<span class="colorBlue" @click="jump"
          >立即跳转 >>
        </span>
      </div>
    </div>
    <Footer></Footer>
  </div>
</template>
 
<script>
import Header from "@/components/Header";
import Footer from "@/components/Footer";
export default {
  mounted() {
    this.timer = setInterval(() => {
      if (this.time <= 0) {
        this.$router.push("/login");
        clearInterval(this.timer);
        this.time = 3;
        return;
      }
      this.time--;
    }, 1000);
  },
  data() {
    return {
      time: 3,
      timer: null,
      info: this.$route.query.info,
    };
  },
  components: {
    Header,
    Footer,
  },
  methods: {
    jump() {
      this.$router.push("/login");
    },
  },
  beforeRouteLeave(to, from, next) {
    if (this.timer) {
      clearInterval(this.timer);
    }
    next();
  },
};
</script>
 
<style lang="scss" scoped>
.registerSuccess {
  position: absolute;
  height: 100%;
  width: 100%;
  min-width: 1280px;
  background: url("/images/register/success.png");
  background-size: 100% 100%;
  font-size: 14px;
 
  .container {
    position: absolute;
    width: 660px;
    height: 450px;
    left: 320px;
    top: 22vh;
    text-align: center;
    background: #ffffff;
 
    .title {
      margin-top: 90px;
      margin-bottom: 60px;
      font-size: 28px;
 
      span {
        margin-right: 20px;
        color: rgb(54, 178, 74);
        font-size: 48px;
      }
    }
 
    .name {
      font-size: 14px;
      margin-bottom: 20px;
    }
 
    .jump {
      margin-top: 80px;
      display: flex;
      align-items: center;
      justify-content: center;
      cursor: pointer;
    }
  }
 
  .Footer {
    position: absolute;
    width: 100%;
    bottom: 0;
    background-color: #252525;
    color: #9b9ea0;
  }
}
</style>