From 9ef48d7b2da7c408b53f73be0f6eef3cbac1c84a Mon Sep 17 00:00:00 2001
From: 黄学彪 <hxb@hdlchina.com.cn>
Date: 星期四, 19 十一月 2020 10:23:45 +0800
Subject: [PATCH] Evoyo.Home1.1.0120111601_Release

---
 ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/CompoundControls/BelongAreaControl.cs |   18 ++++++++++++------
 1 files changed, 12 insertions(+), 6 deletions(-)

diff --git a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/CompoundControls/BelongAreaControl.cs b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/CompoundControls/BelongAreaControl.cs
index 8bbe274..a8c760c 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/CompoundControls/BelongAreaControl.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/CompoundControls/BelongAreaControl.cs
@@ -54,7 +54,7 @@
         /// <param name="i_gateway">缃戝叧瀵硅薄</param>
         public void InitControl(string i_caption, ZigBee.Device.ZbGateway i_gateway)
         {
-            var room = HdlGatewayLogic.Current.GetRoomByGateway(i_gateway);
+            var room = HdlRoomLogic.Current.GetRoomByGateway(i_gateway);
             this.DoInitControl(i_caption, room);
         }
 
@@ -76,7 +76,7 @@
         /// <param name="i_listDevice">璁惧瀵硅薄</param>
         public void InitControl(string i_caption, List<ZigBee.Device.CommonDevice> i_listDevice)
         {
-            var room = Common.LocalDevice.Current.GeteRealDeviceRoom(i_listDevice[0]);
+            var room = HdlRoomLogic.Current.GeteRealDeviceRoom(i_listDevice[0]);
             this.DoInitControl(i_caption, room);
         }
 
@@ -144,11 +144,15 @@
             //鍙崇澶�
             this.AddRightArrow();
 
-            this.ButtonClickEvent += (sender, e) =>
+            //濡傛灉褰撳墠鏄睍绀烘ā鏉�,鍒欓渶瑕佸鐞�
+            if (Common.Config.Instance.Home.IsShowTemplate == false)
             {
-                //鍖哄煙閫夋嫨
-                this.ShowSelectRoom(btnTextView, i_caption);
-            };
+                this.ButtonClickEvent += (sender, e) =>
+                {
+                    //鍖哄煙閫夋嫨
+                    this.ShowSelectRoom(btnTextView, i_caption);
+                };
+            }
         }
 
         #endregion
@@ -169,6 +173,8 @@
                 txtView.Text = selectName;
                 //璋冪敤鍥炶皟鍑芥暟
                 this.SelectRoomEvent?.Invoke(RoomKey);
+                //涓婁紶绌洪棿鍖哄煙淇℃伅
+                HdlRoomLogic.Current.SetRoomInfoToGateway();
             });
             if (result == false)
             {

--
Gitblit v1.8.0