|
@@ -481,7 +481,11 @@ public class CockpitHandlingEfficiencyService {
|
|
|
? warningFacts(snapshot, types, industry, level, district)
|
|
? warningFacts(snapshot, types, industry, level, district)
|
|
|
: alarmFacts(snapshot, types, industry, level, district);
|
|
: alarmFacts(snapshot, types, industry, level, district);
|
|
|
for (EventFact fact : facts) {
|
|
for (EventFact fact : facts) {
|
|
|
|
|
+ // 发布时刻缺失时退回更新时间(不把已存在的预警从窗口里抹掉)。
|
|
|
OffsetDateTime eventTime = parseEventTime(fact.eventTime);
|
|
OffsetDateTime eventTime = parseEventTime(fact.eventTime);
|
|
|
|
|
+ if (eventTime == null) {
|
|
|
|
|
+ eventTime = parseEventTime(fact.updateTime);
|
|
|
|
|
+ }
|
|
|
if (eventTime == null) {
|
|
if (eventTime == null) {
|
|
|
continue;
|
|
continue;
|
|
|
}
|
|
}
|
|
@@ -579,11 +583,15 @@ public class CockpitHandlingEfficiencyService {
|
|
|
String industry) {
|
|
String industry) {
|
|
|
CockpitHandlingEfficiencySnapshot.SourceType type =
|
|
CockpitHandlingEfficiencySnapshot.SourceType type =
|
|
|
isBlank(typeCode) ? null : types.get(typeCode.trim());
|
|
isBlank(typeCode) ? null : types.get(typeCode.trim());
|
|
|
- if (type == null
|
|
|
|
|
- || !SMART_DEVICE.equals(type.getObjectKind())
|
|
|
|
|
|
|
+ // 维护者 2026-11-05:预警条目不得因类型解析不出而被丢;行业如实为 null,
|
|
|
|
|
+ // 只有显式行业筛选才排除。
|
|
|
|
|
+ if (type == null) {
|
|
|
|
|
+ return industry == null;
|
|
|
|
|
+ }
|
|
|
|
|
+ if (!SMART_DEVICE.equals(type.getObjectKind())
|
|
|
|| type.getIndustry() == null
|
|
|| type.getIndustry() == null
|
|
|
|| !INDUSTRIES.contains(type.getIndustry())) {
|
|
|| !INDUSTRIES.contains(type.getIndustry())) {
|
|
|
- return false;
|
|
|
|
|
|
|
+ return industry == null;
|
|
|
}
|
|
}
|
|
|
return industry == null || industry.equals(type.getIndustry());
|
|
return industry == null || industry.equals(type.getIndustry());
|
|
|
}
|
|
}
|