Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
amos-boot-biz
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
项目统一框架
amos-boot-biz
Commits
e798ceaa
Commit
e798ceaa
authored
Jan 05, 2022
by
xixinzhao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
消防系统根节点总数
parent
324e4a79
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
1 deletion
+8
-1
FireFightingSystemServiceImpl.java
...uipmanage/service/impl/FireFightingSystemServiceImpl.java
+8
-1
No files found.
amos-boot-module/amos-boot-module-biz/amos-boot-module-equip-biz/src/main/java/com/yeejoin/equipmanage/service/impl/FireFightingSystemServiceImpl.java
View file @
e798ceaa
...
@@ -992,13 +992,20 @@ public class FireFightingSystemServiceImpl extends ServiceImpl<FireFightingSyste
...
@@ -992,13 +992,20 @@ public class FireFightingSystemServiceImpl extends ServiceImpl<FireFightingSyste
vo
.
setId
(
String
.
valueOf
(
item
.
getId
()));
vo
.
setId
(
String
.
valueOf
(
item
.
getId
()));
return
vo
;
return
vo
;
}).
collect
(
Collectors
.
toList
());
}).
collect
(
Collectors
.
toList
());
// 计算总数
long
total
=
typeList
.
stream
().
mapToLong
(
o
->
{
if
(!
ObjectUtils
.
isEmpty
(
o
.
get
(
"total"
)))
{
return
(
long
)
o
.
get
(
"total"
);
}
return
0
;
}).
sum
();
// 自定义根节点返回树
// 自定义根节点返回树
FireFightingSystemTypeTreeVo
parentNode
=
new
FireFightingSystemTypeTreeVo
();
FireFightingSystemTypeTreeVo
parentNode
=
new
FireFightingSystemTypeTreeVo
();
parentNode
.
setType
(
"all"
);
parentNode
.
setType
(
"all"
);
parentNode
.
setName
(
"全部分类"
);
parentNode
.
setName
(
"全部分类"
);
parentNode
.
setId
(
"-1"
);
parentNode
.
setId
(
"-1"
);
parentNode
.
setParentId
(
"-1"
);
parentNode
.
setParentId
(
"-1"
);
parentNode
.
setTotal
(
String
.
valueOf
(
total
));
parentNode
.
setChildren
(
childrenList
);
parentNode
.
setChildren
(
childrenList
);
return
Collections
.
singletonList
(
parentNode
);
return
Collections
.
singletonList
(
parentNode
);
}
}
...
...
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