#添加了设备类型查询显示
This commit is contained in:
@@ -234,6 +234,12 @@ public class Device extends BaseDO {
|
||||
|
||||
private Boolean hasHost;
|
||||
|
||||
@TableField(exist = false)
|
||||
private String productModel;// 产品型号
|
||||
|
||||
@TableField(exist = false)
|
||||
private String deviceType;
|
||||
|
||||
@TableField(exist = false)
|
||||
private LocationMessage locationMessage;
|
||||
|
||||
|
||||
@@ -570,16 +570,16 @@ public class HostMessageHandler implements CustomMqttMessageHandler {
|
||||
}
|
||||
}
|
||||
}
|
||||
// try {
|
||||
// NettyDevice device = deviceSessionManager.getDevice(deviceId);
|
||||
// if (device != null && device.getDevice() != null) {
|
||||
// Long siteId = device.getDevice().getSiteId();
|
||||
// websocketMesDispather.mapMessageDispather(siteId,
|
||||
// JsonUtils.toJsonString(sendDto));
|
||||
// }
|
||||
// } catch (Exception e) {
|
||||
// log.error("实时地图数据websocket推送失败: siteId={}, error={}", e);
|
||||
// }
|
||||
try {
|
||||
NettyDevice device = deviceSessionManager.getDevice(deviceId);
|
||||
if (device != null && device.getDevice() != null) {
|
||||
Long siteId = device.getDevice().getSiteId();
|
||||
websocketMesDispather.mapMessageDispather(siteId,
|
||||
JsonUtils.toJsonString(sendDto));
|
||||
}
|
||||
} catch (Exception e) {
|
||||
log.error("实时地图数据websocket推送失败: siteId={}, error={}", e);
|
||||
}
|
||||
// todo 推送实时位置和状态消息到外部
|
||||
try {
|
||||
GlobalMemory.customMqttDeviceMonitor.publish(mqttClientId,
|
||||
|
||||
Reference in New Issue
Block a user