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

This commit is contained in:
高嵩
2023-03-30 14:59:01 +08:00
14 changed files with 130 additions and 32 deletions
@@ -2663,6 +2663,8 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
projectCertificationInventoryEOTemp.setId(UUID.randomUUID().toString().replace("-", ""));
projectCertificationInventoryEOTemp.setProjectLibraryId(projectLibraryId);
projectCertificationInventoryEOTemp.setFlowStatus(CertificationInventoryFlowStatusEnum.LIST_TO_BE_RELEASED.getValue());
projectCertificationInventoryEOTemp.setCreateTime(new Date());
projectCertificationInventoryEOTemp.setUpdateTime(new Date());
projectCertificationInventoryEOList.add(projectCertificationInventoryEOTemp);
}else {
noSerialNumberList.add(authDummyInventoryInfoEO.getSerialNumber());
@@ -2711,13 +2713,13 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
public void importData(MultipartFile file, ProjectCertificationInventoryEO projectCertificationInventoryEO) {
String title = "";
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEO.getCut())){
title = "*类别,*检验项目,*配置项,*WVTA ID," +
title = title = "*类别,*检验项目,*配置项,*WVTA ID," +
"*标准编号,*责任领域,*工程接口人,*责任人," +
"*交付物类型,交付物模板,*截止日期";
"*交付物类型,交付物模板,*截止日期,报告编号,产品型号,生产企业名称";
}else {
title = "*Category,*Inspection Items,*Configuration Item,*WVTA ID," +
"*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(".");
@@ -2989,6 +2991,12 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
//截止时间
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");
//报告编号
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
if(StringUtils.isNotBlank(wvtaId)){
if(wvtaId.length() > 100){
if(wvtaId.length() > 300){
String message = "";
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){
message = errorMsg + "WVTA ID不能超过100个字符, ";
message = errorMsg + "WVTA ID不能超过300个字符, ";
}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);
}
@@ -3025,12 +3068,12 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
//类别
if(StringUtils.isNotBlank(category)){
if(category.length() > 100){
if(category.length() > 300){
String message = "";
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){
message = errorMsg + "类别不能超过100个字符, ";
message = errorMsg + "类别不能超过300个字符, ";
}else{
message = errorMsg + " The Category cannot contain more than 100 characters, ";
message = errorMsg + " The Category cannot contain more than 300 characters, ";
}
msgList.add(message);
}
@@ -3049,9 +3092,9 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
if(inspectionItem.length() > 100){
String message = "";
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){
message = errorMsg + "检验项目不能超过100个字符, ";
message = errorMsg + "检验项目不能超过300个字符, ";
}else{
message = errorMsg + " The InspectionItem cannot contain more than 100 characters, ";
message = errorMsg + " The InspectionItem cannot contain more than 300 characters, ";
}
msgList.add(message);
}
@@ -3067,12 +3110,12 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
//配置项
if(StringUtils.isNotBlank(configItem)){
if(configItem.length() > 100){
if(configItem.length() > 300){
String message = "";
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEOTemp.getCut())){
message = errorMsg + "配置项不能超过100个字符, ";
}else{
message = errorMsg + " The ConfigItem cannot contain more than 100 characters, ";
message = errorMsg + " The ConfigItem cannot contain more than 300 characters, ";
}
msgList.add(message);
}
@@ -9741,7 +9741,7 @@ public class ProjectLawsInventoryEOServiceImpl extends ServiceImpl<ProjectLawsIn
params.put("Initiator",projectLibraryBase.getStudioEngineerName());
this.sendMessageByTemplateId(TemplateInfoEnum2.REGULATION_LIST_RELEASE2.getValue(),params);
this.sendMessageByTemplateId(TemplateInfoEnum2.REGULATION_TASK_CONFIRMATION1.getValue(),params);
}
}
@@ -9844,7 +9844,7 @@ public class ProjectLawsInventoryEOServiceImpl extends ServiceImpl<ProjectLawsIn
params.put("hrefFeishu_EN",(String)hrefFeishuMap.get("hrefFeishu_EN"));
params.put("Initiator",projectLibraryBase.getStudioEngineerName());
this.sendMessageByTemplateId(TemplateInfoEnum2.REGULATION_LIST_RELEASE2.getValue(),params);
this.sendMessageByTemplateId(TemplateInfoEnum2.REGULATION_TASK_CONFIRMATION1.getValue(),params);
}
}