guhongwei 5 years ago
parent
commit
9b32da2f9c
1 changed files with 7 additions and 6 deletions
  1. 7 6
      src/layout/layout-part/heads.vue

+ 7 - 6
src/layout/layout-part/heads.vue

@@ -14,8 +14,8 @@
             <span v-if="user">
               {{ user.name }}
             </span>
-            <span v-else @click="nameBtn()">
-              登录
+            <span v-else>
+              <el-link href="/login" :underline="false" target="_blank">登录</el-link>
             </span>
           </span>
           <span @click="logoutBtn()"><i class="iconfont iconiconfront-"></i>退出登录</span>
@@ -66,10 +66,6 @@ export default {
     passwdBtn() {
       this.passwdDia = true;
     },
-    // 点击名字
-    nameBtn() {
-      this.$router.push({ path: '/login' });
-    },
     // 退出登录
     logoutBtn() {
       alert('退出登录');
@@ -134,4 +130,9 @@ export default {
     border-right: 0;
   }
 }
+/deep/.el-link.el-link--default {
+  color: #000;
+  font-size: 16px;
+  top: -2px;
+}
 </style>