| | |
| | | }; |
| | | dispalyView.AddChidren(contentView); |
| | | |
| | | if (MainPage.LoginUser.regionList.Count < 3) |
| | | if ( UserInfo.Current.regionList.Count < 3) |
| | | { |
| | | } |
| | | else if (MainPage.LoginUser.regionList.Count < 4) |
| | | else if ( UserInfo.Current.regionList.Count < 4) |
| | | { |
| | | dispalyView = new FrameLayout() |
| | | { |
| | |
| | | contentView.Height = Application.GetRealHeight(45 * 3); |
| | | dispalyView.AddChidren(contentView); |
| | | } |
| | | else if (MainPage.LoginUser.regionList.Count < 5) |
| | | else if ( UserInfo.Current.regionList.Count < 5) |
| | | { |
| | | dispalyView = new FrameLayout() |
| | | { |
| | |
| | | |
| | | |
| | | |
| | | foreach (var home in MainPage.LoginUser.regionList) |
| | | foreach (var home in UserInfo.Current.regionList) |
| | | { |
| | | var btnHomeName = new Button() |
| | | { |
| | |
| | | }; |
| | | contentView.AddChidren(btnHomeName); |
| | | |
| | | if (MainPage.LoginUser.regionList.IndexOf(home) < MainPage.LoginUser.regionList.Count - 1) |
| | | if ( UserInfo.Current.regionList.IndexOf(home) < UserInfo.Current.regionList.Count - 1) |
| | | { |
| | | contentView.AddChidren(new Button() |
| | | { |
| | |
| | | var regionId = (string)btnHomeName.Tag; |
| | | dialog.Close(); |
| | | //DB_ResidenceData.residenceData.CurReginID = regionId; |
| | | LoadEvent_ChangeCurHome(MainPage.LoginUser.regionList.Find((obj) => obj.RegionID == regionId)); |
| | | LoadEvent_ChangeCurHome( UserInfo.Current.regionList.Find((obj) => obj.RegionID == regionId)); |
| | | LoadContentView(); |
| | | }; |
| | | } |
| | |
| | | } |
| | | //倒出新住宅数据 |
| | | FileUtils.RestoreRegionFiles(newRegionRootPath); |
| | | MainPage.LoginUser.SaveUserInfo(); |
| | | UserInfo.Current.SaveUserInfo(); |
| | | DB_ResidenceData.residenceData.EixtAccount(); |
| | | DB_ResidenceData.residenceData.CurReginID = homeTemp.RegionID; |
| | | OnAppConfig.Instance.SaveUserConfig(); |
| | |
| | | { |
| | | Action updataHeadImage = () => |
| | | { |
| | | userHeadImageView.ImagePath = MainPage.LoginUser.headImagePagePath; |
| | | userHeadImageView.ImagePath = UserInfo.Current.headImagePagePath; |
| | | }; |
| | | Action updataUserName = () => |
| | | { |
| | | btnUserName.Text = MainPage.LoginUser.userName; |
| | | btnUserName.Text = UserInfo.Current.userName; |
| | | }; |
| | | |
| | | var personalDataView = new PersonalDataPage(updataHeadImage, updataUserName); |