|
@@ -418,6 +418,7 @@ public class CaseDownService {
|
|
|
//http://127.0.0.1:8080/offline.html?caseId=362&app=1&share=1#/show/summary
|
|
|
|
|
|
static String batName = "start-browser.bat";
|
|
|
+ static String batName2 = "信创环境启动(打开后选在终端运行).sh";
|
|
|
public void cpIndexHtml(Integer caseId){
|
|
|
log.info("down-offline-cpIndexHtml:{}",caseId);
|
|
|
|
|
@@ -425,8 +426,13 @@ public class CaseDownService {
|
|
|
FileUtil.copyContent(new File(FilePath.OFFLINE_TEMPLATE_PATH),new File(caseOfflinePath),true);
|
|
|
|
|
|
String s = FileUtil.readString(caseOfflinePath + File.separator + batName, StandardCharsets.UTF_8);
|
|
|
- String s1 = s.replaceAll("@caseId", String.valueOf(caseId));
|
|
|
- FileUtil.writeString(s1, caseOfflinePath + File.separator + batName,"UTF-8");
|
|
|
+ s = s.replaceAll("@caseId", String.valueOf(caseId));
|
|
|
+ FileUtil.writeString(s, caseOfflinePath + File.separator + batName,"UTF-8");
|
|
|
+
|
|
|
+ String s1 = FileUtil.readString(caseOfflinePath + File.separator + batName2, StandardCharsets.UTF_8);
|
|
|
+ s1 = s1.replaceAll("@caseId", String.valueOf(caseId));
|
|
|
+ FileUtil.writeString(s1, caseOfflinePath + File.separator + batName2,"UTF-8");
|
|
|
+
|
|
|
}
|
|
|
|
|
|
|
|
@@ -481,16 +487,6 @@ public class CaseDownService {
|
|
|
ShellUtil.unZip(kkzipPath,kknumPath);
|
|
|
FileUtil.del(kkzipPath);
|
|
|
}else {
|
|
|
-// InputStream in = minIoUploadService.getObject(uri);
|
|
|
-// FileOutputStream out = new FileOutputStream(sszipPath);
|
|
|
-// byte[] buffer = new byte[1024];
|
|
|
-// int bytesRead;
|
|
|
-// while ((bytesRead = in.read(buffer)) != -1) {
|
|
|
-// out.write(buffer, 0, bytesRead);
|
|
|
-// }
|
|
|
-// out.flush();
|
|
|
-// out.close();
|
|
|
-// in.close();
|
|
|
ShellUtil.yunDownloadSs(uri.replace(queryPath, ""), sszipPath);
|
|
|
ShellUtil.unZip(sszipPath,ssNumPath);
|
|
|
FileUtil.del(sszipPath);
|