From 61b2a3e25b9e29327dd72cfeb89f3e38aeecdd08 Mon Sep 17 00:00:00 2001
From: shuishen <1109946754@qq.com>
Date: Sat, 23 Dec 2023 18:16:41 +0800
Subject: [PATCH] 右上角头像显示异常处理
---
src/page/index/top/index.vue | 11 +++++++++--
1 files changed, 9 insertions(+), 2 deletions(-)
diff --git a/src/page/index/top/index.vue b/src/page/index/top/index.vue
index a2bc11f..7594a19 100644
--- a/src/page/index/top/index.vue
+++ b/src/page/index/top/index.vue
@@ -67,7 +67,7 @@
<i :class="isFullScren ? 'icon-tuichuquanping' : 'icon-quanping'" @click="handleScreen"></i>
</div>
</el-tooltip>
- <img class="top-bar__img" :src="userInfo.avatar">
+ <img class="top-bar__img" :src="topBarImg">
<el-dropdown>
<span class="el-dropdown-link">
{{ userInfo.userName }}
@@ -198,7 +198,14 @@
"tag",
"logsLen",
"logsFlag"
- ])
+ ]),
+ topBarImg () {
+ if (this.userInfo.avatar.indexOf('upload') != -1) {
+ return this.website.minioUrl + this.userInfo.avatar
+ } else {
+ return this.userInfo.avatar
+ }
+ }
},
methods: {
handleScreen () {
--
Gitblit v1.9.3