변경
This commit is contained in:
parent
7a38574459
commit
15df969634
@ -114,6 +114,11 @@ public class LoginVO implements Serializable{
|
||||
|
||||
private String dormantYn; // 휴먼회원여부 ( N:일반회원, Y:휴먼회원)
|
||||
|
||||
/**
|
||||
* 보안로그인 여부
|
||||
*/
|
||||
private String secuLoginFlag;
|
||||
|
||||
public String getDormantYn() {
|
||||
return dormantYn;
|
||||
}
|
||||
@ -411,5 +416,12 @@ public class LoginVO implements Serializable{
|
||||
public void setOuterCertYn(String outerCertYn) {
|
||||
this.outerCertYn = outerCertYn;
|
||||
}
|
||||
public String getSecuLoginFlag() {
|
||||
return secuLoginFlag;
|
||||
}
|
||||
public void setSecuLoginFlag(String secuLoginFlag) {
|
||||
this.secuLoginFlag = secuLoginFlag;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@ -604,6 +604,10 @@ public class EgovMberManageServiceImpl extends EgovAbstractServiceImpl implement
|
||||
|
||||
return resultCnt;
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public void updateSecureLoginFlag(MberManageVO mberManageVO) throws Exception {
|
||||
mberManageDAO.updateSecureLoginFlag(mberManageVO);
|
||||
}
|
||||
|
||||
}
|
||||
@ -333,4 +333,8 @@ public class MberManageDAO extends EgovComAbstractDAO{
|
||||
return resultCnt;
|
||||
}
|
||||
|
||||
public void updateSecureLoginFlag(MberManageVO mberManageVO) throws Exception {
|
||||
update("mberManageDAO.updateSecureLoginFlag",mberManageVO);
|
||||
}
|
||||
|
||||
}
|
||||
@ -16,9 +16,12 @@ import javax.annotation.Resource;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import org.springframework.http.HttpStatus;
|
||||
import org.springframework.http.ResponseEntity;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.ModelAttribute;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
@ -3003,18 +3006,22 @@ public class EgovMypageController {
|
||||
|
||||
//kmc 본인인증 실/개발 서버 구분
|
||||
String serverNm = "";
|
||||
if(request.getServerName().contains("192.168.0.60") || request.getServerName().contains("localhost")) {
|
||||
serverNm = request.getScheme() + "://192.168.0.60:8085";
|
||||
}else{
|
||||
serverNm = request.getScheme() + "://www.munjaon.co.kr";
|
||||
}
|
||||
// if(request.getServerName().contains("192.168.0.60") || request.getServerName().contains("localhost")) {
|
||||
// serverNm = request.getScheme() + "://192.168.0.60:8085";
|
||||
// }else{
|
||||
// serverNm = request.getScheme() + "://www.munjaon.co.kr";
|
||||
// }
|
||||
serverNm = request.getScheme() + "://munjaon.co.kr";
|
||||
|
||||
AuthCertVO certVO = kmcCertCheck.authCertCheckNine(serverNm + "/web/user/selectSecurityAuthn.do", loginVO.getId());
|
||||
model.addAttribute("certVO", certVO);
|
||||
}
|
||||
|
||||
MberManageVO mberManageVO = new MberManageVO();
|
||||
mberManageVO.setMberId(loginVO.getId());
|
||||
|
||||
model.addAttribute("mberManageVO", userManageService.selectUserInfo(mberManageVO));
|
||||
|
||||
|
||||
model.addAttribute("pageTab", "mberSecureLogin");
|
||||
return "web/user/mberSecureLogin";
|
||||
}
|
||||
@ -3833,7 +3840,7 @@ public class EgovMypageController {
|
||||
certVO.setCertNation(kmcVO.getNation());
|
||||
certVO.setCertName(kmcVO.getName());
|
||||
certVO.setCertResult(kmcVO.getResult());
|
||||
certVO.setCertType("dddddddddddddddddddddd");
|
||||
certVO.setCertType("secureLoginOFF");
|
||||
certVO.setCertIpaddr(kmcVO.getIp());
|
||||
certVO.setBirthDay(kmcVO.getBirthDay());
|
||||
certVO.setSexdstnCode(kmcVO.getGender());
|
||||
@ -3848,4 +3855,32 @@ public class EgovMypageController {
|
||||
return "web/user/securityAuthnPage";
|
||||
}
|
||||
|
||||
@RequestMapping(value="/web/user/mberSecureLoginAjax.do")
|
||||
public ResponseEntity<?> mberSecureLoginAjax(MberManageVO mberManageVO, @RequestBody Map<String, String> params){
|
||||
LoginVO loginVO = EgovUserDetailsHelper.isAuthenticated()? (LoginVO)EgovUserDetailsHelper.getAuthenticatedUser():null;
|
||||
String userId = loginVO == null ? "" : EgovStringUtil.isNullToString(loginVO.getId());
|
||||
|
||||
if("Y".equals(params.get("secuLoginFlag"))) {
|
||||
mberManageVO.setSecuLoginFlag("N");
|
||||
}else {
|
||||
mberManageVO.setSecuLoginFlag("Y");
|
||||
}
|
||||
mberManageVO.setMberId(userId);
|
||||
mberManageVO.setLastUpdusrId(userId);
|
||||
|
||||
try {
|
||||
mberManageService.updateSecureLoginFlag(mberManageVO);
|
||||
|
||||
return new ResponseEntity<>("success", HttpStatus.OK);
|
||||
} catch (Exception e) {
|
||||
System.out.println("mberSecureLoginAjax Error!!!!!!!!!!!!!!!!!!!!");
|
||||
System.out.println("mberSecureLoginAjax Error!!!!!!!!!!!!!!!!!!!!");
|
||||
System.out.println("mberSecureLoginAjax Error!!!!!!!!!!!!!!!!!!!!");
|
||||
System.out.println("mberSecureLoginAjax Error!!!!!!!!!!!!!!!!!!!!");
|
||||
System.out.println("mberSecureLoginAjax Error!!!!!!!!!!!!!!!!!!!!");
|
||||
|
||||
return new ResponseEntity<>("fail", HttpStatus.OK);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -243,4 +243,6 @@ public interface EgovMberManageService {
|
||||
|
||||
//기업회원 기업정보 변경신청 취소 처리
|
||||
public int updateCmpUserInfoCancel(MberManageVO mberManageVO) throws Exception;
|
||||
|
||||
public void updateSecureLoginFlag(MberManageVO mberManageVO) throws Exception;
|
||||
}
|
||||
@ -504,6 +504,12 @@ public class MberManageVO extends UserDefaultVO{
|
||||
private String dormantDate;
|
||||
private String spamYn;
|
||||
|
||||
|
||||
/**
|
||||
* 보안로그인 여부
|
||||
*/
|
||||
private String secuLoginFlag;
|
||||
|
||||
public String getSpamYn() {
|
||||
return spamYn;
|
||||
}
|
||||
@ -1784,5 +1790,12 @@ public class MberManageVO extends UserDefaultVO{
|
||||
public void setHotlineAgentCode(String hotlineAgentCode) {
|
||||
this.hotlineAgentCode = hotlineAgentCode;
|
||||
}
|
||||
public String getSecuLoginFlag() {
|
||||
return secuLoginFlag;
|
||||
}
|
||||
public void setSecuLoginFlag(String secuLoginFlag) {
|
||||
this.secuLoginFlag = secuLoginFlag;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
@ -1223,6 +1223,13 @@ public class MainController {
|
||||
|
||||
model.addAttribute("userCandidateYn", userCandidateYn);
|
||||
|
||||
if(loginVO != null) {
|
||||
MberManageVO mberManageVO = new MberManageVO();
|
||||
mberManageVO.setMberId(loginVO.getId());
|
||||
|
||||
model.addAttribute("mberManageVO", userManageService.selectUserInfo(mberManageVO));
|
||||
}
|
||||
|
||||
return "web/com/webCommonHeader";
|
||||
}
|
||||
|
||||
|
||||
@ -2106,4 +2106,13 @@
|
||||
WHERE CMPHST_ID = #cmpHstId#
|
||||
|
||||
</update>
|
||||
|
||||
<update id="mberManageDAO.updateSecureLoginFlag" parameterClass="mberVO">
|
||||
|
||||
UPDATE LETTNGNRLMBER SET
|
||||
SECU_LOGIN_FLAG = #secuLoginFlag#
|
||||
,LAST_UPDUSR_ID = #lastUpdusrId#
|
||||
WHERE MBER_ID = #mberId#
|
||||
|
||||
</update>
|
||||
</sqlMap>
|
||||
|
||||
@ -1206,6 +1206,7 @@
|
||||
|
||||
, A.EMAIL_YN AS emailYN
|
||||
, A.SMS_YN AS smsYN
|
||||
, A.SECU_LOGIN_FLAG AS secuLoginFlag
|
||||
|
||||
FROM
|
||||
LETTNGNRLMBER A
|
||||
|
||||
@ -109,6 +109,14 @@ $(document).ready(function (){
|
||||
|
||||
//등급제 시행 ON/OFF 체크(비로그인)
|
||||
//getMberSettingDetailByNotLogin_Header();
|
||||
|
||||
var secuLoginFlag = '${mberManageVO.secuLoginFlag}';
|
||||
|
||||
if (secuLoginFlag === 'Y') {
|
||||
$('#secuLoginFlag').attr('class', 'state on').text('ON');
|
||||
} else if (secuLoginFlag === 'N') {
|
||||
$('#secuLoginFlag').attr('class', 'state off').text('OFF');
|
||||
}
|
||||
});
|
||||
|
||||
//등급제 시행 ON/OFF 체크(비로그인)
|
||||
@ -1647,7 +1655,7 @@ function actionLogin() {
|
||||
<button type="button" class="btnType btnType2" onclick="location.href='/web/uat/uia/actionLogout.do'">로그아웃</button>
|
||||
<div class="security_box">
|
||||
<p class="title"><i class="icon_lock"></i>보안로그인</p>
|
||||
<a href="#" class="state on">ON</a>
|
||||
<a href="#" id="secuLoginFlag" class="state"> </a>
|
||||
<!-- <a href="#" class="state off">OFF</a> -->
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@ -36,17 +36,27 @@ $(document).ready(function(){
|
||||
} else {}
|
||||
});
|
||||
|
||||
|
||||
// secuLoginFlag 값에 따라 해당하는 탭에 'on' 클래스 추가
|
||||
if ('${mberManageVO.secuLoginFlag}' === 'Y') {
|
||||
$('.security_tab a').filter(function() {
|
||||
return $(this).text() === 'ON';
|
||||
}).addClass('on');
|
||||
} else {
|
||||
$('.security_tab a').filter(function() {
|
||||
return $(this).text() === 'OFF';
|
||||
}).addClass('on');
|
||||
}
|
||||
// on/off 시 confirm 창 노출
|
||||
$('.security_tab a').click(function (e) {
|
||||
|
||||
|
||||
console.log($(this).hasClass("on"))
|
||||
if ($(this).hasClass("on") == false) {
|
||||
if ($(this).text().trim() == "ON") {
|
||||
if (!confirm("보안로그인 설정 후 로그인 시, 등록한 휴대폰번호로 추가 인증이 진행됩니다")) {
|
||||
$(this).removeClass("on");
|
||||
$(this).siblings("a").addClass("on");
|
||||
} else {
|
||||
callTo();
|
||||
$(this).addClass("on");
|
||||
$(this).siblings("a").removeClass("on");
|
||||
}
|
||||
@ -55,8 +65,8 @@ $(document).ready(function(){
|
||||
$(this).removeClass("on");
|
||||
$(this).siblings("a").addClass("on");
|
||||
} else {
|
||||
$(this).addClass("on");
|
||||
$(this).siblings("a").removeClass("on");
|
||||
// $(this).addClass("on");
|
||||
// $(this).siblings("a").removeClass("on");
|
||||
openKMCISWindow();
|
||||
}
|
||||
}
|
||||
@ -539,7 +549,27 @@ function openKMCISWindow(){
|
||||
|
||||
//자식창에서 호출
|
||||
function callTo() {
|
||||
alert("호출입니다.");
|
||||
$.ajax({
|
||||
url: '/web/user/mberSecureLoginAjax.do',
|
||||
type: 'POST',
|
||||
contentType: 'application/json',
|
||||
data: JSON.stringify({
|
||||
secuLoginFlag: '${mberManageVO.secuLoginFlag}'
|
||||
}),
|
||||
success: function(response) {
|
||||
if(response === 'success'){
|
||||
alert('변경이 완료되었습니다.');
|
||||
location.reload();
|
||||
}else{
|
||||
alert('변경에 실패했습니다. 다시 시도해 주세요.');
|
||||
location.reload();
|
||||
}
|
||||
|
||||
},
|
||||
error: function(error) {
|
||||
alert("error");
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function linkPage(pageNo){
|
||||
@ -551,7 +581,11 @@ function linkPage(pageNo){
|
||||
//휴대푠 번호 등록 [끝]--------------------------------------------------------------------------------------------
|
||||
|
||||
</script>
|
||||
|
||||
<form name="reqKMCISForm" method="post" action="#">
|
||||
<input type="hidden" id="tr_url" name="tr_url" value = "${certVO.tr_url}">
|
||||
<input type="hidden" id="tr_add" name="tr_add" value = "${certVO.tr_add}">
|
||||
<input type="hidden" id="tr_cert" name="tr_cert" value = "${certVO.tr_cert}">
|
||||
</form>
|
||||
<form name="listForm" action="<c:url value='/web/user/mberSecureLogin.do'/>" method="post">
|
||||
<input name="pageIndex" type="hidden" value="<c:out value='${mberCertLoginLogVO.pageIndex}'/>"/>
|
||||
</form>
|
||||
@ -641,7 +675,7 @@ function linkPage(pageNo){
|
||||
<p class="lately_date">최근 변경일시 : <span>2024-11-01 12:49</span></p>
|
||||
|
||||
<div class="tab_depth1 security_tab">
|
||||
<a href="#none" class="on">ON</a>
|
||||
<a href="#none">ON</a>
|
||||
<a href="#none">OFF</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user