From 2ec9898778d3beda89278e2a53ac0e68b3035d29 Mon Sep 17 00:00:00 2001
From: 陈嘉乐 <cjl@hdlchina.com.cn>
Date: 星期三, 01 七月 2020 15:06:24 +0800
Subject: [PATCH] 2020-7-1-2

---
 ZigbeeApp/Shared/Phone/Device/Logic/DoorLockLogic/LockLogicList.cs |   46 ++++------------------------------------------
 1 files changed, 4 insertions(+), 42 deletions(-)

diff --git a/ZigbeeApp/Shared/Phone/Device/Logic/DoorLockLogic/LockLogicList.cs b/ZigbeeApp/Shared/Phone/Device/Logic/DoorLockLogic/LockLogicList.cs
old mode 100644
new mode 100755
index b9531ef..55df661
--- a/ZigbeeApp/Shared/Phone/Device/Logic/DoorLockLogic/LockLogicList.cs
+++ b/ZigbeeApp/Shared/Phone/Device/Logic/DoorLockLogic/LockLogicList.cs
@@ -99,33 +99,7 @@
                             continue;
                         }
                         Common.Logic.LockLogicList.Add(logic);
-                        //bool yes = false;
-                        //for (int a = 0; a < logic.Accounts.Count; a++)
-                        //{
-                        //    //Option4鏄澶噈ac锛汷ption2鏄澶囩鍙o紱
-                        //    if (logic.Accounts[a]["Option4"].ToString() != Send.CurrentDoorLock.DeviceAddr && logic.Accounts[a]["Option2"].ToString() != Send.CurrentDoorLock.DeviceEpoint.ToString())
-                        //    {
-                        //        //鏌ユ壘鏄惁鏄偅涓棬閿侊紱
-                        //        //濡傛灉涓嶆槸璇ラ棬閿佽仈鍔ㄤ簨浠朵笉鏄剧ず鍑烘潵;
-                        //        yes = false;
-
-                        //    }
-                        //    else
-                        //    {
-                        //        yes = true;
-
-                        //    }
-                        //    //if (logic.Accounts[a]["Account"].ToString() == Config.Instance.Guid)
-                        //    //{
-                        //    //    //鏌ユ壘鑷繁璐﹀彿涓嬬殑鍒涘缓鑱斿姩浜嬩欢锛�
-                        //    //    yes = true;
-                        //    //    break;
-                        //    //}
-                        //}
-                        //if (yes)
-                        //{
-                        //    Common.Logic.LockLogicList.Add(listlogic[j]);
-                        //}
+                      
                     }
                 }
             }
@@ -320,29 +294,17 @@
         /// <returns></returns>
         private bool Exist(Common.Logic logic)
         {
-            bool yes = false;
             for (int j = 0; j < logic.Accounts.Count; j++)
             {
                 //Option4鏄澶噈ac锛汷ption2鏄澶囩鍙o紱
-                if (logic.Accounts[j]["Option4"].ToString() != Send.CurrentDoorLock.DeviceAddr && logic.Accounts[j]["Option2"].ToString() != Send.CurrentDoorLock.DeviceEpoint.ToString())
+                if (logic.Accounts[j]["Option4"].ToString() == Send.CurrentDoorLock.DeviceAddr)
                 {
                     //鏌ユ壘鏄惁鏄偅涓棬閿侊紱
                     //濡傛灉涓嶆槸璇ラ棬閿佽仈鍔ㄤ簨浠朵笉鏄剧ず鍑烘潵;
-                    yes = false;
+                    return true;
                 }
-                else
-                {
-                    yes = true;
-                }
-                //if (logic.Accounts[j]["Account"].ToString() == Config.Instance.Guid)
-                //{
-                //    //鏌ユ壘鑷繁璐﹀彿涓嬬殑鍒涘缓鑱斿姩浜嬩欢锛�
-                //    yes = true;
-                //    break;
-                //}
-
             }
-            return yes;
+            return false;
         }
     }
 }

--
Gitblit v1.8.0