From 01c46e7bfe9aa8fb20b29f70c83c03a307af548a Mon Sep 17 00:00:00 2001
From: JLChen <551775569@qq.com>
Date: 星期二, 22 十二月 2020 16:35:16 +0800
Subject: [PATCH] 2020-12-22 1.更新。

---
 HDL_ON/UI/UI2/3-Intelligence/Automation/LogicMethod.cs |   14 +++++++++-----
 1 files changed, 9 insertions(+), 5 deletions(-)

diff --git a/HDL_ON/UI/UI2/3-Intelligence/Automation/LogicMethod.cs b/HDL_ON/UI/UI2/3-Intelligence/Automation/LogicMethod.cs
old mode 100644
new mode 100755
index 6154e4a..8a0f17e
--- a/HDL_ON/UI/UI2/3-Intelligence/Automation/LogicMethod.cs
+++ b/HDL_ON/UI/UI2/3-Intelligence/Automation/LogicMethod.cs
@@ -5,7 +5,7 @@
 namespace HDL_ON.UI.UI2.Intelligence.Automation
 {
 
-    public class LogicMethod
+    public  class  LogicMethod
     {
         /// <summary>
         /// 琛ㄧず鏄潯浠�
@@ -135,7 +135,6 @@
         /// <returns></returns>
         public static List<HDL_ON.Entity.Room> GetGatewayRoomList(string name)
         {
-
             List<Entity.Room> roomList = new List<Entity.Room>();
             Entity.Room room1 = new Entity.Room();
             room1.roomName = name;//榛樿涓�涓埧闂村悕涓�:鍏ㄩ儴鍖哄煙
@@ -144,9 +143,14 @@
             var roomLists = GetGatewayRoomList();
             foreach (var room in roomLists)
             {
+                var devlist = GetRoomDevice(room);
+                if (devlist.Count == 0)
+                {
+                    //杩囨护鎺夋病鏈夎澶囩殑鎴块棿;
+                    continue;
+                }
                 roomList.Add(room);
             }
-
             return roomList;
         }
         /// <summary>
@@ -155,7 +159,7 @@
         /// <returns></returns>
         public static List<HDL_ON.Entity.Function> GetGatewayDeviceList()
         {
-            return HDL_ON.Entity.DB_ResidenceData.functionList.GetAllFunction();
+            return Entity.FunctionList.List.GetDeviceFunctionList();
         }
         /// <summary>
         /// 鑾峰彇缃戝叧鍦烘櫙鍒楄〃
@@ -163,7 +167,7 @@
         /// <returns></returns>
         public static List<HDL_ON.Entity.Scene> GetSceneList()
         {
-            return HDL_ON.Entity.DB_ResidenceData.functionList.scenes;
+            return HDL_ON.Entity.FunctionList.List.scenes;
         }
         /// <summary>
         /// 鑾峰彇鎴块棿鐨勮澶囧垪琛�

--
Gitblit v1.8.0