From ade5917841b0fdcb1df7353ef7c56b1a1bdc9282 Mon Sep 17 00:00:00 2001
From: 黄学彪 <hxb@hdlchina.com.cn>
Date: 星期二, 22 九月 2020 10:03:32 +0800
Subject: [PATCH] 删除 Gateway.Ios文件

---
 ZigbeeApp/Shared/Phone/UserCenter/Member/SubAccountLevelUpSuccessForm.cs |  108 +++++++++++++++++++++++++++++++++++-------------------
 1 files changed, 70 insertions(+), 38 deletions(-)

diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Member/SubAccountLevelUpSuccessForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Member/SubAccountLevelUpSuccessForm.cs
index 0e308f5..06f7bcc 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Member/SubAccountLevelUpSuccessForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Member/SubAccountLevelUpSuccessForm.cs
@@ -13,7 +13,7 @@
 
         /// <summary>
         /// 鎴愬憳鐨勪俊鎭�
-        /// </summary>
+        /// </summary>
         private MemberInfoRes memberInfo = null;
 
         #endregion
@@ -23,19 +23,19 @@
         /// <summary>
         /// 鐢婚潰鏄剧ず(搴曞眰浼氬浐瀹氳皟鐢ㄦ鏂规硶锛屽�熶互瀹屾垚鐢婚潰鍒涘缓)
         /// </summary>
-        /// <param name="info">鎴愬憳淇℃伅</param>
-        public void ShowForm(MemberInfoRes info)
-        {
-            this.memberInfo = info;
-
-            //鍒濆鍖栦腑閮ㄦ帶浠�
-            this.InitMiddleFrame();
+        /// <param name="info">鎴愬憳淇℃伅</param>
+        public void ShowForm(MemberInfoRes info)
+        {
+            this.memberInfo = info;
+
+            //鍒濆鍖栦腑閮ㄦ帶浠�
+            this.InitMiddleFrame();
         }
 
-        /// <summary>
-        /// 鍒濆鍖栦腑閮ㄦ帶浠�
-        /// </summary>
-        private void InitMiddleFrame()
+        /// <summary>
+        /// 鍒濆鍖栦腑閮ㄦ帶浠�
+        /// </summary>
+        private void InitMiddleFrame()
         {
             //鑳屾櫙妗�
             var frame = new FrameLayout();
@@ -43,23 +43,35 @@
             frame.Height = Application.GetRealHeight(1097);
             frame.BackgroundColor = UserCenterColor.Current.White;
             frame.Gravity = Gravity.Center;
-            frame.Radius = (uint)Application.GetMinRealAverage(6);
+            frame.Radius = (uint)Application.GetRealHeight(17);
             bodyFrameLayout.AddChidren(frame);
 
             //鐢ㄦ埛鍥炬爣
-            var btnUserIcon = new PicViewControl(207, 207);
-            btnUserIcon.Y = Application.GetRealHeight(104);
+            string iconPath = System.IO.Path.Combine(UserCenterResourse.AccountOption.UserPictruePath, memberInfo.DistributedMark + ".png");
+            var btnUserIcon = new ImageView();
+            btnUserIcon.Height = this.GetPictrueRealSize(207);
+            btnUserIcon.Width = this.GetPictrueRealSize(207);
+            btnUserIcon.Radius = (uint)this.GetPictrueRealSize(207) / 2;
+            btnUserIcon.Y = Application.GetRealHeight(104);
             btnUserIcon.Gravity = Gravity.CenterHorizontal;
-            btnUserIcon.UnSelectedImagePath = "Center/Admin.png";
+            if (System.IO.File.Exists(iconPath) == true)
+            {
+                btnUserIcon.ImageBytes = Shared.IO.FileUtils.ReadFile(iconPath);
+            }
+            else
+            {
+                btnUserIcon.ImagePath = "Center/Admin.png";
+            }
             frame.AddChidren(btnUserIcon);
 
             //鏄电О
             var btnName = new NormalViewControl(frame.Width, Application.GetRealHeight(55), false);
-            btnName.TextAlignment = TextAlignment.Center;
-            btnName.Y = Application.GetRealHeight(334);
-            btnName.TextColor = UserCenterColor.Current.TextColor2;
-            btnName.TextSize = 16;
-            btnName.Text = memberInfo.UserName;
+            btnName.IsBold = true;
+            btnName.TextAlignment = TextAlignment.Center;
+            btnName.Y = Application.GetRealHeight(334);
+            btnName.TextColor = UserCenterColor.Current.TextColor2;
+            btnName.TextSize = 16;
+            btnName.Text = memberInfo.UserName;
             if (string.IsNullOrEmpty(memberInfo.UserName) == true)
             {
                 btnName.Text = memberInfo.Account;
@@ -68,35 +80,55 @@
 
             //鏉冮檺
             var btnAuthority = new NormalViewControl(frame.Width, Application.GetRealHeight(50), false);
-            btnAuthority.TextAlignment = TextAlignment.Center;
-            btnAuthority.Y = Application.GetRealHeight(400);
-            btnAuthority.TextColor = UserCenterColor.Current.TextGrayColor;
-            btnAuthority.TextID = R.MyInternationalizationString.uMember;
+            btnAuthority.TextAlignment = TextAlignment.Center;
+            btnAuthority.Y = Application.GetRealHeight(400);
+            btnAuthority.TextColor = UserCenterColor.Current.TextGrayColor1;
+            if (memberInfo.AccountType == 1)
+            {
+                btnAuthority.TextID = R.MyInternationalizationString.Administrator;
+            }
+            else
+            {
+                btnAuthority.TextID = R.MyInternationalizationString.uMember;
+            }
             btnAuthority.TextSize = 12;
             frame.AddChidren(btnAuthority);
 
-            //鎴愬憳鎺堟潈鎴愬姛
+            
             var btnMsg = new NormalViewControl(frame.Width, Application.GetRealHeight(81), false);
-            btnMsg.TextID = R.MyInternationalizationString.uMemberAuthorizationSuccess;
+            btnMsg.IsBold = true;
+            if (memberInfo.AccountType == 1)
+            {
+                //鎺堟潈鎴愬姛!
+                btnMsg.TextID = R.MyInternationalizationString.uMemberAuthorizationSuccess;
+            }
+            else
+            {
+                //鍙栨秷鎴愬姛
+                btnMsg.TextID = R.MyInternationalizationString.uCancelSuccess;
+            }
             btnMsg.Y = Application.GetRealHeight(541);
             btnMsg.TextAlignment = TextAlignment.Center;
             btnMsg.TextSize = 20;
             frame.AddChidren(btnMsg);
 
-            //璇ユ垚鍛樺凡鎴愪负绠$悊鍛�,鎮ㄧ殑鎺у埗鏉冨凡绉讳氦
-            string strMsg = Language.StringByID(R.MyInternationalizationString.uSubAccountLevelIsUpAndLetAuthorization);
-            if (strMsg.Contains("{0}") == true)
-            {
-                strMsg = string.Format(strMsg, "\r\n", "\r\n");
-            }
-            var btnView = new NormalViewControl(frame.Width, Application.GetRealHeight(147), false);
-            btnView.Y = Application.GetRealHeight(622);
+            var btnView = new NormalViewControl(frame.Width, Application.GetRealHeight(50), false);
+            btnView.Y = btnMsg.Bottom;
             btnView.TextAlignment = TextAlignment.Center;
-            btnView.Text = strMsg;
-            btnView.TextColor = UserCenterColor.Current.TextGrayColor;
+            if (memberInfo.AccountType == 1)
+            {
+                //璇ユ垚鍛樺凡鎴愪负绠$悊鍛�
+                btnView.TextID = R.MyInternationalizationString.uSubAccountLevelIsUp;
+            }
+            else
+            {
+                //璇ョ鐞嗗憳宸叉垚涓烘垚鍛�
+                btnView.TextID = R.MyInternationalizationString.uSubAccountLevelIsDown;
+            }
+            btnView.TextColor = UserCenterColor.Current.TextGrayColor1;
             btnView.IsMoreLines = true;
             btnView.TextSize = 12;
-            frame.AddChidren(btnView);
+            frame.AddChidren(btnView);
 
             //瀹屾垚
             var btnFinish = new BottomClickButton(688);

--
Gitblit v1.8.0