Merge branch 'dev' into dev-xml-parse

main
minuk926 2 years ago
commit f00efe716f

@ -43,6 +43,15 @@ public class BoardCreateMgtController {
}
@RequestMapping(value = "/mngBoardCreateSchPopup")
public ModelAndView mngBoardCreateSchPopup(@RequestParam final Map<String, Object> paraMap){
ModelAndView mav = new ModelAndView();
mav.addAllObjects(paraMap);
mav.addObject("pageTitle","템플릿 조회");
mav.setViewName(FrameworkConstants.FRAMEWORK_JSP_BASE_PATH +"mng/bbs/mngBoardCreateSchPopup.popup");
return mav;
}
@RequestMapping(value = "/mngBoardCreateMgtPopup")
public ModelAndView mngBoardCreateMgtPopup(final XitBbsCreateMngVO vo) {
ModelAndView mav = new ModelAndView();

@ -64,7 +64,7 @@
</div>
</div>
<div id="grid"></div>
<!-- <iframe id="iframe" width="1024" height="500" src="fims/biz/sample/sampleForm2.jsp"></iframe> -->
<div id="bs" style="border:1px solid red; bottom: 0; width:1330px; position: fixed; bottom: 0; z-index: 999; background-color: #cccccc; display: none" >
<div id="bsHeader" style="height: 50px">bottom sheet<button id="bsClose" style="float: right;">close</button></div>

@ -4,11 +4,8 @@
<c:set var="isUpdate" value="${!empty boardMaster.bbsId}"/>
<c:set var="bizName" value="게시판 생성"/>
<script type="text/javascript" src="<c:url value="/framework/util/validator.do"/>"></script>
<validator:javascript formName="boardMaster" staticJavascript="false" xhtml="true" cdata="false"/>
<div class="popup" style="min-width: 100px;">
<div class="popup_inner" style="max-width: 800px;">
<%@include file="/WEB-INF/jsp/framework/biz-popup-title.jsp" %>
@ -108,6 +105,7 @@
<a href="#" id="choiceLink" name="choiceLink">
<img src="<c:url value='/resources/images/img_search.gif' />" width="15" height="15" align="middle" alt="새창"></a>
<form:input path="tmplatId" hidden="true"/>
<form:input path="bbsId" hidden="true"/>
<form:errors path="tmplatId" />
</td>
</tr>
@ -141,6 +139,12 @@
* Global Variable
**************************************************************************/
let orgData;
var callbackSearch = (data) => {
if (data) {
$('#tmplatNm').val(data.tmplatNm);
$('#tmplatId').val(data.tmplatId);
}
};
/* *******************************
* Biz function
@ -158,7 +162,7 @@
if (!fnBiz.validate()) return;
cmmBizAjax('modify', {
url: '<c:url value="/framework/biz/mng/bbs/modifyBoardCreate"/>'
url: '<c:url value="/framework/biz/mng/bbs/modifyBoardCreate.do"/>'
,data: $("#boardMaster").serialize()
});
}
@ -199,6 +203,14 @@
$('#btnRemove').on('click', () => {
fnBiz.remove();
});
$('#choiceLink').on('click', () => {
CmmPopup.open(
'<c:url value="/framework/biz/mng/bbs/mngBoardCreateSchPopup.do"/>'
, {}
, {width: 900, height: 870}
, '프로그램 조회'
);
});
});
/**************************************************************************

@ -1,161 +1,187 @@
<%@ 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"%>
<div class="popup" style="min-width: 100%;">
<div class="popup_inner" style="max-width: 900px;">
<p class="pop_title">템플릿 조회</p>
<script type="text/javascript" src="<c:url value='/resources/framework/js/egov/EgovBBSMng.js' />"></script>
<script type="text/javascript">
function press(event) {
if (event.keyCode==13) {
fn_egov_select_brdMstr('1');
<form name="frmSearch" id="frmSearch">
<div class="search r2">
<table>
<caption>검색조건</caption>
<colgroup>
<col style="width: 350px;">
<col>
<col>
<col>
<col>
<col>
<col>
</colgroup>
<tbody>
<tr>
<td>
<label for="progrmKoreanNm">프로그램 한글명</label>
<input name="progrmKoreanNm" id="progrmKoreanNm" type="text" size="60" value="<c:out value='${progrmKoreanNm}'/>" maxlength="60" title="프로그램명">
</td>
<td colspan="6">
<input type="button" id="btnSearch" class="btn_search" title="검색" value="검색" />
</td>
</tr>
</tbody>
</table>
</div>
</form>
<div class="page_btn">
<span class="fll">
<div class="list clearfix" id="totCnt">전체 ㅣ <span>0</span></div>
</span>
</div>
<div id="grid"></div>
<div class="popup_btn">
<span class="flr p_flr">
<a href="#" class="btn lightgray" onclick="window.close()">닫기</a>
</span>
</div>
</div>
</div>
<script type="text/javaScript">
/**************************************************************************
* Global Variable
**************************************************************************/
let GRID = null;
/* *******************************
* Biz function
******************************* */
const fnBiz = {
search: () => {
GRID.reloadData();
}
,onClickGrid: (ev) => {
const data = ev.grid.getRow(ev.rowKey);
window.opener.callbackSearch(data);
window.close();
}
}
function fn_egov_select_brdMstr(pageNo){
document.frm.pageIndex.value = pageNo;
document.frm.action = "<c:url value='/framework/biz/mng/bbs/BbsCreateMng_choice_popup.do'/>";
document.frm.submit();
}
function fn_egov_select_brdMstrInfo(bbsId, bbsNm){
//리턴값 설정
var obj = new Object();
obj['bbsId'] = bbsId;
obj['bbsNm'] = bbsNm;
//리턴
var callbackMethod = '${param.callback}';
if(callbackMethod==undefined||callbackMethod==null||callbackMethod=='')
callbackMethod = 'showModalDialogCallback';
window.opener[callbackMethod](obj);
window.close();
/**************************************************************************
* event
**************************************************************************/
$(() => {
$('#btnSearch').on('click', () => fnBiz.search());
});
/* *******************************
* Grid
******************************* */
const initGrid = () => {
const gridColumns = [
{
header: '템플릿명',
name: 'tmplatNm',
minWidth: 200,
sortable: true,
sortingType: 'desc',
//align: 'center',
renderer: {
type: CustomButtonRenderer,
options: {
formatter: (props)=>({
formatter: props.grid.getRow(props.rowKey).tmplatNm
,element: "text"
})
,eventFunction: fnBiz.onClickGrid
,eventType: "click"
}
}
},
{
header: '템플릿구분',
name: 'tmplatSeCodeNm',
width: 80,
sortable: false,
align: 'center'
},
{
header: '템플릿경로',
name: 'tmplatCours',
minWidth: 200,
sortable: false,
//align: 'left'
},
{
header: '사용여부',
name: 'useAt',
width: 60,
sortable: false,
align: 'center',
formatter: 'listItemText',
editable: false,
editor: {
type: 'select', //select, radio, checkbox, text
options: {
listItems: [
{value: 'Y', text: '사용'},
{value: 'N', text: '미사용'}
]
}
},
},
{
header: '등록일자',
name: 'frstRegisterPnttm',
width: 160,
sortable: false,
align: 'center',
formatter({value}){
return setDateTimeFmt(value);
}
}
];
const gridOptions = {
el: 'grid',
rowHeaders: ['rowNum'],
columns: gridColumns
};
const gridDatasource = {
initialRequest: true, // 화면 load시 조회 안함 - default
api: {
readData: {
url: '<c:url value="/framework/biz/mng/bbs/findBoardTmpls.do"/>'
,serializer: (params) => {
const schKey = $('#searchCondition').val();
let schValue = $('input[name=searchKeyword]').val();
if(schKey === 'tmplatSeCode') schValue = $('select[name=searchKeyword]').val();
return getPageParam({[schKey]: schValue}, params);
}
}
}
};
GRID = TuiGrid.of(gridOptions, gridDatasource, (res) => {
});
}
/**************************************************************************
* initialize
**************************************************************************/
$(document).ready(function(){
initGrid();
});
</script>
<title>게시판 정보</title>
<style type="text/css">
h1 {font-size:12px;}
caption {visibility:hidden; font-size:0; height:0; margin:0; padding:0; line-height:0;}
</style>
<form name="frm" method="post" action="<c:url value='/framework/biz/mng/bbs/BbsCreateMng_choice_popup.do'/>">
<input type="submit" value="실행" onclick="fn_egov_select_brdMstr('1'); return false;" id="invisible" class="invisible" />
<input type="hidden" name="bbsId" value="">
<!-- 검색 필드 박스 시작 -->
<div id="search_field">
<div id="search_field_loc"><h2><strong>게시판 정보</strong></h2></div>
<fieldset><legend>조건정보 영역</legend>
<div class="sf_start">
<ul id="search_first_ul">
<li>
<label for="searchCnd">검색유형선력</label>
<select name="searchCnd" class="select" title="검색유형선력">
<!-- option selected value=''>--선택하세요--</option-->
<option value="0" <c:if test="${searchVO.searchCnd == '0'}">selected="selected"</c:if> >게시판명</option>
<option value="1" <c:if test="${searchVO.searchCnd == '1'}">selected="selected"</c:if> >게시판유형</option>
</select>
</li>
<li>
<label for="searchWrd" class="invisible">검색어</label>
<input id="searchWrd" name="searchWrd" type="text" size="35" value='<c:out value="${searchVO.searchWrd}"/>' maxlength="35" onkeypress="press(event);">
</li>
</ul>
<ul id="search_second_ul">
<li>
<div class="buttons" style="float:right;">
<a href="<c:url value='/framework/biz/mng/bbs/BbsCreateMng_choice_popup.do'/>" onclick="javascript:fn_egov_select_brdMstr('1'); return false;"><img src="<c:url value='/resources/images/img_search.gif'/>" alt="search" />조회 </a>
</div>
</li>
</ul>
</div>
</fieldset>
</div>
<!-- //검색 필드 박스 끝 -->
<div id="page_info"><div id="page_info_align"></div></div>
<!-- table add start -->
<div class="default_tablestyle">
<table cellpadding="0" cellspacing="0">
<caption>게시판정보</caption>
<colgroup>
<col width="10%" >
<col width="36%" >
<col width="10%" >
<col width="10%" >
<col width="15%" >
<col width="8%" >
<col width="8%" >
</colgroup>
<thead>
<tr>
<th scope="col" class="f_field" nowrap="nowrap">번호</th>
<th scope="col" nowrap="nowrap">게시판명</th>
<th scope="col" nowrap="nowrap">게시판유형</th>
<th scope="col" nowrap="nowrap">게시판속성</th>
<th scope="col" nowrap="nowrap">생성일</th>
<th scope="col" nowrap="nowrap">사용여부</th>
<th scope="col" nowrap="nowrap">선택</th>
</tr>
</thead>
<tbody>
<c:forEach var="result" items="${resultList}" varStatus="status">
<!-- loop 시작 -->
<tr>
<!--td class="lt_text3" nowrap="nowrap"><input type="checkbox" name="check1" class="check2"></td-->
<td nowrap="nowrap"><strong><c:out value="${(searchVO.pageIndex-1) * searchVO.pageSize + status.count}"/></strong></td>
<td nowrap="nowrap">
<c:out value="${result.bbsNm}"/>
</td>
<td nowrap="nowrap"><c:out value="${result.bbsTyCodeNm}"/></td>
<td nowrap="nowrap"><c:out value="${result.bbsAttrbCodeNm}"/></td>
<td nowrap="nowrap"><c:out value="${result.frstRegisterPnttm}"/></td>
<td nowrap="nowrap">
<c:if test="${result.useAt == 'N'}"><spring:message code="button.notUsed" /></c:if>
<c:if test="${result.useAt == 'Y'}"><spring:message code="button.use" /></c:if>
</td>
<td nowrap="nowrap">
<input type="button" value="선택"
onClick="javascript:fn_egov_select_brdMstrInfo('<c:out value="${result.bbsId}"/>','<c:out value="${result.bbsNm}"/>');" />
</td>
</tr>
</c:forEach>
<c:if test="${fn:length(resultList) == 0}">
<tr>
<td nowrap colspan="7" ><spring:message code="common.nodata.msg" /></td>
</tr>
</c:if>
</tbody>
</table>
</div>
<!-- 페이지 네비게이션 시작 -->
<div id="paging_div">
<ul class="paging_align">
<ui:pagination paginationInfo = "${paginationInfo}" type="image" jsFunction="fn_egov_select_brdMstr" />
</ul>
</div>
<!-- //페이지 네비게이션 끝 -->
<input name="pageIndex" type="hidden" value="<c:out value='${searchVO.pageIndex}'/>"/>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td height="10"></td>
</tr>
</table>
<div class="buttons" align="center" >
<table border="0" cellspacing="0" cellpadding="0" align="center">
<tr>
<td><a href="#LINK" onclick="javascript:parent.close(); return false;">닫기</a></td>
</tr>
</table>
</div>
</form>

Loading…
Cancel
Save