allen 11 月之前
父節點
當前提交
e1785cc069

+ 4 - 4
taais-modules/taais-biz/src/main/java/com/taais/biz/service/impl/AlgorithmTaskServiceImpl.java

@@ -684,8 +684,8 @@ public class AlgorithmTaskServiceImpl extends BaseServiceImpl<AlgorithmTaskMappe
                 if (osName.contains("win")) {
                 } else {
                     // Linux/Unix 环境
-                    imagePath = imagePath.replaceAll("/", "\\\\");
-                    destPath = destPath.replaceAll("/", "\\\\");
+                    imagePath = imagePath.replaceAll("\\\\", "/");
+                    destPath = destPath.replaceAll("\\\\", "/");
                 }
                 FileUtils.copyFile(imagePath, destPath);
                 log.info("复制图片文件成功source:{},target:{}", imagePath, destPath);
@@ -699,8 +699,8 @@ public class AlgorithmTaskServiceImpl extends BaseServiceImpl<AlgorithmTaskMappe
                 if (osName.contains("win")) {
                 } else {
                     // Linux/Unix 环境
-                    txtPathStr = txtPathStr.replaceAll("/", "\\\\");
-                    destLabelPath = destLabelPath.replaceAll("/", "\\\\");
+                    txtPathStr = txtPathStr.replaceAll("\\\\", "/");
+                    destLabelPath = destLabelPath.replaceAll("\\\\", "/");
                 }
                 try {
                     FileUtils.copyFile(txtPathStr, destLabelPath);