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 : EgovAuthorGroupManage.jsp
Description : EgovAuthorGroupManage List 화면
Modification Information
수정일 수정자 수정내용
------- -------- ---------------------------
2009.03.23 lee.m.j 최초 생성
2011.08.31 JJY 경량환경 버전 생성
author : 공통서비스 개발팀 lee.m.j
since : 2009.03.23
--%>
<%@ 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 uri="http://java.sun.com/jsp/jstl/functions" prefix="fn" %>
<%@ taglib prefix="spring" uri="http://www.springframework.org/tags"%>
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %>
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Language" content="ko" >
<%-- <link href="<c:url value='/'/>css/common.css" rel="stylesheet" type="text/css" > --%>
<title>권한그룹 목록</title>
<script type="text/javaScript" language="javascript" defer="defer">
$( document).ready(function() {
//정렬 아이콘 표시
var searchSortCnd = $("[name='searchSortCnd']").val();
var searchSortOrd = $("[name='searchSortOrd']").val();
if (searchSortCnd != "" && searchSortOrd != "") {
var imgOrdr = "";
if (searchSortOrd == "desc") imgOrdr = "down";
else imgOrdr = "up";
var $sort_div = $("#sort_"+ searchSortCnd);
var ordrImg = "<img class='ordr' src='/direct/img/sort_"+imgOrdr+"_on.png' alt=''>";
// <img class="ordr" src="/direct/img/sort_up_img.png" style="display: none;" alt="">
$sort_div.attr("sortOrd", searchSortOrd);
$sort_div.find("div img").remove();
$sort_div.find("div").append(ordrImg);
}
// 정렬 항목 이벤트
$(".sort").click(function(e) {
sortSearch(this);
});
});
//목록 정렬 항목 클릭
function sortSearch(obj) {
var sortOrd = $(obj).attr("sortOrd");
var sortCnd = $(obj).attr("id");
$("[name='searchSortCnd']").val(sortCnd.substring(5)); // 구분자 제거
if (sortOrd == "desc") $("[name='searchSortOrd']").val("asc");
else $("[name='searchSortOrd']").val("desc");
linkPage(1);
}
function fncCheckAll() {
var checkField = document.listForm.delYn;
if(document.listForm.checkAll.checked) {
if(checkField) {
if(checkField.length > 1) {
for(var i=0; i < checkField.length; i++) {
checkField[i].checked = true;
}
} else {
checkField.checked = true;
}
}
} else {
if(checkField) {
if(checkField.length > 1) {
for(var j=0; j < checkField.length; j++) {
checkField[j].checked = false;
}
} else {
checkField.checked = false;
}
}
}
}
function fncManageChecked() {
var resultCheck = false;
var checkField = document.listForm.delYn;
var checkId = document.listForm.checkId;
var selectAuthor = document.listForm.authorManageCombo;
var booleanRegYn = document.listForm.regYn;
var listMberTyCode = document.listForm.mberTyCode;
var returnId = "";
var returnAuthor = "";
var returnRegYn = "";
var returnmberTyCode = "";
var checkedCount = 0;
if(checkField) {
if(checkField.length > 1) {
for(var i=0; i<checkField.length; i++) {
if(checkField[i].checked) {
checkedCount++;
checkField[i].value = checkId[i].value;
if(returnId == "") {
returnId = checkField[i].value;
returnAuthor = selectAuthor[i].value;
returnRegYn = booleanRegYn[i].value;
returnmberTyCode = listMberTyCode[i].value;
}
else {
returnId = returnId + ";" + checkField[i].value;
returnAuthor = returnAuthor + ";" + selectAuthor[i].value;
returnRegYn = returnRegYn + ";" + booleanRegYn[i].value;
returnmberTyCode = returnmberTyCode + ";" + listMberTyCode[i].value;
}
}
}
if(checkedCount > 0)
resultCheck = true;
else {
alert("선택된 항목이 없습니다.");
resultCheck = false;
}
} else {
if(document.listForm.delYn.checked == false) {
alert("선택 항목이 없습니다.");
resultCheck = false;
}
else {
returnId = checkId.value;
returnAuthor = selectAuthor.value;
returnRegYn = booleanRegYn.value;
returnmberTyCode = listMberTyCode.value;
resultCheck = true;
}
}
} else {
alert("조회된 결과가 없습니다.");
}
document.listForm.userIds.value = returnId;
document.listForm.authorCodes.value = returnAuthor;
document.listForm.regYns.value = returnRegYn;
document.listForm.mberTyCodes.value = returnmberTyCode ;
return resultCheck;
}
function fncAddAuthorGroupInsert() {
if(!fncManageChecked()) return;
if(confirm("등록하시겠습니까?")) {
document.listForm.action = "<c:url value='/sec/rgm/EgovAuthorGroupInsert.do'/>";
document.listForm.submit();
}
}
function fncAuthorGroupDeleteList() {
if(!fncManageChecked()) return;
if(confirm("등록취소 하시겠습니까?")) {
document.listForm.action = "<c:url value='/sec/rgm/EgovAuthorGroupDelete.do'/>";
document.listForm.submit();
}
}
function linkPage(pageNo){
var searchForm = document.searchForm ;
searchForm.pageIndex.value = pageNo ;
searchForm.searchCondition.value = $('#searchCondition').val();
searchForm.searchKeyword.value = $('#searchKeyword').val();
searchForm.searchSortOrd.value = $('#searchSortOrd').val() ;
searchForm.pageUnit.value = $('#pageUnit').val();
searchForm.action = "<c:url value='/sec/rgm/EgovAuthorGroupList.do'/>";
searchForm.submit();
}
function fncSelectAuthorGroupPop() {
if(document.listForm.searchCondition.value == '3') {
window.open("<c:url value='/sec/gmt/EgovGroupSearchView.do'/>","notice","height=500, width=800, top=50, left=20, scrollbars=no, resizable=no");
} else {
alert("그룹을 선택하세요.");
return;
}
}
function onSearchCondition() {
document.listForm.searchKeyword.value = "";
if(document.listForm.searchCondition.value == '3') {
document.listForm.searchKeyword.readOnly = true;
} else {
document.listForm.searchKeyword.readOnly = false;
}
}
function press() {
if (event.keyCode==13) {
fncSelectAuthorGroupList();
event.preventDefault();
}
}
function fncSelectAuthorGroupList(){
linkPage(1);
}
</script>
</head>
<body>
<form:form id="listForm" name="listForm" action="<c:url value='/sec/rgm/EgovAuthorGroupList.do'/>" method="post">
<input type="hidden" name="userId"/>
<input type="hidden" name="userIds"/>
<input type="hidden" name="authorCodes"/>
<input type="hidden" name="regYns"/>
<input type="hidden" name="mberTyCodes"/>
<input type="hidden" name="sortOrder" id="sortOrder" value="${authorGroupVO.sortOrder}" />
<input type="hidden" name="pageIndex" value="<c:out value='${authorGroupVO.pageIndex}'/>"/>
<div class="cont_area">
<div class="cont_main_title">
<img src="/direct/img/home_icon.png" alt="">
<span id="cnt_cate_list"></span>
</div>
<div class="cont_serch_area">
<div class="basic_serch_area">
<select id="searchCondition" name="searchCondition" onchange="onSearchCondition()" title="조회조건">
<option value="" <c:if test="${authorGroupVO.searchCondition == ''}">selected</c:if> >전체</option>
<option value="1" <c:if test="${authorGroupVO.searchCondition == '1'}">selected</c:if> >아이디</option>
<option value="2" <c:if test="${authorGroupVO.searchCondition == '2'}">selected</c:if> >관리자명</option>
</select>
<input type="text" id="searchKeyword" name="searchKeyword" value="<c:out value='${authorGroupVO.searchKeyword}'/>" size="25" title="검색" onkeypress="press();" />
<div class="serch_btns">
<input type="button" value="검색" class="serch_btn" onclick="fncSelectAuthorGroupList(); return false;">
</div>
</div>
</div>
<div class="list_info">
<div class="all_list_number">총
<span class="all_number"><c:out value="${paginationInfo.totalRecordCount}"/></span>건</div>
<div class="list_info_right">
<div class="list_write"><input type="button" value="등록" onclick="fncAddAuthorGroupInsert(); return false;"></div>
<div class="list_count">
<select name="pageUnit" id="pageUnit" class="select" title="검색조건선택" onchange="fncSelectAuthorGroupList();">
<option value='10' <c:if test="${authorManageVO.pageUnit == '10' or authorManageVO.pageUnit == ''}">selected</c:if>>10줄</option>
<option value='20' <c:if test="${authorManageVO.pageUnit == '20'}">selected</c:if>>20줄</option>
<option value='30' <c:if test="${authorManageVO.pageUnit == '30'}">selected</c:if>>30줄</option>
</select>
</div>
<div class="del_btn">
<!-- <input type="button" value="삭제" onclick="fncAuthorGroupDeleteList(); return false;"/> -->
</div>
</div>
</div>
<div class="list_wrap">
<table>
<tr>
<th><input type="checkbox" name="checkAll" id="checkAll" onClick="fncManageChecked();">
<label for="checkAll"></label></th>
<th>
<div class="sort" id="sort_ESNTL_ID">번호
<div class="sort_btn"><!-- 정렬버튼 -->
<img src="/direct/img/sort_up_img.png" alt="">
</div>
</div>
</th>
<th>
<div class="sort" id="sort_USER_ID">아이디
<div class="sort_btn"><!-- 정렬버튼 -->
<img src="/direct/img/sort_up_img.png" alt="">
</div>
</div>
</th>
<th>
<div class="sort" id="sort_USER_NM">관리자명
<div class="sort_btn"><!-- 정렬버튼 -->
<img src="/direct/img/sort_up_img.png" alt="">
</div>
</div>
</th>
<th>
<div class="sort" id="sort_AUTHOR_CODE">권한
<div class="sort_btn"><!-- 정렬버튼 -->
<img src="/direct/img/sort_up_img.png" alt="">
</div>
</th>
<th>
<div class="sort" id="sort_REG_YN">등록 여부
<div class="sort_btn"><!-- 정렬버튼 -->
<img src="/direct/img/sort_up_img.png" alt="">
</div>
</div>
</th>
</tr>
<c:forEach var="authorGroup" items="${authorGroupList}" varStatus="status">
<tr>
<td>
<input name="delYn" id="check${status.index}" type="checkbox" <c:out value="${status.count}"/>" />
<label for="check${status.index}"></label>
<input type="hidden" name="checkId" value="<c:out value="${authorGroup.uniqId}"/>" />
</td>
<td>
<c:if test="${authorGroupVO.searchSortOrd eq 'asc' }">
<c:out value="${(authorGroupVO.pageIndex - 1) * authorGroupVO.pageUnit + status.count}"/>
</c:if>
<c:if test="${authorGroupVO.searchSortOrd eq 'desc' }">
<c:out value="${ ( paginationInfo.totalRecordCount - ((authorGroupVO.pageIndex -1)*authorGroupVO.pageUnit) ) - status.index }"/>
</c:if>
</td>
<td>
<c:out value="${authorGroup.userId}"/>
</td>
<td>
<c:out value="${authorGroup.userNm}"/>
<input type="hidden" name="mberTyCode" value="${authorGroup.mberTyCode}"/>
</td>
<td>
<select name="authorManageCombo" title="권한">
<c:forEach var="authorManage" items="${authorManageList}" varStatus="status">
<option value="<c:out value="${authorManage.authorCode}"/>" <c:if test="${authorManage.authorCode == authorGroup.authorCode}">selected</c:if> ><c:out value="${authorManage.authorNm}"/></option>
</c:forEach>
</select>
</td>
<td>
<c:out value="${authorGroup.regYn}"/>
<input type="hidden" name="regYn" value="<c:out value="${authorGroup.regYn}"/>">
</td>
</tr>
</c:forEach>
<c:if test="${empty authorGroupList}">
<tr><td colspan="8"><spring:message code="common.nodata.msg" /></td></tr>
</c:if>
</table>
</div>
<!-- 페이지 네비게이션 시작 -->
<c:if test="${!empty authorGroupList}">
<div class="page">
<ul>
<ui:pagination paginationInfo = "${paginationInfo}" type="image" jsFunction="linkPage" />
</ul>
</div>
</c:if>
<!-- //페이지 네비게이션 끝 -->
</div>
</form:form>
<form name="searchForm" method="get">
<input name="searchCondition" type="hidden" />
<input name="searchKeyword" type="hidden" />
<input name="pageIndex" type="hidden" />
<input name="pageUnit" type="hidden" value="10" />
<input type="hidden" name="searchSortCnd" id="searchSortCnd" value="<c:out value="${authorGroupVO.searchSortCnd}" />" />
<input type="hidden" name="searchSortOrd" id="searchSortOrd" value="<c:out value="${authorGroupVO.searchSortOrd}" />" />
</form>
</body>
</html>