微调
This commit is contained in:
@@ -182,7 +182,8 @@ public class SocketContrastResponseService {
|
|||||||
FormalTestManager.pstDataType = null;
|
FormalTestManager.pstDataType = null;
|
||||||
FormalTestManager.isPstData = false;
|
FormalTestManager.isPstData = false;
|
||||||
FormalTestManager.isWaveCheck = false;
|
FormalTestManager.isWaveCheck = false;
|
||||||
FormalTestManager.isXu = param.getPhaseCheck() == 1 ? true : false;
|
// FormalTestManager.isXu = param.getPhaseCheck() == 1 ? true : false;
|
||||||
|
FormalTestManager.isXu = true;
|
||||||
FormalTestManager.nonWaveDataSourceEnum = null;
|
FormalTestManager.nonWaveDataSourceEnum = null;
|
||||||
|
|
||||||
String[] datasourceIds = FormalTestManager.currentTestPlan.getDatasourceId().split(",");
|
String[] datasourceIds = FormalTestManager.currentTestPlan.getDatasourceId().split(",");
|
||||||
|
|||||||
@@ -71,9 +71,11 @@ public class PqIcdPathServiceImpl extends ServiceImpl<PqIcdPathMapper, PqIcdPath
|
|||||||
pqIcdPath.setState(DataStateEnum.ENABLE.getCode());
|
pqIcdPath.setState(DataStateEnum.ENABLE.getCode());
|
||||||
|
|
||||||
String commInstallPath = this.getCommInstallPath();
|
String commInstallPath = this.getCommInstallPath();
|
||||||
|
System.out.println("commInstallPath = " + commInstallPath);
|
||||||
long FILE_SIZE_LIMIT = 1 * 1024 * 1024;
|
long FILE_SIZE_LIMIT = 1 * 1024 * 1024;
|
||||||
MultipartFile mappingFile = param.getMappingFile();
|
MultipartFile mappingFile = param.getMappingFile();
|
||||||
|
|
||||||
|
System.out.println("mappingFile = " + ObjectUtil.isNotNull(mappingFile) + " " + !mappingFile.isEmpty());
|
||||||
if (ObjectUtil.isNotNull(mappingFile) && !mappingFile.isEmpty()) {
|
if (ObjectUtil.isNotNull(mappingFile) && !mappingFile.isEmpty()) {
|
||||||
String mappingFilename = mappingFile.getOriginalFilename();
|
String mappingFilename = mappingFile.getOriginalFilename();
|
||||||
|
|
||||||
@@ -87,6 +89,7 @@ public class PqIcdPathServiceImpl extends ServiceImpl<PqIcdPathMapper, PqIcdPath
|
|||||||
try {
|
try {
|
||||||
// 如果文件存在,则先删除
|
// 如果文件存在,则先删除
|
||||||
String mappingFilePath = commInstallPath + "\\DeviceControl\\Config\\" + mappingFilename;
|
String mappingFilePath = commInstallPath + "\\DeviceControl\\Config\\" + mappingFilename;
|
||||||
|
System.out.println("mappingFilePath = " + mappingFilePath);
|
||||||
Path path = Paths.get(mappingFilePath);
|
Path path = Paths.get(mappingFilePath);
|
||||||
File file = path.toFile();
|
File file = path.toFile();
|
||||||
if (file.exists()) {
|
if (file.exists()) {
|
||||||
@@ -100,10 +103,12 @@ public class PqIcdPathServiceImpl extends ServiceImpl<PqIcdPathMapper, PqIcdPath
|
|||||||
bufferedOutputStream.flush();
|
bufferedOutputStream.flush();
|
||||||
|
|
||||||
bufferedOutputStream.close();
|
bufferedOutputStream.close();
|
||||||
|
System.out.println("File saved successfully");
|
||||||
} catch (IOException e) {
|
} catch (IOException e) {
|
||||||
throw new BusinessException(ReportResponseEnum.FILE_UPLOAD_FAILED);
|
throw new BusinessException(ReportResponseEnum.FILE_UPLOAD_FAILED);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
System.out.println("mappingFile is null or empty");
|
||||||
throw new BusinessException(IcdResponseEnum.FILE_NOT_NULL);
|
throw new BusinessException(IcdResponseEnum.FILE_NOT_NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -131,7 +136,7 @@ public class PqIcdPathServiceImpl extends ServiceImpl<PqIcdPathMapper, PqIcdPath
|
|||||||
String workDir = System.getProperty("user.dir");
|
String workDir = System.getProperty("user.dir");
|
||||||
// String workDir = "D:\\program\\CN_Gather";
|
// String workDir = "D:\\program\\CN_Gather";
|
||||||
// 获取映射文件存放文件夹
|
// 获取映射文件存放文件夹
|
||||||
String dirPath = workDir.substring(0, workDir.lastIndexOf("\\")) + "\\9100";
|
String dirPath = workDir + "\\9100";
|
||||||
return dirPath;
|
return dirPath;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user