From eb3dd00b0b7fcda477229d518d250f9c842b790b Mon Sep 17 00:00:00 2001
From: feiyu02 <risaku@163.com>
Date: 星期二, 21 十月 2025 17:45:44 +0800
Subject: [PATCH] 2025.10.21 1. 走航季度报告相关数据计算逻辑调整
---
src/main/kotlin/com/flightfeather/uav/biz/sourcetrace/model/PollutedClue.kt | 8 +++++++-
1 files changed, 7 insertions(+), 1 deletions(-)
diff --git a/src/main/kotlin/com/flightfeather/uav/biz/sourcetrace/model/PollutedClue.kt b/src/main/kotlin/com/flightfeather/uav/biz/sourcetrace/model/PollutedClue.kt
index 19eedc2..6035ec5 100644
--- a/src/main/kotlin/com/flightfeather/uav/biz/sourcetrace/model/PollutedClue.kt
+++ b/src/main/kotlin/com/flightfeather/uav/biz/sourcetrace/model/PollutedClue.kt
@@ -45,6 +45,7 @@
var exceptionData = mutableListOf<BaseRealTimeData>()
var historyData = mutableListOf<BaseRealTimeData>()
exceptions.forEach { e ->
+ // 灏嗛噰鏍锋椂闂存渶鏃╃殑浣滀负寮�濮嬫暟鎹�
if (startData == null) {
startData = e.second.startData
} else {
@@ -53,6 +54,7 @@
}
}
+ // 灏嗛噰鏍锋椂闂存渶鏅氱殑浣滀负缁撴潫鏁版嵁
if (endData == null) {
endData = e.second.endData
} else {
@@ -61,6 +63,7 @@
}
}
+ // 灏嗘墍鏈夊紓甯告暟鎹幓閲嶅悎骞�
if (exceptionData.isEmpty()) {
exceptionData = e.second.exceptionData
} else {
@@ -71,6 +74,7 @@
}
}
+ // 灏嗘墍鏈夊巻鍙叉暟鎹幓閲嶅悎骞�
if (historyData.isEmpty()) {
historyData = e.second.historyData
} else {
@@ -81,10 +85,12 @@
}
}
}
+ // 鎸夌収閲囨牱鏃堕棿鍗囧簭鎺掑垪
exceptionData.sortBy { it.dataTime }
historyData.sortBy { it.dataTime }
- val factorList = exceptions.map { it.first }
+ // 鑾峰彇鍘婚噸鍚庣殑鐩戞祴鍥犲瓙绫诲瀷
+ val factorList = exceptions.map { it.first }.distinct()
pollutedData = PollutedData(
startData!!, endData, factorList, exceptionData, historyData, eType, windLevelCondition
)
--
Gitblit v1.9.3