MrShi
16 小时以前 23e9c8e4e541b961db66681fec39767dd93be90f
admin/src/views/login.vue
@@ -3,7 +3,8 @@
    <img src="@/assets/images/bg@2x.png" class="main_bg" alt="">
    <div class="login_wrap">
      <div class="login_img">
        <div class="h3">智慧物流园区安消一体化系统</div>
<!--        <div class="h2">公务车钥匙智能柜管理系统</div>-->
        <div class="h3">公务车钥匙智能柜管理系统</div>
      </div>
      <div class="form_wrap">
        <div class="tabs">
@@ -114,11 +115,11 @@
      if (this.loading) {
        return
      }
      this.loading = true
      if (this.activeTab == 0) {
        if (!this.__check()) {
          return
        }
        this.loading = true
        loginByPassword({
          username: this.username.trim(),
          password: this.password,
@@ -137,7 +138,8 @@
              localStorage.removeItem('isRemPsd')
            }
            Cookies.set('dm_user_token', res)
            this.$router.push('index')
            // window.location.reload()
            this.$router.push('/')
          })
          .catch(e => {
            this.refreshCaptcha()
@@ -153,12 +155,16 @@
        if (!smsCode) {
          return Message.error('请输入验证码')
        }
        this.loading = true
        loginByPhone({ phone, code: smsCode }).then(res => {
          if (this.isRemPsd) {
            localStorage.setItem('phone', this.username.trim())
          }
          Cookies.set('dm_user_token', res)
          this.$router.push('index')
          this.$router.push('/')
          // this.$router.push('index')
        }).catch(e => {
          this.refreshCaptcha()
        }).finally(() => {
          this.loading = false
        })
@@ -173,7 +179,7 @@
      }
      sendSmsPost({ phone, type: 0 }).then(res => {
        Message.success('短信发送成功')
        this.downTime = 10
        this.downTime = 60
        let timer = setInterval(() => {
          if (this.downTime == 0) {
            return clearInterval(timer)
@@ -264,7 +270,20 @@
      background: url("../assets/images/login_img@2x.png");
      background-size: 100% 100%;
      padding-left: 40px;
      padding-top: 80px;
      padding-top: 60px;
      .h2 {
        color: $primary-color;
        background-color: #fff;
        height: 24px;
        display: flex;
        align-items: center;
        justify-content: center;
        border-radius: 4px;
        width: 248px;
        display: flex;
        margin-bottom: 12px;
      }
      .h3 {
        font-size: 28px;