From beacb68ac16331f9e25c98ad382705a1ed29740a Mon Sep 17 00:00:00 2001 From: jjh Date: Tue, 6 Feb 2024 15:30:10 +0900 Subject: [PATCH] =?UTF-8?q?=EB=B0=9C=EC=86=A1=20=EB=B0=98=EC=86=A1=20?= =?UTF-8?q?=EC=88=98=EC=A0=95.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../xit/fims/sndb/service/bean/SndngBean.java | 12 +- .../xit/fims/sndb/web/Sndb01Controller.java | 33 +- .../sql/mapper/fims/sndb/sndng-mapper.xml | 6 +- .../WEB-INF/jsp/fims/excl/excl01010-main.jsp | 13 +- .../WEB-INF/jsp/fims/excl/excl01020-info.jsp | 10 +- .../WEB-INF/jsp/fims/excl/excl02010-main.jsp | 13 +- .../WEB-INF/jsp/fims/excl/excl02020-info.jsp | 10 +- .../WEB-INF/jsp/fims/excl/excl02030-info.jsp | 10 +- .../WEB-INF/jsp/fims/levy/levy01010-main.jsp | 37 +- .../WEB-INF/jsp/fims/levy/levy01020-info.jsp | 11 +- .../WEB-INF/jsp/fims/levy/levy01050-main.jsp | 15 +- .../WEB-INF/jsp/fims/levy/levy02010-main.jsp | 13 +- .../WEB-INF/jsp/fims/levy/levy02020-info.jsp | 10 +- .../WEB-INF/jsp/fims/rdca/rdca01020-info.jsp | 10 +- .../WEB-INF/jsp/fims/sndb/sndb01010-main.jsp | 147 ++-- .../WEB-INF/jsp/fims/sndb/sndb01020-info.jsp | 445 ++++++------ .../WEB-INF/jsp/fims/sndb/sndb01030-main.jsp | 646 ++++++++++-------- .../WEB-INF/jsp/fims/sndb/sndb01040-info.jsp | 426 ++++++------ .../WEB-INF/jsp/fims/sprt/sprt02020-info.jsp | 50 +- .../WEB-INF/jsp/fims/sprt/sprt02030-info.jsp | 27 +- .../WEB-INF/jsp/fims/sprt/sprt02040-info.jsp | 23 +- .../WEB-INF/jsp/fims/sprt/sprt02050-info.jsp | 29 +- .../WEB-INF/jsp/fims/sprt/sprt02060-info.jsp | 21 +- .../WEB-INF/jsp/fims/sprt/sprt02070-info.jsp | 21 +- .../WEB-INF/jsp/fims/sprt/sprt02080-info.jsp | 23 +- 25 files changed, 1120 insertions(+), 941 deletions(-) diff --git a/src/main/java/cokr/xit/fims/sndb/service/bean/SndngBean.java b/src/main/java/cokr/xit/fims/sndb/service/bean/SndngBean.java index 82e009f4..9563a64b 100644 --- a/src/main/java/cokr/xit/fims/sndb/service/bean/SndngBean.java +++ b/src/main/java/cokr/xit/fims/sndb/service/bean/SndngBean.java @@ -178,14 +178,14 @@ public class SndngBean extends AbstractComponent { boolean rtnScs = false; // DB 처리 결과 String rtnMsg = "[F] "; // 처리 결과 메시지 - List wrngTrgtList = sndngMapper.selectWrngTrgtCrdnIDs(req); + List trgtList = sndngMapper.selectWrngTrgtCrdnIDs(req); // 조회 건수 확인 - if (wrngTrgtList == null || wrngTrgtList.size() < 1) { + if (trgtList == null || trgtList.size() < 1) { rtnMsg = "[F] 작업 중 대상 자료가 존재하지 않습니다."; return rtnMsg; } - if (sndng.getTnocs() != wrngTrgtList.size()) { + if (sndng.getTnocs() != trgtList.size()) { rtnMsg = "[F] 조회된 총 건수와 대상 건수가 다릅니다."; return rtnMsg; } @@ -195,7 +195,7 @@ public class SndngBean extends AbstractComponent { // 발송(TB_SNDNG) 대장에 등록한다. sndng.setDeptCd(userInfo.string("DEPT_CD")); // 부서 코드 - sndng.setVltnId(wrngTrgtList.get(0).string("VLTN_ID")); // 위반 ID + sndng.setVltnId(trgtList.get(0).string("VLTN_ID")); // 위반 ID sndng.setLevyBgngYmd(null); // 부과 시작 일자 sndng.setLevyEndYmd(null); // 부과 종료 일자 sndng.setSndngEndYmd(null); // 발송 종료 일자 @@ -223,8 +223,8 @@ public class SndngBean extends AbstractComponent { } // 발송 상세(TB_SNDNG_DTL) 대장에 등록한다. - for (int iLoop = 0; iLoop < wrngTrgtList.size(); iLoop++) { - rtnMsg = createWrngSndngDtl(sndng, wrngTrgtList.get(iLoop).string("CRDN_ID")); + for (int iLoop = 0; iLoop < trgtList.size(); iLoop++) { + rtnMsg = createWrngSndngDtl(sndng, trgtList.get(iLoop).string("CRDN_ID")); // 메시지 확인 if (!rtnMsg.contains("[S]")) { throw new RuntimeException("계도장 발송 등록 작업중 발송상세 등록에 실패하였습니다."); // 예외를 발생시켜서 DB Rollback diff --git a/src/main/java/cokr/xit/fims/sndb/web/Sndb01Controller.java b/src/main/java/cokr/xit/fims/sndb/web/Sndb01Controller.java index 50ef263d..88c07aec 100644 --- a/src/main/java/cokr/xit/fims/sndb/web/Sndb01Controller.java +++ b/src/main/java/cokr/xit/fims/sndb/web/Sndb01Controller.java @@ -120,6 +120,7 @@ public class Sndb01Controller extends ApplicationController { * @return /sndb/sndb01/010-main */ public ModelAndView warningTargetMain() { + // ModelAndView mav = new ModelAndView("fims/sndb/sndb01010-main"); // 사용자 정보 @@ -156,6 +157,7 @@ public class Sndb01Controller extends ApplicationController { * } */ public ModelAndView getWarningTargetList(SndbQuery req) { + // if (!"xls".equals(req.getDownload())) { List result = sndngService.getWrngTrgtList(setFetchSize(req)); return setCollectionInfo(new ModelAndView("jsonView"), result, "wrngTrgt"); @@ -232,17 +234,17 @@ public class Sndb01Controller extends ApplicationController { * } */ public ModelAndView getWarningTargetInfo(SndbQuery req) { - List wrngTrgts = sndngService.getWrngTrgts(req); - - boolean json = jsonResponse(); + // + ModelAndView mav = getWarningTargetList(req); - ModelAndView mav = new ModelAndView(json ? "jsonView" : "fims/sndb/sndb01020-info"); + mav.setViewName("fims/sndb/sndb01020-info"); return mav - .addObject("pageName", "sndb01020") - .addObject("callPurpose", req.getCallPurpose()) // 호출 용도 - .addObject("wrngTrgtQuery", json ? req : toJson(req)) // Query - .addObject("wrngTrgt", json ? wrngTrgts : toJson(wrngTrgts)) // 계고장 발송 대상 정보 + .addObject("pageName", "sndb01020") // View(jsp)에서 사용할 id 뒤에 붙일 suffix + .addObject("infoPrefix", "wrngTrgt") // prefix + .addObject("callPurpose", req.getCallPurpose()) // 호출 용도 + .addObject("mainQuery", toJson(req)) // 검색 조건 + .addObject("wrngTrgtList", toJson(mav.getModel().get("wrngTrgt"))) // ; } @@ -254,6 +256,7 @@ public class Sndb01Controller extends ApplicationController { * } */ public ModelAndView createWarningSendingList(SndbQuery req, Sndng sndng) { + // boolean saved = false; String rtnMsg = "[F] "; @@ -274,6 +277,7 @@ public class Sndb01Controller extends ApplicationController { * @return /sndb/sndb01/030-main */ public ModelAndView warningSendingMain() { + // ModelAndView mav = new ModelAndView("fims/sndb/sndb01030-main"); // 사용자 정보 @@ -303,6 +307,7 @@ public class Sndb01Controller extends ApplicationController { * } */ public ModelAndView getWarningSendingList(SndbQuery req) { + // if (!"xls".equals(req.getDownload())) { List result = sndngService.getWrngSndngList(setFetchSize(req)); return setCollectionInfo(new ModelAndView("jsonView"), result, "wrngSndng"); @@ -364,14 +369,18 @@ public class Sndb01Controller extends ApplicationController { */ public ModelAndView getWarningSendingDetailInfo(SndbQuery req) { // - ModelAndView mav = getWarningSendingDetailList(req); + List list = sndngDtlService.getSndngDtlList(req); + + boolean json = jsonResponse(); - mav.setViewName("fims/sndb/sndb01040-info"); + ModelAndView mav = new ModelAndView(json ? "jsonView" : "fims/sndb/sndb01040-info"); return mav .addObject("pageName", "sndb01040") - .addObject("query", toJson(req)) - .addObject("wrngSndngDtlList", toJson(mav.getModel().get("wrngSndngDtlList"))) + .addObject("infoPrefix", "wrngSndng") // prefix + .addObject("callPurpose", req.getCallPurpose()) // 호출 용도 + .addObject("mainQuery", json ? req : toJson(req)) // Query + .addObject("wrngSndngDtl", json ? list : toJson(list)) // 계고장 발송 대상 정보 ; } diff --git a/src/main/resources/sql/mapper/fims/sndb/sndng-mapper.xml b/src/main/resources/sql/mapper/fims/sndb/sndng-mapper.xml index 260a001e..ade32f3f 100644 --- a/src/main/resources/sql/mapper/fims/sndb/sndng-mapper.xml +++ b/src/main/resources/sql/mapper/fims/sndb/sndng-mapper.xml @@ -402,9 +402,9 @@