longyvfengyun
2022-05-17 8ff3fb1b80e89a367aa1e91a2885636cfa0a0743
内容提交
3个文件已修改
1个文件已添加
42 ■■■■■ 已修改文件
package.json 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/assets/images/loading-open.gif 补丁 | 查看 | 原始文档 | blame | 历史
src/pages/dataTest/realTime.vue 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/pages/login.vue 36 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
package.json
@@ -32,7 +32,7 @@
    "vue-draggable-resizable": "^2.2.0",
    "vue-jsonp": "^0.1.8",
    "vue-layer": "^1.2.0",
    "vue-router": "^3.4.3",
    "vue-router": "^3.0.7",
    "vue-seamless-scroll": "^1.1.23",
    "vue-video-player": "^5.0.1",
    "vue2-verify": "^1.0.2",
src/assets/images/loading-open.gif
src/pages/dataTest/realTime.vue
@@ -3225,9 +3225,9 @@
          }
          if(data.rlayworkmode == 1 || data.rlayworkmode == 3) {
            this.buscoupleSwitch = 1;
          }else {
            this.buscoupleSwitch = 0;
          }else {
            this.buscoupleSwitch = 1;
          }
        }).catch(error=>{
          this.buscoupleSwitch = 0;
src/pages/login.vue
@@ -1,5 +1,8 @@
<template>
  <div class="login-wrapper">
  <div class="auto-login-loading" v-if="isAutoLogin">
    <img src="../assets/images/loading-open.gif">
  </div>
  <div class="login-wrapper" v-else>
    <div class="login_container">
      <div class="sliderCon">
        <div class="logo">
@@ -332,6 +335,7 @@
      readSeconds: readSeconds?readSeconds:0,
      codeBtnLoading: false,
      showName: true,
      isAutoLogin: true,
    };
  },
  created() {
@@ -505,8 +509,10 @@
      this.loading = false;
      let rs = JSON.parse(res.data.result);
      if (rs.code == 1) {
        console.log(rs);
        this.$message.success("登录成功");
        // 非自动登录提示登录成功
        if(!this.isAutoLogin) {
          this.$message.success("登录成功");
        }
        // 重置登录时间
        this.readSeconds = 0;
        sessionStorage.setItem("readSeconds", "0");
@@ -576,17 +582,9 @@
        this.$apis.userMager.userInfo
          .getUserLoginInfo(uid)
          .then((res) => {
            let rs = JSON.parse(res.data.result);
            if (rs.code == 1) {
              let data = rs.data;
              this.$store.dispatch("user/changeAutoLogin", 1);
              this.$store.dispatch("user/changePage", pageName);
              this.loginForm.username = data.UName;
              this.loginForm.password = data.USnId;
              this.normalLogin();
            } else {
              this.init();
            }
            this.$store.dispatch("user/changeAutoLogin", 1);
            this.$store.dispatch("user/changePage", pageName);
            this.handleLogin(res, true);
          })
          .catch((error) => {
            this.$notify.error({
@@ -811,9 +809,11 @@
      this.changeVerifyCode();
      let autoLogin = this.$route.query.autoLogin;
      if (autoLogin) {
        this.isAutoLogin = true;
        // 自动登录
        this.autoLogin();
      } else {
        this.isAutoLogin = false;
        // 初始化
        this.init();
      }
@@ -833,6 +833,14 @@
</script>
<style>
.auto-login-loading {
  display: flex;
  height: 100%;
  flex-direction: row;
  justify-content: center;
  align-items: center;
  background-color: #E7EBEF;
}
.login_from .el-input__inner {
  height: 48px;
  line-height: 48px;