refactor:자주쓰는의견 등록 완료 / 수정 진행중

This commit is contained in:
hylee 2022-10-18 16:12:53 +09:00
parent 303e3682c8
commit 59fe222962
9 changed files with 352 additions and 162 deletions

View File

@ -163,6 +163,7 @@ public class ExmpAppManagerController {
result = fileUtil.parseFileInf(files, "Exmp_" , 0, atchFileId, "", ""); result = fileUtil.parseFileInf(files, "Exmp_" , 0, atchFileId, "", "");
atchFileId = fileMngService.insertFileInfs(result); atchFileId = fileMngService.insertFileInfs(result);
} }
exmpManageVO.setAtchFileId(atchFileId); exmpManageVO.setAtchFileId(atchFileId);
exmpManageVO.setFrstRegisterId(loginVO.getUniqId()); exmpManageVO.setFrstRegisterId(loginVO.getUniqId());
return ResponseEntity.ok().body(exmpAppManageService.insertExmpAppManager(exmpManageVO)); return ResponseEntity.ok().body(exmpAppManageService.insertExmpAppManager(exmpManageVO));

View File

@ -18,6 +18,8 @@ import org.springframework.web.bind.annotation.RequestMethod;
import egovframework.rte.fdl.security.userdetails.util.EgovUserDetailsHelper; import egovframework.rte.fdl.security.userdetails.util.EgovUserDetailsHelper;
import egovframework.rte.ptl.mvc.tags.ui.pagination.PaginationInfo; import egovframework.rte.ptl.mvc.tags.ui.pagination.PaginationInfo;
import kcc.com.cmm.LoginVO; import kcc.com.cmm.LoginVO;
import kcc.kccadr.adjPgrMgr.exmp.app.service.ExmpAppManageService;
import kcc.kccadr.adjPgrMgr.exmp.cmm.ExmpManageVO;
import kcc.kccadr.adjcclt.opinion.service.AdjstOpinionService; import kcc.kccadr.adjcclt.opinion.service.AdjstOpinionService;
import kcc.kccadr.adjcclt.opinion.service.AdjstOpinionVO; import kcc.kccadr.adjcclt.opinion.service.AdjstOpinionVO;
import kcc.kccadr.adjcclt.service.AdjstConciliatorVO; import kcc.kccadr.adjcclt.service.AdjstConciliatorVO;
@ -44,7 +46,9 @@ public class AdjstOpinionController {
@Resource(name = "adjstOpinionService") @Resource(name = "adjstOpinionService")
private AdjstOpinionService adjstOpinionService; private AdjstOpinionService adjstOpinionService;
@Resource(name = "ExmpAppManageService")
private ExmpAppManageService exmpAppManageService;
// @RequestMapping(value = {"/web/kccadr/adjcclt/ai/adjstOpinionList.do"}, method = RequestMethod.POST) // @RequestMapping(value = {"/web/kccadr/adjcclt/ai/adjstOpinionList.do"}, method = RequestMethod.POST)
// public ResponseEntity<RestResponse> adjstFindByOpinion(HttpServletRequest request , @RequestBody AdjstOpinionVO adjstOpinionVO) throws Exception { // public ResponseEntity<RestResponse> adjstFindByOpinion(HttpServletRequest request , @RequestBody AdjstOpinionVO adjstOpinionVO) throws Exception {
@ -52,46 +56,38 @@ public class AdjstOpinionController {
// } // }
@RequestMapping("/web/kccadr/adjcclt/ai/adjstOpinionList.do") @RequestMapping("/web/kccadr/adjcclt/ai/adjstOpinionList.do")
public String adjstOpinionList(@ModelAttribute("adjstOpinionVO") AdjstOpinionVO adjstOpinionVO, ModelMap model) throws Exception public String adjstOpinionList(@ModelAttribute("exmpManageVO") ExmpManageVO exmpManageVO, ModelMap model) throws Exception
{ {
String auth = EgovUserDetailsHelper.isAuthenticated() ? null : EgovUserDetailsHelper.getAuthenticatedUser().toString(); LoginVO loginVO = (LoginVO) EgovUserDetailsHelper.getAuthenticatedUser();
LoginVO loginVO = "anonymousUser".equals(auth) ? null : (LoginVO)EgovUserDetailsHelper.getAuthenticatedUser();
if (loginVO == null) {
model.addAttribute("msg", "로그인 해주세요."); exmpManageVO.setFrstRegisterId(loginVO.getUniqId());
return "redirect:/web/user/login/ssoLogin.do"; if(exmpManageVO.getPageUnit() != 10) {
} exmpManageVO.setPageUnit(exmpManageVO.getPageUnit());
logger.info(" + loginVO.getName() :: [{}]", loginVO.getName()); }
// adjstOpinionVO.setFrstRegisterId(loginVO.getUniqId());
// if(adjstOpinionVO.getPageUnit() != 10) { if("".equals(exmpManageVO.getSearchSortCnd())){ //최초조회시 최신것 조회List
// adjstOpinionVO.setPageUnit(adjstOpinionVO.getPageUnit()); // exmpManageVO.setSearchSortCnd("T1.Exmp_CC_TY");
// } // exmpManageVO.setSearchSortOrd("asc");
// }
// if("".equals(adjstOpinionVO.getSearchSortCnd())){ //최초조회시 최신것 조회List System.out.println("exmpManageVO.getSearchCondition() :: "+exmpManageVO.getSearchCondition());
// adjstOpinionVO.setSearchSortCnd("RS.ADR_SEQ");
// adjstOpinionVO.setSearchSortOrd("desc"); /** paging */
// } PaginationInfo paginationInfo = new PaginationInfo();
paginationInfo.setCurrentPageNo(exmpManageVO.getPageIndex());
paginationInfo.setRecordCountPerPage(exmpManageVO.getPageUnit());
paginationInfo.setPageSize(exmpManageVO.getPageSize());
/** paging */ exmpManageVO.setFirstIndex(paginationInfo.getFirstRecordIndex());
PaginationInfo paginationInfo = new PaginationInfo(); exmpManageVO.setLastIndex(paginationInfo.getLastRecordIndex());
paginationInfo.setCurrentPageNo(adjstOpinionVO.getPageIndex()); exmpManageVO.setRecordCountPerPage(paginationInfo.getRecordCountPerPage());
paginationInfo.setRecordCountPerPage(adjstOpinionVO.getPageUnit());
paginationInfo.setPageSize(adjstOpinionVO.getPageSize()); // 의견 코드
exmpManageVO.setExmpCd("03");
adjstOpinionVO.setFirstIndex(paginationInfo.getFirstRecordIndex());
adjstOpinionVO.setLastIndex(paginationInfo.getLastRecordIndex()); paginationInfo.setTotalRecordCount(exmpAppManageService.selectExmpOpinionsManagerCount(exmpManageVO));
adjstOpinionVO.setRecordCountPerPage(paginationInfo.getRecordCountPerPage()); model.addAttribute("paginationInfo", paginationInfo);
model.addAttribute("list", exmpAppManageService.selectExmpOpinionsManagerList(exmpManageVO));
// paginationInfo.setTotalRecordCount(adjstOpinionService.selectAdjstOpinionListCount(adjstOpinionVO));
model.addAttribute("paginationInfo", paginationInfo);
// List<AdjstOpinionVO> list = adjstOpinionService.selectAdjstOpinionList(adjstOpinionVO);
// decryptInfomation(list, null);
// model.addAttribute("list", list);
return "/web/kccadr/adjcclt/opinion/adjstOpinionList"; return "/web/kccadr/adjcclt/opinion/adjstOpinionList";
} }

View File

@ -6,6 +6,7 @@ import java.time.format.TextStyle;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List; import java.util.List;
import java.util.Locale; import java.util.Locale;
import java.util.Map;
import javax.annotation.Resource; import javax.annotation.Resource;
import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletRequest;
@ -14,12 +15,15 @@ import org.apache.commons.collections.CollectionUtils;
import org.apache.commons.lang3.StringUtils; import org.apache.commons.lang3.StringUtils;
import org.slf4j.Logger; import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
import org.springframework.http.ResponseEntity;
import org.springframework.stereotype.Controller; import org.springframework.stereotype.Controller;
import org.springframework.ui.ModelMap; import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.ModelAttribute; import org.springframework.web.bind.annotation.ModelAttribute;
import org.springframework.web.bind.annotation.RequestBody; import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod; import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.multipart.MultipartFile;
import org.springframework.web.multipart.MultipartHttpServletRequest; import org.springframework.web.multipart.MultipartHttpServletRequest;
import org.springframework.web.servlet.ModelAndView; import org.springframework.web.servlet.ModelAndView;
import org.springframework.web.servlet.mvc.support.RedirectAttributes; import org.springframework.web.servlet.mvc.support.RedirectAttributes;
@ -49,6 +53,7 @@ import kcc.kccadr.adjcclt.service.AdjstConciliatorVO;
import kcc.kccadr.adjreqmgr.service.AdjReqMgrVO; import kcc.kccadr.adjreqmgr.service.AdjReqMgrVO;
import kcc.kccadr.cmm.CmmUtil; import kcc.kccadr.cmm.CmmUtil;
import kcc.kccadr.cmm.KccadrConstants; import kcc.kccadr.cmm.KccadrConstants;
import kcc.kccadr.cmm.RestResponse;
import kcc.kccadr.kccadrCom.service.KccadrMgrUdtService; import kcc.kccadr.kccadrCom.service.KccadrMgrUdtService;
import kcc.kccadr.ojct.service.OjctService; import kcc.kccadr.ojct.service.OjctService;
import kcc.kccadr.ojct.service.OjctVO; import kcc.kccadr.ojct.service.OjctVO;
@ -411,10 +416,47 @@ public class AdjstConciliatorController {
*/ */
@RequestMapping("/web/kccadr/adjcclt/popup/adjstOpinionsRegistPopList.do") @RequestMapping("/web/kccadr/adjcclt/popup/adjstOpinionsRegistPopList.do")
public String adjstOpinionsRegistPopList(@ModelAttribute("adjstConciliatorVO") AdjstConciliatorVO adjstConciliatorVO, ModelMap model) throws Exception { public String adjstOpinionsRegistPopList(@ModelAttribute("adjstConciliatorVO") AdjstConciliatorVO adjstConciliatorVO, ModelMap model) throws Exception {
// model.addAttribute("info", adjstConciliatorService.selectAdjstRecommendationCommentDetail(adjstConciliatorVO));
return "/web/kccadr/adjcclt/popup/adjstOpinionsRegistPopList"; return "/web/kccadr/adjcclt/popup/adjstOpinionsRegistPopList";
} }
/**
* 의견관리 목록 > 자주쓰는 의견 상세 팝업
*/
@RequestMapping("/web/kccadr/adjcclt/popup/adjstOpinionsRegistPopDetail.do")
public String opinionsRegistAdjstPopDetail(@ModelAttribute("exmpManageVO") ExmpManageVO exmpManageVO, ModelMap model) throws Exception {
System.out.println(" + exmpManageVO :: "+ exmpManageVO.getExmpMgrId());
model.addAttribute("dataInfo", exmpAppManageService.selectExmpAppManagerInfo(exmpManageVO));
return "/web/kccadr/adjcclt/popup/adjstOpinionsRegistPopDetail";
}
@RequestMapping(value="/web/kccadr/adjcclt/insertExmpOpinionsAjax.do")
public ResponseEntity<RestResponse> insertExmpAppManager(ExmpManageVO exmpManageVO) throws Exception {
LoginVO loginVO = (LoginVO) EgovUserDetailsHelper.getAuthenticatedUser();
exmpManageVO.setFrstRegisterId(loginVO.getUniqId());
return ResponseEntity.ok().body(exmpAppManageService.insertExmpAppManager(exmpManageVO));
}
/*
@RequestMapping(value="/web/kccadr/adjcclt/insertExmpOpinionsAjax.do")
public ModelAndView insertExmpAppManager(ExmpManageVO exmpManageVO) throws Exception {
ModelAndView modelAndView = new ModelAndView();
modelAndView.setViewName("jsonView");
LoginVO loginVO = (LoginVO) EgovUserDetailsHelper.getAuthenticatedUser();
System.out.println("exmpManageVO.getExmpCd : " + exmpManageVO.getExmpCd());
System.out.println("exmpManageVO.getCcTy : " + exmpManageVO.getExmpCcTy());
System.out.println("exmpManageVO.getExmpCn : " + exmpManageVO.getExmpCn());
exmpManageVO.setFrstRegisterId(loginVO.getUniqId());
exmpAppManageService.insertExmpAppManager(exmpManageVO);
return modelAndView;
}*/
/** /**
* 조정사건 목록 화면 * 조정사건 목록 화면
*/ */

View File

@ -112,7 +112,12 @@
AND T1.EXMP_CC_TY = #searchCondition# AND T1.EXMP_CC_TY = #searchCondition#
</isNotEmpty> </isNotEmpty>
</isNotEmpty> </isNotEmpty>
ORDER BY 1=1
<isNotEmpty prepend="AND" property="frstRegisterId">
T1.FRST_REGISTER_ID = #frstRegisterId#
</isNotEmpty>
ORDER BY T1.FRST_REGIST_PNTTM DESC
<!-- <isNotEmpty property="searchSortCnd"> --> <!-- <isNotEmpty property="searchSortCnd"> -->
<!-- ,$searchSortCnd$ --> <!-- ,$searchSortCnd$ -->
<!-- </isNotEmpty> --> <!-- </isNotEmpty> -->

View File

@ -32,7 +32,7 @@
function linkPage(pageNo){ function linkPage(pageNo){
var listForm = document.listForm ; var listForm = document.listForm ;
listForm.pageIndex.value = pageNo ; listForm.pageIndex.value = pageNo ;
listForm.action = "<c:url value='/web/kccadr/adjcclt/ai/adjstConciliatorList.do'/>"; listForm.action = "<c:url value='/web/kccadr/adjcclt/ai/adjstOpinionList.do'/>";
listForm.submit(); listForm.submit();
} }
@ -49,12 +49,13 @@
</head> </head>
<body> <body>
<form:form id="listForm" name="listForm" commandName="adjstOpinionVO" onsubmit="return false;" method="post"> <form:form id="listForm" name="listForm" commandName="adjstOpinionVO" onsubmit="return false;" method="post">
<input type="hidden" name="pageIndex" value="<c:out value='${adjstOpinionVO.pageIndex}' default='1' />"/> <input type="hidden" name="pageIndex" value="<c:out value='${adjstOpinionVO.pageIndex}' default='1' />"/>
<input type="hidden" name="searchSortCnd" value="<c:out value="${adjstOpinionVO.searchSortCnd}" />" /> <input type="hidden" name="searchSortCnd" value="<c:out value="${adjstOpinionVO.searchSortCnd}" />" />
<input type="hidden" name="searchSortOrd" value="<c:out value="${adjstOpinionVO.searchSortOrd}" />" /> <input type="hidden" name="searchSortOrd" value="<c:out value="${adjstOpinionVO.searchSortOrd}" />" />
<input type="hidden" name="searchStatus" value="<c:out value="${adjstOpinionVO.searchStatus}" />" /> <input type="hidden" name="searchStatus" value="<c:out value="${adjstOpinionVO.searchStatus}" />" />
<input type="hidden" name="adrSeq" value="" /> <input type="hidden" name="adrSeq" value="" />
<input type="hidden" name="adrSn" value="" /> <input type="hidden" name="adrSn" value="" />
</form:form>
<!-- cont --> <!-- cont -->
<div class="cont_wrap sub02_1" id="sub"> <div class="cont_wrap sub02_1" id="sub">
@ -62,46 +63,15 @@
<div class="cont_tit"> <div class="cont_tit">
<h2>자주쓰는의견 목록</h2> <h2>자주쓰는의견 목록</h2>
</div> </div>
<div class="list_top">
<!-- <p>총 건수 : <span>204</span>건</p> --> <!-- <p>총 건수 : <span>204</span>건</p> -->
<div class="list_util"> <div class="list_top">
<label for="searchCondition">검색조건 선택</label> <div class="list_util">
<select name="searchCondition" id="searchCondition" class="subSearch"> <label for="searchCondition">검색조건 선택</label>
<option value="1" ${adjstConciliatorVO.searchCondition eq '1' ? 'selected' : '' }>조정번호</option> <kc:select codeId="CC045" skipCd="10,50,70,80" name="searchCondition" id="searchCondition" defaultValue="" defaultText="전체" selectedValue="${exmpManageVO.searchCondition}"/>
<option value="2" ${adjstConciliatorVO.searchCondition eq '2' ? 'selected' : '' }>접수기간</option> <label for="searchKeyword">검색 조건 입력</label>
<option value="3" ${adjstConciliatorVO.searchCondition eq '3' ? 'selected' : '' }>신청인명</option> <input type="text" name="searchKeyword" id="searchKeyword" value="<c:out value='${exmpManageVO.searchKeyword}' />" placeholder="검색 조건 입력" size="20">
<option value="4" ${adjstConciliatorVO.searchCondition eq '4' ? 'selected' : '' }>피신청인명</option> <button type="button" class="btnType07" onclick="fncGoList(); return false;">검색</button>
<option value="5" ${adjstConciliatorVO.searchCondition eq '5' ? 'selected' : '' }>신청내용</option> </div>
<option value="6" ${adjstConciliatorVO.searchCondition eq '6' ? 'selected' : '' }>조정상태</option>
</select>
<div class="sel_date">
<div class="calendar_wrap">
<input type="text" class="searchStartDt startDate inp" title="검색시작일" id="searchStartDt" name="searchStartDt" onclick="return calendarOpen('searchStartDt-lry','',this)" onfocus="return calendarOpen('searchStartDt-lry','',this)" value="${adjstConciliatorVO.searchStartDt}" data-datecontrol="true">
<button type="button" title="달력 팝업 열기" class="btn_start btn_cal" onclick="return calendarOpen('searchStartDt-lry','',this)"><i></i></button>
</div>
<!-- <div class="calendar_in" id="calendarName_startDate" style="z-index: 9;">
<button type="button" value="달력 팝업 열기" onclick="return calendarOpen('searchStartDt-lry','',this)" class="btn_cal"></button>
<div id="searchStartDt-lry" class="calendarPop" style="display: none;">
<iframe id="searchStartDt-ifrm" name="searchStartDt-ifrm" class="calendar-frame" src="/kccadrPb/usr/mini_calendar.html" title="달력 팝업" frameborder="0" scrolling="no"></iframe>
</div>
</div> --> ~
<div class="calendar_wrap">
<input type="text" class="searchEndDt endDate inp" title="검색종료일" id="searchEndDt" name="searchEndDt" onclick="return calendarOpen2('searchEndDt-lry','',this)" onfocus="return calendarOpen2('searchEndDt-lry','',this)" value="${adjstConciliatorVO.searchEndDt}" data-datecontrol="true">
<button type="button" title="달력 팝업 열기" class="btn_end btn_cal" onclick="return calendarOpen2('searchEndDt-lry','',this)"><i></i></button>
</div>
<!-- <div class="calendar_in" id="calendarName_endDate" style="z-index: 9;">
<button type="button" value="달력 팝업 열기" onclick="return calendarOpen('searchEndDt-lry','',this)" class="btn_cal"></button>
<div id="searchEndDt-lry" class="calendarPop" style="display: none;">
<iframe id="searchEndDt-ifrm" name="searchEndDt-ifrm" class="calendar-frame" src="/kccadrPb/usr/mini_calendar.html" title=" 달력 팝업" frameborder="0" scrolling="no"></iframe>
</div>
</div> -->
</div>
<div class="input_wrap">
<label for="searchKeyword">검색어 입력</label>
<input type="text" class="search_input" id=searchKeyword name="searchKeyword" placeholder="검색어를 입력하세요" value="<c:out value='${adjstConciliatorVO.searchKeyword}'/>">
</div>
<button type="button" class="btn_search" onclick="fncGoList();">검색</button>
</div>
</div> </div>
<!-- //list_top --> <!-- //list_top -->
@ -123,26 +93,25 @@
</tr> </tr>
</thead> </thead>
<tbody> <tbody>
<%-- <c:forEach var="list" items="${list}" varStatus="status"> --%> <c:forEach var="list" items="${list}" varStatus="status">
<tr> <tr>
<td class="td_date"> <td class="td_date">
<%-- <p><c:out value="${list.sbmtDe}"/></p> --%> <p><c:out value="${list.frstRegistPnttm}"/></p>
2022-09-30
</td> </td>
<td> <td>
<a href="#none" onclick="">유형</a> <kc:code codeId="CC045" code="${list.exmpCcTy}"/>
</td> </td>
<td> <td>
<a href="#none" onclick="">내용</a> <a href="#none" onclick="javascript:AdjstReq.opinionsRegistAdjstPopDetail('${list.exmpMgrId }');"><c:out value="${list.exmpCn}" /></a>
</td> </td>
<td> <td>
삭제버튼 <button type="button" class="btnType01">삭제</button>
</td> </td>
</tr> </tr>
<%-- </c:forEach> --%> </c:forEach>
<%-- <c:if test="${empty list}"> --%> <c:if test="${empty list}">
<%-- <tr><td colspan="10"><spring:message code="common.nodata.msg" /></td></tr> --%> <tr><td colspan="4"><spring:message code="common.nodata.msg" /></td></tr>
<%-- </c:if> --%> </c:if>
</tbody> </tbody>
</table> </table>
</div> </div>
@ -160,7 +129,6 @@
</div> </div>
<!-- //page --> <!-- //page -->
</div> </div>
</form:form>
</div> </div>
</body> </body>
</html> </html>

View File

@ -70,12 +70,14 @@ $(document).ready(function(){
<p>자주쓰는 의견 목록</p> <button class="btn_popup_close tooltip-close" data-focus="opinion_popup_close" title="팝업 닫기"><i></i></button> <p>자주쓰는 의견 목록</p> <button class="btn_popup_close tooltip-close" data-focus="opinion_popup_close" title="팝업 닫기"><i></i></button>
</div> </div>
<div class="popup_cont"> <div class="popup_cont">
<div class="popup_search"> <div class="list_top">
<label for="searchCondition">검색조건 선택</label> <div class="list_util">
<kc:select codeId="CC045" skipCd="10,50,70,80" name="searchCondition" id="searchCondition" defaultValue="" defaultText="전체" selectedValue="${exmpManageVO.searchCondition}"/> <label for="searchCondition">검색조건 선택</label>
<label for="searchKeyword">검색 조건 입력</label> <kc:select codeId="CC045" skipCd="10,50,70,80" name="searchCondition" id="searchCondition" defaultValue="" defaultText="전체" selectedValue="${exmpManageVO.searchCondition}"/>
<input type="text" name="searchKeyword" id="searchKeyword" value="<c:out value='${exmpManageVO.searchKeyword}' />" placeholder="검색 조건 입력" size="20"> <label for="searchKeyword">검색 조건 입력</label>
<button type="button" class="btnType07" onclick="fncGoList(); return false;">검색</button> <input type="text" name="searchKeyword" id="searchKeyword" value="<c:out value='${exmpManageVO.searchKeyword}' />" placeholder="검색 조건 입력" size="20">
<button type="button" class="btnType07" onclick="fncGoList(); return false;">검색</button>
</div>
</div> </div>
<table class="popup_list"> <table class="popup_list">

View File

@ -0,0 +1,129 @@
<%@ page contentType="text/html; charset=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="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>
<%@ taglib prefix="kc" uri="/WEB-INF/tlds/kcc_tld.tld"%>
<!DOCTYPE html>
<html lang="ko">
<head>
<title>자주쓰는 의견 상세</title>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<script type="text/javascript" src="/kccadrPb/usr/script/popup.js"></script>
<script type="text/javaScript" language="javascript">
$(document).ready(function(){
// 레이어팝업 포커싱 이동 수정
$(".tooltip-close").click(function(){
var activeTarget = $('[data-tooltip-con="opinion_regi_popup"]');
activeTarget.hide();
$('[data-tooltip="opinion_regi_popup"]').focus();
});
// 레이어팝업 포커싱 이동 수정
$("#regBtn").click(function(){
if($('#exmpCcTy').val() == '')
{
alert("유형을 선택해 주세요");
return false;
}
if($('#exmpCn').val() == '')
{
alert("내용을 입력해 주세요");
$('#exmpCn').focus();
return false;
}
if(confirm("등록하시겠습니까?"))
{
// var data = {
// exmpCcTy : $("#exmpCcTy").val()
// , exmpCd : '30'
// , exmpCn : $("#exmpCn").val()
// }
var data = new FormData(document.createForm);
$.ajax({
type:"POST",
url: "/web/kccadr/adjcclt/insertExmpOpinionsAjax.do",
data: data,
dataType:'json',
async: false,
processData: false,
contentType: false,
cache: false,
success:function(returnData){
if(returnData.status == "OK"){
alert(returnData.data);
window.location.reload();
}else{
alert(returnData.data);
}
},
error:function(request , status, error){
console.log('request : ', request);
console.log('status : ', status);
console.log('error : ', error);
}
});
}
});
});
</script>
<style type="text/css">
.btn_wrap .btnType07 {vertical-align:middle;}
</style>
</head>
<body>
<form name="createForm" id="createForm">
<input type="hidden" id="exmpCd" name="exmpCd" value="03">
<!-- 일정 상세 -->
<div class="popup_wrap opinion_regi_popup" tabindex="0" data-tooltip-con="opinion_regi_popup" data-focus="opinion_regi_popup" data-focus-prev="opinion_regi_popup_close">
<div class="popup_tit">
<p>자주쓰는 의견 상세</p> <button class="btn_popup_close tooltip-close" data-focus="opinion_regi_popup_close" title="팝업 닫기"><i></i></button>
</div>
<div class="popup_cont">
<table class="popup_tbType01">
<colgroup>
<col style="width:100px;" />
<col style="width:auto;" />
</colgroup>
<tbody>
<tr>
<td>유형</td>
<td>
<kc:select codeId="CC045" skipCd="10,50,70,80" id="exmpCcTy" name="exmpCcTy" defaultValue="" defaultText="선택" selectedValue="${dataInfo.exmpCcTy}"/>
</td>
</tr>
<!-- <tr> -->
<!-- <td>제목</td> -->
<!-- <td> -->
<!-- <input type="text" name="" id="" /> -->
<!-- </td> -->
<!-- </tr> -->
<tr>
<td>내용</td>
<td>
<textarea id="exmpCn" name="exmpCn" rows="5"><c:out value="${dataInfo.exmpCn}" /> </textarea>
</td>
</tr>
</tbody>
</table>
<div class="btn_wrap">
<button class="btnType07" id="regBtn">저장</button>
<button class="btnType01 tooltip-close" data-focus="opinion_regi_popup_close" data-focus-next="opinion_regi_popup">닫기</button>
</div>
</div>
</div>
</form>
</body>
</html>

View File

@ -15,19 +15,7 @@
<script type="text/javascript" src="/kccadrPb/usr/script/popup.js"></script> <script type="text/javascript" src="/kccadrPb/usr/script/popup.js"></script>
<script type="text/javaScript" language="javascript"> <script type="text/javaScript" language="javascript">
function fncGoList(){
linkPage(1);
}
function linkPage(pageNo){
var data = {
pageIndex : pageNo,
searchKeyword : $("#searchKeyword").val(),
searchCondition : $("#searchCondition").val(),
pageUnit : 5,
}
AdjstReq.historyAdjstPopList(data);
}
$(document).ready(function(){ $(document).ready(function(){
@ -38,6 +26,56 @@ $(document).ready(function(){
$('[data-tooltip="opinion_regi_popup"]').focus(); $('[data-tooltip="opinion_regi_popup"]').focus();
}); });
// 레이어팝업 포커싱 이동 수정
$("#regBtn").click(function(){
if($('#exmpCcTy').val() == '')
{
alert("유형을 선택해 주세요");
return false;
}
if($('#exmpCn').val() == '')
{
alert("내용을 입력해 주세요");
$('#exmpCn').focus();
return false;
}
if(confirm("등록하시겠습니까?"))
{
// var data = {
// exmpCcTy : $("#exmpCcTy").val()
// , exmpCd : '30'
// , exmpCn : $("#exmpCn").val()
// }
var data = new FormData(document.createForm);
$.ajax({
type:"POST",
url: "/web/kccadr/adjcclt/insertExmpOpinionsAjax.do",
data: data,
dataType:'json',
async: false,
processData: false,
contentType: false,
cache: false,
success:function(returnData){
if(returnData.status == "OK"){
alert(returnData.data);
window.location.reload();
}else{
alert(returnData.data);
}
},
error:function(request , status, error){
console.log('request : ', request);
console.log('status : ', status);
console.log('error : ', error);
}
});
}
});
}); });
</script> </script>
<style type="text/css"> <style type="text/css">
@ -45,55 +83,47 @@ $(document).ready(function(){
</style> </style>
</head> </head>
<body> <body>
<form name="createForm" id="createForm">
<input type="hidden" id="exmpCd" name="exmpCd" value="03">
<!-- 일정 상세 --> <!-- 일정 상세 -->
<form:form commandName="adjstReqVO" id="popList" name="popList" method="post" onsubmit="return false;"> <div class="popup_wrap opinion_regi_popup" tabindex="0" data-tooltip-con="opinion_regi_popup" data-focus="opinion_regi_popup" data-focus-prev="opinion_regi_popup_close">
<input type="hidden" name="pageIndex" value="<c:out value='${adjstReqVO.pageIndex}' default='1' />"/> <div class="popup_tit">
<input type="hidden" name="searchSortCnd" value="<c:out value="${adjstReqVO.searchSortCnd}" />" /> <p>자주쓰는 의견 등록</p> <button class="btn_popup_close tooltip-close" data-focus="opinion_regi_popup_close" title="팝업 닫기"><i></i></button>
<input type="hidden" name="searchSortOrd" value="<c:out value="${adjstReqVO.searchSortOrd}" />" /> </div>
</form:form> <div class="popup_cont">
<div class="popup_wrap opinion_regi_popup" tabindex="0" data-tooltip-con="opinion_regi_popup" data-focus="opinion_regi_popup" data-focus-prev="opinion_regi_popup_close"> <table class="popup_tbType01">
<div class="popup_tit"> <colgroup>
<p>자주쓰는 의견 등록</p> <button class="btn_popup_close tooltip-close" data-focus="opinion_regi_popup_close" title="팝업 닫기"><i></i></button> <col style="width:100px;" />
</div> <col style="width:auto;" />
<div class="popup_cont"> </colgroup>
<table class="popup_tbType01"> <tbody>
<colgroup> <tr>
<col style="width:100px;" /> <td>유형</td>
<col style="width:auto;" /> <td>
</colgroup> <kc:select codeId="CC045" skipCd="10,50,70,80" id="exmpCcTy" name="exmpCcTy" defaultValue="" defaultText="선택" selectedValue="${exmpManageVO.searchCondition}"/>
<tbody> </td>
<tr> </tr>
<td>유형</td> <!-- <tr> -->
<td> <!-- <td>제목</td> -->
<select name="" id=""> <!-- <td> -->
<option value="">기일조서</option> <!-- <input type="text" name="" id="" /> -->
<option value="">조정권고안</option> <!-- </td> -->
<option value="">조정조서</option> <!-- </tr> -->
<option value="">직권조정결정서</option> <tr>
</select> <td>내용</td>
</td> <td>
</tr> <textarea id="exmpCn" name="exmpCn" rows="5"></textarea>
<tr> </td>
<td>제목</td> </tr>
<td> </tbody>
<input type="text" name="" id="" /> </table>
</td>
</tr> <div class="btn_wrap">
<tr> <button class="btnType07" id="regBtn">저장</button>
<td>제목</td> <button class="btnType01 tooltip-close" data-focus="opinion_regi_popup_close" data-focus-next="opinion_regi_popup">닫기</button>
<td> </div>
<textarea name="" id="" rows="5"></textarea> </div>
</td> </div>
</tr> </form>
</tbody>
</table>
<div class="btn_wrap">
<button class="btnType07">저장</button>
<button class="btnType01 tooltip-close" data-focus="opinion_regi_popup_close" data-focus-next="opinion_regi_popup">닫기</button>
</div>
</div>
</div>
</body> </body>
</html> </html>

View File

@ -1261,6 +1261,23 @@ var AdjstReq = {
, "adjstOpinionsRegistPop" , "adjstOpinionsRegistPop"
); );
}, },
opinionsRegistAdjstPopDetail : function(param){
console.log(' param : ', param);
var paramObj = {
exmpMgrId : param
};
// 이전신청데이터 팝업 호출..
commonPopLayeropen(
"/web/kccadr/adjcclt/popup/adjstOpinionsRegistPopDetail.do"
, 1000
, 700
, paramObj
, "N"
, "adjstOpinionsRegistPop"
);
},
openExamplePop : function(exmpCd){ openExamplePop : function(exmpCd){
/* /*
- 01 : 신청취지 - 01 : 신청취지