Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Sign in
Toggle navigation
T
tamp_fund
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
周鹏
tamp_fund
Commits
dc2967c6
Commit
dc2967c6
authored
Nov 15, 2023
by
钱坤
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
私募的latest_nav更新startDate逻辑调整
parent
e1df123d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
2 deletions
+6
-2
FundLatestNavService.java
...ava/com/tanpu/fund/service/impl/FundLatestNavService.java
+6
-2
No files found.
src/main/java/com/tanpu/fund/service/impl/FundLatestNavService.java
View file @
dc2967c6
...
...
@@ -49,6 +49,8 @@ public class FundLatestNavService {
Date
startTime
=
list
.
get
(
0
).
getCreateTime
();
List
<
FundLatestNav
>
latestList
=
fundInfoCustomMapper
.
getFundLatestNet
(
startTime
);
List
<
FundLatestNav
>
latestListRH
=
fundInfoCustomMapper
.
getFundLatestNetInRH
(
startTime
);
Date
newStartTime
=
latestList
.
stream
().
map
(
FundLatestNav:
:
getCreateTime
).
max
(
Date:
:
compareTo
).
orElseGet
(
null
);
Date
newStartTimeRH
=
latestListRH
.
stream
().
map
(
FundLatestNav:
:
getCreateTime
).
max
(
Date:
:
compareTo
).
orElseGet
(
null
);
List
<
FundLatestNav
>
navList
=
new
ArrayList
<>(
latestListRH
.
size
()
+
latestList
.
size
()
+
1
);
navList
.
addAll
(
latestList
);
navList
.
addAll
(
latestListRH
);
...
...
@@ -104,8 +106,10 @@ public class FundLatestNavService {
p
+=
200
;
}
Date
newStartTime
=
latestList
.
stream
().
map
(
FundLatestNav:
:
getCreateTime
).
max
(
Date:
:
compareTo
).
get
();
Date
newStartTimeRH
=
latestListRH
.
stream
().
map
(
FundLatestNav:
:
getCreateTime
).
max
(
Date:
:
compareTo
).
get
();
if
(
newStartTime
==
null
||
newStartTimeRH
==
null
)
{
log
.
info
(
"私募新净值起始时间本次不需要更新,newStartTime: {}, start: {}"
,
newStartTime
,
newStartTimeRH
);
return
;
}
FundLatestNav
target
=
new
FundLatestNav
();
// 存储较小的那个,保证两个表里的都能被扫描到.
target
.
setCreateTime
(
newStartTime
.
before
(
newStartTimeRH
)
?
newStartTime
:
newStartTimeRH
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment