From 72be4f06a683de33ddd563c8447c39f7f17e5b7d Mon Sep 17 00:00:00 2001
From: 黄学彪 <hxb@hdlchina.com.cn>
Date: 星期一, 06 一月 2020 13:03:50 +0800
Subject: [PATCH] 合并代码

---
 ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlGatewayReceiveLogic.cs |   31 +++++++++++++++----------------
 1 files changed, 15 insertions(+), 16 deletions(-)

diff --git a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlGatewayReceiveLogic.cs b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlGatewayReceiveLogic.cs
index 76b7605..303e827 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlGatewayReceiveLogic.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlGatewayReceiveLogic.cs
@@ -51,8 +51,8 @@
         /// <param name="gatewayId">缃戝叧ID</param>
         /// <param name="topic">鏁翠釜涓婚</param>
         /// <param name="reportTopic">涓婃姤鏁版嵁鐨勪富棰�</param>
-        /// <param name="receiveData">鎺ユ敹鐨勬暟鎹�</param>
-        public void GatewayOverallMsgReceive(string gatewayId, string topic, string reportTopic, JObject receiveData)
+        /// <param name="msgData">鎺ユ敹鐨勬暟鎹�</param>
+        public void GatewayOverallMsgReceive(string gatewayId, string topic, string reportTopic, string msgData)
         {
             if (topic == "AppNoLogin")
             {
@@ -67,7 +67,7 @@
                 });
                 return;
             }
-            else if (topic == "BeingSqueezedOffline")
+            else if (topic == "ZigbeeGateWayToClient/" + Common.Config.Instance.ConnEmqClientId + "/Push/NotifySqueeze")
             {
                 HdlThreadLogic.Current.RunMain(() =>
                 {
@@ -93,8 +93,8 @@
                 });
                 return;
             }
-            else if (topic == "/ZigbeeGateWayToClient/" + Common.Config.Instance.Guid + "/Push/Deleted"
-                || topic == "/ZigbeeGateWayToClient/" + Common.Config.Instance.Guid + "/Push/DeletedShareData")
+            else if (topic == "ZigbeeGateWayToClient/" + Common.Config.Instance.Guid + "/Push/Deleted"
+                || topic == "ZigbeeGateWayToClient/" + Common.Config.Instance.Guid + "/Push/DeletedShareData")
             {
                 if (UserCenterResourse.UserInfo.AuthorityNo == 3)
                 {
@@ -117,52 +117,51 @@
                     //涓嶆槸鑷繁缁戝畾鐨勭綉鍏筹紝鍒欎笉澶勭悊
                     return;
                 }
-
                 //璁惧灞炴�т笂鎶�
                 if (reportTopic == "DeviceStatusReport")
                 {
                     //璁惧灞炴�т笂鎶�
-                    this.DeviceAttributeReportPush(receiveData);
+                    this.DeviceAttributeReportPush(JObject.Parse(msgData));
                 }
                 //浼犳劅鍣ㄤ笂鎶�
                 else if (reportTopic == "IASInfoReport")
                 {
-                    this.SensorDeviceReportPush(receiveData);
+                    this.SensorDeviceReportPush(JObject.Parse(msgData));
                 }
                 //闂ㄩ攣涓婃姤
                 else if (topic == gatewayId + "/Alarms/SendAlarmInform")
                 {
-                    this.DoorLockDeviceReportPush(receiveData);
+                    this.DoorLockDeviceReportPush(null);
                 }
                 //閫氳繃澶栭儴鏂瑰紡甯冮槻鎾ら槻鎴愬姛鏃舵姤鍛�
                 else if (topic == gatewayId + "/Security/EnOrWithdrawSucceedReport")
                 {
-                    this.SecurityEnOrWithdrawSucceedReport(receiveData);
+                    this.SecurityEnOrWithdrawSucceedReport(JObject.Parse(msgData));
                 }
                 //璁惧鍦ㄧ嚎鐘舵�佹洿鏂板弽棣�
                 else if (reportTopic == "OnlineStatusChange_Respon")
                 {
-                    this.DeviceOnlineChangePush(receiveData);
+                    this.DeviceOnlineChangePush(JObject.Parse(msgData));
                 }
                 //鎾ら槻
                 else if (topic == gatewayId + "/Security/WithdrawMode_Respon")
                 {
-                    this.RemoveSafetyGarrisonPush(receiveData);
+                    this.RemoveSafetyGarrisonPush(JObject.Parse(msgData));
                 }
                 //甯冮槻
                 else if (topic == gatewayId + "/Security/EnableMode_Respon")
                 {
-                    this.SetSafetyGarrisonPush(receiveData);
+                    this.SetSafetyGarrisonPush(JObject.Parse(msgData));
                 }
                 //閫昏緫瑙﹀彂涓婃姤
                 else if (topic == gatewayId + "/Logic/Execute_Respon")
                 {
-                    this.LogicExecutePush(receiveData);
+                    this.LogicExecutePush(null);
                 }
                 //鍦烘櫙瑙﹀彂涓婃姤
                 else if (topic == gatewayId + "/Scene/Exec_Respon")
                 {
-                    this.SceneExecPush(receiveData);
+                    this.SceneExecPush(null);
                 }
             }
             catch (Exception ex)
@@ -233,7 +232,7 @@
         private void DoorLockDeviceReportPush(JObject receiveData)
         {
             //淇濆瓨闂ㄩ攣淇℃伅鍒版湰鍦�
-            HdlAlarmsLogic.Current.SaveDoorLockAlarmInfo(receiveData);
+            //HdlAlarmsLogic.Current.SaveDoorLockAlarmInfo(receiveData);
 
             //鏄剧ず鏈夋柊娑堟伅鐨勭壒鏁�
             this.ShowHadNewMessageAppeal();

--
Gitblit v1.8.0