From 4bc494792dd6e6ef973efaf349df29384c49e8f3 Mon Sep 17 00:00:00 2001 From: JIWOO Date: Mon, 11 Nov 2024 17:46:07 +0900 Subject: [PATCH] =?UTF-8?q?=EC=9D=B4=EC=A7=80=EC=9A=B0=20-=20=EA=B4=80?= =?UTF-8?q?=EB=A6=AC=EC=9E=90=20=EB=B6=84=EC=9F=81=EC=A1=B0=EC=A0=95=20?= =?UTF-8?q?=EC=82=AC=EB=A1=80=20=EA=B4=80=EB=A6=AC,=20=EB=B6=84=EC=9F=81?= =?UTF-8?q?=EC=A1=B0=EC=A0=95=EC=95=88=EB=82=B4,=20=EB=89=B4=EC=8A=A4?= =?UTF-8?q?=EB=A0=88=ED=84=B0=EC=97=90=20=EC=9D=B4=EB=85=B8=EB=A6=AD?= =?UTF-8?q?=EC=8A=A4=20=EB=8F=84=EC=9E=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../gtm/counsel/OnlineCounselController.java | 75 +++ .../com/gtm/exam/ExamBoardController.java | 38 ++ .../com/gtm/team/TeamBoardController.java | 38 ++ .../jsp/seed/_extra/gtm/board/edit.jsp | 17 +- .../WEB-INF/jsp/seed/_extra/gtm/exam/edit.jsp | 636 +++++++++++------- .../jsp/seed/_extra/gtm/exam/write.jsp | 102 ++- .../jsp/seed/_extra/gtm/exam/write_back.jsp | 239 +++++++ .../seed/_extra/gtm/onlineCounsel/lawView.jsp | 122 +++- .../_extra/gtm/onlineCounsel/lawWrite.jsp | 95 ++- .../seed/_extra/gtm/onlineCounsel/view.jsp | 117 +++- .../seed/_extra/gtm/onlineCounsel/write.jsp | 95 ++- .../WEB-INF/jsp/seed/_extra/gtm/team/edit.jsp | 122 +++- .../jsp/seed/_extra/gtm/team/write.jsp | 90 ++- 13 files changed, 1494 insertions(+), 292 deletions(-) create mode 100644 src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/exam/write_back.jsp diff --git a/src/main/java/seed/com/gtm/counsel/OnlineCounselController.java b/src/main/java/seed/com/gtm/counsel/OnlineCounselController.java index 17d27447..d86dedf0 100644 --- a/src/main/java/seed/com/gtm/counsel/OnlineCounselController.java +++ b/src/main/java/seed/com/gtm/counsel/OnlineCounselController.java @@ -16,6 +16,8 @@ import seed.com.gtm.seedfile.SeedFileService; import seed.com.gtm.util.Criteria; import seed.com.gtm.util.PageMaker; import seed.com.user.counsel.CounselService; +import seed.common.service.InnorixFileService; +import seed.utils.FairnetUtils; import seed.utils.SeedUtils; @Controller @@ -30,6 +32,9 @@ public class OnlineCounselController { @Autowired private CounselService service2; + @Autowired + private InnorixFileService innorixFileService; + public void setSessionMessageRemove(HttpSession session){ session.removeAttribute("url"); session.removeAttribute("message"); @@ -71,6 +76,16 @@ public class OnlineCounselController { model.addAttribute("memberList", memberList); model.addAttribute("fileList", fileService.fileList(paramMap)); + + //이노릭스 수정화면 용 파일 값 넘겨주기 + String innorixFileListInfoStr = ""; + try { + innorixFileListInfoStr = FairnetUtils.innorixFileListInfo(fileService.fileList(paramMap)); + }catch(Exception e){ + System.out.println("이노릭스 에러"); + } + model.addAttribute("innorixFileListInfoStr", innorixFileListInfoStr); + return "/seed/_extra/gtm/onlineCounsel/view"; } @@ -105,6 +120,17 @@ public class OnlineCounselController { fileService.fileInsert(paramMap, request, session); + //이노릭스 대용량 업로드 + String innorixFileListStr = (String) paramMap.get("innorixFileListVO"); + if(!"".equals(innorixFileListStr)) { + try { + paramMap.put("innorixDataIdx", paramMap.get("dataIdx")); + innorixFileService.innorixExtraFileInsert(innorixFileListStr, paramMap); + }catch(Exception e) { + System.out.println("이노릭스에러"); + } + } + map.put("message", "common.message.reg"); map.put("url", "/gtm/case/onlineCounsel/list.do"); @@ -149,6 +175,21 @@ public class OnlineCounselController { "&searchDate4=" + searchDate4 + "&searchDate5=" + searchDate5 + "&searchDate6=" + searchDate6 + "&searchApp=" + searchApp + "&searchMa=" + searchMa + "&searchTitle=" + searchTitle + "&searchType=" + searchType + "&searchState=" + searchState + "&fileFuncType=" + fileFuncType); + + fileService.fileDel(paramMap); + + //이노릭스 대용량 업로드 + String innorixFileListStr = (String) paramMap.get("innorixFileListVO"); + if(!"".equals(innorixFileListStr)) { + try { + String counselSeqTemp = counselSeq; + int innorixDataIdx = Integer.parseInt(counselSeqTemp); + paramMap.put("innorixDataIdx", innorixDataIdx); + innorixFileService.innorixExtraFileInsert(innorixFileListStr, paramMap); + }catch(Exception e) { + System.out.println("이노릭스에러"); + } + } return "/_common/jsp/message"; } @@ -251,6 +292,15 @@ public class OnlineCounselController { paramMap.put("fileFuncType", SeedUtils.setReplaceNull(paramMap.get("fileFuncType2"))); model.addAttribute("fileList2", fileService.fileList(paramMap)); + //이노릭스 수정화면 용 파일 값 넘겨주기 + String innorixFileListInfoStr = ""; + try { + innorixFileListInfoStr = FairnetUtils.innorixFileListInfo(fileService.fileList(paramMap)); + }catch(Exception e){ + System.out.println("이노릭스 에러"); + } + model.addAttribute("innorixFileListInfoStr", innorixFileListInfoStr); + return "/seed/_extra/gtm/onlineCounsel/lawView"; } @@ -262,6 +312,7 @@ public class OnlineCounselController { model.addAttribute("memberList", memberList); + return "/seed/_extra/gtm/onlineCounsel/lawWrite"; } @@ -282,6 +333,17 @@ public class OnlineCounselController { map.put("message", "common.message.reg"); map.put("url", "/gtm/case/onlineCounsel/lawList.do"); + //이노릭스 대용량 업로드 + String innorixFileListStr = (String) paramMap.get("innorixFileListVO"); + if(!"".equals(innorixFileListStr)) { + try { + paramMap.put("innorixDataIdx", paramMap.get("dataIdx")); + innorixFileService.innorixExtraFileInsert(innorixFileListStr, paramMap); + }catch(Exception e) { + System.out.println("이노릭스에러"); + } + } + return "/_common/jsp/message"; } @@ -327,6 +389,19 @@ public class OnlineCounselController { "&searchDate4=" + searchDate4 + "&searchDate5=" + searchDate5 + "&searchDate6=" + searchDate6 + "&searchApp=" + searchApp + "&searchMa=" + searchMa + "&searchTitle=" + searchTitle + "&searchType=" + searchType + "&searchState=" + searchState + "&fileFuncType=" + fileFuncType + "&fileFuncType2=" + fileFuncType2); + //이노릭스 대용량 업로드 + String innorixFileListStr = (String) paramMap.get("innorixFileListVO"); + if(!"".equals(innorixFileListStr)) { + try { + String counselSeqTemp = counselSeq; + int innorixDataIdx = Integer.parseInt(counselSeqTemp); + paramMap.put("innorixDataIdx", innorixDataIdx); + innorixFileService.innorixExtraFileInsert(innorixFileListStr, paramMap); + }catch(Exception e) { + System.out.println("이노릭스에러"); + } + } + return "/_common/jsp/message"; } diff --git a/src/main/java/seed/com/gtm/exam/ExamBoardController.java b/src/main/java/seed/com/gtm/exam/ExamBoardController.java index 7b0a6952..9a9cb021 100644 --- a/src/main/java/seed/com/gtm/exam/ExamBoardController.java +++ b/src/main/java/seed/com/gtm/exam/ExamBoardController.java @@ -16,7 +16,9 @@ import org.springframework.web.bind.annotation.RequestParam; import seed.com.gtm.seedfile.SeedFileService; import seed.com.gtm.util.PageMaker; +import seed.common.service.InnorixFileService; import seed.com.gtm.util.Criteria; +import seed.utils.FairnetUtils; import seed.utils.SeedDbUtilsSupport; @Controller @@ -28,6 +30,9 @@ public class ExamBoardController { @Autowired private SeedFileService fileService; + @Autowired + private InnorixFileService innorixFileService; + public void setSessionMessageRemove(HttpSession session){ session.removeAttribute("url"); session.removeAttribute("message"); @@ -58,6 +63,17 @@ public class ExamBoardController { paramMap.put("dataIdx", paramMap.get("seq")); fileService.fileInsert(paramMap, request, session); + //이노릭스 대용량 업로드 + String innorixFileListStr = (String) paramMap.get("innorixFileListVO"); + if(!"".equals(innorixFileListStr)) { + try { + paramMap.put("innorixDataIdx", paramMap.get("dataIdx")); + innorixFileService.innorixExtraFileInsert(innorixFileListStr, paramMap); + }catch(Exception e) { + System.out.println("이노릭스에러"); + } + } + map.put("message", "common.message.reg"); map.put("url", "/gtm/case/exam/"+boardIdx+"/list.do"); @@ -159,6 +175,15 @@ public class ExamBoardController { model.addAttribute("fileList", fileList); model.addAttribute("fileListSize", fileList.size()); + //이노릭스 수정화면 용 파일 값 넘겨주기 + String innorixFileListInfoStr = ""; + try { + innorixFileListInfoStr = FairnetUtils.innorixFileListInfo(fileList); + }catch(Exception e){ + System.out.println("이노릭스 에러"); + } + model.addAttribute("innorixFileListInfoStr", innorixFileListInfoStr); + return "/seed/_extra/gtm/exam/edit"; } @@ -179,6 +204,19 @@ public class ExamBoardController { "&fileFuncType=" + paramMap.get("fileFuncType") ); + //이노릭스 대용량 업로드 + String innorixFileListStr = (String) paramMap.get("innorixFileListVO"); + if(!"".equals(innorixFileListStr)) { + try { + String bbsNoStr = (String)paramMap.get("examNo"); + int innorixDataIdx = Integer.parseInt(bbsNoStr); + paramMap.put("innorixDataIdx", innorixDataIdx); + innorixFileService.innorixExtraFileInsert(innorixFileListStr, paramMap); + }catch(Exception e) { + System.out.println("이노릭스에러"); + } + } + return "/_common/jsp/message"; } diff --git a/src/main/java/seed/com/gtm/team/TeamBoardController.java b/src/main/java/seed/com/gtm/team/TeamBoardController.java index 69b37b61..63e406f3 100644 --- a/src/main/java/seed/com/gtm/team/TeamBoardController.java +++ b/src/main/java/seed/com/gtm/team/TeamBoardController.java @@ -16,6 +16,8 @@ import org.springframework.web.bind.annotation.RequestParam; import seed.com.gtm.seedfile.SeedFileService; import seed.com.gtm.util.Criteria; import seed.com.gtm.util.PageMaker; +import seed.common.service.InnorixFileService; +import seed.utils.FairnetUtils; @Controller @RequestMapping("/gtm/case") @@ -26,6 +28,9 @@ public class TeamBoardController { @Autowired private SeedFileService fileService; + @Autowired + private InnorixFileService innorixFileService; + @RequestMapping(value="/team/board/write.do", method=RequestMethod.GET) public String teamWrite(ModelMap model, @RequestParam Map paramMap){ return "/seed/_extra/gtm/team/write"; @@ -44,6 +49,17 @@ public class TeamBoardController { paramMap.put("dataIdx", paramMap.get("seq")); fileService.fileInsert(paramMap, request, session); + //이노릭스 대용량 업로드 + String innorixFileListStr = (String) paramMap.get("innorixFileListVO"); + if(!"".equals(innorixFileListStr)) { + try { + paramMap.put("innorixDataIdx", paramMap.get("dataIdx")); + innorixFileService.innorixExtraFileInsert(innorixFileListStr, paramMap); + }catch(Exception e) { + System.out.println("이노릭스에러"); + } + } + map.put("message", "common.message.reg"); map.put("url", "/gtm/case/team/board/list.do"); @@ -94,6 +110,15 @@ public class TeamBoardController { model.addAttribute("fileList", fileList); model.addAttribute("fileListSize", fileList.size()); + //이노릭스 수정화면 용 파일 값 넘겨주기 + String innorixFileListInfoStr = ""; + try { + innorixFileListInfoStr = FairnetUtils.innorixFileListInfo(fileList); + }catch(Exception e){ + System.out.println("이노릭스 에러"); + } + model.addAttribute("innorixFileListInfoStr", innorixFileListInfoStr); + return "/seed/_extra/gtm/team/edit"; } @@ -112,6 +137,19 @@ public class TeamBoardController { "&fileFuncType=" + paramMap.get("fileFuncType") ); + //이노릭스 대용량 업로드 + String innorixFileListStr = (String) paramMap.get("innorixFileListVO"); + if(!"".equals(innorixFileListStr)) { + try { + String dataIdx = (String)paramMap.get("dataIdx"); + int innorixDataIdx = Integer.parseInt(dataIdx); + paramMap.put("innorixDataIdx", innorixDataIdx); + innorixFileService.innorixExtraFileInsert(innorixFileListStr, paramMap); + }catch(Exception e) { + System.out.println("이노릭스에러"); + } + } + return "/_common/jsp/message"; } diff --git a/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/board/edit.jsp b/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/board/edit.jsp index f1218f4e..978d7a55 100644 --- a/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/board/edit.jsp +++ b/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/board/edit.jsp @@ -60,6 +60,7 @@ ${bbsView.BBS_REG_NM} +

첨부자료

@@ -235,22 +236,6 @@ // 파일 삭제 이벤트 control.on('removeFiles', function (p) { fn_deleteCallBackInnorix(p[0].dataIdx) - /* if (removeFlag == true) { - // 삭제된 파일정보 배열에 담기 - for (var i = 0; i < p.length; i++ ) { - var fileObj = new Object(); - if (p[i].transferType == "download") - { - fileObj.downloadUrl = p[i].downloadUrl; - fileObj.printFileName = p[i].printFileName; - fileObj.fileSize = p[i].fileSize; - - delFileArr.push(fileObj); - deleteArr(downFileArr, "printFileName", p[i].printFileName); - } - } - } - removeFlag = true; */ }); }); diff --git a/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/exam/edit.jsp b/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/exam/edit.jsp index 8a98fa19..21941b57 100644 --- a/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/exam/edit.jsp +++ b/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/exam/edit.jsp @@ -1,259 +1,379 @@ -<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> -<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %> -<%@ taglib uri="http://www.springframework.org/tags/form" prefix="form"%> - - - -정보 관리 - - - - - - - - - -
-
-

분쟁조정 사례(${menuName})

-
- -
-

분쟁조정 사례(${menuName})를 수정 할 수 있는 페이지 입니다.

-
-
-
-
- - - - - - - - - - - - -
-
-
-

제목

-
- -
-
-
-

작성자

-
- ${memberName} -
-
-
-

첨부자료

-
-
- -
-
    - -
  • - gif  ${list.EXTRA_FILE_NAME} - 삭제 - -
  • -
    -
- - - -
-
- -
-

사건 유형 및 분류 선택

-
- - - / - - - - - -
-
- -
-

사건의 개요

-
- -
-
-
-

분쟁사실 및 당사자 주장

-
- -
-
-
-

검토

-
- -
-
-
-

조정결과

-
- -
-
-
- -
- - -
-
-
- -
- -
- -
-
-
- - - -
- - - - +<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> +<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %> +<%@ taglib uri="http://www.springframework.org/tags/form" prefix="form"%> +<%@ taglib prefix="spring" uri="http://www.springframework.org/tags"%> + + + +정보 관리 + + + + + + + + + + + + + + + +
+
+

분쟁조정 사례(${menuName})

+
+ +
+

분쟁조정 사례(${menuName})를 수정 할 수 있는 페이지 입니다.

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

제목

+
+ +
+
+
+

작성자

+
+ ${memberName} +
+
+ +
+

첨부자료

+
+
+ + + + +
+ +

+ + + + + +
+
+ <%--
+

첨부자료

+
+
+ +
+
    + +
  • + gif  ${list.EXTRA_FILE_NAME} + 삭제 + +
  • +
    +
+ + + +
+
--%> + +
+

사건 유형 및 분류 선택

+
+ + + / + + + + + +
+
+ +
+

사건의 개요

+
+ +
+
+
+

분쟁사실 및 당사자 주장

+
+ +
+
+
+

검토

+
+ +
+
+
+

조정결과

+
+ +
+
+
+ +
+ + + +
+
+
+ +
+ +
+ +
+
+
+ + + +
+ + + + \ No newline at end of file diff --git a/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/exam/write.jsp b/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/exam/write.jsp index edfd91d5..10c67dcb 100644 --- a/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/exam/write.jsp +++ b/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/exam/write.jsp @@ -1,6 +1,7 @@ <%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %> <%@ taglib uri="http://www.springframework.org/tags/form" prefix="form"%> +<%@ taglib prefix="spring" uri="http://www.springframework.org/tags"%> @@ -11,6 +12,12 @@ + + + + + + @@ -47,7 +54,24 @@ ${memberName}
+
+

첨부자료

+
+
+ + + + +
+ +

+ + + +
+
+

사건 유형 및 분류 선택

@@ -114,7 +138,8 @@
- + +
@@ -159,6 +184,10 @@ attach_list_view: false }); + /* innorix-1 + 첨부파일 업로드 경로 전역 변수 선언 + */ + var directory = ""; $(window).load(function(){ $("#idx_toolbar_webnote_content_imagecenter").hide(); @@ -199,8 +228,77 @@ return false; } */ }); + + /* innorix-2 + 첨부파일 업로드 경로 설정 + fileFuncType와 세션의 siteId등의 정보를 이용해 업로드 경로 설정 + */ + var fileFuncType = $("#fileTempUpFrm").find("input[name='fileFuncType']").val(); + var url = "" + getFileDirectory(fileFuncType, url, function(result){ + directory = result; + }); + + /* innorix-3 + 이노릭스 업로드 컨트롤 생성 + control 객체는 innorixCommon.js에서 생성 + */ + control = innorix.create({ + el: '#fileControl', // 컨트롤 출력 HTML 객체 ID + transferMode: 'both', // 업로드, 다운로드 혼합사용 + agent : false, + installUrl: "", // Agent 설치 페이지 + uploadUrl: "", // 업로드 URL + allowExtension : ["txt","jpeg","jpg","png","gif","bmp","mp3","mp4","hwp","doc","docx","xls","xlsx","ppt","pptx","pdf","zip","alz"] + }); + + // 업로드 완료 후 temp 파일 저장 - 사용X + //control.on('afterAddFiles', function (p) { + //console.log('afterAddFiles : ', p); + //var postObj = new Object(); + //postObj.directory = directory; + //control.setPostData(postObj); + //control.upload(); // 업로드 시작 + /* $("#fileTempUpFrm").submit(); */ + /* fn_callBackInnorix(p.files); // 파일 정보 DB isnert function */ + //}); + + /* innorix-5 + 이노릭스 업로드 완료 후 + 콜백 함수로 파일 정보 전달 + */ + control.on('uploadComplete', function (p) { + console.log('uploadComplete : ', p); + fn_callBackInnorix(p.files); // 파일 정보 DB isnert function + }); }); + + /* innorix-4 + 이노릭스 업로드 시작 + 첨부파일이 있을 시 업로드 후 게시글 작성 + 첨부파일이 없을 시 바로 게시글 작성 + */ + function innorixUpload(){ + if(control.getUploadFiles().length > 0){ + var postObj = new Object(); + postObj.directory = directory; + control.setPostData(postObj); + control.upload(); // 업로드 시작 */ + }else{ + $("button[type='submit']").click(); + } + } + + /* innorix-6 + 게시글 등록 처리 + 첨부파일 정보 DB 등록 및 게시글 등록 처리 + */ + function fn_callBackInnorix(data){ + $("input[name='innorixFileListVO']").val(JSON.stringify(data)); + $("button[type='submit']").click(); + } + function goList(){ $("#paramFrm").submit(); diff --git a/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/exam/write_back.jsp b/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/exam/write_back.jsp new file mode 100644 index 00000000..edfd91d5 --- /dev/null +++ b/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/exam/write_back.jsp @@ -0,0 +1,239 @@ +<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> +<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %> +<%@ taglib uri="http://www.springframework.org/tags/form" prefix="form"%> + + + + +정보 관리 + + + + + + + + + +
+
+

분쟁조정 사례(${menuName})

+
+ +
+

분쟁조정 사례(${menuName})를 작성 할 수 있는 페이지 입니다.

+
+
+
+
+ + + + + <%-- --%> + + +
+
+
+

제목

+
+ +
+
+
+

작성자

+
+ ${memberName} +
+
+
+

첨부자료

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

사건 유형 및 분류 선택

+
+ + + / + + + +
+
+
+

사건의 개요

+
+ +
+
+
+

분쟁사실 및 당사자 주장

+
+ +
+
+
+

검토

+
+ +
+
+
+

조정결과

+
+ +
+
+
+ + + +
+ + +
+
+
+ +
+ +
+ +
+
+
+ + + + +
+ <%-- + + --%> + + + + + \ No newline at end of file diff --git a/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/onlineCounsel/lawView.jsp b/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/onlineCounsel/lawView.jsp index c424f3b0..e088752c 100644 --- a/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/onlineCounsel/lawView.jsp +++ b/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/onlineCounsel/lawView.jsp @@ -1,6 +1,7 @@ <%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %> <%@ taglib uri="http://www.springframework.org/tags/form" prefix="form"%> +<%@ taglib prefix="spring" uri="http://www.springframework.org/tags"%> @@ -9,6 +10,13 @@ + + + + + + + @@ -212,9 +220,25 @@
+

상담기록카드

+
+ + + + +
+ +

+ + + + + +
+ <%--
@@ -231,7 +255,7 @@ -
+
--%> @@ -251,7 +275,8 @@ - + + @@ -338,6 +363,12 @@ return true; } + /* innorix-1 + 첨부파일 업로드 경로 전역 변수 선언 + */ + var directory = ""; + var fileList = ""; + $(document).ready(function(){ caseGubunCombo(); counselAppTypeCombo(); @@ -379,8 +410,95 @@ $(optionList[i]).attr("selected", true); } } + + /* 이노릭스 대용량 업로드 솔루션 */ + + /* innorix-2 + 첨부파일 업로드 경로 설정 + fileFuncType와 세션의 siteId등의 정보를 이용해 업로드 경로 설정 + */ + var fileFuncType = $("#fileTempUpFrm").find("input[name='fileFuncType']").val(); + var url = "" + getFileDirectory(fileFuncType, url, function(result){ + directory = result; + }); + + + /* innorix-3 + 이노릭스 업로드 컨트롤 생성 + control 객체는 innorixCommon.js에서 생성 + */ + control = innorix.create({ + el: '#fileControl', // 컨트롤 출력 HTML 객체 ID + transferMode: 'both', // 업로드, 다운로드 혼합사용 + agent : false, + installUrl: "", // Agent 설치 페이지 + uploadUrl: "", // 업로드 URL + allowExtension : ["txt","jpeg","jpg","png","gif","bmp","mp3","mp4","hwp","doc","docx","xls","xlsx","ppt","pptx","pdf","zip","alz"] + }); + + var downFileArr =${innorixFileListInfoStr}; + + + /* innorix-5 + 이노릭스 업로드 완료 후 + 콜백 함수로 파일 정보 전달 + */ + control.on('uploadComplete', function (p) { + console.log('uploadComplete : ', p); + fn_callBackInnorix(p.files); // 파일 정보 DB isnert function + }); + + // 파일전송 컨트롤 로딩 완료 + control.on('loadComplete', function (p) { + resetFileArr = downFileArr; // 다운로드 정보 초기화 정보 생성 + resetFileArr = resetFileArr.slice(0); // 배열 깊은 복사 + control.presetDownloadFiles(resetFileArr); // 다운로드 파일 추가 + }); + + // 파일 삭제 이벤트 + control.on('removeFiles', function (p) { + fn_deleteCallBackInnorix(p[0].dataIdx) + }); + }); + /* innorix-4 + 이노릭스 업로드 시작 + 첨부파일이 있을 시 업로드 후 게시글 수정 + 첨부파일이 없을 시 바로 게시글 수정 + */ + function innorixUpload(){ + if(control.getUploadFiles().length > 0){ + var postObj = new Object(); + postObj.directory = directory; + control.setPostData(postObj); + control.upload(); // 업로드 시작 + }else{ + $("button[type='submit']").click(); + } + } + + + /* innorix-6 + 게시글 등록 처리 + 첨부파일 정보 DB 등록 및 게시글 등록 처리 + */ + function fn_callBackInnorix(data){ + $("input[name='innorixFileListVO']").val(JSON.stringify(data)); + $("button[type='submit']").click(); + } + + function fn_deleteCallBackInnorix(dataIdx){ + var deleteFileData = $("#deleteFileDataId").val(); + if(deleteFileData != ""){ + deleteFileData = deleteFileData+","+dataIdx + }else{ + deleteFileData = dataIdx + } + $("#deleteFileDataId").val(deleteFileData); + } + //상담분야 function caseGubunCombo(){ var url = ""; diff --git a/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/onlineCounsel/lawWrite.jsp b/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/onlineCounsel/lawWrite.jsp index 4c3b50bc..026b7abc 100644 --- a/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/onlineCounsel/lawWrite.jsp +++ b/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/onlineCounsel/lawWrite.jsp @@ -1,6 +1,7 @@ <%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %> <%@ taglib uri="http://www.springframework.org/tags/form" prefix="form"%> +<%@ taglib prefix="spring" uri="http://www.springframework.org/tags"%> @@ -9,6 +10,13 @@ + + + + + + + @@ -132,32 +140,47 @@ +

상담기록카드

+
+ + + + +
+ +

+ + + +
+ <%--
-
+
--%>
- + +
@@ -172,6 +195,12 @@ + + @@ -100,15 +107,31 @@ +

첨부파일

+
+ + + + +
+ +

+ + + + + +
+ <%-- +
--%>
@@ -251,7 +274,8 @@ - + +
@@ -275,6 +299,13 @@ + + + @@ -63,9 +71,26 @@ +

첨부파일

-
+
+
+ + + + +
+ +

+ + + + + +
+ +

이메일

@@ -187,7 +212,8 @@
- + +
@@ -218,6 +244,11 @@ location.href="/gtm/case/onlineCounsel/list.do"; } + /* innorix-1 + 첨부파일 업로드 경로 전역 변수 선언 + */ + var directory = ""; + $(document).ready(function(){ @@ -273,8 +304,66 @@ counselAppTypeCombo(); counselResertGubunCombo(); counselRouteCombo(); + + + /* innorix-2 + 첨부파일 업로드 경로 설정 + fileFuncType와 세션의 siteId등의 정보를 이용해 업로드 경로 설정 + */ + var fileFuncType = $("#fileTempUpFrm").find("input[name='fileFuncType']").val(); + var url = "" + getFileDirectory(fileFuncType, url, function(result){ + directory = result; + }); + + /* innorix-3 + 이노릭스 업로드 컨트롤 생성 + control 객체는 innorixCommon.js에서 생성 + */ + control = innorix.create({ + el: '#fileControl', // 컨트롤 출력 HTML 객체 ID + transferMode: 'both', // 업로드, 다운로드 혼합사용 + agent : false, + installUrl: "", // Agent 설치 페이지 + uploadUrl: "", // 업로드 URL + allowExtension : ["txt","jpeg","jpg","png","gif","bmp","mp3","mp4","hwp","doc","docx","xls","xlsx","ppt","pptx","pdf","zip","alz"] + }); + /* innorix-5 + 이노릭스 업로드 완료 후 + 콜백 함수로 파일 정보 전달 + */ + control.on('uploadComplete', function (p) { + console.log('uploadComplete : ', p); + fn_callBackInnorix(p.files); // 파일 정보 DB isnert function + }); + }); + /* innorix-4 + 이노릭스 업로드 시작 + 첨부파일이 있을 시 업로드 후 게시글 작성 + 첨부파일이 없을 시 바로 게시글 작성 + */ + function innorixUpload(){ + if(control.getUploadFiles().length > 0){ + var postObj = new Object(); + postObj.directory = directory; + control.setPostData(postObj); + control.upload(); // 업로드 시작 */ + }else{ + $("button[type='submit']").click(); + } + } + + /* innorix-6 + 게시글 등록 처리 + 첨부파일 정보 DB 등록 및 게시글 등록 처리 + */ + function fn_callBackInnorix(data){ + $("input[name='innorixFileListVO']").val(JSON.stringify(data)); + $("button[type='submit']").click(); + } + //상담분야 function caseGubunCombo(){ var url = ""; diff --git a/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/team/edit.jsp b/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/team/edit.jsp index 021ecd61..63dbaa46 100644 --- a/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/team/edit.jsp +++ b/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/team/edit.jsp @@ -1,6 +1,7 @@ <%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %> <%@ taglib uri="http://www.springframework.org/tags/form" prefix="form"%> +<%@ taglib prefix="spring" uri="http://www.springframework.org/tags"%> @@ -10,6 +11,12 @@ + + + + + + @@ -46,9 +53,25 @@ ${memberName}
+

첨부자료

+
+ + + + +
+ +

+ + + + + +
+ <%--
@@ -64,7 +87,7 @@ -
+
--%>

내용

@@ -75,7 +98,8 @@
- + + 목록
@@ -116,7 +140,14 @@ fade_popup: true, //팝업 열리기/닫히기 시 fade in/out 기능 적용 여부(사용pc 사용이 낮은경우 false로 ) attach_list_view: false }); - + + + /* innorix-1 + 첨부파일 업로드 경로 전역 변수 선언 + */ + var directory = ""; + var fileList = ""; + $(window).load(function(){ $("#idx_toolbar_webnote_content_imagecenter").hide(); @@ -150,8 +181,93 @@ return false; } */ }); + + /* 이노릭스 대용량 업로드 솔루션 */ + + /* innorix-2 + 첨부파일 업로드 경로 설정 + fileFuncType와 세션의 siteId등의 정보를 이용해 업로드 경로 설정 + */ + var fileFuncType = $("#fileTempUpFrm").find("input[name='fileFuncType']").val(); + var url = "" + getFileDirectory(fileFuncType, url, function(result){ + directory = result; + }); + + /* innorix-3 + 이노릭스 업로드 컨트롤 생성 + control 객체는 innorixCommon.js에서 생성 + */ + control = innorix.create({ + el: '#fileControl', // 컨트롤 출력 HTML 객체 ID + transferMode: 'both', // 업로드, 다운로드 혼합사용 + agent : false, + installUrl: "", // Agent 설치 페이지 + uploadUrl: "", // 업로드 URL + allowExtension : ["txt","jpeg","jpg","png","gif","bmp","mp3","mp4","hwp","doc","docx","xls","xlsx","ppt","pptx","pdf","zip","alz"] + }); + + var downFileArr =${innorixFileListInfoStr}; + + + /* innorix-5 + 이노릭스 업로드 완료 후 + 콜백 함수로 파일 정보 전달 + */ + control.on('uploadComplete', function (p) { + console.log('uploadComplete : ', p); + fn_callBackInnorix(p.files); // 파일 정보 DB isnert function + }); + + // 파일전송 컨트롤 로딩 완료 + control.on('loadComplete', function (p) { + resetFileArr = downFileArr; // 다운로드 정보 초기화 정보 생성 + resetFileArr = resetFileArr.slice(0); // 배열 깊은 복사 + control.presetDownloadFiles(resetFileArr); // 다운로드 파일 추가 + }); + + // 파일 삭제 이벤트 + control.on('removeFiles', function (p) { + fn_deleteCallBackInnorix(p[0].dataIdx) + }); }); + /* innorix-4 + 이노릭스 업로드 시작 + 첨부파일이 있을 시 업로드 후 게시글 수정 + 첨부파일이 없을 시 바로 게시글 수정 + */ + function innorixUpload(){ + if(control.getUploadFiles().length > 0){ + var postObj = new Object(); + postObj.directory = directory; + control.setPostData(postObj); + control.upload(); // 업로드 시작 + }else{ + $("button[type='submit']").click(); + } + } + + + /* innorix-6 + 게시글 등록 처리 + 첨부파일 정보 DB 등록 및 게시글 등록 처리 + */ + function fn_callBackInnorix(data){ + $("input[name='innorixFileListVO']").val(JSON.stringify(data)); + $("button[type='submit']").click(); + } + + function fn_deleteCallBackInnorix(dataIdx){ + var deleteFileData = $("#deleteFileDataId").val(); + if(deleteFileData != ""){ + deleteFileData = deleteFileData+","+dataIdx + }else{ + deleteFileData = dataIdx + } + $("#deleteFileDataId").val(deleteFileData); + } + function goList(){ $("#paramFrm").submit(); } diff --git a/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/team/write.jsp b/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/team/write.jsp index 7ae0de81..b9c9919d 100644 --- a/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/team/write.jsp +++ b/src/main/webapp/WEB-INF/jsp/seed/_extra/gtm/team/write.jsp @@ -1,6 +1,7 @@ <%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %> <%@ taglib uri="http://www.springframework.org/tags/form" prefix="form"%> +<%@ taglib prefix="spring" uri="http://www.springframework.org/tags"%> @@ -10,6 +11,12 @@ + + + + + + @@ -84,9 +91,24 @@ ${memberName} + +

첨부자료

+
+ + + + +
+ +

+ + + +
+

내용

@@ -106,7 +128,8 @@
- + +
@@ -149,6 +172,11 @@ }); + /* innorix-1 + 첨부파일 업로드 경로 전역 변수 선언 + */ + var directory = ""; + $(window).load(function(){ $("#idx_toolbar_webnote_content_imagecenter").hide(); @@ -181,8 +209,66 @@ return false; } */ }); + + /* innorix-2 + 첨부파일 업로드 경로 설정 + fileFuncType와 세션의 siteId등의 정보를 이용해 업로드 경로 설정 + */ + var fileFuncType = $("#fileTempUpFrm").find("input[name='fileFuncType']").val(); + var url = "" + getFileDirectory(fileFuncType, url, function(result){ + directory = result; + }); + + /* innorix-3 + 이노릭스 업로드 컨트롤 생성 + control 객체는 innorixCommon.js에서 생성 + */ + control = innorix.create({ + el: '#fileControl', // 컨트롤 출력 HTML 객체 ID + transferMode: 'both', // 업로드, 다운로드 혼합사용 + agent : false, + installUrl: "", // Agent 설치 페이지 + uploadUrl: "", // 업로드 URL + allowExtension : ["txt","jpeg","jpg","png","gif","bmp","mp3","mp4","hwp","doc","docx","xls","xlsx","ppt","pptx","pdf","zip","alz"] + }); + + /* innorix-5 + 이노릭스 업로드 완료 후 + 콜백 함수로 파일 정보 전달 + */ + control.on('uploadComplete', function (p) { + console.log('uploadComplete : ', p); + fn_callBackInnorix(p.files); // 파일 정보 DB isnert function + }); + }); + /* innorix-4 + 이노릭스 업로드 시작 + 첨부파일이 있을 시 업로드 후 게시글 작성 + 첨부파일이 없을 시 바로 게시글 작성 + */ + function innorixUpload(){ + if(control.getUploadFiles().length > 0){ + var postObj = new Object(); + postObj.directory = directory; + control.setPostData(postObj); + control.upload(); // 업로드 시작 */ + }else{ + $("button[type='submit']").click(); + } + } + + /* innorix-6 + 게시글 등록 처리 + 첨부파일 정보 DB 등록 및 게시글 등록 처리 + */ + function fn_callBackInnorix(data){ + $("input[name='innorixFileListVO']").val(JSON.stringify(data)); + $("button[type='submit']").click(); + } + function goList(){ $("#paramFrm").submit(); }