| | |
| | | } |
| | | if(StringUtils.isNotBlank(id) || StringUtils.isNotBlank(lcStatus) ){ |
| | | //String tableName = this.getTableName(treeQueryObject.getConditionMap().get("btmTypeId"),treeQueryObject.getConditionMap().get("id"), treeQueryObject.getConditionMap().get("lcStatus")); |
| | | // TODO: 2024-1-24 23:25我去掉了懒加载,因为会影响数据授权过滤,而且这儿感觉没必要做懒加载 |
| | | doList = codeClassifyMapper |
| | | .selectCodeClassifyDOByTree( |
| | | treeQueryObject.getConditionMap().get("id"), |
| | |
| | | if(!viewClassByRoleIds.isSuccess() && viewClassByRoleIds.getData().isEmpty()){ |
| | | throw new ServiceException("主数据查看权限未配置,或配置有误!"); |
| | | } |
| | | long startTime = System.currentTimeMillis(); |
| | | // 过滤 |
| | | filterTreeNodes(tree,viewClassByRoleIds.getData()); |
| | | long endTime = System.currentTimeMillis(); |
| | | System.out.println(("执行时间:"+(endTime-startTime)/1000)+"s"); |
| | | } |
| | | // 加载分类是否具有子分类 |
| | | tree.parallelStream().forEach(item -> { |
| | |
| | | /*Boolean checkHasChild = checkHasChild(tree.getOid()); |
| | | tree.setLeaf(!checkHasChild);*/ |
| | | if (classifyIds.contains(tree.getOid())) { |
| | | // 如果顶层节点存在于 classifyIds 中,直接保留其子节点集合 |
| | | // 如果顶层节点存在 classifyIds ,直接保留其子节点集合 |
| | | continue; |
| | | } |
| | | if (tree.getChildren() != null && !tree.getChildren().isEmpty()) { |