Commit fd593700 by 宋祥

1.配件制造图默认不显示问题修复

parent be1b826f
......@@ -338,15 +338,15 @@ public class ServiceHGWD001D extends TreeService {
return;
}
List<String> labels = ObjectUtils.listKey(nodes, "label");
Map<String, Integer> resultMap = null;
if (isType) {
resultMap = HGWDTools.HgWd001.countBySource(labels);
} else {
resultMap = HGWDTools.HgWd001.countByParent(labels);
}
Map<String, Integer> resultMap = HGWDTools.HgWd001.countByParent(labels);
for (Map node : nodes) {
Integer cnt = resultMap == null ? null : resultMap.get(node.get("label"));
node.put("leaf", cnt == null || cnt == 0 ? 1 : 0);
if (isType) {
node.put("leaf", 0);
} else {
String label = MapUtils.getString(node, "label");
Integer cnt = resultMap == null ? null : resultMap.get(label);
node.put("leaf", cnt == null || cnt == 0 ? 1 : 0);
}
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment