From eae766b3bd20e0cf2cccf4013fb1c067739afa30 Mon Sep 17 00:00:00 2001 From: itn Date: Thu, 3 Aug 2023 15:19:43 +0900 Subject: [PATCH] =?UTF-8?q?=EA=B8=B0=EC=97=85=ED=9A=8C=EC=9B=90=20?= =?UTF-8?q?=EC=B2=A8=EB=B6=80=ED=8C=8C=EC=9D=BC=20=EB=B7=B0=EC=96=B4=20?= =?UTF-8?q?=EC=82=AC=EC=97=85=EC=9E=90=EB=93=B1=EB=A1=9D=EC=A6=9D/?= =?UTF-8?q?=EC=9E=AC=EC=A7=81=EC=A6=9D=EB=AA=85=EC=84=9C=20=ED=95=9C?= =?UTF-8?q?=ED=99=94=EB=A9=B4=EC=97=90=EC=84=9C=20=EB=B3=B4=EA=B8=B0=20?= =?UTF-8?q?=EA=B8=B0=EB=8A=A5=20=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/java/itn/com/cmm/util/PdfUtil.java | 4 +- .../cmm/web/EgovFileDownloadController.java | 4 +- .../let/mjo/msg/web/MjonMsgController.java | 26 +++++--- .../cmm/uss/umt/EgovMberCmpHstListByType.jsp | 10 ++- .../WEB-INF/jsp/uss/ion/msg/pdfView.jsp | 65 ++++++++++++++++++- 5 files changed, 91 insertions(+), 18 deletions(-) diff --git a/src/main/java/itn/com/cmm/util/PdfUtil.java b/src/main/java/itn/com/cmm/util/PdfUtil.java index 97014445..5be56982 100644 --- a/src/main/java/itn/com/cmm/util/PdfUtil.java +++ b/src/main/java/itn/com/cmm/util/PdfUtil.java @@ -131,8 +131,8 @@ public final class PdfUtil { PDPageContentStream contents = new PDPageContentStream(doc, page); contents.drawImage(pdImage, pageWidthPosition, pageHeightPosition, imgWidth, imgHeight); contents.close(); - doc.save("/usr/local/tomcat/file/sht/pdf/" + uuid + ".pdf"); - //doc.save("C:/TEST/" + uuid + ".pdf"); + //doc.save("/usr/local/tomcat/file/sht/pdf/" + uuid + ".pdf"); + doc.save("C:/TEST/" + uuid + ".pdf"); } catch (Exception e) { System.out.println("Exception! : " + e.getMessage()); diff --git a/src/main/java/itn/com/cmm/web/EgovFileDownloadController.java b/src/main/java/itn/com/cmm/web/EgovFileDownloadController.java index 4408051f..eb98c264 100644 --- a/src/main/java/itn/com/cmm/web/EgovFileDownloadController.java +++ b/src/main/java/itn/com/cmm/web/EgovFileDownloadController.java @@ -465,8 +465,8 @@ public class EgovFileDownloadController { String fileNm = (String) commandMap.get("fileNm"); try { - File uFile = new File("/usr/local/tomcat/file/sht/pdf/", fileNm); - //File uFile = new File("C:/TEST/", fileNm); + //File uFile = new File("/usr/local/tomcat/file/sht/pdf/", fileNm); + File uFile = new File("C:/TEST/", fileNm); long fSize = uFile.length(); diff --git a/src/main/java/itn/let/mjo/msg/web/MjonMsgController.java b/src/main/java/itn/let/mjo/msg/web/MjonMsgController.java index 00b45d58..b96210cd 100644 --- a/src/main/java/itn/let/mjo/msg/web/MjonMsgController.java +++ b/src/main/java/itn/let/mjo/msg/web/MjonMsgController.java @@ -5046,7 +5046,21 @@ public class MjonMsgController { public String pdfView(FileVO fileVO , ModelMap model , HttpServletRequest request) throws Exception { - + + // 파라미터 + String docuDiv = request.getParameter("docuDiv"); + String atchFileId = request.getParameter("atchFileId"); + String workAtchFileId = request.getParameter("workAtchFileId"); + String mberNm = request.getParameter("mberNm"); + String bizNo = request.getParameter("bizNo"); + String ceoNm = request.getParameter("ceoNm"); + String hstManagerNm = request.getParameter("hstManagerNm"); + String hstMbtlNum = request.getParameter("hstMbtlNum"); + + if (docuDiv.equals("2")) { + fileVO.setAtchFileId(workAtchFileId); + } + FileVO fvo = fileService.selectFileInf(fileVO); String path = ""; String fileType = ""; @@ -5068,15 +5082,11 @@ public class MjonMsgController { } } - String mberNm = request.getParameter("mberNm"); - String bizNo = request.getParameter("bizNo"); - String ceoNm = request.getParameter("ceoNm"); - String hstManagerNm = request.getParameter("hstManagerNm"); - String hstMbtlNum = request.getParameter("hstMbtlNum"); - model.addAttribute("pdfPath", path); model.addAttribute("fileType", fileType); - model.addAttribute("atchFileId", fileVO.getAtchFileId()); + model.addAttribute("docuDiv", docuDiv); + model.addAttribute("atchFileId", atchFileId); + model.addAttribute("workAtchFileId", workAtchFileId); model.addAttribute("mberNm", mberNm); model.addAttribute("bizNo", bizNo); model.addAttribute("ceoNm", ceoNm); diff --git a/src/main/webapp/WEB-INF/jsp/cmm/uss/umt/EgovMberCmpHstListByType.jsp b/src/main/webapp/WEB-INF/jsp/cmm/uss/umt/EgovMberCmpHstListByType.jsp index 669be8b0..c93442b4 100644 --- a/src/main/webapp/WEB-INF/jsp/cmm/uss/umt/EgovMberCmpHstListByType.jsp +++ b/src/main/webapp/WEB-INF/jsp/cmm/uss/umt/EgovMberCmpHstListByType.jsp @@ -22,8 +22,10 @@ $( document ).ready(function() { }); // PdfView -function pdfViewPop(atchFileId,mberNm,bizNo,ceoNm,hstManagerNm,hstMbtlNum) { +function pdfViewPop(docuDiv,atchFileId,workAtchFileId,mberNm,bizNo,ceoNm,hstManagerNm,hstMbtlNum) { + document.pdfForm.docuDiv.value = docuDiv; document.pdfForm.atchFileId.value = atchFileId; + document.pdfForm.workAtchFileId.value = workAtchFileId; document.pdfForm.fileSn.value = 0; document.pdfForm.mberNm.value = mberNm; document.pdfForm.bizNo.value = bizNo; @@ -284,7 +286,9 @@ function fnSetCalMonth(val) {
+ + @@ -469,7 +473,7 @@ function fnSetCalMonth(val) { - + @@ -481,7 +485,7 @@ function fnSetCalMonth(val) { - + diff --git a/src/main/webapp/WEB-INF/jsp/uss/ion/msg/pdfView.jsp b/src/main/webapp/WEB-INF/jsp/uss/ion/msg/pdfView.jsp index d39d309d..527a3d57 100644 --- a/src/main/webapp/WEB-INF/jsp/uss/ion/msg/pdfView.jsp +++ b/src/main/webapp/WEB-INF/jsp/uss/ion/msg/pdfView.jsp @@ -41,6 +41,21 @@ html { overflow-y: auto; } + + @@ -76,15 +91,46 @@ html { ${hstManagerNm} ${hstMbtlNum} - - - + + + + + + + + + + + + + +
+ + + + + + + + + + + + + + + + + +
+
+
PDF 뷰어에서 지원하지 않는 형식의 파일입니다. 첨부파일 다운로드후 확인해주세요. @@ -102,6 +148,19 @@ html {


+ + + + + + + + + + + + +