加保护
This commit is contained in:
parent
694c169e48
commit
ab5b90b85d
|
|
@ -371,15 +371,17 @@ public class BackApplyServiceImpl implements BackApplyService {
|
|||
try {
|
||||
// 先查第四层类型
|
||||
listL4 = backApplyMapper.getUseTypeTreeL4(bean);
|
||||
List<Long> list4ParentIds = listL4.stream().map(o -> o.getParentId()).collect(Collectors.toList());
|
||||
// 根据第四层parentId 查第三层类型
|
||||
listL3 = backApplyMapper.getUseTypeTreeL3(list4ParentIds);
|
||||
List<Long> list3ParentIds = listL3.stream().map(o -> o.getParentId()).collect(Collectors.toList());
|
||||
// 根据第三层parentId 查第1.2层类型
|
||||
listL21 = backApplyMapper.getUseTypeTreeL21(list3ParentIds);
|
||||
list.addAll(listL4);
|
||||
list.addAll(listL3);
|
||||
list.addAll(listL21);
|
||||
if (CollectionUtils.isNotEmpty(listL4)) {
|
||||
List<Long> list4ParentIds = listL4.stream().map(o -> o.getParentId()).collect(Collectors.toList());
|
||||
// 根据第四层parentId 查第三层类型
|
||||
listL3 = backApplyMapper.getUseTypeTreeL3(list4ParentIds);
|
||||
List<Long> list3ParentIds = listL3.stream().map(o -> o.getParentId()).collect(Collectors.toList());
|
||||
// 根据第三层parentId 查第1.2层类型
|
||||
listL21 = backApplyMapper.getUseTypeTreeL21(list3ParentIds);
|
||||
list.addAll(listL4);
|
||||
list.addAll(listL3);
|
||||
list.addAll(listL21);
|
||||
}
|
||||
if (CollectionUtils.isNotEmpty(list)) {
|
||||
// 创建树形结构(数据集合作为参数)
|
||||
TypeTreeBuild treeBuild = new TypeTreeBuild(list);
|
||||
|
|
|
|||
Loading…
Reference in New Issue