From c6b9fa1342a9fd568ecee5718096e359440ceeb2 Mon Sep 17 00:00:00 2001 From: leebj Date: Fri, 20 Sep 2024 11:09:54 +0900 Subject: [PATCH] =?UTF-8?q?=ED=81=B4=EB=A6=B0=ED=8C=8C=ED=82=B9=20?= =?UTF-8?q?=EC=9E=90=EB=A3=8C=20=EC=A1=B0=ED=9A=8C=20=EC=BF=BC=EB=A6=AC=20?= =?UTF-8?q?=EC=9D=B4=EB=8F=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/cokr/xit/cp/CleanParkingQuery.java | 55 +++++ .../cokr/xit/cp/dao/CleanParkingMapper.java | 6 +- .../cokr/xit/fims/rent/dao/LsctMapper.java | 10 +- .../xit/fims/rent/service/bean/LsctBean.java | 27 ++- .../sql/mapper/cp/cleanParking-mapper.xml | 198 ++++++++++-------- .../sql/mapper/fims/rent/lsct-mapper.xml | 106 +--------- 6 files changed, 194 insertions(+), 208 deletions(-) diff --git a/src/main/java/cokr/xit/cp/CleanParkingQuery.java b/src/main/java/cokr/xit/cp/CleanParkingQuery.java index 80d8bb31..4a3cd516 100644 --- a/src/main/java/cokr/xit/cp/CleanParkingQuery.java +++ b/src/main/java/cokr/xit/cp/CleanParkingQuery.java @@ -6,4 +6,59 @@ public class CleanParkingQuery extends CmmnQuery { private static final long serialVersionUID = 1L; + private String schEntNm; // 기업 명 + private String schVhrno; // 차량번호 + private String schCrdnYmdFrom; // 단속 일자 시작 + private String schCrdnYmdTo; // 단속 일자 종료 + private String[] omJnos; // 소유주 번호s + private String omJno; // 소유주 번호 + + public String getSchEntNm() { + return ifEmpty(schEntNm, () -> null); + } + + public void setSchEntNm(String schEntNm) { + this.schEntNm = schEntNm; + } + + public String getSchVhrno() { + return ifEmpty(schVhrno, () -> null); + } + + public void setSchVhrno(String schVhrno) { + this.schVhrno = schVhrno; + } + + public String getSchCrdnYmdFrom() { + return ifEmpty(schCrdnYmdFrom, () -> null); + } + + public void setSchCrdnYmdFrom(String schCrdnYmdFrom) { + this.schCrdnYmdFrom = schCrdnYmdFrom; + } + + public String getSchCrdnYmdTo() { + return ifEmpty(schCrdnYmdTo, () -> null); + } + + public void setSchCrdnYmdTo(String schCrdnYmdTo) { + this.schCrdnYmdTo = schCrdnYmdTo; + } + + public String[] getOmJnos() { + return ifEmpty(omJnos, () -> null); + } + + public void setOmJnos(String... omJnos) { + this.omJnos = omJnos; + } + + public String getOmJno() { + return ifEmpty(omJno, () -> null); + } + + public void setOmJno(String omJno) { + this.omJno = omJno; + } + } diff --git a/src/main/java/cokr/xit/cp/dao/CleanParkingMapper.java b/src/main/java/cokr/xit/cp/dao/CleanParkingMapper.java index 6edaafaf..df78113d 100644 --- a/src/main/java/cokr/xit/cp/dao/CleanParkingMapper.java +++ b/src/main/java/cokr/xit/cp/dao/CleanParkingMapper.java @@ -11,6 +11,10 @@ import cokr.xit.foundation.data.DataObject; @Mapper("cleanParkingMapper") public interface CleanParkingMapper extends AbstractMapper { - List selectList(CleanParkingQuery query); + /** + * @param req 클린파킹 대장 조회 조건 + * @return 클린파킹 대장 목록 + */ + List selectMainList(CleanParkingQuery req); } \ No newline at end of file diff --git a/src/main/java/cokr/xit/fims/rent/dao/LsctMapper.java b/src/main/java/cokr/xit/fims/rent/dao/LsctMapper.java index 98446659..1eac1ea3 100644 --- a/src/main/java/cokr/xit/fims/rent/dao/LsctMapper.java +++ b/src/main/java/cokr/xit/fims/rent/dao/LsctMapper.java @@ -4,11 +4,11 @@ import java.util.List; import org.egovframe.rte.psl.dataaccess.mapper.Mapper; -import cokr.xit.foundation.component.AbstractMapper; -import cokr.xit.foundation.data.DataObject; import cokr.xit.fims.crdn.Crdn; import cokr.xit.fims.rent.Lsct; import cokr.xit.fims.rent.RentQuery; +import cokr.xit.foundation.component.AbstractMapper; +import cokr.xit.foundation.data.DataObject; /** 임대차계약 대장 정보 DAO * @@ -23,12 +23,6 @@ import cokr.xit.fims.rent.RentQuery; @Mapper("lsctMapper") public interface LsctMapper extends AbstractMapper { - /** - * @param req 임대차계약 대장 조회 조건 - * @return 임대차계약 대장 목록 - */ - List selectMainList(RentQuery req); - /** * @param req 임대차계약 대장 조회 조건 * @return 임대차계약 대장 목록 diff --git a/src/main/java/cokr/xit/fims/rent/service/bean/LsctBean.java b/src/main/java/cokr/xit/fims/rent/service/bean/LsctBean.java index 5e656883..6ef7c570 100644 --- a/src/main/java/cokr/xit/fims/rent/service/bean/LsctBean.java +++ b/src/main/java/cokr/xit/fims/rent/service/bean/LsctBean.java @@ -10,6 +10,8 @@ import org.springframework.stereotype.Component; import cokr.xit.base.crypto.bean.XitAria; import cokr.xit.base.file.FileInfo; import cokr.xit.base.file.service.bean.FileBean; +import cokr.xit.cp.CleanParkingQuery; +import cokr.xit.cp.dao.CleanParkingMapper; import cokr.xit.fims.crdn.Crdn; import cokr.xit.fims.crdn.service.bean.CrdnBean; import cokr.xit.fims.payer.Payer; @@ -49,6 +51,9 @@ public class LsctBean extends AbstractBean { @Resource(name = "payerBean") private PayerBean payerBean; + @Resource(name = "cleanParkingMapper") + private CleanParkingMapper cleanParkingMapper; + /**지정한 조건에 따라 단속 대장 목록을 조회하여 반환한다. * 통합플랫폼으로 사용하지 안을 경우 렌트 소스만 사용하기 위해서 TB_CRDN, TB_PAYER에 직접 등록한다. * @param req 임대차계약 대장 조회 조건 @@ -74,7 +79,16 @@ public class LsctBean extends AbstractBean { } // 연계 View 테이블 조회 - List mainList = lsctMapper.selectMainList(req); + CleanParkingQuery cpQuery = new CleanParkingQuery(); + cpQuery.setSggCd(req.getSggCd()); + cpQuery.setTaskSeCd(req.getTaskSeCd()); + cpQuery.setSchCrdnYmdFrom(req.getSchCrdnYmdFrom()); + cpQuery.setSchCrdnYmdTo(req.getSchCrdnYmdTo()); + cpQuery.setSchVhrno(req.getSchVhrno()); + cpQuery.setOmJnos(req.getOmJnos()); + cpQuery.setOmJno(req.getOmJno()); + cpQuery.setSchEntNm(req.getSchEntNm()); + List mainList = cleanParkingMapper.selectMainList(cpQuery); if (mainList.size() > 0) { for (int iLoop = 0; iLoop < mainList.size(); iLoop++) { @@ -271,7 +285,16 @@ public class LsctBean extends AbstractBean { } // 연계 View 테이블 조회 - List mainList = lsctMapper.selectMainList(req); + CleanParkingQuery cpQuery = new CleanParkingQuery(); + cpQuery.setSggCd(req.getSggCd()); + cpQuery.setTaskSeCd(req.getTaskSeCd()); + cpQuery.setSchCrdnYmdFrom(req.getSchCrdnYmdFrom()); + cpQuery.setSchCrdnYmdTo(req.getSchCrdnYmdTo()); + cpQuery.setSchVhrno(req.getSchVhrno()); + cpQuery.setOmJnos(req.getOmJnos()); + cpQuery.setOmJno(req.getOmJno()); + cpQuery.setSchEntNm(req.getSchEntNm()); + List mainList = cleanParkingMapper.selectMainList(cpQuery); if (mainList.size() > 0) { for (int iLoop = 0; iLoop < mainList.size(); iLoop++) { diff --git a/src/main/resources/sql/mapper/cp/cleanParking-mapper.xml b/src/main/resources/sql/mapper/cp/cleanParking-mapper.xml index ffc6857d..f391b3f6 100644 --- a/src/main/resources/sql/mapper/cp/cleanParking-mapper.xml +++ b/src/main/resources/sql/mapper/cp/cleanParking-mapper.xml @@ -2,96 +2,110 @@ - - + + \ No newline at end of file diff --git a/src/main/resources/sql/mapper/fims/rent/lsct-mapper.xml b/src/main/resources/sql/mapper/fims/rent/lsct-mapper.xml index 77411662..40bbad0a 100644 --- a/src/main/resources/sql/mapper/fims/rent/lsct-mapper.xml +++ b/src/main/resources/sql/mapper/fims/rent/lsct-mapper.xml @@ -42,111 +42,7 @@ - +