南网,epc和国网模板下載更新
This commit is contained in:
parent
15f982e3a4
commit
758ee01647
|
|
@ -73,4 +73,9 @@ public class ComOtherPersonBean extends PersonFileBean{
|
|||
*/
|
||||
private Integer isNormal;
|
||||
|
||||
/**
|
||||
* 职工类型
|
||||
*/
|
||||
private String workType;
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -23,6 +23,7 @@ import javax.annotation.Resource;
|
|||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.util.*;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
/**
|
||||
* @author fly
|
||||
|
|
@ -381,6 +382,10 @@ public class StateGridServiceImpl implements StateGridService {
|
|||
//项目关键人员
|
||||
if (tbData.getComCoreList() != null && !tbData.getComCoreList().isEmpty()) {
|
||||
for (ComCorePersonBean item : tbData.getComCoreList()) {
|
||||
|
||||
if(!("项目经理".equals(item.getPostName()) || "项目负责人".equals(item.getPostName()))){
|
||||
continue;
|
||||
}
|
||||
// 【拟投入项目经理(项目负责人)一览表】
|
||||
Map<String, Object> map = new HashMap<>();
|
||||
map.put("bName", ""); // 标的名称
|
||||
|
|
@ -414,7 +419,7 @@ public class StateGridServiceImpl implements StateGridService {
|
|||
map2.put("level", item2.getLevel()); // 项目经理(项目负责人)级别
|
||||
}
|
||||
if ("项目经理B证".equals(item2.getDiploma())) {
|
||||
map2.put("bCode", ""); // 项目经理(项目负责人)B证证书编号
|
||||
map2.put("bCode", item2.getDiploma()+item2.getDiplomaNum()); // 项目经理(项目负责人)B证证书编号
|
||||
}
|
||||
});
|
||||
}
|
||||
|
|
@ -503,6 +508,7 @@ public class StateGridServiceImpl implements StateGridService {
|
|||
//本项目现场作业人员统计表
|
||||
if (tbData.getComOtherList() != null && !tbData.getComOtherList().isEmpty()) {
|
||||
for (ComOtherPersonBean item : tbData.getComOtherList()) {
|
||||
//表格 数据
|
||||
Map<String, Object> map = new HashMap<>();
|
||||
map.put("name", item.getUserName() != null ? item.getUserName() : "" ); // 姓名
|
||||
map.put("position", item.getPostName() != null ? item.getPostName() : "" ); // 工作岗位
|
||||
|
|
@ -520,7 +526,19 @@ public class StateGridServiceImpl implements StateGridService {
|
|||
|
||||
// 投入本项目主要项目团队(施工团队)一览表
|
||||
if (tbData.getComOtherList() != null && !tbData.getComOtherList().isEmpty()) {
|
||||
for (ComOtherPersonBean item : tbData.getComOtherList()) {
|
||||
|
||||
//使用 Java 8 Stream 进行分组、排序并每组只取一个
|
||||
Map<String, ComOtherPersonBean> groupedMap = tbData.getComOtherList().stream()
|
||||
.filter(Objects::nonNull) // 非空过滤
|
||||
.sorted(Comparator.comparing(ComOtherPersonBean::getPostName)) // 按 postName 排序
|
||||
.collect(Collectors.toMap(
|
||||
ComOtherPersonBean::getPostName, // 分组字段
|
||||
item -> item, // 当前元素本身
|
||||
(existing, replacement) -> existing // 如果键冲突,保留第一个出现的元素
|
||||
));
|
||||
// 获取去重后的有序列表
|
||||
List<ComOtherPersonBean> result = new ArrayList<>(groupedMap.values());
|
||||
for (ComOtherPersonBean item : result) {
|
||||
Map<String, Object> map = new HashMap<>();
|
||||
List<String> proList = new ArrayList<>();
|
||||
map.put("name", item.getUserName() != null ? item.getUserName() : ""); // 姓名
|
||||
|
|
@ -542,7 +560,15 @@ public class StateGridServiceImpl implements StateGridService {
|
|||
Map<String, Object> map2 = new HashMap<>();
|
||||
List<Map<String, Object>> imgList = new ArrayList<>(); // 项目副经理证书图片及其他个人材料图片
|
||||
map.put("title", item.getTitle() != null ? item.getTitle() : ""); // 项目名称
|
||||
item.getOtherFileList().forEach(item2 -> {
|
||||
List<TbFileSourceVo> allFileList = new ArrayList<>();
|
||||
List<TbCertificationVo> certList = item.getCertList();
|
||||
if (certList != null && !certList.isEmpty()) {
|
||||
certList.forEach(item1 -> {
|
||||
allFileList.addAll(item1.getTbFileSourceVoList());
|
||||
});
|
||||
}
|
||||
allFileList.addAll(item.getOtherFileList());
|
||||
allFileList.forEach(item2 -> {
|
||||
Map<String, Object> imgMap = new HashMap<>();
|
||||
try {
|
||||
imgMap.put("index", IdUtils.fastSimpleUUID());
|
||||
|
|
@ -742,24 +768,35 @@ public class StateGridServiceImpl implements StateGridService {
|
|||
otherMap.put("zw", item.getPostName() != null ? item.getPostName() : "");
|
||||
otherMap.put("name", item.getUserName() != null ? item.getUserName() : "");
|
||||
otherMap.put("zc", item.getTitle() != null ? item.getTitle() : "");
|
||||
otherMap.put("yg", item.getDiploma());
|
||||
otherMap.put("zs", item.getDiploma() != null ? item.getDiploma() : "");
|
||||
otherMap.put("jb", item.getLevel() != null ? item.getLevel() : "");
|
||||
otherMap.put("zh", item.getDiplomaNum() != null ? item.getDiplomaNum() : "");
|
||||
otherMap.put("zy", item.getMajor() != null ? item.getMajor() : "");
|
||||
otherMap.put("bh", "");
|
||||
// 处理证书列表
|
||||
List<Map<String, Object>> zsList = new ArrayList<>();
|
||||
otherMap.put("yg", item.getWorkType() != null ? item.getWorkType() : "");
|
||||
// otherMap.put("zs", "");
|
||||
// otherMap.put("jb", "");
|
||||
// otherMap.put("zh", "");
|
||||
// otherMap.put("zy", "");
|
||||
// otherMap.put("bh", "");
|
||||
if(!item.getCertList().isEmpty()){
|
||||
for (int i = 0; i < item.getCertList().size(); i++) {
|
||||
TbCertificationVo cert = item.getCertList().get(i);
|
||||
if(i == 0){
|
||||
otherMap.put("zs", cert.getDiploma() != null ? cert.getDiploma() : "");
|
||||
otherMap.put("jb", cert.getLevel() != null ? cert.getLevel() : "");
|
||||
otherMap.put("zh", cert.getDiplomaNum() != null ? cert.getDiplomaNum() : "");
|
||||
otherMap.put("zy", item.getMajor() != null ? item.getMajor() : "");
|
||||
otherMap.put("bh", "");
|
||||
}else{
|
||||
Map<String, Object> zsMap = new HashMap<>();
|
||||
zsMap.put("zs", cert.getDiploma() != null ? cert.getDiploma() : "");
|
||||
zsMap.put("jb", cert.getLevel() != null ? cert.getLevel() : "");
|
||||
zsMap.put("zh", cert.getDiplomaNum() != null ? cert.getDiplomaNum() : "");
|
||||
zsMap.put("zy", item.getMajor() != null ? item.getMajor() : "");
|
||||
zsMap.put("bh", "");
|
||||
zsList.add(zsMap);
|
||||
}
|
||||
}
|
||||
}
|
||||
//表设计是不可能有两个证件,后续修改,将item.getDiploma()改成集合存储
|
||||
// if (item.getDiploma() != null || item.getDiplomaNum() != null || item.getMajor() != null || item.getLevel() != null) {
|
||||
// Map<String, Object> zsMap = new HashMap<>();
|
||||
// zsMap.put("zs", item.getDiploma() != null ? item.getDiploma() : "");
|
||||
// zsMap.put("jb", item.getLevel() != null ? item.getLevel() : "");
|
||||
// zsMap.put("zh", item.getDiplomaNum() != null ? item.getDiplomaNum() : "");
|
||||
// zsMap.put("zy", item.getMajor() != null ? item.getMajor() : "");
|
||||
// zsMap.put("bh", "");
|
||||
// zsList.add(zsMap);
|
||||
// }
|
||||
otherMap.put("zsList", zsList);
|
||||
otherUserList.add(otherMap);
|
||||
// 处理人员证件图片
|
||||
|
|
@ -777,8 +814,10 @@ public class StateGridServiceImpl implements StateGridService {
|
|||
}
|
||||
}
|
||||
|
||||
if (item.getDiplomaFileList() != null) {
|
||||
allImages.addAll(item.getDiplomaFileList());
|
||||
if (!item.getCertList().isEmpty()) {
|
||||
item.getCertList().forEach(item2 -> {
|
||||
allImages.addAll(item2.getTbFileSourceVoList());
|
||||
});
|
||||
}
|
||||
if (item.getOtherFileList() != null) {
|
||||
allImages.addAll(item.getOtherFileList());
|
||||
|
|
@ -884,8 +923,10 @@ public class StateGridServiceImpl implements StateGridService {
|
|||
// 处理人员证件图片
|
||||
// 处理身份证、资格证书和其他资质的图片
|
||||
List<TbFileSourceVo> allImages = new ArrayList<>();
|
||||
if (item.getDiplomaFileList() != null) {
|
||||
allImages.addAll(item.getDiplomaFileList());
|
||||
if (!item.getCertList().isEmpty()) {
|
||||
item.getCertList().forEach(item2 -> {
|
||||
allImages.addAll(item2.getTbFileSourceVoList());
|
||||
});
|
||||
}
|
||||
if (item.getOtherFileList() != null) {
|
||||
allImages.addAll(item.getOtherFileList());
|
||||
|
|
|
|||
|
|
@ -222,7 +222,8 @@
|
|||
tkp.diploma_num,
|
||||
tkp.major,
|
||||
tkp.`level`,
|
||||
tgou.position as post_name
|
||||
tgou.position as post_name,
|
||||
if(tkp.work_type = 1,'正式职工','劳务派遣') as workType
|
||||
FROM tb_gw_other_user tgou
|
||||
LEFT JOIN tb_other_people tkp ON tgou.other_id = tkp.id
|
||||
WHERE tgou.gw_id = #{id}
|
||||
|
|
|
|||
Loading…
Reference in New Issue