From ae142832f9721956f963cf008047a2620a035bf7 Mon Sep 17 00:00:00 2001
From: 陈嘉乐 <cjl@hdlchina.com.cn>
Date: 星期五, 27 十一月 2020 17:00:58 +0800
Subject: [PATCH] 2020-11-27-3
---
HDL_ON/UI/UI2/4-PersonalCenter/PersonalDataPageBLL.cs | 68 +++++++++++++++++++++++++++++----
1 files changed, 59 insertions(+), 9 deletions(-)
diff --git a/HDL_ON/UI/UI2/4-PersonalCenter/PersonalDataPageBLL.cs b/HDL_ON/UI/UI2/4-PersonalCenter/PersonalDataPageBLL.cs
index 7d06a5e..41b9bcd 100644
--- a/HDL_ON/UI/UI2/4-PersonalCenter/PersonalDataPageBLL.cs
+++ b/HDL_ON/UI/UI2/4-PersonalCenter/PersonalDataPageBLL.cs
@@ -17,6 +17,7 @@
LoadEvent_SkipInterpretationSettings();
LoadEvent_ChangeBindEmail();
LoadEvent_ChangeBindPhone();
+ LoadEvent_SkipModifyPassword();
}
/// <summary>
@@ -37,10 +38,39 @@
{
btnLogout.MouseUpEventHandler += (sender, e) =>
{
+ #region 淇濆瓨鏈湴鏁版嵁鑷虫枃浠跺す
+ string oldRegionRootPath = FileUtils.CreateRegionBackup(DB_ResidenceData.residenceData.CurReginID.ToString());
+ new System.Threading.Thread(() =>
+ {
+ try
+ {
+ var backuplist = FileUtils.ReadFiles();
+ FileUtils.DeleteRegionFiles(oldRegionRootPath);
+ //绉诲姩鏂囦欢
+ foreach (var fileName in backuplist)
+ {
+ System.IO.FileInfo fileInfo = new System.IO.FileInfo(FileUtils.RootPath + fileName);
+ if (fileInfo.Exists)
+ {
+ fileInfo.MoveTo(oldRegionRootPath + fileName);
+ MainPage.Log("move file : " + fileName);
+ }
+ }
+ }
+ catch (Exception ex)
+ {
+ MainPage.Log($"xxx:{ex.Message}");
+ }
+ finally
+ {
+ FileUtils.DeleteAllFile();
+ }
+ }).Start();
+ #endregion
+
MainPage.LoginUser.lastTime = DateTime.MinValue;
MainPage.LoginUser.SaveUserInfo();
- MainPage.GoLoginPage(MainPage.LoginUser.accountString);
- FileUtils.DeleteAllFile();
+ MainPage.GoLoginPage(MainPage.LoginUser);
DB_ResidenceData.residenceData.EixtAccount();
};
}
@@ -48,16 +78,18 @@
/// <summary>
/// 鍔犺浇鑳屾櫙鍥鹃�夋嫨鍖哄煙浜嬩欢鍒楄〃
/// </summary>
- void LoadEvent_PictureOptionViewEventList()
+ void LoadEvent_PictureOptionViewEventList(FrameLayout baseView)
{
pictureOptionView.MouseUpEventHandler = (sender, e) =>
{
- pictureOptionView.RemoveFromParent();
+ baseView.RemoveFromParent();
};
-
+ baseView.MouseUpEventHandler = (sender, e) => {
+ baseView.RemoveFromParent();
+ };
btnCancel.MouseUpEventHandler = (sender, e) =>
{
- pictureOptionView.RemoveFromParent();
+ baseView.RemoveFromParent();
};
btnTakePicture.MouseUpEventHandler = (sender, e) =>
@@ -85,6 +117,7 @@
}
}), pid.ToString(), 1, 1);
pictureOptionView.RemoveFromParent();
+ baseView.RemoveFromParent();
};
btnAlbum.MouseUpEventHandler = (sender, e) =>
@@ -113,6 +146,7 @@
}
}, pid.ToString(), 1, 1);
pictureOptionView.RemoveFromParent();
+ baseView.RemoveFromParent();
};
}
@@ -129,7 +163,7 @@
{
new Tip()
{
- CloseTime = 3,
+ CloseTime = 1,
Text = Language.StringByID(StringId.UesrNameCannotBeEmpty),
Direction = AMPopTipDirection.None,
}.Show(bodyView);
@@ -174,7 +208,7 @@
var tip = new Tip()
{
Text = tipStr,
- CloseTime = 3,
+ CloseTime = 1,
Direction = AMPopTipDirection.None
};
tip.Show(bodyView);
@@ -195,7 +229,7 @@
})
{ IsBackground = true }.Start();
};
- new PublicAssmebly().LoadDialog_EditParater(StringId.UesrName, MainPage.LoginUser.userName, callBack, StringId.UesrNameCannotBeEmpty, 0, new System.Collections.Generic.List<string>());
+ new PublicAssmebly().LoadDialog_EditParater(StringId.ChangeName, MainPage.LoginUser.userName, callBack, StringId.UesrNameCannotBeEmpty, 0, new System.Collections.Generic.List<string>());
};
btnUserName.MouseUpEventHandler = eventHandler;
btnEditUserNameIcon.MouseUpEventHandler = eventHandler;
@@ -262,5 +296,21 @@
#endregion
+ /// <summary>
+ /// 璺宠浆淇敼瀵嗙爜鐣岄潰
+ /// </summary>
+ void LoadEvent_SkipModifyPassword()
+ {
+ EventHandler<MouseEventArgs> eventHandler = (sender, e) => {
+ var page = new ResetPasswordOptionPage();
+ MainPage.BasePageView.AddChidren(page);
+ page.LoadPage();
+ MainPage.BasePageView.PageIndex = MainPage.BasePageView.ChildrenCount - 1;
+ };
+ btnResetPasswordRight.MouseUpEventHandler = eventHandler;
+ btnResetPasswordText.MouseUpEventHandler = eventHandler;
+ resetPasswordView.MouseUpEventHandler = eventHandler;
+ }
+
}
}
\ No newline at end of file
--
Gitblit v1.8.0