From 0cbe80a545080b057a0be38053b7d5e984cbb3da Mon Sep 17 00:00:00 2001 From: Blank Date: Wed, 5 Feb 2025 12:12:42 +0800 Subject: [PATCH] =?UTF-8?q?[=E5=A2=9E=E5=8A=A0]1.=20=E5=A2=9E=E5=8A=A0?= =?UTF-8?q?=E6=8E=A5=E5=8F=A3=E5=9C=B0=E5=9D=80=E7=9A=84=E5=8F=98=E5=8C=96?= =?UTF-8?q?=E5=85=BC=E5=AE=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Assets/Hotfix/UI/Logic/UILogin/UILogin.Logic.cs | 4 ++-- Assets/Hotfix/UI/Logic/UILogin/UIPlayerCreate.Logic.cs | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Assets/Hotfix/UI/Logic/UILogin/UILogin.Logic.cs b/Assets/Hotfix/UI/Logic/UILogin/UILogin.Logic.cs index f057361..10752ff 100644 --- a/Assets/Hotfix/UI/Logic/UILogin/UILogin.Logic.cs +++ b/Assets/Hotfix/UI/Logic/UILogin/UILogin.Logic.cs @@ -54,7 +54,7 @@ private async void Login() }; req.Platform = PathHelper.GetPlatformName; - var respLogin = await GameApp.Web.Post($"http://127.0.0.1:28080/game/api/{nameof(ReqLogin)}", req); + var respLogin = await GameApp.Web.Post($"http://127.0.0.1:28080/game/api/{nameof(ReqLogin).ConvertToSnakeCase()}", req); if (respLogin.ErrorCode > 0) { Log.Error("登录失败,错误信息:" + respLogin.ErrorCode); @@ -68,7 +68,7 @@ private async void Login() ReqPlayerList reqPlayerList = new ReqPlayerList(); reqPlayerList.Id = respLogin.Id; - var respPlayerList = await GameApp.Web.Post($"http://127.0.0.1:28080/game/api/{nameof(ReqPlayerList)}", reqPlayerList); + var respPlayerList = await GameApp.Web.Post($"http://127.0.0.1:28080/game/api/{nameof(ReqPlayerList).ConvertToSnakeCase()}", reqPlayerList); if (respPlayerList.ErrorCode > 0) { Log.Error("登录失败,错误信息:" + respPlayerList.ErrorCode); diff --git a/Assets/Hotfix/UI/Logic/UILogin/UIPlayerCreate.Logic.cs b/Assets/Hotfix/UI/Logic/UILogin/UIPlayerCreate.Logic.cs index 4dc62db..8642c22 100644 --- a/Assets/Hotfix/UI/Logic/UILogin/UIPlayerCreate.Logic.cs +++ b/Assets/Hotfix/UI/Logic/UILogin/UIPlayerCreate.Logic.cs @@ -40,7 +40,7 @@ private async void OnCreateButtonClick() #region 创建角色 - var respPlayerCreate = await GameApp.Web.Post($"http://127.0.0.1:28080/game/api/{nameof(ReqPlayerCreate)}", req); + var respPlayerCreate = await GameApp.Web.Post($"http://127.0.0.1:28080/game/api/{nameof(ReqPlayerCreate).ConvertToSnakeCase()}", req); if (respPlayerCreate.ErrorCode > 0) { @@ -60,7 +60,7 @@ private async void OnCreateButtonClick() ReqPlayerList reqPlayerList = new ReqPlayerList(); reqPlayerList.Id = req.Id; - var respPlayerList = await GameApp.Web.Post($"http://127.0.0.1:28080/game/api/{nameof(ReqPlayerList)}", reqPlayerList); + var respPlayerList = await GameApp.Web.Post($"http://127.0.0.1:28080/game/api/{nameof(ReqPlayerList).ConvertToSnakeCase()}", reqPlayerList); if (respPlayerList.ErrorCode > 0) {