Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
smart_gov_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
赵啸非
smart_gov_platform
Commits
afec1783
Commit
afec1783
authored
Feb 28, 2023
by
赵啸非
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加业务修改通知php
parent
c7f4326f
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
20 deletions
+15
-20
base-manager/src/main/java/com/mortals/xhx/module/site/service/impl/SiteBusinessServiceImpl.java
...xhx/module/site/service/impl/SiteBusinessServiceImpl.java
+15
-20
No files found.
base-manager/src/main/java/com/mortals/xhx/module/site/service/impl/SiteBusinessServiceImpl.java
View file @
afec1783
...
@@ -152,19 +152,8 @@ public class SiteBusinessServiceImpl extends AbstractCRUDCacheServiceImpl<SiteBu
...
@@ -152,19 +152,8 @@ public class SiteBusinessServiceImpl extends AbstractCRUDCacheServiceImpl<SiteBu
}
}
}
}
@Override
protected
void
saveBefore
(
SiteBusinessEntity
entity
,
Context
context
)
throws
AppException
{
}
@Override
protected
void
updateBefore
(
SiteBusinessEntity
entity
,
Context
context
)
throws
AppException
{
super
.
updateBefore
(
entity
,
context
);
}
@Override
@Override
protected
void
updateAfter
(
SiteBusinessEntity
entity
,
Context
context
)
throws
AppException
{
protected
void
updateAfter
(
SiteBusinessEntity
entity
,
Context
context
)
throws
AppException
{
//更新事项业务表中字段
//更新事项业务表中字段
List
<
BusinessMatterEntity
>
businessMatterEntities
=
businessMatterService
.
find
(
new
BusinessMatterQuery
().
siteBusinessId
(
entity
.
getId
()))
List
<
BusinessMatterEntity
>
businessMatterEntities
=
businessMatterService
.
find
(
new
BusinessMatterQuery
().
siteBusinessId
(
entity
.
getId
()))
.
stream
()
.
stream
()
...
@@ -174,28 +163,34 @@ public class SiteBusinessServiceImpl extends AbstractCRUDCacheServiceImpl<SiteBu
...
@@ -174,28 +163,34 @@ public class SiteBusinessServiceImpl extends AbstractCRUDCacheServiceImpl<SiteBu
if
(!
ObjectUtils
.
isEmpty
(
businessMatterEntities
))
{
if
(!
ObjectUtils
.
isEmpty
(
businessMatterEntities
))
{
businessMatterService
.
update
(
businessMatterEntities
,
context
);
businessMatterService
.
update
(
businessMatterEntities
,
context
);
}
}
super
.
updateAfter
(
entity
,
context
);
super
.
updateAfter
(
entity
,
context
);
}
}
@Override
@Override
protected
void
removeBefore
(
Long
[]
ids
,
Context
context
)
throws
AppException
{
protected
void
removeBefore
(
Long
[]
ids
,
Context
context
)
throws
AppException
{
List
<
SiteBusinessEntity
>
c
ollect
=
Arrays
.
asList
(
ids
).
stream
()
List
<
SiteBusinessEntity
>
c
hilds
=
Arrays
.
asList
(
ids
).
stream
()
.
flatMap
(
item
->
{
.
flatMap
(
item
->
{
SiteBusinessEntity
siteBusinessEntity
=
this
.
get
(
item
);
SiteBusinessEntity
siteBusinessEntity
=
this
.
get
(
item
);
return
this
.
find
(
new
SiteBusinessQuery
().
parentId
(
siteBusinessEntity
.
getId
())).
stream
();
return
this
.
find
(
new
SiteBusinessQuery
().
parentId
(
siteBusinessEntity
.
getId
())).
stream
();
}).
collect
(
Collectors
.
toList
());
}).
collect
(
Collectors
.
toList
());
log
.
info
(
"delete childs list:{}"
,
JSON
.
toJSONString
(
childs
));
log
.
info
(
"delete list:{}"
,
JSON
.
toJSONString
(
collect
));
Long
[]
childIds
=
childs
.
stream
().
map
(
item
->
item
.
getId
()).
toArray
(
Long
[]::
new
);
Long
[]
childIds
=
collect
.
stream
().
map
(
item
->
item
.
getId
()).
toArray
(
Long
[]::
new
);
this
.
getDao
().
delete
(
childIds
);
this
.
getDao
().
delete
(
childIds
);
Long
[]
bussinessIds
=
c
ollect
.
stream
().
map
(
item
->
item
.
getBusinessId
()).
toArray
(
Long
[]::
new
);
Long
[]
bussinessIds
=
c
hilds
.
stream
().
map
(
item
->
item
.
getBusinessId
()).
toArray
(
Long
[]::
new
);
log
.
info
(
"
b
ussinessIds:{}"
,
JSON
.
toJSONString
(
bussinessIds
));
log
.
info
(
"
childB
ussinessIds:{}"
,
JSON
.
toJSONString
(
bussinessIds
));
if
(!
ObjectUtils
.
isEmpty
(
bussinessIds
)){
if
(!
ObjectUtils
.
isEmpty
(
bussinessIds
)){
businessService
.
remove
(
bussinessIds
,
context
);
businessService
.
remove
(
bussinessIds
,
context
);
}
}
List
<
Long
>
mainIds
=
this
.
get
(
ids
,
context
).
stream
().
map
(
item
->
item
.
getBusinessId
()).
collect
(
Collectors
.
toList
());
if
(!
ObjectUtils
.
isEmpty
(
mainIds
)){
//删除
businessService
.
remove
(
mainIds
,
context
);
}
}
}
...
...
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