260422_05_ENH: 로그인 시 최초 1회만 휴대전화 인증을 하도록 수정
This commit is contained in:
@@ -18,33 +18,33 @@ case "login"
|
||||
Dim r_id : r_id = Request("r_id")
|
||||
Dim r_pw : r_pw = Request("r_pw")
|
||||
|
||||
Session("name") = ""
|
||||
Session("phone") = ""
|
||||
Session("r_phone") = ""
|
||||
Session("position") = ""
|
||||
|
||||
DBConnect()
|
||||
|
||||
SQL = ""
|
||||
SQL = SQL&" select r_name, dbo.base64_decode(r_phone) phone, r_phone, r_position, "&VbCrlf
|
||||
SQL = SQL&" Flag from exitpoll.dbo.R_info "&VbCrlf
|
||||
SQL = SQL&" select r_name, dbo.base64_decode(r_phone) phone, r_phone, r_position, Flag, chk as mobile_check "&VbCrlf
|
||||
SQL = SQL&" from exitpoll.dbo.R_info "&VbCrlf
|
||||
SQL = SQL&" where r_name = '"&r_id&"' and dbo.base64_decode(r_pass) = '"&r_pw&"' "&VbCrlf
|
||||
|
||||
Objdb.Open SQL,DBConn,3,1,1
|
||||
if not Objdb.eof Then
|
||||
If objdb("Flag") = "1" Then
|
||||
IF objdb("mobile_check") = "0" Then
|
||||
Response.write "NotMobileCheck"
|
||||
|
||||
ElseIf objdb("Flag") = "1" Then
|
||||
Session("name") = objdb("r_name")
|
||||
Session("phone") = objdb("phone")
|
||||
Session("r_phone") = objdb("r_phone")
|
||||
Session("position") = objdb("r_position")
|
||||
Response.Write "True"
|
||||
Else
|
||||
Session("name") = ""
|
||||
Session("phone") = ""
|
||||
Session("r_phone") = ""
|
||||
Session("position") = ""
|
||||
Response.write "X"
|
||||
End If
|
||||
Else
|
||||
Session("name") = ""
|
||||
Session("phone") = ""
|
||||
Session("r_phone") = ""
|
||||
Session("position") = ""
|
||||
Response.Write "False"
|
||||
End If
|
||||
|
||||
|
||||
@@ -158,23 +158,23 @@
|
||||
success: function (res) {
|
||||
if (res === "nouser") {
|
||||
alert("<22><EFBFBD><DEB4><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><>ġ<EFBFBD><C4A1><EFBFBD><EFBFBD> <20>ʴ<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>Դϴ<D4B4>.\n<>ٽ<EFBFBD> <20>Է<EFBFBD><D4B7><EFBFBD><EFBFBD>ּ<EFBFBD><D6BC><EFBFBD>.");
|
||||
window.open("about:blank", "_self").close();
|
||||
} else if (res === "complete") {
|
||||
/*
|
||||
if (window.opener && !window.opener.closed) {
|
||||
window.opener.document.getElementById("mobileVerified").value = "Y";
|
||||
window.opener.document.getElementById("LoginOk").disabled = false;
|
||||
}
|
||||
*/
|
||||
alert("<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>Ϸ<EFBFBD><CFB7>Ǿ<EFBFBD><C7BE><EFBFBD><EFBFBD>ϴ<EFBFBD>.");
|
||||
window.open("about:blank", "_self").close();
|
||||
$("#LoginOk", opener.document).click();
|
||||
} else {
|
||||
alert("System Error\n<><6E><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>");
|
||||
window.open("about:blank", "_self").close();
|
||||
}
|
||||
},
|
||||
error: function () {
|
||||
alert("System Error\n<><6E><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>");
|
||||
window.open("about:blank", "_self").close();
|
||||
}
|
||||
//window.open("about:blank", "_self").close();
|
||||
});
|
||||
<% Else %>
|
||||
// source<63><65> signup <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
|
||||
@@ -45,11 +45,11 @@
|
||||
<label>비밀번호</label>
|
||||
<input type="password" class="form-control" name="r_pw" id="r_pw" value="" inputmode="text" placeholder="핸드폰번호(11자리)">
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<div class="form-group" style="display:none">
|
||||
<label>모바일 인증</label>
|
||||
<button type="button" class="form-control btn btn-warning" name="mobile_chk" id="mobile_chk">휴대폰 본인인증</button>
|
||||
</div>
|
||||
<input type="hidden" id="mobileVerified" value="N">
|
||||
<!--<input type="hidden" id="mobileVerified" value="N">-->
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-warning" id="LoginOk">로그인</button>
|
||||
|
||||
@@ -27,9 +27,10 @@
|
||||
$("#LoginOk").on("click",function(){
|
||||
var r_id = $("#r_id").val();
|
||||
var r_pw = $("#r_pw").val();
|
||||
const verified = document.getElementById("mobileVerified").value;
|
||||
//const verified = document.getElementById("mobileVerified").value;
|
||||
|
||||
if (r_id == "" || r_pw == "" || verified !== "Y"){
|
||||
//if (r_id == "" || r_pw == "" || verified !== "Y"){
|
||||
if (r_id == "" || r_pw == ""){
|
||||
if (r_id == ""){
|
||||
alert("[이름]을 입력하여 주십시오.");
|
||||
return false;
|
||||
@@ -38,10 +39,12 @@
|
||||
alert("[핸드폰 번호]를 입력하여 주십시오.");
|
||||
return false;
|
||||
}
|
||||
/*
|
||||
if (verified !== "Y") {
|
||||
alert("[휴대폰 본인인증]을 먼저 완료해주세요.");
|
||||
return false;
|
||||
}
|
||||
*/
|
||||
} else {
|
||||
$.ajax({
|
||||
url:"../Ajax/AjaxSelect.asp",
|
||||
@@ -51,10 +54,12 @@
|
||||
if(res == "False"){
|
||||
alert("등록된 정보가 없습니다.");
|
||||
return false
|
||||
}else{
|
||||
if(res == "ban"){
|
||||
|
||||
}else if(res == "X"){
|
||||
} else if(res == "NotMobileCheck") {
|
||||
alert("휴대폰 본인인증이 되지 않은 지원자 입니다.\n본인인증을 진행합니다.");
|
||||
$("#mobile_chk").click();
|
||||
return false;
|
||||
} else {
|
||||
if(res == "X"){
|
||||
alert("현재 대상자 아님으로 변경되었습니다.\n지원 해주셔서 감사합니다.");
|
||||
}else{
|
||||
alert("안녕하세요? :)");
|
||||
|
||||
Reference in New Issue
Block a user