From 6a6a257d2a51169150be5ccdd11fe05a473b21c8 Mon Sep 17 00:00:00 2001 From: yystopf Date: Tue, 28 Mar 2023 15:03:13 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D:=20=E8=B4=A1=E7=8C=AE?= =?UTF-8?q?=E8=80=85=E5=A4=A7=E5=B0=8F=E5=86=99=E6=97=A0=E6=B3=95=E6=AD=A3?= =?UTF-8?q?=E5=B8=B8=E5=8C=B9=E9=85=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/repositories/_contributor.json.jbuilder | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/app/views/repositories/_contributor.json.jbuilder b/app/views/repositories/_contributor.json.jbuilder index bbfa08262..fa5151264 100644 --- a/app/views/repositories/_contributor.json.jbuilder +++ b/app/views/repositories/_contributor.json.jbuilder @@ -2,17 +2,17 @@ user = $redis_cache.hgetall("v2-owner-common:#{contributor["name"]}-#{contributo if user.blank? json.contributions contributor["contributions"] # json.gid contributor["id"] - json.login contributor["name"] + json.login contributor["name"].downcase json.type nil - json.name contributor["name"] + json.name contributor["name"].downcase json.image_url User::Avatar.get_letter_avatar_url(contributor["name"]) json.contribution_perc User.new(login: contributor["name"], mail: contributor["email"]).simple_contribution_perc(project, contributor["contribution_perc"]) else json.contributions contributor["contributions"] # json.gid contributor["id"] - json.login user["login"] + json.login user["login"].downcase json.type user["type"] - json.name user["name"] + json.name user["name"].downcase json.image_url user["avatar_url"] db_user = User.find_by_id(user["id"]) json.contribution_perc db_user.simple_contribution_perc(project, contributor["contribution_perc"]) if db_user.present?