|
@@ -21,6 +21,7 @@ import cn.cslg.pas.exception.UnLoginException;
|
|
import cn.cslg.pas.exception.XiaoShiException;
|
|
import cn.cslg.pas.exception.XiaoShiException;
|
|
import cn.cslg.pas.factorys.businessFactory.Business;
|
|
import cn.cslg.pas.factorys.businessFactory.Business;
|
|
import cn.cslg.pas.mapper.TreeNodeMapper;
|
|
import cn.cslg.pas.mapper.TreeNodeMapper;
|
|
|
|
+import cn.cslg.pas.service.business.es.EsProductPatentService;
|
|
import cn.cslg.pas.service.common.FileManagerService;
|
|
import cn.cslg.pas.service.common.FileManagerService;
|
|
import cn.cslg.pas.service.permissions.PermissionService;
|
|
import cn.cslg.pas.service.permissions.PermissionService;
|
|
import cn.cslg.pas.service.query.FormatQueryService;
|
|
import cn.cslg.pas.service.query.FormatQueryService;
|
|
@@ -33,6 +34,7 @@ import org.springframework.beans.BeanUtils;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
import org.springframework.stereotype.Service;
|
|
import org.springframework.stereotype.Service;
|
|
import org.springframework.transaction.annotation.Transactional;
|
|
import org.springframework.transaction.annotation.Transactional;
|
|
|
|
+import org.springframework.util.CollectionUtils;
|
|
import org.springframework.web.multipart.MultipartFile;
|
|
import org.springframework.web.multipart.MultipartFile;
|
|
|
|
|
|
import java.io.IOException;
|
|
import java.io.IOException;
|
|
@@ -75,6 +77,9 @@ public class TreeNodeService extends ServiceImpl<TreeNodeMapper, TreeNode> imple
|
|
@Autowired
|
|
@Autowired
|
|
private AssoProjectTreeNodeService assoProjectTreeNodeService;
|
|
private AssoProjectTreeNodeService assoProjectTreeNodeService;
|
|
|
|
|
|
|
|
+ @Autowired
|
|
|
|
+ private EsProductPatentService esProductPatentService;
|
|
|
|
+
|
|
@Override
|
|
@Override
|
|
public Object queryMessage(QueryRequest queryRequest) throws Exception {
|
|
public Object queryMessage(QueryRequest queryRequest) throws Exception {
|
|
List<String> sqls = formatQueryService.reSqls(queryRequest, "treeNode");
|
|
List<String> sqls = formatQueryService.reSqls(queryRequest, "treeNode");
|
|
@@ -157,7 +162,6 @@ public class TreeNodeService extends ServiceImpl<TreeNodeMapper, TreeNode> imple
|
|
return records;
|
|
return records;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
-
|
|
|
|
//返回树
|
|
//返回树
|
|
this.loadTreeNode(treeNodes);
|
|
this.loadTreeNode(treeNodes);
|
|
reTreeNodeVOS = this.reTrees(treeNodes);
|
|
reTreeNodeVOS = this.reTrees(treeNodes);
|
|
@@ -453,7 +457,7 @@ public class TreeNodeService extends ServiceImpl<TreeNodeMapper, TreeNode> imple
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
- private void loadTreeNode(List<TreeNodeVO> treeNodeVOS) throws IOException {
|
|
|
|
|
|
+ private void loadTreeNode(List<TreeNodeVO> treeNodeVOS) throws Exception {
|
|
List<String> createIds = new ArrayList<>();
|
|
List<String> createIds = new ArrayList<>();
|
|
List<Integer> ids = new ArrayList<>();
|
|
List<Integer> ids = new ArrayList<>();
|
|
treeNodeVOS.forEach(
|
|
treeNodeVOS.forEach(
|
|
@@ -467,6 +471,20 @@ public class TreeNodeService extends ServiceImpl<TreeNodeMapper, TreeNode> imple
|
|
}
|
|
}
|
|
);
|
|
);
|
|
|
|
|
|
|
|
+ if (!CollectionUtils.isEmpty(treeNodeVOS)) {
|
|
|
|
+ for (TreeNodeVO nodeVO : treeNodeVOS) {
|
|
|
|
+ Integer type = nodeVO.getType();
|
|
|
|
+ if (type != null) {
|
|
|
|
+ if (type == 1 || type == 2) {
|
|
|
|
+ Long relevantProductNum = esProductPatentService.selectRelevantProductNum(nodeVO.getId());
|
|
|
|
+ nodeVO.setRelevantProductNum(relevantProductNum);
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+
|
|
List<Personnel> personnels = new ArrayList<>();
|
|
List<Personnel> personnels = new ArrayList<>();
|
|
List<String> guids = new ArrayList<>();
|
|
List<String> guids = new ArrayList<>();
|
|
List<SystemFile> systemFiles = new ArrayList<>();
|
|
List<SystemFile> systemFiles = new ArrayList<>();
|