File name
Commit message
Commit date
File name
Commit message
Commit date
File name
Commit message
Commit date
File name
Commit message
Commit date
File name
Commit message
Commit date
File name
Commit message
Commit date
File name
Commit message
Commit date
<%--
Class Name : EgovUserSelectUpdt.jsp
Description : 사용자상세조회, 수정 JSP
Modification Information
수정일 수정자 수정내용
------- -------- ---------------------------
2009.03.03 JJY 최초 생성
2011.08.31 JJY 경량환경 버전 생성
author : 공통서비스 개발팀 JJY
since : 2009.03.03
--%>
<%@ page contentType="text/html; charset=utf-8" pageEncoding="utf-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="ui" uri="http://egovframework.gov/ctl/ui"%>
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %>
<%@ taglib prefix="spring" uri="http://www.springframework.org/tags"%>
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %>
<%@ taglib prefix="validator" uri="http://www.springmodules.org/tags/commons-validator" %>
<%@ taglib prefix="double-submit" uri="http://www.egovframe.go.kr/tags/double-submit/jsp" %>
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Language" content="ko" >
<title>관리자 수정</title>
<script type="text/javascript" src="<c:url value="/validator.do"/>"></script>
<validator:javascript formName="userManageVO" staticJavascript="false" xhtml="true" cdata="false"/>
<script type="text/javascript" src="<c:url value='/js/EgovCmmUtl.js'/>" ></script>
<!-- 암화화 순서에 유의 -->
<script type="text/javascript" src="/js/RSA/rsa.js"></script>
<script type="text/javascript" src="/js/RSA/jsbn.js"></script>
<script type="text/javascript" src="/js/RSA/prng4.js"></script>
<script type="text/javascript" src="/js/RSA/rng.js"></script>
<script src="/direct/js/jquery.nice-select.min.js"></script>
<link rel="stylesheet" href="/direct/css/nice-select.css">
<script type="text/javaScript" language="javascript" defer="defer">
$( document ).ready(function(){
$('select').not(".displayN").niceSelect();
if($("#authorCode").val() != "ROLE_CS"){
$("#emailSandTr").hide();
$("#smsSandTr").hide();
}
$("#authorCode").change(function(){
if(this.value == "ROLE_CS"){
$("#emailSandTr").show();
$("#smsSandTr").show();
}else{
$("#emailSandTr").hide();
$("#smsSandTr").hide();
}
});
});
{
var killBackSpace = function(e) { e = e ? e : window.event; var t = e.target ? e.target : e.srcElement ? e.srcElement : null; if(t && t.tagName && (t.type && /(password)|(text)|(file)/.test(t.type.toLowerCase())) || t.tagName.toLowerCase() == 'textarea') { return true; } var k = e.keyCode ? e.keyCode : e.which ? e.which : null; if(k == 8) { if(e.preventDefault) { e.preventDefault(); } return false; } return true; }; if(typeof document.addEventListener != 'undefined') { document.addEventListener('keydown', killBackSpace, false); }else if(typeof document.attachEvent != 'undefined') { document.attachEvent('onkeydown', killBackSpace); }else { if(document.onkeydown != null) { var oldOnkeydown = document.onkeydown; document.onkeydown = function(e) { oldOnkeydown(e); killBackSpace(e); }; }else { document.onkeydown = killBackSpace; } }
}
{
history.pushState(null , null, location.href);
}
function fnListPage(){
document.searchForm.action = "<c:url value='/uss/umt/user/EgovUserManage.do'/>";
document.searchForm.submit();
}
function fnDeleteUser(checkedIds) {
if(confirm("<spring:message code="common.delete.msg" />")){
document.userManageVO.checkedIdForDel.value=checkedIds;
document.userManageVO.action = "<c:url value='/uss/umt/user/EgovUserDelete.do'/>";
document.userManageVO.submit();
}
}
function fnPasswordMove(){
document.modiForm.action = "<c:url value='/uss/umt/user/EgovUserPasswordUpdtView.do'/>";
document.modiForm.submit();
}
function fnUpdate(){
if(!nCheck()){
return;
}
var email = document.getElementById("emailAdres").value;
if(email != ''){
//var exptext = /^[A-Za-z0-9_\.\-]+@[A-Za-z0-9\-]+\.[A-Za-z0-9\-]+/;
var exptext = /^[0-9a-zA-Z]([-_.]?[0-9a-zA-Z])*@[0-9a-zA-Z]([-_.]?[0-9a-zA-Z])*.[a-zA-Z]{2,3}$/i;
if(exptext.test(email)==false){
alert("이메일주소 형식이 올바르지 않습니다.");
return;
}
}
if(!validateUserManageVO(document.userManageVO)){
return;
}else{
if($("#passwdCmp").val() == ""){
alert("수정하시려면 비밀번호 확인란에 비밀번호를 넣어주세요.");
return ;
}
if(!confirm("수정하시겠습니까?")){
return ;
}
<c:if test="${empty isAdmin and empty isMember}">
var rsa = new RSAKey();
rsa.setPublic($('#RSAModulus').val(),$('#RSAExponent').val());
$("#rsaPasswd").val(rsa.encrypt($("#passwdCmp").val()));
</c:if>
document.userManageVO.submit();
}
}
function updateMemberAjax(){
var url = "/uss/umt/user/EgovUserSelectUpdtAjax.do";
var data = new FormData(document.userManageVO);
$.ajax({
type: "POST",
url: url,
data: data,
dataType:'json',
async: false,
processData: false,
contentType: false,
cache: false,
//timeout: 600000,
success: function (returnData, status) {
if(status == 'success'){ // status 확인 필요한가. 석세스 안뜨면 에러 가지 않나
if("fail"==returnData.result){
alert(returnData.message);
return;
}
alert("저장 되었습니다.");
goList();
} else if(status== 'fail'){
alert("저장에 실패하였습니다. !!");
}
},
error: function (e) { alert("저장에 실패하였습니다."); console.log("ERROR : ", e); }
});
}
function fn_egov_inqire_cert() {
var url = '/uat/uia/EgovGpkiRegist.do';
var popupwidth = '500';
var popupheight = '400';
var title = '인증서';
Top = (window.screen.height - popupheight) / 3;
Left = (window.screen.width - popupwidth) / 2;
if (Top < 0) Top = 0;
if (Left < 0) Left = 0;
Future = "fullscreen=no,toolbar=no,location=no,directories=no,status=no,menubar=no, scrollbars=no,resizable=no,left=" + Left + ",top=" + Top + ",width=" + popupwidth + ",height=" + popupheight;
PopUpWindow = window.open(url, title, Future)
PopUpWindow.focus();
}
function fn_egov_dn_info_setting(dn) {
var frm = document.userManageVO;
frm.subDn.value = dn;
}
//직원 상세 - 부서 선택박스 변경 시
function fn_select_emp_part(obj) {
var selectId = $(obj).children("option:selected").val();
var selectDepth = $(obj).children("option:selected").attr("depth")*1+1;
if(selectId == "" && selectDepth =="2"){
$('#partIdx').val(selectId) ;
$("#depth_2").remove();
$("#depth_3").remove();
return;
}
if(selectId == "" && selectDepth =="3"){
$('#partIdx').val($('#depth_1').val());
$("#depth_3").remove();
return;
}
if(selectDepth =="4"){
if(selectId == ""){
$('#partIdx').val($('#depth_2').val());
}else{
$('#partIdx').val(selectId) ;
}
return;
}
if(selectDepth =="2"){
$("#depth_2").remove();
$("#depth_3").remove();
}
if(selectDepth =="3"){
$("#depth_3").remove();
}
$('#partIdx').val(selectId) ;
ajaxGetChartDepth( selectId, selectDepth );
}
function ajaxGetChartDepth(upperIdx , depth){
$.ajax({
type:"POST",
url:"<c:url value='/uss/umt/user/ajaxGetChartDepth.do' />",
data:{ "depth": depth , "upperIdx": upperIdx},
dataType:'json',
success:function(returnData, status){
if(status == "success") {
var str = "<select id='depth_"+depth+"' depth='"+depth+"' onchange='fn_select_emp_part(this);'>";
str += "<option value='' depth='"+depth+"'>선택</option>";
$.each(returnData.orgChartDepth , function(idx, val){
str += "<option value='"+val.id+"' depth='"+depth+"'>"+val.text+"</option>";
});
str += "</select>";
$("#orgChartDepth").append(str);
}else{ alert("ERROR!");return;}
},
error:function(request , status, error){
alert("code:"+request.status+"\n"+"message:"+request.responseText+"\n"+"error:"+error);
}
});
}
function changSelect(obj){
var str = "<option value='ROLE_USER_MEMBER'>일반관리자</option>";
if(obj.value == "super"){
str += "<option value='ROLE_ADMIN'>최고관리자</option>"
}
$("#authorCode option").remove();
$("#authorCode").append(str);
}
function passMissReset(){
$.ajax({
type:"POST",
url:"/uss/umt/user/PassMissResetAjax.do",
data:{
"id": "${userManageVO.emplyrId}"
,"userSe" : "USR"
},
dataType:'json',
timeout:(1000*30),
success:function(returnData, status){
if(status == "success") {
alert("카운터가 초기화 되었습니다.");
}else{ alert("ERROR!");return;}
},
error:function(request , status, error){
alert("code:"+request.status+"\n"+"message:"+request.responseText+"\n"+"error:"+error);
}
});
}
function nCheck(){
var numCheck = document.getElementById("offmTelno").value;
if(numCheck!=""){
if(/[^0123456789-]/g.test(numCheck)){
alert("사무실 전화번호는 숫자와 특수문자'-'만 입력이 가능합니다.");
return false;
}
}
return true;
}
function nCheck2(){
var numCheck = document.getElementById("numCheck");
if(/[^0123456789]/g.test(numCheck.value)){
alert("숫자가 아닙니다.\n\n0~9의 숫자만 허용합니다.");
}
}
</script>
</head>
<body>
<form:form commandName="userManageVO" action="${pageContext.request.contextPath}/uss/umt/user/EgovUserSelectUpdt.do" name="userManageVO" method="post" >
<double-submit:preventer tokenKey="someKey" />
<input name="checkedIdForDel" type="hidden" />
<!-- 검색조건 유지 -->
<input type="hidden" name="searchCondition" value="<c:out value='${userSearchVO.searchCondition}'/>"/>
<input type="hidden" name="searchKeyword" value="<c:out value='${userSearchVO.searchKeyword}'/>"/>
<input type="hidden" name="sbscrbSttus" value="<c:out value='${userSearchVO.sbscrbSttus}'/>"/>
<input type="hidden" name="pageIndex" value="<c:out value='${userSearchVO.pageIndex}'/>"/>
<input type="hidden" name="rsaPasswd" id="rsaPasswd" />
<input type="hidden" id="RSAModulus" value="${RSAModulus}"/>
<input type="hidden" id="RSAExponent" value="${RSAExponent}"/>
<input type="hidden" name="partIdx" id="partIdx" value="<c:out value='${userManageVO.partIdx}'/>"/>
<input type="hidden" name="emplyrSttusCode" value="<c:out value='${userSearchVO.emplyrSttusCode}'/>"/>
<!-- 사용자유형정보 : password 수정화면으로 이동시 타겟 유형정보 확인용, 만약검색조건으로 유형이 포함될경우 혼란을 피하기위해 userTy명칭을 쓰지 않음-->
<input type="hidden" name="userTyForPassword" value="<c:out value='${userManageVO.userTy}'/>" />
<!-- cont -->
<div class="contWrap">
<div class="pageTitle">
<div class="pageIcon"><img src="/pb/img/pageTitIcon4.png" alt=""></div>
<h2 class="titType1 c_222222 fwBold">관리자수정</h2>
<p class="tType6 c_999999"> </p>
</div>
<div class="pageCont">
<div class="listTop resisterList">
<p class="right block fwMd"><span class="tType4 c_e40000 fwBold">*</span>는 필수입력 항목입니다.</p>
</div>
<table class="tbType2">
<colgroup>
<col style="width: 20%">
<col style="width: 80%">
</colgroup>
<tbody>
<tr>
<th><span class="reqArea">사용자아이디</span></th>
<td colspan="3">
<form:input path="emplyrId" id="emplyrId" size="50" maxlength="20" readonly="true" />
<form:errors path="emplyrId" cssClass="error"/>
<form:hidden path="uniqId" />
</td>
</tr>
<tr>
<th><span class="reqArea">이름</span></th>
<td colspan="3">
<form:input path="emplyrNm" id="emplyrNm" cssClass="txaIpt" size="50" maxlength="60" />
<form:errors path="emplyrNm" cssClass="error" />
</td>
</tr>
<tr>
<th>권한</th>
<td colspan="3">
<select name="authorCode" id="authorCode" title="권한">
<c:forEach var="authorResult" items="${authorList}" varStatus="status">
<c:if test="${(authorResult.authorCode eq 'ROLE_ADMIN')||(authorResult.authorCode eq 'ROLE_CS')}">
<option value="<c:out value="${authorResult.authorCode}"/>" <c:if test="${authorResult.authorCode eq userManageVO.authorCode}">selected</c:if>>
<c:out value="${authorResult.authorNm}"/>
</option>
</c:if>
</c:forEach>
</select>
</td>
</tr>
<tr>
<th><span class="reqArea">이메일주소</span></th>
<td colspan="3">
<form:input path="emailAdres" id="emailAdres" cssClass="txaIpt" size="50" maxlength="50" />
<form:errors path="emailAdres" cssClass="error" />
</td>
</tr>
<tr id="emailSandTr">
<th>이메일 발송여부</th>
<td colspan="3">
<select name="emailSendYN" id="emailSendYN" title="메일 발송여부">
<option value="Y" <c:if test="${'Y' eq userManageVO.emailSendYN}">selected</c:if>>
이메일 발송
</option>
<option value="N" <c:if test="${'N' eq userManageVO.emailSendYN}">selected</c:if>>
이메일 미발송
</option>
</select>
</td>
</tr>
<tr id="smsSandTr">
<th>SMS 발송여부</th>
<td colspan="3">
<select name="mbtlSendYN" id="mbtlSendYN" title="SMS 발송여부">
<option value="Y" <c:if test="${'Y' eq userManageVO.mbtlSendYN}">selected</c:if>>
SMS 발송
</option>
<option value="N" <c:if test="${'N' eq userManageVO.mbtlSendYN}">selected</c:if>>
SMS 미발송
</option>
</select>
</td>
</tr>
<tr>
<th>직급</th>
<td colspan="3">
<form:input path="ofcpsNm" id="ofcpsNm" cssClass="txaIpt" size="50" maxlength="15" placeholder="" />
<form:errors path="ofcpsNm" cssClass="error" />
</td>
</tr>
<tr>
<th>핸드폰 번호</th>
<td colspan="3">
<form:input path="moblphonNo" id="moblphonNo" cssClass="txaIpt" size="50" maxlength="15" placeholder="예시 : 010-1234-4567" />
<form:errors path="moblphonNo" cssClass="error" />
</td>
</tr>
<tr>
<th>전화번호</th>
<td colspan="3">
<form:input path="offmTelno" id="offmTelno" cssClass="txaIpt" size="50" maxlength="15" placeholder="예시 : 02-123-4567" />
<form:errors path="offmTelno" cssClass="error" />
</td>
</tr>
<tr>
<th>팩스번호</th>
<td colspan="3">
<form:input path="fxnum" id="fxnum" cssClass="txaIpt" size="50" maxlength="15" placeholder="예시 : 02-123-4567" />
<form:errors path="fxnum" cssClass="error" />
</td>
</tr>
<tr>
<th>담당업무</th>
<td colspan="3">
<form:input path="userWork" id="userWork" cssClass="txaIpt" size="50" maxlength="15" placeholder="" />
<form:errors path="userWork" cssClass="error" />
</td>
</tr>
<c:if test="${empty isAdmin and empty isMember}">
<tr>
<th>비밀번호확인</th>
<td colspan="3">
<input type="password" name="passwdCmp" id="passwdCmp" type="text" value="" size="50" maxlength="50" style="width: 95%;">
</td>
</tr>
</c:if>
<c:if test="${!empty isAdmin}">
<tr id="smsSandTr">
<th>미허용 IP 문자인증 여부</th>
<td colspan="3">
<select name="outerCertYn" id="outerCertYn" title="SMS 문자인증 여부">
<option value="Y" <c:if test="${'Y' eq userManageVO.outerCertYn}">selected</c:if>>
SMS 문자 인증
</option>
<option value="N" <c:if test="${'N' eq userManageVO.outerCertYn}">selected</c:if>>
SMS 문자 미인증
</option>
</select>
</td>
</tr>
</c:if>
<c:if test="${!empty isAdmin}">
<tr>
<th>로그인실패 초기화</th>
<td colspan="3">
<input type="button" class="btnType1" value="초기화" onclick="passMissReset(); return false;">
</td>
</tr>
</c:if>
</tbody>
</table>
<div class="btnWrap">
<input type="button" class="btnType1" value="비밀번호변경" onclick="fnPasswordMove(); return false;">
<input type="button" class="btnType1" value="수 정" onclick="fnUpdate(); return false;">
<c:if test="${not empty isAdmin}">
<input type="button" class="btnType1 bg_ed4545" value="삭 제" onclick="fnDeleteUser('<c:out value='${userManageVO.userTy}'/>:<c:out value='${userManageVO.uniqId}'/>'); return false;">
<input type="button" class="btnType1 bg_888888" value="목 록" onclick="fnListPage(); return false;">
</c:if>
</div>
</div>
</div>
<!-- //cont -->
<form:hidden path="password" />
<input type="hidden" name="gnrlUser" value="N"> <!-- gnrlUser가 N이면 관리자등록 -->
</form:form>
<form name="searchForm" method="get">
<input type="hidden" name="searchSortCnd" value="<c:out value="${userSearchVO.searchSortCnd}" />"/>
<input type="hidden" name="searchSortOrd" value="<c:out value="${userSearchVO.searchSortOrd}" />"/>
<input type="hidden" name="searchCondition" value="<c:out value='${userSearchVO.searchCondition}'/>"/>
<input type="hidden" name="searchKeyword" value="<c:out value='${userSearchVO.searchKeyword}'/>"/>
<input type="hidden" name="pageUnit" value="<c:out value='${userSearchVO.pageUnit}'/>"/>
<input type="hidden" name="PageIndex" value="<c:out value='${userSearchVO.pageIndex}' default='1' /> "/>
<input type="hidden" name="emplyrSttusCode" value="<c:out value='${userSearchVO.emplyrSttusCode}'/>"/>
</form>
<form name="modiForm" method="get" action="<c:url value='/sec/ram/EgovAuthorRoleList.do'/>" >
<input type="hidden" name="uniqId" value="<c:out value='${userManageVO.uniqId}'/>"/>
<input type="hidden" name="userTyForPassword" value="<c:out value='${userManageVO.userTy}'/>" />
<input type="hidden" name="emplyrId" value="<c:out value='${userManageVO.emplyrId}'/>" />
<input type="hidden" name="gnrlUser" value="N"/>
<input type="hidden" name="emplyrSttusCode" value="<c:out value='${userSearchVO.emplyrSttusCode}'/>"/>
</form>
</body>
</html>