|
|
|
@ -241,12 +241,13 @@ public class FilterLogSaveEventListener { |
|
|
|
Set<FilterLogEntity> unMergedLogs = new HashSet<>(); |
|
|
|
for (FilterLogEntity currentLog : logs) { |
|
|
|
Set<String> thingAttrs; |
|
|
|
if(onlyMergeMissThingAttr){ |
|
|
|
if (onlyMergeMissThingAttr) { |
|
|
|
thingAttrs = currentLog.getMissingThingAttrs(); |
|
|
|
if (CollectionUtils.isEmpty(thingAttrs)) { |
|
|
|
mergedLogs.add(currentLog); |
|
|
|
continue; |
|
|
|
} |
|
|
|
}else { |
|
|
|
} else { |
|
|
|
thingAttrs = currentLog.getDefThingAttrs(); |
|
|
|
} |
|
|
|
thingAttrs.forEach( |
|
|
|
@ -271,7 +272,9 @@ public class FilterLogSaveEventListener { |
|
|
|
} |
|
|
|
}); |
|
|
|
} |
|
|
|
mergedLogs.addAll(unMergedLogs); |
|
|
|
if (!unMergedLogs.isEmpty()) { |
|
|
|
mergedLogs.addAll(unMergedLogs); |
|
|
|
} |
|
|
|
return mergedLogs.stream().filter(Objects::nonNull).collect(Collectors.toSet()); |
|
|
|
} |
|
|
|
|
|
|
|
|