1.谐波溯源算法

2.北京暂降平台
This commit is contained in:
2025-10-10 08:33:37 +08:00
parent 5c8088e808
commit 2b1a33aea0
16 changed files with 586 additions and 406 deletions

View File

@@ -480,16 +480,9 @@ public class LedgerScaleServiceImpl implements LedgerScaleService {
InputStream respStream = fileStorageUtil.getFileStream(respDataResult.getUserResponsibility());
String respStr = IoUtil.readUtf8(respStream);
List<CustomerResponsibility> respData = JSONArray.parseArray(respStr, CustomerResponsibility.class);
List<String> userNos = respData.stream().map(it -> it.getCustomerName().substring(it.getCustomerName().indexOf("(") + 1, it.getCustomerName().indexOf(")"))).collect(Collectors.toList());
List<LedgerBaseInfo> ledgerBaseInfoList = lineMapper.queryMonitorByUser(userNos);
Map<String, LedgerBaseInfo> ledgerBaseInfoMap = ledgerBaseInfoList.stream().collect(Collectors.toMap(LedgerBaseInfo::getUserNo, Function.identity()));
respData.forEach(it -> {
String tem = it.getCustomerName().substring(it.getCustomerName().indexOf("(") + 1, it.getCustomerName().indexOf(")"));
if (ledgerBaseInfoMap.containsKey(tem)) {
LedgerBaseInfo ledgerBaseInfo = ledgerBaseInfoMap.get(tem);
it.setMonitorId(ledgerBaseInfo.getLineId());
}
it.setMonitorId(tem);
});
return respData;
}