Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
sample-form-platform
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
赵啸非
sample-form-platform
Commits
4457030b
Commit
4457030b
authored
Feb 19, 2023
by
赵啸非
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加材料数量统计
parent
fbad186f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
5 deletions
+6
-5
sample-form-manager/src/main/java/com/mortals/xhx/daemon/task/SyncSiteMatterTaskImpl.java
...a/com/mortals/xhx/daemon/task/SyncSiteMatterTaskImpl.java
+6
-5
No files found.
sample-form-manager/src/main/java/com/mortals/xhx/daemon/task/SyncSiteMatterTaskImpl.java
View file @
4457030b
...
@@ -46,7 +46,8 @@ public class SyncSiteMatterTaskImpl implements ITaskExcuteService {
...
@@ -46,7 +46,8 @@ public class SyncSiteMatterTaskImpl implements ITaskExcuteService {
if
(
siteRest
.
getCode
()
==
YesNoEnum
.
YES
.
getValue
())
{
if
(
siteRest
.
getCode
()
==
YesNoEnum
.
YES
.
getValue
())
{
log
.
info
(
"总数量:{}"
,
siteRest
.
getData
().
size
());
log
.
info
(
"总数量:{}"
,
siteRest
.
getData
().
size
());
siteRest
.
getData
().
forEach
(
site
->
{
siteRest
.
getData
().
forEach
(
site
->
{
int
page
=
100
;
sheetMatterService
.
getDao
().
delete
(
new
SheetMatterQuery
().
siteId
(
site
.
getId
()));
int
page
=
100
;
int
pageNum
=
100
;
int
pageNum
=
100
;
for
(
int
i
=
1
;
i
<=
page
;
i
++){
for
(
int
i
=
1
;
i
<=
page
;
i
++){
SiteMatterPdu
siteMatterPdu
=
new
SiteMatterPdu
();
SiteMatterPdu
siteMatterPdu
=
new
SiteMatterPdu
();
...
@@ -76,12 +77,12 @@ public class SyncSiteMatterTaskImpl implements ITaskExcuteService {
...
@@ -76,12 +77,12 @@ public class SyncSiteMatterTaskImpl implements ITaskExcuteService {
}).
collect
(
Collectors
.
toList
());
}).
collect
(
Collectors
.
toList
());
if
(!
ObjectUtils
.
isEmpty
(
sheetMatterEntities
))
{
if
(!
ObjectUtils
.
isEmpty
(
sheetMatterEntities
))
{
sheetMatterService
.
getDao
().
delete
(
new
SheetMatterQuery
().
siteId
(
site
.
getId
()));
//
sheetMatterService.getDao().delete(new SheetMatterQuery().siteId(site.getId()));
log
.
info
(
"新增数量:{}"
,
sheetMatterEntities
.
size
());
log
.
info
(
"新增数量:{}"
,
sheetMatterEntities
.
size
());
List
<
List
<
SheetMatterEntity
>>
partition
=
ListUtil
.
partition
(
sheetMatterEntities
,
500
);
sheetMatterService
.
save
(
sheetMatterEntities
);
/* List<List<SheetMatterEntity>> partition = ListUtil.partition(sheetMatterEntities, 500);
for (List<SheetMatterEntity> matterEntities : partition) {
for (List<SheetMatterEntity> matterEntities : partition) {
sheetMatterService
.
save
(
matterEntities
);
}*/
}
}
}
}
else
{
}
else
{
...
...
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