fix: javascript 선언 오류 fix

main
minuk926 2 years ago
parent e4d506b5fc
commit 4f78815ff2

@ -18,6 +18,7 @@ import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.ui.ModelMap;
import org.springframework.validation.BindingResult;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.ModelAttribute;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
@ -69,14 +70,8 @@ public class XitUserRegMngController {
private int PAGE_SIZE;
@RequestMapping(value = "mngUserRegMgtForm", method={RequestMethod.GET, RequestMethod.POST})
public ModelAndView mngUserRegMgtForm() {
ModelAndView mav = new ModelAndView();
//사용자상태코드를 코드정보로부터 조회
mav.addObject("emplyrSttusCode_result", xitFrameCodeService.findCmmnDetailCodes("XIT013"));//사용자상태코드목록
return mav;
@GetMapping(value = "mngUserRegMgtForm")
public void mngUserRegMgtForm() {
}
/**

@ -27,7 +27,7 @@ public abstract class AbstractExceptionViewResolver implements HandlerExceptionR
@Override
public ModelAndView resolveException(HttpServletRequest request, HttpServletResponse response, Object obj, Exception exception) {
logger.error("AbstractExceptionViewResolver exception catch : ", exception);
logger.error("AbstractExceptionViewResolver::resolveException : ", exception);
exception.printStackTrace();

@ -51,7 +51,7 @@
<!-- 데이터 출력 -->
<div id="grid_t0"></div>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
let GRID = null;
/* ========================

@ -78,7 +78,7 @@
<!-- //popup -->
</form:form>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
const init = () => {
//닫기 버튼 Event
$("#btnClose").click(function() {

@ -19,7 +19,7 @@
</select>
<!-- tag lib sample -->
<code:select id="sch_date_opt1" name="sch_date_opt1" codeId="ENS003" defaultSelect="99" cls="selectBox" alt="selectBox tag"/>
<code:select id="sch_date_opt1" name="sch_date_opt1" codeId="ENS003" title="시작날자선택" defaultSelect="99" cls="selectBox" alt="selectBox tag"/>
<code:radio id="sch_date_opt2" name="sch_date_opt2" codeId="ENS003" defaultSelect="02" cls="radioBox" alt="radio tag"/>
</li>
<li>

@ -59,7 +59,7 @@
%>
</head>
<script language="javascript">
<script type="text/javaScript">
function init(){
var url = location.href;
var confmKey = " U01TX0FVVEgyMDE3MDQyMTE3MTQ1MjIwNzQ4";
@ -127,4 +127,4 @@ function init(){
<!-- 해당시스템의 인코딩타입이 EUC-KR일경우에만 추가 END-->
</form>
</body>
</html>
</html>

@ -16,7 +16,7 @@
<link rel="stylesheet" type="text/css" href="${ctx}/resources/3rd-party/juso/css/addrlink.css"></link>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>주소정보연계 | 도로명주소 안내시스템</title>
<script language="javascript">
<script type="text/javaScript">
//특수문자, 특정문자열(sql예약어) 제거
function checkSearchedWord(obj){
obj.value = obj.value+" ";

@ -9,7 +9,7 @@
<script type="text/javascript" src="<c:url value='/js/framework/egov/EgovCalPopup.js' />"></script>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
window.onload = function(){
fnInitAll();
}

@ -77,7 +77,7 @@
</form:form>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
$(document).ready(function(){
XitAuthGrpMng_edit.init();

@ -77,7 +77,7 @@
</form:form>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
$(document).ready(function(){
XitAuthGrpMng_input.init();

@ -151,7 +151,7 @@ table.tbl03 th {
}
</style>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
$(document).ready(function(){
XitAuthHierarchyMng_edit.init();

@ -62,7 +62,7 @@
</form:form>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
$(document).ready(function(){
XitAuthRegMng_edit.init();

@ -62,7 +62,7 @@
</form:form>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
$(document).ready(function(){
XitAuthRegMng_input.init();

@ -86,7 +86,7 @@
</form:form>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
$(document).ready(function(){
XitAuthRuleMng_edit.init();

@ -86,7 +86,7 @@
</form:form>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
$(document).ready(function(){
XitAuthRuleMng_input.init();

@ -93,7 +93,7 @@
<script type="text/javascript" src="<c:url value='/js/framework/egov/EgovMultiFile.js'/>"></script>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
/* *******************************
* 로그인 정책관리 Functions

@ -15,7 +15,7 @@
<script type="text/javascript" src="<c:url value="/_cmmn_/util/validator.do"/>"></script>
<validator:javascript formName="groupManage" staticJavascript="false" xhtml="true" cdata="false"/>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
function fncSelectGroupList() {
var varFrom = document.getElementById("groupManage");

@ -16,7 +16,7 @@
<script type="text/javascript" src="<c:url value="/_cmmn_/util/validator.do"/>"></script>
<validator:javascript formName="groupManage" staticJavascript="false" xhtml="true" cdata="false"/>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
function fncSelectGroupList() {
var varFrom = document.getElementById("groupManage");

@ -14,7 +14,7 @@
<script type="text/javascript" src="<c:url value="/_cmmn_/util/validator.do"/>"></script>
<validator:javascript formName="authorManage" staticJavascript="false" xhtml="true" cdata="false"/>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
function fncSelectAuthorList() {
var varFrom = document.getElementById("authorManage");

@ -14,7 +14,7 @@
<script type="text/javascript" src="<c:url value="/_cmmn_/util/validator.do"/>"></script>
<validator:javascript formName="authorManage" staticJavascript="false" xhtml="true" cdata="false"/>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
function fncSelectAuthorList() {
var varFrom = document.getElementById("authorManage");
varFrom.action = "<c:url value='/framework/biz/mng/auth/AuthRegMng_list.do'/>";

@ -15,7 +15,7 @@
<script type="text/javascript" src="<c:url value="/_cmmn_/util/validator.do"/>"></script>
<validator:javascript formName="roleManage" staticJavascript="false" xhtml="true" cdata="false"/>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
function fncSelectRoleList() {
var varFrom = document.getElementById("roleManage");

@ -16,7 +16,7 @@
<script type="text/javascript" src="<c:url value="/_cmmn_/util/validator.do"/>"></script>
<validator:javascript formName="roleManage" staticJavascript="false" xhtml="true" cdata="false"/>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
function fncSelectRoleList() {
var varFrom = document.getElementById("roleManage");

@ -85,7 +85,7 @@
</form:form>
<script type="text/javascript" src="<c:url value='/js/framework/egov/EgovCalPopup.js' />"></script>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
$(document).ready(function(){
XitBatchRegMng_edit.init();
});

@ -75,7 +75,7 @@
</form:form>
<script type="text/javascript" src="<c:url value='/js/framework/egov/EgovCalPopup.js' />"></script>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
$(document).ready(function(){
XitBatchRegMng_input.init();
});

@ -136,7 +136,7 @@
<script type="text/javascript" src="<c:url value='/js/framework/egov/EgovCalPopup.js' />"></script>
<script type="text/javascript" src="<c:url value='/js/framework/egov/EgovCmmUtl.js' />"></script>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
$(document).ready(function(){
XitBatchScheduleMng_edit.init();
XitBatchScheduleMng_edit.fn_egov_executCycleOnChange();

@ -121,7 +121,7 @@
<script type="text/javascript" src="<c:url value='/js/xitframework/egov/EgovCalPopup.js' />"></script>
<script type="text/javascript" src="<c:url value='/js/xitframework/egov/EgovCmmUtl.js' />"></script>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
$(document).ready(function(){
XitBatchScheduleMng_input.init();
XitBatchScheduleMng_input.fn_egov_executCycleOnChange();

@ -12,7 +12,7 @@
<script type="text/javascript" src="<c:url value="/_cmmn_/util/validator.do"/>"></script>
<validator:javascript formName="batchOpert" staticJavascript="false" xhtml="true" cdata="false"/>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
/* ********************************************************

@ -14,7 +14,7 @@
<script type="text/javascript" src="<c:url value="/_cmmn_/util/validator.do"/>"></script>
<script type="text/javascript" src="<c:url value='/resources/js/framework/egov/EgovCalPopup.js' />"></script>
<validator:javascript formName="batchOpert" staticJavascript="false" xhtml="true" cdata="false"/>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
/* ********************************************************
* 목록 으로 가기

@ -6,7 +6,7 @@
<%pageContext.setAttribute("crlf", "\r\n"); %>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
/* ********************************************************
* 목록 으로 가기

@ -15,7 +15,7 @@
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
/* ********************************************************

@ -17,7 +17,7 @@
<script type="text/javascript" src="<c:url value='/js/framework/egov/EgovCalPopup.js' />"></script>
<script type="text/javascript" src="<c:url value='/js/framework/egov/EgovCmmUtl.js' />"></script>
<validator:javascript formName="batchSchdul" staticJavascript="false" xhtml="true" cdata="false"/>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
$(document).ready(function(){
fn_egov_init();

@ -16,7 +16,7 @@
<script type="text/javascript" src="<c:url value='/js/framework/egov/EgovCalPopup.js' />"></script>
<script type="text/javascript" src="<c:url value='/js/framework/egov/EgovCmmUtl.js' />"></script>
<validator:javascript formName="batchSchdul" staticJavascript="false" xhtml="true" cdata="false"/>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
$(document).ready(function(){
fn_egov_init();

@ -8,7 +8,7 @@
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
/* ********************************************************

@ -58,7 +58,7 @@
<div id="grid" style="margin-top: 10px;"></div>
</form>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
$(document).ready(function(){
XitClCodeMng_list.init();
});

@ -54,7 +54,7 @@
<div id="grid" style="margin-top: 10px;"></div>
</form>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
$(document).ready(function(){
XitCmmnCodeMng_list.init();
});

@ -57,7 +57,7 @@
<div id="grid" style="margin-top: 10px;"></div>
</form>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
$(document).ready(function(){
XitDetailCodeMng_list.init();
});

@ -10,7 +10,7 @@
<script type="text/javascript" src="<c:url value="/_cmmn_/util/validator.do"/>"></script>
<validator:javascript formName="cmmnClCode" staticJavascript="false" xhtml="true" cdata="false"/>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
/* ********************************************************
* 목록 으로 가기
******************************************************** */

@ -11,7 +11,7 @@
<script type="text/javascript" src="<c:url value="/_cmmn_/util/validator.do"/>"></script>
<validator:javascript formName="cmmnClCode" staticJavascript="false" xhtml="true" cdata="false"/>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
/* ********************************************************
* 목록 으로 가기
******************************************************** */

@ -6,7 +6,7 @@
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
/* ********************************************************
* 페이징 처리 함수
******************************************************** */

@ -13,7 +13,7 @@
<script type="text/javascript" src="<c:url value="/_cmmn_/util/validator.do"/>"></script>
<validator:javascript formName="cmmnCode" staticJavascript="false" xhtml="true" cdata="false"/>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
/* ********************************************************
* 목록 으로 가기
******************************************************** */

@ -12,7 +12,7 @@
<script type="text/javascript" src="<c:url value="/_cmmn_/util/validator.do"/>"></script>
<validator:javascript formName="cmmnCode" staticJavascript="false" xhtml="true" cdata="false"/>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
/* ********************************************************
* 목록 으로 가기
******************************************************** */

@ -7,7 +7,7 @@
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
/* ********************************************************
* 페이징 처리 함수
******************************************************** */

@ -12,7 +12,7 @@
<script type="text/javascript" src="<c:url value="/_cmmn_/util/validator.do"/>"></script>
<validator:javascript formName="cmmnDetailCode" staticJavascript="false" xhtml="true" cdata="false"/>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
/* ********************************************************
* 목록 으로 가기
******************************************************** */

@ -11,7 +11,7 @@
<script type="text/javascript" src="<c:url value="/_cmmn_/util/validator.do"/>"></script>
<validator:javascript formName="cmmnDetailCode" staticJavascript="false" xhtml="true" cdata="false"/>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
/* ********************************************************
* 목록 으로 가기
******************************************************** */

@ -6,7 +6,7 @@
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
/* ********************************************************
* 페이징 처리 함수
******************************************************** */

@ -10,7 +10,7 @@
<script type="text/javascript" src="<c:url value="/_cmmn_/util/validator.do"/>"></script>
<validator:javascript formName="zip" staticJavascript="false" xhtml="true" cdata="false"/>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
/* ********************************************************
* 목록 으로 가기
******************************************************** */

@ -11,7 +11,7 @@
<script type="text/javascript" src="<c:url value="/_cmmn_/util/validator.do"/>"></script>
<validator:javascript formName="zip" staticJavascript="false" xhtml="true" cdata="false"/>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
/* ********************************************************
* 목록 으로 가기
******************************************************** */

@ -7,7 +7,7 @@
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
/* ********************************************************
* 목록 으로 가기
******************************************************** */

@ -7,7 +7,7 @@
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
/* ********************************************************
* 페이징 처리 함수
******************************************************** */

@ -94,7 +94,7 @@
</form:form>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
$(document).ready(function(){
XitMenuListMng_edit.init();

@ -108,7 +108,7 @@ form[name="menuManageVO"] textarea{
}
</style>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
$(document).ready(function(){
XitMenuListMng_input.init();

@ -49,7 +49,7 @@
</form:form>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
$(document).ready(function(){
XitMenuListMng_inputs.init();

@ -26,9 +26,9 @@
<col style="width: 8%;"/>
<col style="width: 20%;"/>
<col style="width: 8%;"/>
<col style="width: ;"/>
<col/>
<col style="width: 8%;"/>
<col style="width: ;"/>
<col/>
<col style="width: 7%;"/>
</colgroup>
<tbody>
@ -58,9 +58,7 @@
</form>
<script language="javascript1.2" type="text/javaScript">
$(document).ready(function(){
XitMenuListMng_list.init();
});
/* *******************************
* 메뉴목록 관리 Functions
******************************* */
@ -291,11 +289,8 @@ var XitMenuListMng_list = {
}
}
}
/* ********************************************************
* 처리결과메시지 출력
******************************************************** */
<c:if test="${!empty message}">alert("${message}");</c:if>
$(document).ready(function(){
XitMenuListMng_list.init();
});
</script>

@ -56,7 +56,7 @@
<!-- 데이터 출력 -->
<div id="grid_t0"></div>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
let GRID = null;
/* ========================

@ -81,7 +81,7 @@
<!-- //popup -->
</form:form>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
/* *******************************
* 프로그램 목록관리 수정화면 Functions
******************************* */

@ -69,7 +69,7 @@
<script type="text/javascript" src="<c:url value='/resources/js/framework/egov/EgovMultiFile.js'/>"></script>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
$(document).ready(function(){
XitUserAbsntMng_edit.init();

@ -68,7 +68,7 @@
<script type="text/javascript" src="<c:url value='/resources/js/framework/egov/EgovMultiFile.js'/>"></script>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
$(document).ready(function(){
XitUserAbsntMng_input.init();

@ -14,7 +14,7 @@
<script type="text/javascript" src="<c:url value='/resources/js/framework/egov/EgovMultiFile.js'/>"></script>
<script type="text/javascript" src="<c:url value="/_cmmn_/util/validator.do"/>"></script>
<validator:javascript formName="mainImage" staticJavascript="false" xhtml="true" cdata="false"/>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
function fncSelectUserAbsnceList() {
var varFrom = document.getElementById("userAbsnce");

@ -11,7 +11,7 @@
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
$(document).ready(function(){
XitUserAbsntMng_input.init();

@ -14,7 +14,7 @@
<script type="text/javascript" src="<c:url value='/resources/js/framework/egov/EgovMultiFile.js'/>"></script>
<script type="text/javascript" src="<c:url value="/_cmmn_/util/validator.do"/>"></script>
<validator:javascript formName="userAbsnce" staticJavascript="false" xhtml="true" cdata="false"/>
<script type="text/javaScript" language="javascript">
<script type="text/javaScript">
function fncSelectUserAbsnceList() {
var varFrom = document.getElementById("userAbsnce");

@ -1,8 +1,5 @@
<%@ page language="java" 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"%>
<%@ include file="/WEB-INF/jsp/framework/taglibs.jsp"%>
<form name="frmSearch" id="frmSearch" method="post">
@ -19,28 +16,23 @@
<col style="width: 8%;"/>
<col style="width: 30%;"/>
<col style="width: 8%;"/>
<col style="width: ;"/>
<col/>
<col style="width: 8%;"/>
<col style="width: ;"/>
<col/>
<col style="width: 7%;"/>
</colgroup>
<tbody>
<tr>
<td colspan="6">
<select name="sbscrbSttus" id="sbscrbSttus" title="검색조건1-사용자상태" style=" width: 100px">
<option value="0" <c:if test="${empty userSearchVO.sbscrbSttus || userSearchVO.sbscrbSttus == '0'}">selected="selected"</c:if> >상태(전체)</option>
<option value="A" <c:if test="${userSearchVO.sbscrbSttus == 'A'}">selected="selected"</c:if> >가입신청</option>
<option value="D" <c:if test="${userSearchVO.sbscrbSttus == 'D'}">selected="selected"</c:if> >삭제</option>
<option value="P" <c:if test="${userSearchVO.sbscrbSttus == 'P'}">selected="selected"</c:if> >승인</option>
</select>
<select name="searchCondition" id="searchCondition" title="검색조건2-검색어구분" style="width: 100px">
<code:select id="sbscrbSttus" name="sbscrbSttus" codeId="XIT013" title="사용자상태" cls="selectBox" alt="selectBox tag"/>
<select name="searchCondition" id="searchCondition" title="검색구분" class="selectBox">
<option value="0" <c:if test="${userSearchVO.searchCondition == '0'}">selected="selected"</c:if> >ID</option>
<option value="1" <c:if test="${empty userSearchVO.searchCondition || userSearchVO.searchCondition == '1'}">selected="selected"</c:if> >Name</option>
</select>
<input name="searchKeyword" title="검색어" type="text" value="<c:out value="${userSearchVO.searchKeyword}"/>" />
</td>
<td>
<input type="button" id="btnSearch" class="btn_search" title="검색" value="검색" />
<input type="button" id="btnSearch" class="btn_search" title="검색" value="검색" onclick="XitUserRegMng_list.findData()"/>
</td>
</tr>
</tbody>
@ -60,331 +52,269 @@
<div id="grid"></div>
</form>
<script type="text/javaScript" language="javascript" defer="defer">
$(document).ready(function(){
XitUserRegMng_list.init();
});
/* *******************************
* 사용자 등록관리 Functions
******************************* */
var XitUserRegMng_list = {
/* ========================
* 초기화
======================== */
init : function(){
/**
* Grid Config Settings
*/
//Grid Style Set
Grid.applyTheme('striped'); // Call API of static method
//Grid 체크박스 checked EventListner
instance.on('check', function(ev) {
// console.log('check!', ev);
});
//Grid 체크박스 unchecked EventListner
instance.on('uncheck', function(ev) {
// console.log('uncheck!', ev);
});
//Grid 체크박스 focus이동 EventListner
instance.on('focusChange', function(ev) {
// console.log('change focused cell!', ev);
});
/**
* Elements EventListener Settings
*/
//검색 Event 설정
$('#btnSearch').on({
click: function(){
XitUserRegMng_list.findData();
}
});
/*등록 버튼 Event 설정
등록 팝업을 OPEN 한다.*/
$('#btnRegist').on({
click: function(){
XitUserRegMng_list.pagePopup('insert', '<c:url value="/framework/biz/mng/usr/UserRegMng_input.do"/>');
}
});
//삭제 버튼 Event 설정
$('#btnDelete').on({
click: function(){
if(confirm("삭제하시겠습니까?")){
var checkArr = instance.getCheckedRows();
var checkedIds = "";
checkArr.forEach(function(item, index){
checkedIds += (item.userTy +":"+item.userId);
if(checkArr.length -1 > index){
checkedIds += ",";
<script type="text/javaScript" defer="defer">
let GRID = null;
/* *******************************
* 사용자 등록관리 Functions
******************************* */
var XitUserRegMng_list = {
/* ========================
* 초기화
======================== */
init : function(){
const gridColumns = [
{
header: '번호',
name: 'rowNum',
width: 50,
sortable: false,
align: 'center',
renderer: {
type : RowNumberRenderer
}
},
{
header: '아이디',
name: 'userId',
width: 160,
sortable: true,
sortingType: 'desc',
align: 'center',
renderer: {
type: CustomButtonRenderer,
options: {
formatter : function(props){
var rowData = props.grid.getRow(props.rowKey);
var obj = {
formatter : rowData.userId
,element : "text"
}
return obj;
}
,eventFunction: XitUserRegMng_list.fnClickRegBtn
,eventType : "click"
}
})
document.frmSearch.checkedIdForDel.value=checkedIds;
XitUserRegMng_list.removeData();
}
},
{
header: '사용자 이름',
name: 'userNm',
width: 120,
sortable: false,
align: 'center'
},
{
header: '사용자 이메일',
name: 'emailAdres',
minWidth: 160,
sortable: false,
align: 'center'
},
{
header: '전화번호',
name: 'moblphonNo',
width: 120,
sortable: false,
align: 'center'
},
{
header: '등록일',
name: 'sbscrbDe',
width: 150,
sortable: false,
align: 'center'
},
{
header: '가입상태',
name: 'userSttusCode',
width: 110,
sortable: false,
align: 'center'
}
}
});
XitUserRegMng_list.fn_setInputLimit();
},
/* ========================
* 입력값 언어 선택
======================== */
fn_setInputLimit : function(){
},
/* ========================
* 데이터 조회
======================== */
findData : function(){
instance.reloadData();
},
/* ========================
* 데이터 등록
======================== */
addData : function(){
},
/* ========================
* 데이터 수정
======================== */
modifyData : function(){
},
/* ========================
* 데이터 삭제
======================== */
removeData : function(){
var param = $("#frmSearch").serialize();
$.ajax({
url : "/framework/biz/mng/usr/UserRegMng_deletes_proc.do",
data : param,
type : "post",
dataType : "json",
success : function(data) {
alert(data.resp.message);
XitUserRegMng_list.findData();
window.close();
},
error: function(){
}
});
},
/* ========================
* 유효성 검증
======================== */
validate : function(flag){
switch(flag){
case 'delete' :
/* 필수값 설정 */
var dataSet = instance.getData(); //Grid에 출력된 DataSet
var arrCheckedRowKey = instance.getCheckedRowKeys(); //선택한 row의 key값( 선택된 row 정보가 필요 시 "getCheckedRows()" )
// var arrCheckedRow = instance.getCheckedRows(); //선택한 row
];
/* 유효성 확인 */
if(dataSet.length==0){
alert("조회된 결과가 없습니다.");
return false;
const gridOptions = {
el: 'grid',
rowHeaders: [],
columns: gridColumns,
columnOptions: {
frozenCount: 1 //고정컬럼 갯수
, minWidth: 80 //최소 사이즈
}
if(arrCheckedRowKey.length==0) {
alert("선택된 자료가 없습니다.");
return false;
}
break;
}
return true;
},
/* ========================
* 페이지 이동
-외부사이트 링크가 필요 시 사용(내부코드는 각 페이지에 맞게 수정, ex>https://www.gov.kr/portal/main )
======================== */
pageLink: function(flag, url, params){
switch (flag) {
case "move": //페이지 이동
document.frmSearch.searchKeyword.value = "";
document.frmSearch.action = url;
document.frmSearch.submit();
break;
case "popup": //팝업 OPEN
XitUserRegMng_list.pagePopup(flag, url, params);
break;
default:
break;
}
},
/* ========================
* 페이지 Open
-팝업페이지를 Open 한다.
======================== */
pagePopup: function(flag, url, params){
var popUrl = url;
popUrl += "?tilesDef=popup";
if(!(params == undefined || params == null)){
popUrl += "&";
popUrl += params;
}
var popTitle = '';
var popOption = '';
switch (flag) {
case "insert": //등록
popTitle = "사용자 신규등록";
popOption = "width=1100px, height=700px, resizable=no, scrollbars=yes, location=no, top=50px, left=50px";
break;
case "detail": //상세
popTitle = "사용자 상세";
popOption = "width=1100px, height=700px, resizable=no, scrollbars=yes, location=no, top=50px, left=50px";
break;
default:
break;
}
window.open(popUrl, popTitle ,popOption);
},
/* ========================
* 상세 팝업 조회 버튼 클릭
-선택한 신청의 상세 조회 팝업을 OPEN 한다.
======================== */
fnClickRegBtn: function(props){
var rowData = props.grid.getRow(props.rowKey);
var params = "";
params += "selectedId=" + rowData.uniqId;
XitUserRegMng_list.pagePopup('detail', '<c:url value="/framework/biz/mng/usr/UserRegMng_edit.do"/>', params);
}
}
};
const gridDatasource = { //DataSource
/* -----------------------
* DataSource API Setting
----------------------- */
//initialRequest: true, // 화면 load시 조회 안함 - default
api: {
readData: {
url: '<c:url value="/framework/biz/mng/usr/UserRegMng_list.ajax"/>'
, method: 'get'
, serializer: (params) => {
return fnAddPageInfo(document.frmSearch, params);
}
}
}
};
GRID = TuiGrid.of(gridOptions, gridDatasource, (res) => {
console.log('Grid~~~~~~~~~');
});
<%--
/*등록 버튼 Event 설정
등록 팝업을 OPEN 한다.*/
$('#btnRegist').on({
click: function(){
XitUserRegMng_list.pagePopup('insert', '<c:url value="/framework/biz/mng/usr/UserRegMng_input.do"/>');
}
});
//삭제 버튼 Event 설정
$('#btnDelete').on({
click: function(){
if(confirm("삭제하시겠습니까?")){
var checkArr = instance.getCheckedRows();
var checkedIds = "";
checkArr.forEach(function(item, index){
checkedIds += (item.userTy +":"+item.userId);
if(checkArr.length -1 > index){
checkedIds += ",";
}
})
document.frmSearch.checkedIdForDel.value=checkedIds;
XitUserRegMng_list.removeData();
}
}
});
--%>
},
/* ========================
* 데이터 조회
======================== */
findData : function(){
console.log($('#frmSearch').serialize())
GRID.reloadData();
},
/* ========================
* 데이터 등록
======================== */
addData : function(){
},
/* ========================
* 데이터 수정
======================== */
modifyData : function(){
},
/* ========================
* 데이터 삭제
======================== */
removeData : function(){
var param = $("#frmSearch").serialize();
$.ajax({
url : "/framework/biz/mng/usr/UserRegMng_deletes_proc.do",
data : param,
type : "post",
dataType : "json",
success : function(data) {
alert(data.resp.message);
XitUserRegMng_list.findData();
window.close();
},
error: function(){
/* ******************************
* Grid 환경 설정
****************************** */
var GridConfig = new XitTuiGridConfig();
GridConfig.setOptGridId('grid'); //Grid를 출력할 Element ID(해당 Element에 Grid가 출력 됨)
GridConfig.setOptGridHeight(270); //Grid 높이(단위: px)
GridConfig.setOptRowHeight(20); //Grid row 높이(단위: px)
GridConfig.setOptRowHeaderType('checkbox'); //Row 첫번째 Cell 타입(rowNum: 순번, checkbox: 체크박스, '': 아무것도 출력 안함)
GridConfig.setOptPageOptions({ //페이징(Pagination) 옵션
useClient: true //Client Paging 여부(true 설정 시 클라이언트 자체 페이징 처리. 서버호출 X)
,perPage: 10 //페이지당 표시 건수
});
GridConfig.setOptColumnOptions({ //컬럼고정 옵션
});
GridConfig.setOptDataSource({ //DataSource
/* -----------------------
* DataSource Config Setting
* -설정항목은 Global 적용 되며
* -API별 적용을 원할 경우 각 API 안에 작성 가능(우선순위: 개별->글로벌)
----------------------- */
//contentType: 'application/json',
//headers: { 'x-custom-header': 'custom-header' },
initialRequest: true, //디폴트 값은 true(false: 인스턴스 생성 시 요청은 보내지 않음. 이런 경우 "instance.reloadData()"를 사용하여 요청 가능)
//serializer: function(params) {
//return $(document.frmSearch).serialize();
// },
/* -----------------------
* DataSource API Setting
----------------------- */
api: {
readData : {
url: '<c:url value="/framework/biz/mng/usr/UserRegMng_list.ajax"/>', method: 'GET'
,initParams: {}
,serializer: function(params) {
var form = document.frmSearch;
var serializeParam = $(form).serialize();
for(var key in params){
if(key=='perPage'){
if(params[key]==undefined)
serializeParam +='&'+key+'=-1';
else
serializeParam +='&'+key+'='+params[key];
}else
serializeParam +='&'+key+'='+params[key];
}
return serializeParam;
}
}
,createData: { url: '', method: 'POST'}
,updateData: { url: '', method: 'PUT'}
,modifyData: { url: '', method: 'PUT'}
,deleteData: { url: '', method: 'DELETE'}
}
});
GridConfig.setOptHeader({
}); //Grid 헤더 정보(헤더 셀 병합 필요 시 설정)
GridConfig.setOptColumns([ //Grid 컬럼 정보(명칭,매핑 field, 기타옵션 등)
{
header: '번호',
name: 'rowNum',
width: 50,
sortable: false,
align: 'center',
renderer: {
type : RowNumberRenderer
}
},
{
header: '아이디',
name: 'userId',
width: 160,
sortable: true,
sortingType: 'desc',
align: 'center',
renderer: {
type: CustomButtonRenderer,
options: {
formatter : function(props){
var rowData = props.grid.getRow(props.rowKey);
var obj = {
formatter : rowData.userId
,element : "text"
});
},
/* ========================
* 유효성 검증
======================== */
validate : function(flag){
switch(flag){
case 'delete' :
/* 필수값 설정 */
var dataSet = instance.getData(); //Grid에 출력된 DataSet
var arrCheckedRowKey = instance.getCheckedRowKeys(); //선택한 row의 key값( 선택된 row 정보가 필요 시 "getCheckedRows()" )
// var arrCheckedRow = instance.getCheckedRows(); //선택한 row
/* 유효성 확인 */
if(dataSet.length==0){
alert("조회된 결과가 없습니다.");
return false;
}
return obj;
}
,eventFunction: XitUserRegMng_list.fnClickRegBtn
,eventType : "click"
if(arrCheckedRowKey.length==0) {
alert("선택된 자료가 없습니다.");
return false;
}
break;
}
return true;
},
/* ========================
* 페이지 이동
-외부사이트 링크가 필요 시 사용(내부코드는 각 페이지에 맞게 수정, ex>https://www.gov.kr/portal/main )
======================== */
pageLink: function(flag, url, params){
switch (flag) {
case "move": //페이지 이동
document.frmSearch.searchKeyword.value = "";
document.frmSearch.action = url;
document.frmSearch.submit();
break;
case "popup": //팝업 OPEN
XitUserRegMng_list.pagePopup(flag, url, params);
break;
default:
break;
}
},
/* ========================
* 페이지 Open
-팝업페이지를 Open 한다.
======================== */
pagePopup: function(flag, url, params){
var popUrl = url;
popUrl += "?tilesDef=popup";
if(!(params == undefined || params == null)){
popUrl += "&";
popUrl += params;
}
var popTitle = '';
var popOption = '';
switch (flag) {
case "insert": //등록
popTitle = "사용자 신규등록";
popOption = "width=1100px, height=700px, resizable=no, scrollbars=yes, location=no, top=50px, left=50px";
break;
case "detail": //상세
popTitle = "사용자 상세";
popOption = "width=1100px, height=700px, resizable=no, scrollbars=yes, location=no, top=50px, left=50px";
break;
default:
break;
}
window.open(popUrl, popTitle ,popOption);
},
/* ========================
* 상세 팝업 조회 버튼 클릭
-선택한 신청의 상세 조회 팝업을 OPEN 한다.
======================== */
fnClickRegBtn: function(props){
var rowData = props.grid.getRow(props.rowKey);
var params = "";
params += "selectedId=" + rowData.uniqId;
XitUserRegMng_list.pagePopup('detail', '<c:url value="/framework/biz/mng/usr/UserRegMng_edit.do"/>', params);
}
},
{
header: '사용자 이름',
name: 'userNm',
width: 120,
sortable: false,
align: 'center'
},
{
header: '사용자 이메일',
name: 'emailAdres',
minWidth: 160,
sortable: false,
align: 'center'
},
{
header: '전화번호',
name: 'moblphonNo',
width: 120,
sortable: false,
align: 'center'
},
{
header: '등록일',
name: 'sbscrbDe',
width: 150,
sortable: false,
align: 'center'
},
{
header: '가입상태',
name: 'userSttusCode',
width: 110,
sortable: false,
align: 'center'
}
]);
var Grid = tui.Grid;
var instance = GridConfig.instance(Grid); //Grid 인스턴스
/* ********************************************************
* 처리결과메시지 출력
******************************************************** */
<c:if test="${!empty message}">alert("${message}");</c:if>
$(document).ready(function(){
XitUserRegMng_list.init();
});
</script>

Loading…
Cancel
Save