Bläddra i källkod

更新

样式分支
fyf 2 år sedan
förälder
incheckning
c53fd58706
1 ändrade filer med 6 tillägg och 10 borttagningar
  1. +6
    -10
      BPASmartClient.IoT/DataVClient.cs

+ 6
- 10
BPASmartClient.IoT/DataVClient.cs Visa fil

@@ -140,7 +140,6 @@ namespace BPASmartClient.IoT
MessageLog.GetInstance.Show($"客户端:【{ClientId}】,设备名称{DeviceDataV.deviceTable.devicename}阿里云连接成功"); MessageLog.GetInstance.Show($"客户端:【{ClientId}】,设备名称{DeviceDataV.deviceTable.devicename}阿里云连接成功");
} }
else MessageLog.GetInstance.ShowEx(message); else MessageLog.GetInstance.ShowEx(message);

} }


/// <summary> /// <summary>
@@ -171,17 +170,14 @@ namespace BPASmartClient.IoT
/// <param name="message"></param> /// <param name="message"></param>
private void DevIOTActionHandler(string deviceId, string topic, string message) private void DevIOTActionHandler(string deviceId, string topic, string message)
{ {
//if (DeviceDataVs.ContainsKey() DeviceDataVs[deviceId].BroadcastTopic == topic && !string.IsNullOrEmpty(message))//广播主题消息,将广播消息发送到相应客户端
//{
// IOTCommandModel iOTCommand = Tools.JsonToObjectTools<IOTCommandModel>(message);
// if (iOTCommand.deviceName == DeviceDataVs[deviceId].deviceTable.devicename)
// ActionManage.GetInstance.Send("IotBroadcast", iOTCommand);
//}
if (DeviceDataV.BroadcastTopic == topic && !string.IsNullOrEmpty(message))//广播主题消息,将广播消息发送到相应客户端
{
IOTCommandModel iOTCommand = Tools.JsonToObjectTools<IOTCommandModel>(message);
if (iOTCommand.deviceName == DeviceDataV.deviceTable.devicename)
ActionManage.GetInstance.Send("IotBroadcast", iOTCommand);
}
} }
#endregion #endregion


} }


//命令实体类 //命令实体类


Laddar…
Avbryt
Spara