From c681ff23a12b9a5a5f06aa6a046b6787f47d8ca2 Mon Sep 17 00:00:00 2001
From: xuhy <3313886187@qq.com>
Date: 星期四, 06 三月 2025 20:22:33 +0800
Subject: [PATCH] bug修改

---
 ruoyi-admin/src/main/java/com/ruoyi/web/controller/tool/PdfUtils.java |   15 +++++++++++----
 1 files changed, 11 insertions(+), 4 deletions(-)

diff --git a/ruoyi-admin/src/main/java/com/ruoyi/web/controller/tool/PdfUtils.java b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/tool/PdfUtils.java
index 720e6f6..cd9b4d4 100644
--- a/ruoyi-admin/src/main/java/com/ruoyi/web/controller/tool/PdfUtils.java
+++ b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/tool/PdfUtils.java
@@ -139,10 +139,17 @@
             }
             String absolutePath = pdfFile.getAbsolutePath();
 
-
-            MultipartFile multipartFile = convertToMultipartFile(stream,fileName.substring(0,fileName.lastIndexOf(".")) );
-            String s = tencentCosUtil.upLoadFile(multipartFile,"/wordToPdf");
-            return s;
+//            InputStream inputStream = new URL(url).openStream();
+//            ByteArrayOutputStream stream = new ByteArrayOutputStream();
+//            IConverter converter = LocalConverter.builder().build();
+//            converter.convert(inputStream)
+//                    .as(documentType)
+//                    .to(stream)
+//                    .as(DocumentType.PDF).execute();
+//            MultipartFile multipartFile = convertToMultipartFile(stream,fileName.substring(0,fileName.lastIndexOf(".")) );
+//            String s = tencentCosUtil.upLoadFile(multipartFile,"/wordToPdf");
+//            return s;
+            return "";
 
         } catch (Exception e) {
             throw new RuntimeException("PDF转换失败: " + e.getMessage(), e);

--
Gitblit v1.7.1