This commit is contained in:
parent
d6279ec605
commit
6fa6783969
|
|
@ -93,22 +93,21 @@ public class SelectServiceImpl implements SelectService {
|
|||
stepTimes.put("数据过滤", System.currentTimeMillis() - filterStart);
|
||||
|
||||
if (CollectionUtils.isNotEmpty(list)) {
|
||||
// 步骤6: 获取班组数据(可选)
|
||||
// 步骤6: 树形结构构建
|
||||
long buildStart = System.currentTimeMillis();
|
||||
groupList = buildTreeEfficiently(list);
|
||||
// 步骤7: 获取班组数据(可选)
|
||||
if (bmUnit.getDeptId() == null) {
|
||||
long teamStart = System.currentTimeMillis();
|
||||
List<ProjectTreeNode> newList = mapper.getTeam();
|
||||
stepTimes.put("获取班组数据", System.currentTimeMillis() - teamStart);
|
||||
|
||||
if (CollectionUtils.isNotEmpty(newList)) {
|
||||
list.addAll(newList);
|
||||
groupList.addAll(newList);
|
||||
}
|
||||
} else {
|
||||
stepTimes.put("获取班组数据", 0L); // 跳过此步骤
|
||||
}
|
||||
|
||||
// 步骤7: 树形结构构建
|
||||
long buildStart = System.currentTimeMillis();
|
||||
groupList = buildTreeEfficiently(list);
|
||||
stepTimes.put("树形结构构建", System.currentTimeMillis() - buildStart);
|
||||
}
|
||||
} catch (Exception e) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue