| | |
| | | btnUserAccount.Text += MainPage.LoginUser.AccountString; |
| | | } |
| | | |
| | | #region 调试人员管理 |
| | | Button debuggingBtn = new Button () { |
| | | X = btnUserName.X, |
| | | Y = Application.GetRealHeight(175 - 40), |
| | | Width = Application.GetRealWidth (200), |
| | | Height = Application.GetRealHeight (30), |
| | | //TextAlignment = TextAlignment.CenterRight, |
| | | Text = "Debugger management", |
| | | TextColor = SkinStyle.Current.TextColor1, |
| | | BackgroundColor = SkinStyle.Current.MainColor, |
| | | TextSize = 14, |
| | | Radius = (uint)Application.GetRealWidth (10) |
| | | }; |
| | | topUserMsgView.AddChidren (debuggingBtn); |
| | | debuggingBtn.Width = debuggingBtn.GetTextWidth () + Application.GetRealWidth (20); |
| | | //debuggingBtn.X = Application.GetRealWidth (640 - 20) - debuggingBtn.Width; |
| | | |
| | | debuggingBtn.MouseUpEventHandler = (sender, e) => { |
| | | GetHomeList (); |
| | | }; |
| | | #endregion |
| | | |
| | | VerticalScrolViewLayout contentView = new VerticalScrolViewLayout () { |
| | | Y = topUserMsgView.Bottom, |
| | | Height = Application.GetRealHeight (1136-80) - topUserMsgView.Bottom, |
| | |
| | | } |
| | | |
| | | |
| | | /// <summary> |
| | | /// 获取住宅列表 |
| | | /// </summary> |
| | | void GetHomeList () |
| | | { |
| | | MainPage.Loading.Start ("Please wait..."); |
| | | System.Threading.Tasks.Task.Run (() => { |
| | | try { |
| | | var revertObj = HttpServerRequest.Current.GetHomeList (); |
| | | if (revertObj.Code == StateCode.SUCCESS) { |
| | | var homeList = Newtonsoft.Json.JsonConvert.DeserializeObject<List<RegionInfoResNew>> (revertObj.Data.ToString ()); |
| | | if (homeList != null && homeList.Count > 0) { |
| | | var findHome = homeList.Find ((obj) => obj.Id == UserConfig.Instance.CurrentRegion.Id); |
| | | if (findHome != null) { |
| | | //查询住宅成功 |
| | | Application.RunOnMainThread (() => { |
| | | //打开调试人员管理 |
| | | DebuggerManagementView page = new DebuggerManagementView (findHome); |
| | | UserMiddle.SettingPageView.AddChidren (page); |
| | | page.ShowDebuggerManagementView (); |
| | | UserMiddle.SettingPageView.PageIndex += 1; |
| | | }); |
| | | return; |
| | | } |
| | | } |
| | | |
| | | IMessageCommon.Current.ShowErrorInfoAlter (Language.StringByID (R.MyInternationalizationString.Home_NoExists)); |
| | | |
| | | } else { |
| | | //错误提示 |
| | | IMessageCommon.Current.ShowErrorInfoAlter (revertObj.Code); |
| | | } |
| | | } catch { |
| | | MainPage.FailureToServer (); |
| | | } finally { |
| | | Application.RunOnMainThread (() => { |
| | | MainPage.Loading.Hide (); |
| | | }); |
| | | } |
| | | }); |
| | | } |
| | | |
| | | ///// <summary> |
| | | ///// 获取子账号列表 |
| | | ///// </summary> |