mirror of
https://codeup.aliyun.com/67c68d4e484ca2f0a13ac3c1/ydc/jsowell-charger-web.git
synced 2026-04-20 19:15:35 +08:00
update 电池算法应用Service
This commit is contained in:
@@ -131,10 +131,12 @@ public class NotificationService {
|
||||
logger.error("平台类型:{}, 平台名称:{}, 站点id:{}, 订单编号:{}, 设备充电中状态变化推送error:{}",
|
||||
secretInfoVO.getPlatformType(), secretInfoVO.getPlatformName(), stationId, orderCode, e.getMessage());
|
||||
}
|
||||
try {
|
||||
platformService.notificationEquipChargeStatus(orderCode);
|
||||
}catch (Exception e){
|
||||
logger.error("notification_equip_charge_status error", e);
|
||||
finally {
|
||||
try {
|
||||
platformService.notificationEquipChargeStatus(orderCode);
|
||||
}catch (Exception e){
|
||||
logger.error("notification_equip_charge_status error", e);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -24,10 +24,7 @@ import org.springframework.stereotype.Service;
|
||||
import org.springframework.util.CollectionUtils;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.ArrayList;
|
||||
import java.util.LinkedHashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.*;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
/**
|
||||
@@ -149,6 +146,10 @@ public class ChargeAlgorithmService {
|
||||
|
||||
List<ChargeAlgorithmData
|
||||
.ChargingDetailInfo> chargingDetailInfos = transformData(transactionCode, chargerOutputInfoList, parameterConfigData, transactionRecordsData);
|
||||
chargingDetailInfos.stream()
|
||||
.filter(info -> info.getCurrentSoc() > 100) // 只处理 currentSoc > 100 的元素
|
||||
.forEach(info -> info.setCurrentSoc(100));
|
||||
Collections.reverse(chargingDetailInfos);
|
||||
|
||||
data.setChargingDetailInfo(chargingDetailInfos);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user