From 126c72100e65cfcc2d44cc44bbf3a1ef7a1d8769 Mon Sep 17 00:00:00 2001 From: huangjiajun <582604932@qq.com> Date: Wed, 18 Dec 2024 23:32:56 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A4=B4=E5=83=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/hdl/hdl_user.go | 2 +- app/svc/svc_common.go | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/app/hdl/hdl_user.go b/app/hdl/hdl_user.go index 6d9d031..f3c16ab 100644 --- a/app/hdl/hdl_user.go +++ b/app/hdl/hdl_user.go @@ -113,7 +113,7 @@ func InviteCodeUserInfo(c *gin.Context) { user = svc.UserImg(user) res := md.InviteCodeUserInfoResp{ Nickname: nickname, - HeadImg: user.Avatar, + HeadImg: svc.GetOssUrl(user.Avatar), } e.OutSuc(c, res, nil) return diff --git a/app/svc/svc_common.go b/app/svc/svc_common.go index 2cd5dd2..17bb9a5 100644 --- a/app/svc/svc_common.go +++ b/app/svc/svc_common.go @@ -22,6 +22,7 @@ func UserImg(user *model.User) *model.User { if user.Avatar == "" { user.Avatar = GetSysCfgStr("default_avatar") } + user.Avatar = GetOssUrl(user.Avatar) return user } func GetOssDomain() string {