JLChen
2020-04-16 9ca2281d589fbd4b35177d1846974f17d12095ae
Crabtree/SmartHome/UI/SimpleControl/MainPage.cs
@@ -37,7 +37,7 @@
        //public static Button LogoButton = new Button ();
        public static string RequestVersion = "20200310";
        public static string RequestVersion = "20200414";
        public static UserInfo LoginUser;
        /// <summary>
        /// 是否是管理员权限(变更了,成员的时候,这个也为ture。为什么会声明这样变量,因为有些接口必须使用原来的Token)
@@ -166,11 +166,13 @@
                    Gravity = Gravity.Center,
                    Width = Application.GetRealWidth (560),
                    Height = Application.GetRealHeight (126),
                    BackgroundColor = SkinStyle.Current.AddTipButtonColor,
                    //BackgroundColor = SkinStyle.Current.AddTipButtonColor,
                    BackgroundColor = SkinStyle.Current.MainColor,
                    Radius = 10,
                    IsMoreLines = true,
                    Text = tip,
                    TextSize = 16,
                    TextColor = 0xFF000000
                };
                MainFrameLayout.AddChidren (button);
                button.MouseUpEventHandler += (sender, e) => {
@@ -218,6 +220,9 @@
            //    }
            //}) { IsBackground = true }.Start ();
            ServicePointManager.ServerCertificateValidationCallback += (sender, cert, chain, error) => {
                return true;
            };
            #region
            var webClient = new WebClient ();
@@ -261,7 +266,7 @@
            try {
                return Newtonsoft.Json.JsonConvert.DeserializeObject<ResponsePack> (responseString);
            } catch (Exception ex) {
                Console.WriteLine (ex.ToString ());
                Utlis.WriteLine (ex.ToString ());
                return new ResponsePack () { StateCode = "Data exception" };
            }
            #endregion
@@ -279,9 +284,11 @@
        {
            ResponsePack revertObj = null;
            try {
                ServicePointManager.ServerCertificateValidationCallback += (sender, cert, chain, error) => {
                    return true;
                };
                #region
                var webClient = new WebClient ();
@@ -307,7 +314,7 @@
                return bytes;
                #endregion
            } catch (Exception ex) {
                Console.WriteLine (ex.Message);
                Utlis.WriteLine (ex.Message);
                return null;
            } finally {
                //requesTime = requesTime.AddDays(1);