Commit f354a8ea authored by 张亚辉's avatar 张亚辉

无净值基金推荐

parent cf692241
......@@ -1677,6 +1677,7 @@ public class ProductServiceImpl implements ProductService, Constant {
PageMethod.startPage(1, 10);
List<IfaImportedFundInfo> importedFundInfoList = ifaImportedFundInfoMapper.selectByExample(example);
if (CollectionUtils.isNotEmpty(importedFundInfoList)) {
List<String> fundIdList = importedFundInfoList.stream().map(IfaImportedFundInfo::getId).collect(Collectors.toList());
IfaImportedFundCountExample countExample = new IfaImportedFundCountExample();
......@@ -1692,7 +1693,7 @@ public class ProductServiceImpl implements ProductService, Constant {
List<String> checkFundIdList = feignClientForDiagnose.getFundCollectInfo(fundIdList).getAttributes();
importedFundInfoList.forEach(item -> {
return importedFundInfoList.stream().map(item -> {
FundSameResp p = FundSameResp.builder()
.fundId(item.getId())
.fundName(item.getFundName())
......@@ -1702,7 +1703,9 @@ public class ProductServiceImpl implements ProductService, Constant {
if (fundCountMap != null && fundCountMap.containsKey(item.getId())) {
p.setRet1y(BigDecimalUtil.toString(fundCountMap.get(item.getId()).getRet1y(), 2));
}
});
return p;
}).collect(Collectors.toList());
}
return new ArrayList<>(0);
}
......@@ -2415,16 +2418,16 @@ public class ProductServiceImpl implements ProductService, Constant {
PageMethod.startPage(1, 10);
List<IfaImportedNonavFund> importedFundInfoList = ifaImportedNonavFundMapper.selectByExample(example);
if (CollectionUtils.isNotEmpty(importedFundInfoList)) {
List<String> fundIdList = importedFundInfoList.stream().map(IfaImportedNonavFund::getId).collect(Collectors.toList());
List<String> checkFundIdList = feignClientForDiagnose.getFundCollectInfo(fundIdList).getAttributes();
importedFundInfoList.forEach(item -> {
FundSameResp p = FundSameResp.builder()
return importedFundInfoList.stream().map(item -> FundSameResp.builder()
.fundId(item.getId())
.fundName(item.getFundName())
.isCheck(CollectionUtils.isNotEmpty(checkFundIdList) ? (checkFundIdList.contains(item.getId()) ? 1 : 0) : 0)
.build();
});
.build()).collect(Collectors.toList());
}
return new ArrayList<>(0);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment