From be5ffb7494d4d82aefd6a5f4c51f8ccb37eb9cb2 Mon Sep 17 00:00:00 2001 From: leebeomjun Date: Tue, 11 Jul 2023 13:50:04 +0900 Subject: [PATCH] =?UTF-8?q?=EB=8B=A8=EC=86=8D=EC=9E=90=EB=A3=8C=20?= =?UTF-8?q?=EC=88=98=EA=B8=B0=20=EB=93=B1=EB=A1=9D=20=ED=99=94=EB=A9=B4=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 --- .../sql/mapper/fims/crdn/crdn05-mapper.xml | 13 +++++--- .../WEB-INF/jsp/fims/crdn/crdn05030-info.jsp | 32 ++++++++++++++++--- 2 files changed, 36 insertions(+), 9 deletions(-) diff --git a/src/main/resources/sql/mapper/fims/crdn/crdn05-mapper.xml b/src/main/resources/sql/mapper/fims/crdn/crdn05-mapper.xml index 5ff189c2..25e23a59 100644 --- a/src/main/resources/sql/mapper/fims/crdn/crdn05-mapper.xml +++ b/src/main/resources/sql/mapper/fims/crdn/crdn05-mapper.xml @@ -80,7 +80,7 @@ INSERT INTO TB_CRDN ( , LINK_TBL_NM ) VALUES ( #{crdn.crdnId} - , #{crdn.sggCd} + , (SELECT SGG_CD FROM TB_SGG_INFO WHERE INST_CD = #{currentUser.institute}) , #{crdn.crdnRegSeCd} , #{crdn.crdnInptSeCd} , #{crdn.linkId} @@ -94,10 +94,13 @@ INSERT INTO TB_CRDN ( , #{crdn.crdnPlc} , #{crdn.dtlCrdnPlc} , #{crdn.teamId} - , (SELECT VLTN_ID FROM TB_VLTN_INFO - WHERE SGG_CD = '41480' - AND TASK_SE_CD = #{crdn.taskSeCd} - AND VLTN_CD = #{crdn.vltnCd}) + , (SELECT B.VLTN_ID + FROM TB_SGG_INFO A + INNER JOIN TB_VLTN_INFO B + WHERE A.SGG_CD = B.SGG_CD + AND A.INST_CD = #{currentUser.institute} + AND B.TASK_SE_CD = #{crdn.taskSeCd} + AND B.VLTN_CD = #{crdn.vltnCd}) , #{crdn.crdnSpareaCd} , #{crdn.crdnBgngTm} , #{crdn.crdnEndHr} diff --git a/src/main/webapp/WEB-INF/jsp/fims/crdn/crdn05030-info.jsp b/src/main/webapp/WEB-INF/jsp/fims/crdn/crdn05030-info.jsp index b3bc076c..c7d14441 100644 --- a/src/main/webapp/WEB-INF/jsp/fims/crdn/crdn05030-info.jsp +++ b/src/main/webapp/WEB-INF/jsp/fims/crdn/crdn05030-info.jsp @@ -13,7 +13,7 @@ 위반일자 + class="form-control form-date" data-fmt-type="day" maxlength="10" required />
@@ -155,7 +155,7 @@
-
+
@@ -246,9 +246,33 @@ $(document).ready(function(){ /************************************************************************** * 초기화 **************************************************************************/ - //달력 초기화 - initDatepicker("frmEdit--${pageName}"); + initDatepicker("frmEdit--${pageName}"); //달력 초기화 + $("#frmEdit--${pageName}").find(".form-date").each(function(){ + $(this).on("input",function(){ + var value = this.value.replaceAll("-",""); + + if(value.length > 7){ + this.value = value.substring(0,4)+"-"+value.substring(4,6)+"-"+value.substring(6); + } else if(value.length > 5){ + this.value = value.substring(0,4)+"-"+value.substring(4); + } + + }); + }); + $("#frmEdit--${pageName}").find(".form-time").each(function(){ + $(this).on("input",function(){ + var value = this.value.replaceAll(":",""); + + if(value.length > 5){ + this.value = value.substring(0,2)+":"+value.substring(2,4)+":"+value.substring(4); + } else if(value.length > 3){ + this.value = value.substring(0,2)+":"+value.substring(2); + } + + }); + }); + //보안모드 fn_securityModeToggle($("#securityMode--top").is(":checked"));