Commit 42996ee2 authored by 张亚辉's avatar 张亚辉

净值

parent 2fdb4589
......@@ -149,8 +149,20 @@ public class ProductServiceImpl implements ProductService, Constant {
Map<String, List<IndexesProfile>> indexIdMap = getIndexIdMap(ls);
getProductCode(indexIdMap, vo, fundInfo);*/
// 最新净值
vo.setNet(getNewNet(fundInfo.getId()));
//查询净值 最新净值 累计净值取分红不投
{
PageMethod.startPage(1, 1);
FundNavExample navExample = new FundNavExample();
navExample.createCriteria().andFundIdEqualTo(id).andDeleteTagEqualTo(BizEnums.DeleteTag.tag_init);
navExample.setOrderByClause("price_date dec");
List<FundNav> fundNavList = fundNavMapper.selectByExample(navExample);
if (CollectionUtils.isNotEmpty(fundNavList)) {
vo.setNet(Net.builder().netDate(fundNavList.get(0).getPriceDate().getTime())
.netValue(BigDecimalUtil.toString(fundNavList.get(0).getNav(), 4))
.cumulativeNav(BigDecimalUtil.toString(fundNavList.get(0).getCumulativeNavWithdrawal(), 4))
.build());
}
}
// 起投金额
Map<String, FundRateMapping> rateMappingMap = getStringFundRateMappingMap(Lists.newArrayList(id));
......@@ -1393,6 +1405,7 @@ public class ProductServiceImpl implements ProductService, Constant {
PageMethod.startPage(1, 1);
IfaImportedFundNavExample navExample = new IfaImportedFundNavExample();
navExample.createCriteria().andFundIdEqualTo(id).andDeleteTagEqualTo(BizEnums.DeleteTag.tag_init);
navExample.setOrderByClause("price_date");
List<IfaImportedFundNav> navList = ifaImportedFundNavMapper.selectByExample(navExample);
if (CollectionUtils.isNotEmpty(navList)) {
detailResp.setNet(Net.builder().netDate(navList.get(0).getPriceDate().getTime())
......
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