|
@@ -76,7 +76,12 @@ public class ImageClassificationFileServiceImpl extends BaseServiceImpl<ImageCla
|
|
|
//查询下级节点信息
|
|
|
// imageClassificationFile.setWbsIds(JSONArray.parseArray(JSONObject.toJSONString(imageClassificationFile.getWbsIdsStr().split(",")), String.class));
|
|
|
WbsTreeContract node = wbsTreeContractClient.getContractWbsTreeByPrimaryKeyId(Long.valueOf(imageClassificationFile.getWbsIdsStr()));
|
|
|
- List<WbsTreeContract> wbsTreeContracts = wbsTreeContractClient.queryCurrentNodeAllChild(imageClassificationFile.getContractId(), node.getId());
|
|
|
+ List<WbsTreeContract> wbsTreeContracts = new ArrayList<>();
|
|
|
+ if (node.getParentId()==0){
|
|
|
+ wbsTreeContracts = wbsTreeContractClient.queryAllChild(imageClassificationFile.getContractId());
|
|
|
+ }else {
|
|
|
+ wbsTreeContracts = wbsTreeContractClient.queryCurrentNodeAllChild(imageClassificationFile.getContractId(), node.getId());
|
|
|
+ }
|
|
|
wbsTreeContracts.add(node);
|
|
|
imageClassificationFile.setWbsIds(wbsTreeContracts.stream().map(wtc->wtc.getPKeyId()+"").collect(Collectors.toList()));
|
|
|
}
|