lsc 2 年之前
父节点
当前提交
58af49f26a
共有 1 个文件被更改,包括 6 次插入4 次删除
  1. 6 4
      src/App.vue

+ 6 - 4
src/App.vue

@@ -78,10 +78,12 @@ export default {
         this.$store.commit("update", ["isLogin", true]);
         // var info = JSON.parse(window.sessionStorage.getItem("userInfo"));
         this.$store.commit("update", ["userInfo", userInfo]);
-        if (userInfo.type == '1') {
-          this.$router.push("/eventCenter?steps=" + "2");
-        } else if (userInfo.type == '2' || userInfo.type == '3' || userInfo.type == '4' || userInfo.type == '5' || userInfo.type == '6') {
-          this.$router.push("/anliList");
+        if (this.$route.path == '/login') {
+          if (userInfo.type == '1') {
+            this.$router.push("/eventCenter?steps=" + "2");
+          } else if (userInfo.type == '2' || userInfo.type == '3' || userInfo.type == '4' || userInfo.type == '5' || userInfo.type == '6') {
+            this.$router.push("/anliList");
+          }
         }
         this.routerP();
       } else {