Merge remote-tracking branch 'origin/dev_lishuo' into dev

This commit is contained in:
suntao 2021-06-09 19:56:26 +08:00
commit dd474f1f61
2 changed files with 11 additions and 3 deletions

View File

@ -286,7 +286,14 @@ public class EditUserController : PFUIPanel
void Save(BaseEventData e)
{
//UIManager.ShowConfirm("Confirm", "Are you sure to edit?", SaveFunc);
SaveFunc();
try
{
SaveFunc();
}
catch (Exception ex)
{
Utils.showToast(gameObject, ex.Message);
}
//App.CurrentUser = user;
//UIManager.ShowAlert("result.errMsg");

View File

@ -6,6 +6,7 @@ using DG.Tweening;
using System;
using System.Collections;
using System.Collections.Generic;
using System.Globalization;
using System.Threading.Tasks;
using UnityEngine;
using UnityEngine.Events;
@ -152,9 +153,9 @@ public class HomeController : PFUIPanel
Utils.DisplayHead(userInfo.Find("Avatar").GetComponent<RawImage>(), App.CurrentUser.WxHeadImg);
userInfo.Find("Country").GetComponent<RawImage>().texture = UIManager.Instance.loginRegOptions.GetCountryImageByName(App.CurrentUser.Country);
userInfo.Find("CaloriesContainer").Find("CaloriesValue").GetComponent<Text>().text = double.Parse(summary.Kcal).ToString("0") +" KCAL";
userInfo.Find("CaloriesContainer").Find("CaloriesValue").GetComponent<Text>().text = double.Parse(summary.Kcal,CultureInfo.InvariantCulture).ToString("0") +" KCAL";
userInfo.Find("KMContainer").Find("KMValue").GetComponent<Text>().text = summary.TotalDistance.ToString("0") +" KM";
userInfo.Find("ClimbContainer").Find("ClimbValue").GetComponent<Text>().text = summary.TotalClimb +" M";
userInfo.Find("ClimbContainer").Find("ClimbValue").GetComponent<Text>().text = double.Parse(summary.TotalClimb,CultureInfo.InvariantCulture).ToString("0") + " M";
userInfo.Find("GroupTop").Find("FtpContainer").Find("FtpTime").GetComponent<Text>().text = App.CurrentUser.LastUpdateFtpTime.ToString("dd.MM.yyyy");
userInfo.Find("GroupTop").Find("WeightContainer").Find("WeightTime").GetComponent<Text>().text = App.CurrentUser.LastUpdateWeightTime.ToString("dd.MM.yyyy");