Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Administrator
/
framework-tools
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit a1d62963
authored
Jul 17, 2024
by
henry
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加接口注释
1 parent
46c3d2a8
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
11 additions
and
5 deletions
framework-analysis/src/main/java/org/arch/analysis/service/impl/ArchMapServiceImpl.java
framework-analysis/src/main/java/org/arch/analysis/vo/ArchMapVo.java
framework-system-manage/src/main/java/org/arch/manage/service/RoleService.java
framework-analysis/src/main/java/org/arch/analysis/service/impl/ArchMapServiceImpl.java
View file @
a1d6296
...
...
@@ -33,27 +33,34 @@ public class ArchMapServiceImpl implements IArchMapService {
return
archMapMapper
.
getOverAllBusAsset
(
mapDto
);
}
/**
* 获取选择对应架构资产树
* @param mapDto
* @return
*/
@Override
public
List
<
ArchMapVo
>
getAssetTree
(
ArchMapDto
mapDto
)
{
//查询所有的对应架构资产数据
List
<
ArchMapVo
>
allDatas
=
archMapMapper
.
getOverAllBusAsset
(
mapDto
);
List
<
ArchMapVo
>
treeList
=
new
ArrayList
<>();
mapDto
.
setParentAssetId
(
0
);
//查询根节点资产数据
List
<
ArchMapVo
>
rootDatas
=
archMapMapper
.
getOverAllBusAsset
(
mapDto
);
if
(!
Collections
.
isEmpty
(
rootDatas
))
{
treeList
=
rootDatas
.
stream
()
.
filter
(
item
->
!
StringUtils
.
isEmpty
(
item
.
getParentAssetId
()))
.
filter
(
item
->
item
.
getParentAssetId
().
equals
(
0
))
.
peek
(
item
->
item
.
set
Children
(
getChildrens
(
item
,
allDatas
))).
collect
(
Collectors
.
toList
());
.
peek
(
item
->
item
.
set
Node
(
getNode
(
item
,
allDatas
))).
collect
(
Collectors
.
toList
());
}
return
treeList
;
}
private
List
<
ArchMapVo
>
get
Childrens
(
ArchMapVo
root
,
List
<
ArchMapVo
>
all
)
{
private
List
<
ArchMapVo
>
get
Node
(
ArchMapVo
root
,
List
<
ArchMapVo
>
all
)
{
List
<
ArchMapVo
>
children
=
all
.
stream
()
.
filter
(
item
->
!
StringUtils
.
isEmpty
(
item
.
getParentAssetId
()))
.
filter
(
item
->
item
.
getParentAssetId
().
equals
(
root
.
getAssetId
()))
.
peek
(
item
->
{
item
.
set
Children
(
getChildrens
(
item
,
all
));
item
.
set
Node
(
getNode
(
item
,
all
));
}).
collect
(
Collectors
.
toList
());
return
children
;
}
...
...
framework-analysis/src/main/java/org/arch/analysis/vo/ArchMapVo.java
View file @
a1d6296
...
...
@@ -40,6 +40,6 @@ public class ArchMapVo {
private
String
assetId
;
private
List
<
ArchMapVo
>
children
;
private
List
<
ArchMapVo
>
node
;
}
framework-system-manage/src/main/java/org/arch/manage/service/RoleService.java
View file @
a1d6296
...
...
@@ -57,7 +57,6 @@ public interface RoleService extends BaseService<Role> {
/**
* 编辑
* @param resources /
*/
boolean
update
(
RoleUpdateDto
roleUpdate
);
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment