|
@@ -9,6 +9,7 @@ import com.rongwei.bsentity.domain.ZhcxCommissionCheckDetailTreeDo;
|
|
|
import com.rongwei.bsentity.domain.ZhcxProjectManageDo;
|
|
|
import com.rongwei.bsentity.dto.commission.ImportProjectCheckBO;
|
|
|
import com.rongwei.bsentity.dto.commission.ParseDocBO;
|
|
|
+import com.rongwei.rwcommon.base.exception.CustomException;
|
|
|
import com.rongwei.rwcommon.utils.SecurityUtil;
|
|
|
import com.rongwei.rwcommon.utils.StringUtils;
|
|
|
|
|
@@ -50,14 +51,35 @@ public class ImportCommissionHelp {
|
|
|
detail.setId(SecurityUtil.getUUID());
|
|
|
detail.setDeleted("0");
|
|
|
detail.setPid(importDto.getId());
|
|
|
+ if(ObjectUtil.isEmpty(rowJson.getString("NO."))){
|
|
|
+ throw new CustomException("字段 'NO.' 不能为空");
|
|
|
+ }
|
|
|
detail.setChapterno(rowJson.getString("NO."));
|
|
|
+
|
|
|
+ if(ObjectUtil.isEmpty(rowJson.getString("模式1"))){
|
|
|
+ throw new CustomException("字段 '模式1' 不能为空");
|
|
|
+ }
|
|
|
detail.setClassification(rowJson.getString("模式1"));
|
|
|
+
|
|
|
+ if(ObjectUtil.isEmpty(rowJson.getString("模式2"))){
|
|
|
+ throw new CustomException("字段 '模式2' 不能为空");
|
|
|
+ }
|
|
|
detail.setClassificationtwo(rowJson.getString("模式2"));
|
|
|
+
|
|
|
detail.setChtestcontent(rowJson.getString("测试内容中文"));
|
|
|
detail.setEntestcontent(rowJson.getString("测试内容英文"));
|
|
|
//detail.setTestmethod(rowJson.getString("标准测试方法"));
|
|
|
+
|
|
|
+ if(ObjectUtil.isEmpty(rowJson.getString("标准测试时间"))){
|
|
|
+ throw new CustomException("字段 '标准测试时间' 不能为空");
|
|
|
+ }
|
|
|
detail.setTesttime(rowJson.getString("标准测试时间"));
|
|
|
+
|
|
|
+ if(ObjectUtil.isEmpty(rowJson.getString("接收标准"))){
|
|
|
+ throw new CustomException("字段 '接收标准' 不能为空");
|
|
|
+ }
|
|
|
detail.setAcceptancecriteria(rowJson.getString("接收标准"));
|
|
|
+
|
|
|
String testAddress = rowJson.getString("测试地点");
|
|
|
if(ObjectUtil.isEmpty(testAddress) || ObjectUtil.isEmpty(importDto.getDictMap().get(testAddress))) {
|
|
|
testAddress = "10";
|