Merge remote-tracking branch 'origin/dev_2nd_LCYH' into dev_2nd_LCYH

This commit is contained in:
zyx.net
2023-03-30 14:01:05 +08:00
4 changed files with 78 additions and 15 deletions
@@ -83,7 +83,7 @@ public class OtaBaSjListController extends JeroController<OtaBaSjList, IOtaBaSjL
queryWrapper.like(OtaBaSjList::getCpmc, cpmc); queryWrapper.like(OtaBaSjList::getCpmc, cpmc);
} }
String cpxh = req.getParameter("cpmc"); String cpxh = req.getParameter("cpxh");
if (StringUtils.isNotBlank(cpxh)) { if (StringUtils.isNotBlank(cpxh)) {
cpxh = cpxh.replace("%", "\\%"); cpxh = cpxh.replace("%", "\\%");
queryWrapper.like(OtaBaSjList::getCpxh, cpxh); queryWrapper.like(OtaBaSjList::getCpxh, cpxh);
@@ -76,6 +76,11 @@ public enum OperatorTypeEnum {
LAWS_INVENTORY_STUDIO_EXPEDITING("法规清单-studio催办","lawsInventoryStudioExpediting"), LAWS_INVENTORY_STUDIO_EXPEDITING("法规清单-studio催办","lawsInventoryStudioExpediting"),
LAWS_INVENTORY_REGULATION_OWNER_EXPEDITING("法规清单-法规工程师催办","lawsInventoryRegulationOwnerExpediting"), LAWS_INVENTORY_REGULATION_OWNER_EXPEDITING("法规清单-法规工程师催办","lawsInventoryRegulationOwnerExpediting"),
LAWS_INVENTORY_ENGINEERING_INTERFACE_PERSON_EXPEDITING("法规清单-工程接口人催办","lawsInventoryEngineeringInterfacePersonExpediting"), LAWS_INVENTORY_ENGINEERING_INTERFACE_PERSON_EXPEDITING("法规清单-工程接口人催办","lawsInventoryEngineeringInterfacePersonExpediting"),
/**
* 待办中心-将法规工程师的法规清单确认待办任务转为已办
*/
TO_DO_CENTER_FG_CONVERT_TO_HAVE_DONE("待办中心,法规工程师待办任务转为已办","toDoCenterFgConvertToHaveDone"),
; ;
String name; String name;
@@ -2663,6 +2663,8 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
projectCertificationInventoryEOTemp.setId(UUID.randomUUID().toString().replace("-", "")); projectCertificationInventoryEOTemp.setId(UUID.randomUUID().toString().replace("-", ""));
projectCertificationInventoryEOTemp.setProjectLibraryId(projectLibraryId); projectCertificationInventoryEOTemp.setProjectLibraryId(projectLibraryId);
projectCertificationInventoryEOTemp.setFlowStatus(CertificationInventoryFlowStatusEnum.LIST_TO_BE_RELEASED.getValue()); projectCertificationInventoryEOTemp.setFlowStatus(CertificationInventoryFlowStatusEnum.LIST_TO_BE_RELEASED.getValue());
projectCertificationInventoryEOTemp.setCreateTime(new Date());
projectCertificationInventoryEOTemp.setUpdateTime(new Date());
projectCertificationInventoryEOList.add(projectCertificationInventoryEOTemp); projectCertificationInventoryEOList.add(projectCertificationInventoryEOTemp);
}else { }else {
noSerialNumberList.add(authDummyInventoryInfoEO.getSerialNumber()); noSerialNumberList.add(authDummyInventoryInfoEO.getSerialNumber());
@@ -2711,13 +2713,13 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
public void importData(MultipartFile file, ProjectCertificationInventoryEO projectCertificationInventoryEO) { public void importData(MultipartFile file, ProjectCertificationInventoryEO projectCertificationInventoryEO) {
String title = ""; String title = "";
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEO.getCut())){ if(CutEnum.CN.getValue().equals(projectCertificationInventoryEO.getCut())){
title = "*类别,*检验项目,*配置项,*WVTA ID," + title = title = "*类别,*检验项目,*配置项,*WVTA ID," +
"*标准编号,*责任领域,*工程接口人,*责任人," + "*标准编号,*责任领域,*工程接口人,*责任人," +
"*交付物类型,交付物模板,*截止日期"; "*交付物类型,交付物模板,*截止日期,报告编号,产品型号,生产企业名称";
}else { }else {
title = "*Category,*Inspection Items,*Configuration Item,*WVTA ID," + title = "*Category,*Inspection Items,*Configuration Item,*WVTA ID," +
"*Standard No,*Responsible Field,*Eng. Interface,*Assignee," + "*Standard No,*Responsible Field,*Eng. Interface,*Assignee," +
"*Deliverable Type,Deliverable Template,*Due Date"; "*Deliverable Type,Deliverable Template,*Due Date,Report No,Product Model,Name Of Manufacturer";
} }
int pos = file.getOriginalFilename().lastIndexOf("."); int pos = file.getOriginalFilename().lastIndexOf(".");
@@ -2989,6 +2991,12 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
//截止时间 //截止时间
String endTime = projectCertificationInventoryEO.getEndTimeStr(); String endTime = projectCertificationInventoryEO.getEndTimeStr();
//报告编号
String reportNumber = projectCertificationInventoryEO.getReportNumber();
//产品型号
String productModel = projectCertificationInventoryEO.getProductModel();
//生产企业名称
String productionEnterpriseName = projectCertificationInventoryEO.getProductionEnterpriseName();
//文件 //文件
//交付物模板 //交付物模板
@@ -3000,16 +3008,51 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
//编号必填 //编号必填
flag = must(projectCertificationInventoryEO, errorMsg, msgList, serialNumber, "编号", "Standard No"); flag = must(projectCertificationInventoryEO, errorMsg, msgList, serialNumber, "编号", "Standard No");
//报告编号
if(StringUtils.isNotBlank(reportNumber)){
if(reportNumber.length() > 200){
String message = "";
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){
message = errorMsg + "报告编号不能超过200个字符, ";
}else{
message = errorMsg + " The Report No cannot contain more than 200 characters, ";
}
msgList.add(message);
}
}
//产品型号
if(StringUtils.isNotBlank(productModel)){
if(productModel.length() > 200){
String message = "";
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){
message = errorMsg + "产品型号不能超过200个字符, ";
}else{
message = errorMsg + " The Product Model cannot contain more than 200 characters, ";
}
msgList.add(message);
}
}
//生产企业名称
if(StringUtils.isNotBlank(productionEnterpriseName)){
if(productionEnterpriseName.length() > 200){
String message = "";
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){
message = errorMsg + "生产企业名称不能超过200个字符, ";
}else{
message = errorMsg + " The Name Of Manufacturer cannot contain more than 200 characters, ";
}
msgList.add(message);
}
}
//WVTA ID //WVTA ID
if(StringUtils.isNotBlank(wvtaId)){ if(StringUtils.isNotBlank(wvtaId)){
if(wvtaId.length() > 100){ if(wvtaId.length() > 300){
String message = ""; String message = "";
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){ if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){
message = errorMsg + "WVTA ID不能超过100个字符, "; message = errorMsg + "WVTA ID不能超过300个字符, ";
}else{ }else{
message = errorMsg + " The WVTA ID cannot contain more than 100 characters, "; message = errorMsg + " The WVTA ID cannot contain more than 300 characters, ";
} }
msgList.add(message); msgList.add(message);
} }
@@ -3025,12 +3068,12 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
//类别 //类别
if(StringUtils.isNotBlank(category)){ if(StringUtils.isNotBlank(category)){
if(category.length() > 100){ if(category.length() > 300){
String message = ""; String message = "";
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){ if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){
message = errorMsg + "类别不能超过100个字符, "; message = errorMsg + "类别不能超过300个字符, ";
}else{ }else{
message = errorMsg + " The Category cannot contain more than 100 characters, "; message = errorMsg + " The Category cannot contain more than 300 characters, ";
} }
msgList.add(message); msgList.add(message);
} }
@@ -3049,9 +3092,9 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
if(inspectionItem.length() > 100){ if(inspectionItem.length() > 100){
String message = ""; String message = "";
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){ if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){
message = errorMsg + "检验项目不能超过100个字符, "; message = errorMsg + "检验项目不能超过300个字符, ";
}else{ }else{
message = errorMsg + " The InspectionItem cannot contain more than 100 characters, "; message = errorMsg + " The InspectionItem cannot contain more than 300 characters, ";
} }
msgList.add(message); msgList.add(message);
} }
@@ -3067,12 +3110,12 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
//配置项 //配置项
if(StringUtils.isNotBlank(configItem)){ if(StringUtils.isNotBlank(configItem)){
if(configItem.length() > 100){ if(configItem.length() > 300){
String message = ""; String message = "";
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){ if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){
message = errorMsg + "配置项不能超过100个字符, "; message = errorMsg + "配置项不能超过100个字符, ";
}else{ }else{
message = errorMsg + " The ConfigItem cannot contain more than 100 characters, "; message = errorMsg + " The ConfigItem cannot contain more than 300 characters, ";
} }
msgList.add(message); msgList.add(message);
} }
@@ -3194,6 +3194,21 @@ public class ProjectLawsInventoryEOServiceImpl extends ServiceImpl<ProjectLawsIn
this.sendMessageByTemplateId(templateId,prarams); this.sendMessageByTemplateId(templateId,prarams);
} }
// 将法规工程师的 法规清单确认待办中心任务转为已办
if(StringUtils.equals(operatorType,OperatorTypeEnum.TO_DO_CENTER_FG_CONVERT_TO_HAVE_DONE.getValue())){
String projectLawsInventoryId = jsonObject.getString("id");
ProjectLawsInventoryEO projectLawsInventoryEO = this.baseMapper.selectById(projectLawsInventoryId);
if(StringUtils.equals(projectLawsInventoryEO.getDesignFlowStatus(),ComplianceFlowStatusEnum.TASK_TO_BE_CONFIRMED.getValue())
||StringUtils.equals(projectLawsInventoryEO.getVerifyFlowStatus(),ComplianceFlowStatusEnum.TASK_TO_BE_CONFIRMED.getValue())){
// 如果该条法规清单的设计验证符合性流程都发起了将法规工程师在待办中心的待办任务转为已办
LambdaUpdateWrapper<ProcessInfoDetailEO> pidUpdateWrap = new LambdaUpdateWrapper<>();
pidUpdateWrap.eq(ProcessInfoDetailEO::getFlowType,FlowTypeEnum.QDQR.getValue());
pidUpdateWrap.eq(ProcessInfoDetailEO::getProjectLawsInventoryId,projectLawsInventoryId);
pidUpdateWrap.set(ProcessInfoDetailEO::getStatus,TaskStatusEnum.HAVE_DONE.getValue());
this.processInfoDetailEOService.update(pidUpdateWrap);
}
}
return new Result<>().success("调用成功!"); return new Result<>().success("调用成功!");
} }