소속시군구가 없는 최고관리자로 로그인시 시군구관리메뉴에서 시군구를 선택하는 기능 추가

main
이범준 10 months ago
parent 7b59259e3f
commit ccd647ac0f

@ -45,4 +45,10 @@ public interface FactionMapper extends AbstractMapper {
* @return
*/
List<DataObject> selectAllInstList();
/** .<br />
* @param
* @return
*/
List<DataObject> selectAllSggList();
}

@ -15,6 +15,7 @@ import cokr.xit.base.web.ApplicationController;
import cokr.xit.fims.cmmn.CmmnQuery;
import cokr.xit.fims.mngt.Sgg;
import cokr.xit.fims.mngt.VltnQuery;
import cokr.xit.fims.mngt.dao.FactionMapper;
import cokr.xit.fims.mngt.service.SggService;
import cokr.xit.fims.mngt.service.TaskService;
import cokr.xit.fims.mngt.service.VltnService;
@ -55,6 +56,9 @@ public class Mngt03Controller extends ApplicationController {
@Resource(name = "factionBean")
private FactionBean factionBean;
@Resource(name = "factionMapper")
private FactionMapper factionMapper;
/** .
* @return fims/mngt/mngt03010-main
*/
@ -66,8 +70,11 @@ public class Mngt03Controller extends ApplicationController {
if(userInfo.getInstitute().equals("default")) {
if(ifEmpty(sggCd, ()->"").equals("")) {
mav.setViewName("fims/mngt/mngt03011-main");
mav.addObject("pageName", "mngt03011");
mav.setViewName("fims/mngt/select-sgg");
mav.addObject("pageName", "selectSgg");
List<DataObject> sggList = factionMapper.selectAllSggList();
mav.addObject("sggList", sggList);
} else {
mav.setViewName("fims/mngt/mngt03010-main");

@ -73,6 +73,14 @@ SELECT S.SGG_CD
WHERE U.USER_ID = #{userId}
</select>
<select id="selectAllSggList" parameterType="string" resultType="dataobject">
/* 모든 시군구 조회(factionMapper.selectAllSggList) */
SELECT SGG_CD
, SGG_NM
FROM TB_SGG
WHERE USE_YN = 'Y'
</select>
<select id="selectAllInstList" parameterType="string" resultType="dataobject">
/* 모든 기관 조회(factionMapper.selectAllInstList) */
SELECT INST_CD

@ -29,7 +29,7 @@ SELECT S.SGG_CD <!-- 시군구 코드 -->
/* 시군구 객체 가져오기(sggMapper.selectSggs) */
<include refid="select" />
<where>
<if test="deptCd != null">
<if test="sggCd != null">
AND S.SGG_CD = #{sggCd} <!-- 시군구 코드 -->
</if>
<if test="useYN != null">

@ -1,10 +0,0 @@
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" isELIgnored="false" session="false"%>
<%@ include file="/WEB-INF/jsp/include/taglib.jsp"%>
<c:set var="pageKorName" scope="request">시군구 목록</c:set>
<div class="content-wrapper">
<div class="container-xxl flex-grow-1 px-0">
<div class="card wrapper-list">
</div>
</div>
</div>

@ -0,0 +1,36 @@
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" isELIgnored="false" session="false"%>
<%@ include file="/WEB-INF/jsp/include/taglib.jsp"%>
<c:set var="pageKorName" scope="request">시군구 목록</c:set>
<div class="content-wrapper">
<div class="container-xxl flex-grow-1 px-0">
<div class="card wrapper-list">
<h1>시군구 선택</h1>
<div id="btnsGoToEditSgg--${pageName}">
<c:forEach items="${sggList}" var="item">
<c:if test="${item.SGG_CD ne 'default'}">
<button type="button" data-value="${item.SGG_CD}" class="w-px-200"
onclick="fnGoToEditSgg('${item.SGG_CD}')">
${item.SGG_NM}(${item.SGG_CD})
</button>
</c:if>
</c:forEach>
</div>
</div>
</div>
</div>
<script>
function fnGoToEditSgg(selected){
var sggMainMenuNum = "62";
var menuUrl = $("#menus").find("li[data-key='"+sggMainMenuNum+"'] a").attr("data-url");
ajax.get({
url: menuUrl,
data : { sggCd : selected },
success:resp => {
$("div[id='innerPage-"+sggMainMenuNum+"']").html(resp);
}
});
}
</script>

@ -346,9 +346,11 @@ $("#btnFastSearch--top").on( "click", function() {
$("#fastTerm--top").onEnterPress(fnGlobalFastSearch);
function fnGlobalFastSearch(){
closeTab("17");
var integrationSearchMenuNum = "17";
closeTab(integrationSearchMenuNum);
var itegrationSearchMenu = $("#menus").find("li[data-key='17'] a")[0];
var itegrationSearchMenu = $("#menus").find("li[data-key='"+integrationSearchMenuNum+"'] a")[0];
if($("#fastTerm--top").val() != ""){
var fastTerm = $("#fastTerm--top").val();

@ -131,7 +131,7 @@ function openMenu(obj, params) {
$("#tab-" + dataKey)[0].appendChild(dynamicPage);
innerPageMap[dataKey] = dynamicPage;
innerPageMap[dataKey] = true;
ajax.request({

Loading…
Cancel
Save