|
|
@@ -193,6 +193,9 @@ public class IotAlarmRuleSourceServiceImpl extends ServiceImpl<IotAlarmRuleSourc
|
|
|
final Map<String, List<IotSensor>> deviceIdAndName = iotSensors.stream().collect(Collectors.groupingBy(IotSensor::getDeviceCode));
|
|
|
for (ProductDeviceTempVo ptv : deviceTempList) {
|
|
|
final List<IotSensor> sensorList = deviceIdAndName.get(ptv.getDeviceId());
|
|
|
+ if (ObjectUtil.isNull(sensorList)) {
|
|
|
+ continue;
|
|
|
+ }
|
|
|
for (IotSensor iotSensor : sensorList) {
|
|
|
ptv.setDeviceName(iotSensor.getDeviceName());
|
|
|
ptv.setOrgName(iotSensor.getOrgName());
|