diff --git a/src/main/resources/application.yml b/src/main/resources/application.yml index 346381d..40a6f96 100644 --- a/src/main/resources/application.yml +++ b/src/main/resources/application.yml @@ -49,6 +49,8 @@ propertyService: - pageSize: 10 # 테스트를 위해 permitAccess 설정 - permitAccess: /intf/**/* + - defaultPassword: 0 + # extFileName: # - encoding: UTF-8 # filename: classpath*:properties/your-file-01.properties @@ -76,6 +78,7 @@ spring: propertyService: properties: - tempDir: C:\temppp + - defaultPassword: 0 app: api: @@ -105,6 +108,7 @@ server: propertyService: properties: - tempDir: C:\temp + - defaultPassword: 0 app: api: diff --git a/src/main/resources/sql/mapper/base/user-mapper.xml b/src/main/resources/sql/mapper/base/user-mapper.xml index e111209..a94c2f1 100644 --- a/src/main/resources/sql/mapper/base/user-mapper.xml +++ b/src/main/resources/sql/mapper/base/user-mapper.xml @@ -85,12 +85,12 @@ SELECT USER_ID +AND USER_ID = #{userID} +AND USER_ACNT = #{account} + AND NSTT_CD = #{institute} - +/* 사용자 정보 등록(userMapper.insertUser) */ SELECT LPAD(NVL(MAX(USER_ID) + 1, 1), 10, '0') NEW_ID FROM TB_USER -/* 사용자 정보 등록(userMapper.insertUser) */ INSERT INTO TB_USER ( USER_ID , USER_ACNT @@ -187,8 +187,8 @@ UPDATE TB_USER SET WHERE USER_ID = #{id} /* 비밀번호 변경(userMapper.changePassword) */ -UPDATE TB_USER SET - PASSWD = CASE USER_ID +UPDATE TB_USER + SET PASSWD = CASE USER_ID WHEN #{userPassword.userID} THEN #{userPassword.password} ELSE PASSWD END , MDFCN_DT = diff --git a/src/main/webapp/WEB-INF/jsp/base/user/password.jsp b/src/main/webapp/WEB-INF/jsp/base/user/password.jsp new file mode 100644 index 0000000..fbcaf93 --- /dev/null +++ b/src/main/webapp/WEB-INF/jsp/base/user/password.jsp @@ -0,0 +1,80 @@ +<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" isELIgnored="false" session="false"%> +<%@ include file="/WEB-INF/jsp/include/taglib.jsp"%> +
+
+
+
+ +
+
+
+
+
+ +
+
+
+
+
+ +
+
+
+
+
+ \ No newline at end of file diff --git a/src/main/webapp/WEB-INF/jsp/base/user/user-info.jsp b/src/main/webapp/WEB-INF/jsp/base/user/user-info.jsp index 5fa5094..c916ebc 100644 --- a/src/main/webapp/WEB-INF/jsp/base/user/user-info.jsp +++ b/src/main/webapp/WEB-INF/jsp/base/user/user-info.jsp @@ -142,8 +142,9 @@
-
+
+
@@ -207,5 +208,31 @@ function saveinfoPrefix() { } }); } + +function _initPassword() { + let resp = userControl.changePassword({ + userIDs: userControl.getCurrent().USER_ID, + init: true + }); + if (resp.saved) + dialog.alert("비밀번호가 초기화됐습니다."); +} + +async function initPassword() { + dialog.alert({ + title: "비밀번호 초기화", + content: "비밀번호를 초기화하시겠습니까?", + onOK: () => { + userControl.changePassword({ + userIDs: userControl.getCurrent().USER_ID, + init: true + }) + .then(resp => { + if (resp.saved) + dialog.alert("비밀번호가 초기화됐습니다."); + }); + } + }); +} //# sourceURL=user-info.jsp \ No newline at end of file diff --git a/src/main/webapp/WEB-INF/jsp/include/tail.jsp b/src/main/webapp/WEB-INF/jsp/include/tail.jsp index 43a0348..2a4c20c 100644 --- a/src/main/webapp/WEB-INF/jsp/include/tail.jsp +++ b/src/main/webapp/WEB-INF/jsp/include/tail.jsp @@ -61,15 +61,19 @@ wctx.csrf = { dialog.title = "마약류폐기지원시스템"; -function logout() { - dialog.alert({ - content:"로그아웃 하시겠습니까?", - onOK:function(){ +function logout(prompt) { + let func = () => { var form = $("
\", method=\"POST\">"); $("").appendTo(form); form.appendTo("body").submit(); - } - }); + }; + if (prompt !== false) + dialog.alert({ + content: "로그아웃 하시겠습니까?", + onOK: func + }); + else + func(); } @@ -92,5 +96,5 @@ async function selectURL(multiple) { }); } - -${functions} +${functions} + \ No newline at end of file diff --git a/src/main/webapp/WEB-INF/jsp/include/top.jsp b/src/main/webapp/WEB-INF/jsp/include/top.jsp index 10d1cf2..93374b8 100644 --- a/src/main/webapp/WEB-INF/jsp/include/top.jsp +++ b/src/main/webapp/WEB-INF/jsp/include/top.jsp @@ -37,14 +37,11 @@
  • -
  • diff --git a/src/main/webapp/WEB-INF/jsp/index.jsp b/src/main/webapp/WEB-INF/jsp/index.jsp index 8e86745..571d983 100644 --- a/src/main/webapp/WEB-INF/jsp/index.jsp +++ b/src/main/webapp/WEB-INF/jsp/index.jsp @@ -146,6 +146,7 @@ $(".sticky-element").sticky({ $(function() { ${onload} mainTabs.open(FIRST_PAGE); + currentUserControl.changePassword(); }); //# sourceURL=index.jsp