wxr
2020-06-08 b71dfb3ca100340005d56e1298292807da82322d
HDL_ON/UI/UI2/4-PersonalCenter/PersonalCenterPageBLL.cs
@@ -6,6 +6,8 @@
{
    public partial class PersonalCenterPage
    {
        /// <summary>
        /// 加载事件列表
        /// </summary>
@@ -17,6 +19,8 @@
            {
                LoadEvent_SkipResdentialManagePage();
            }
            LoadEvent_GoMemberManagement();
        }
        #region 切换住宅
@@ -62,7 +66,7 @@
                VerticalScrolViewLayout view = new VerticalScrolViewLayout()
                {
                    Y = Application.GetRealHeight(60),
                    Height = Application.GetRealHeight(290),
                    Height = Application.GetRealHeight(240),
                };
                frame.AddChidren(view);
@@ -138,7 +142,7 @@
                        TextSize = home.Name.Length > 14 ? CSS.CSS_FontSize.TextFontSize : CSS.CSS_FontSize.SubheadingFontSize,
                        IsSelected = DB_ResidenceData.residenceData.residecenInfo.RegionID == home.RegionID,
                        IsMoreLines = true,
                        Tag = home
                        Tag = MainPage.LoginUser.regionList.IndexOf(home)
                    };
                    contentView.AddChidren(btnHomeName);
                    //if(btnHomeName)
@@ -156,11 +160,11 @@
                    btnHomeName.MouseUpEventHandler += (senderH, en) =>
                    {
                        var regionInfo = btnHomeName.Tag as RegionInfoRes;
                        var regionIndex = (int)btnHomeName.Tag;
                        dialog.Close();
                        DB_ResidenceData.residenceData.residecenInfo = regionInfo;
                        btnCurResidenceName.Text = regionInfo.Name;
                        DB_ResidenceData.residenceData.CurReginIndex = regionIndex;
                        btnCurResidenceName.Text = DB_ResidenceData.residenceData.residecenInfo.Name;
                        OnAppConfig.Instance.SaveUserConfig();
                    };
                }
@@ -178,7 +182,10 @@
            {
                EventHandler<MouseEventArgs> eventHandler = (sender, e) =>
                {
                    var residentialManagePage = new ResidentialManagePage();
                    Action updateResidenceName = () => {
                        btnCurResidenceName.Text = DB_ResidenceData.residenceData.residecenInfo.Name;
                    };
                    var residentialManagePage = new ResidentialManagePage(updateResidenceName);
                    MainPage.BasePageView.AddChidren(residentialManagePage);
                    residentialManagePage.LoadPage();
                    MainPage.BasePageView.PageIndex = MainPage.BasePageView.ChildrenCount - 1;
@@ -187,8 +194,6 @@
                btnResidenceManageText.MouseUpEventHandler = eventHandler;
            }
        }
        #endregion
        #region 个人中心
@@ -198,12 +203,41 @@
                Action updataHeadImage = () => {
                    userHeadImageView.ImagePath = MainPage.LoginUser.headImagePagePath;
                };
                var personalDataView = new PersonalDataPage(updataHeadImage);
                Action updataUserName = () => {
                    btnUserName.Text = MainPage.LoginUser.userName;
                };
                var personalDataView = new PersonalDataPage(updataHeadImage,updataUserName);
                MainPage.BasePageView.AddChidren(personalDataView);
                personalDataView.LoadView();
                MainPage.BasePageView.PageIndex = MainPage.BasePageView.ChildrenCount - 1;
            };
        }
        #endregion
        #region 成员管理
        void LoadEvent_GoMemberManagement()
        {
            EventHandler<MouseEventArgs> eHandler = (sender, e) => {
            //};
            //residenceMemberView.MouseUpEventHandler = (sender, e) => {
                //Action updataHeadImage = () => {
                //    userHeadImageView.ImagePath = MainPage.LoginUser.headImagePagePath;
                //};
                //Action updataUserName = () => {
                //    btnUserName.Text = MainPage.LoginUser.userName;
                //};
                var mmp = new MemberManagementPage();
                MainPage.BasePageView.AddChidren(mmp);
                mmp.LoadPage();
                MainPage.BasePageView.PageIndex = MainPage.BasePageView.ChildrenCount - 1;
            };
            btnResidenceMemberIcon.MouseUpEventHandler = eHandler;
            btnResidenceMemberText.MouseUpEventHandler = eHandler;
        }
        #endregion
    }
}