Browse Source

Merge branch 'master' of http://47.108.172.52:3000/dayou/item-management-1phase

GouGengquan 11 months ago
parent
commit
33dde0f4b6

+ 4 - 4
biz-base/src/main/java/com/dayou/controller/OnlyOfficeCallbackController.java

@@ -39,6 +39,8 @@ public class OnlyOfficeCallbackController {
     private void callBack(HttpServletRequest request, HttpServletResponse response) throws IOException {
     private void callBack(HttpServletRequest request, HttpServletResponse response) throws IOException {
         PrintWriter writer = null;
         PrintWriter writer = null;
         JSONObject jsonObj = null;
         JSONObject jsonObj = null;
+        String originPath = request.getParameter("originPath");
+        System.out.println("===originPath:" + originPath);
         System.out.println("===saveeditedfile------------");
         System.out.println("===saveeditedfile------------");
 
 
         try {
         try {
@@ -60,8 +62,7 @@ public class OnlyOfficeCallbackController {
             if ((int) jsonObj.get("status") == 2) {
             if ((int) jsonObj.get("status") == 2) {
                 String key = (String) jsonObj.get("key");
                 String key = (String) jsonObj.get("key");
                 //通过 key获取到文件在服务器上原始保存路经
                 //通过 key获取到文件在服务器上原始保存路经
-                String originFilePath = "";
-                OnlyOfficeFileUtil.callBackSaveDocument(jsonObj,originFilePath);
+                OnlyOfficeFileUtil.callBackSaveDocument(jsonObj,originPath);
             }
             }
         } catch (IOException e) {
         } catch (IOException e) {
             e.printStackTrace();
             e.printStackTrace();
@@ -74,8 +75,7 @@ public class OnlyOfficeCallbackController {
         if ((int) jsonObj.get("status") == 6) {
         if ((int) jsonObj.get("status") == 6) {
             String key = (String) jsonObj.get("key");
             String key = (String) jsonObj.get("key");
             //通过 key获取到文件在服务器上原始保存路经
             //通过 key获取到文件在服务器上原始保存路经
-            String originFilePath = "";
-           OnlyOfficeFileUtil.callBackSaveDocument(jsonObj,originFilePath);
+           OnlyOfficeFileUtil.callBackSaveDocument(jsonObj,originPath);
             writer.write("{\"error\":1}");
             writer.write("{\"error\":1}");
         } else {
         } else {
             writer.write("{\"error\":0}");
             writer.write("{\"error\":0}");