관리자 시군구코드,기관코드 변경

main
이범준 4 months ago
parent 6ec8b7f1fa
commit d39e565114

@ -52,20 +52,20 @@ public class OgdpBean extends AbstractBean {
ogdp.put("INST_NM", sgg.string("INST_NM"));
ogdp.put("DEPT_CD", dept.string("DEPT_CD"));
ogdp.put("DEPT_NM", dept.string("DEPT_NM"));
ogdp.put("OGDP_CD", sgg.string("INST_CD") + "/" + dept.string("DEPT_CD"));
ogdp.put("OGDP_CD", sgg.string("SGG_CD")+"/"+sgg.string("INST_CD") + ":" + dept.string("DEPT_CD"));
ogdp.put("OGDP_NM", sgg.string("SGG_NM") + " / " + sgg.string("INST_NM") + " : " + dept.string("DEPT_NM"));
ogdpList.add(ogdp);
}
}
DataObject sysAdmin = new DataObject();
sysAdmin.put("SGG_CD", "default");
sysAdmin.put("SGG_NM", "기본 시군구");
sysAdmin.put("INST_CD", "default");
sysAdmin.put("INST_NM", "기본 기관");
sysAdmin.put("DEPT_CD", "default");
sysAdmin.put("DEPT_NM", "기본 부서");
sysAdmin.put("OGDP_CD", "default/default");
sysAdmin.put("OGDP_NM", "기본 시군구 / 기본 기관 : 기본 부서");
sysAdmin.put("SGG_CD", "ADMIN");
sysAdmin.put("SGG_NM", "관리자 시군구");
sysAdmin.put("INST_CD", "ADMIN00");
sysAdmin.put("INST_NM", "관리자 기관");
sysAdmin.put("DEPT_CD", "ADMIN00");
sysAdmin.put("DEPT_NM", "관리자 부서");
sysAdmin.put("OGDP_CD", "ADMIN/ADMIN00:ADMIN00");
sysAdmin.put("OGDP_NM", "관리자 시군구 / 관리자 기관 : 관리자 부서");
ogdpList.add(sysAdmin);
return ogdpList;
@ -76,7 +76,7 @@ public class OgdpBean extends AbstractBean {
SigunguQuery sggQuery = new SigunguQuery();
if(anonymous) {
sggQuery.setSggIDs(sggCd);
} else if(!currentUser().getInstitute().equals("default")){
} else if(!currentUser().getInstitute().equals("ADMIN00")){
sggQuery.setSggIDs(currentUser().getOrgID());
}
List<DataObject> sggs = sigunguBean.getSigunguList(sggQuery);
@ -90,22 +90,22 @@ public class OgdpBean extends AbstractBean {
ogdp.put("INST_NM", sgg.string("INST_NM"));
ogdp.put("DEPT_CD", dept.string("DEPT_CD"));
ogdp.put("DEPT_NM", dept.string("DEPT_NM"));
ogdp.put("OGDP_CD", sgg.string("INST_CD") + "/" + dept.string("DEPT_CD"));
ogdp.put("OGDP_CD", sgg.string("SGG_CD")+"/"+sgg.string("INST_CD") + ":" + dept.string("DEPT_CD"));
ogdp.put("OGDP_NM", sgg.string("SGG_NM") + " / " + sgg.string("INST_NM") + " : " + dept.string("DEPT_NM"));
ogdpList.add(ogdp);
}
}
if(!anonymous && currentUser().getInstitute().equals("default")) {
if(!anonymous && currentUser().getInstitute().equals("ADMIN00")) {
DataObject sysAdmin = new DataObject();
sysAdmin.put("SGG_CD", "default");
sysAdmin.put("SGG_NM", "기본 시군구");
sysAdmin.put("INST_CD", "default");
sysAdmin.put("INST_NM", "기본 기관");
sysAdmin.put("DEPT_CD", "default");
sysAdmin.put("DEPT_NM", "기본 부서");
sysAdmin.put("OGDP_CD", "default/default");
sysAdmin.put("OGDP_NM", "기본 시군구 / 기본 기관 : 기본 부서");
sysAdmin.put("SGG_CD", "ADMIN");
sysAdmin.put("SGG_NM", "관리자 시군구");
sysAdmin.put("INST_CD", "ADMIN00");
sysAdmin.put("INST_NM", "관리자 기관");
sysAdmin.put("DEPT_CD", "ADMIN00");
sysAdmin.put("DEPT_NM", "관리자 부서");
sysAdmin.put("OGDP_CD", "ADMIN/ADMIN00:ADMIN00");
sysAdmin.put("OGDP_NM", "관리자 시군구 / 관리자 기관 : 관리자 부서");
ogdpList.add(sysAdmin);
}
return ogdpList;

@ -52,7 +52,7 @@ public class AdminController extends ApplicationController {
public ModelAndView adminMain(HttpServletResponse hres) {
ModelAndView mav = new ModelAndView();
if(!currentUser().getInstitute().equals("default")) {
if(!currentUser().getInstitute().equals("ADMIN00")) {
hres.setStatus(HttpStatus.FORBIDDEN.value());
mav.setViewName("jsonView");
mav.addObject("message","메뉴 접근 권한이 없습니다.");

@ -48,7 +48,7 @@ public class CodeController extends cokr.xit.base.code.web.CodeController {
ModelAndView mav = new ModelAndView("jsonView");
UserInfo userInfo = currentUser();
if(userInfo.getInstitute().equals("default")) {
if(userInfo.getInstitute().equals("ADMIN00")) {
mav.addObject("sggHasTask", "Y");
} else {

@ -83,7 +83,7 @@ public class OgdpController extends ApplicationController {
UserInfo userInfo = currentUser();
if(userInfo.getInstitute().equals("default")) {
if(userInfo.getInstitute().equals("ADMIN00")) {
if(ifEmpty(sggCd, ()->"").equals("")) {
mav.setViewName("fims/ogdp/select-sgg");

@ -46,14 +46,14 @@ public class StngBean extends AbstractBean {
return stngMapper.selectUserStng(currentUser().getId());
} else if(type.equals("dept")){
UserInfo userInfo = currentUser();
if(userInfo.getInstitute().equals("default")) {
if(userInfo.getInstitute().equals("ADMIN00")) {
return new DataObject();
}
ogdpBean.initUserInfo(userInfo);
return stngMapper.selectDeptStng((String)userInfo.getInfo().get("deptCd"));
} else if(type.equals("sgg")){
UserInfo userInfo = currentUser();
if(userInfo.getInstitute().equals("default")) {
if(userInfo.getInstitute().equals("ADMIN00")) {
return new DataObject();
}
ogdpBean.initUserInfo(userInfo);
@ -92,7 +92,7 @@ public class StngBean extends AbstractBean {
List<String> availableTaskList = new ArrayList<>();
if(userInfo.getInstitute().equals("default")) { //최고관리자
if(userInfo.getInstitute().equals("ADMIN00")) { //최고관리자
availableTaskList = taskList;
@ -176,7 +176,7 @@ public class StngBean extends AbstractBean {
public List<CommonCode> filterTaskSectionCodeForSgg(List<CommonCode> taskSectionCodes) {
List<CommonCode> taskListForSgg = new ArrayList<CommonCode>();
if(currentUser().getInstitute().equals("default")) {
if(currentUser().getInstitute().equals("ADMIN00")) {
taskListForSgg = taskSectionCodes;
} else {
SecuredUserInfo userInfo = currentUser();

@ -69,9 +69,9 @@ SELECT A.USER_ID
, (SELECT GET_CODE_NM('CMN004', A.STTS) FROM DUAL) AS STTS_NM
, A.NSTT_CD AS NSTT_CD
, A.NSTT_CD AS INST_CD
, (CASE WHEN A.NSTT_CD = 'default' THEN '기본 기관' ELSE B.INST_NM END) AS INST_NM
, (CASE WHEN A.NSTT_CD = 'ADMIN00' THEN '관리자 기관' ELSE B.INST_NM END) AS INST_NM
, A.DEPT_CD AS DEPT_CD
, (CASE WHEN A.DEPT_CD = 'default' THEN '기본 부서' ELSE B.DEPT_NM END) AS DEPT_NM
, (CASE WHEN A.DEPT_CD = 'ADMIN00' THEN '관리자 부서' ELSE B.DEPT_NM END) AS DEPT_NM
, A.ORG_ID AS ORG_ID
, A.ORG_ID AS SGG_CD
, B.SGG_NM AS SGG_NM

@ -11,7 +11,7 @@
<option value=""></option>
<c:forEach items="${allOgdpList}" var="item">
<option value="${item.INST_CD}">${item.SGG_NM} / ${item.INST_NM}</option>
</c:forEach>
</c:forEach>
</select>
<select name="deptCode" class="form-select no-bgi" data-map="DEPT_CD"
required title="시군구/기관 및 부서" disabled>
@ -251,8 +251,7 @@ function saveinfoPrefix() {
function setOgdpCodeValues(institute, deptCode, sggCd){
$("#infoPrefix-form [name='institute']").val(institute).trigger("change");
$("#infoPrefix-form [name='deptCode']").val(deptCode).trigger("change");
$("#infoPrefix-form [name='orgID']").val(sggCd);
$("#infoPrefix-form [name='orgID']").val(sggCd).trigger("change");
}
//# sourceURL=user-info.jsp

@ -307,7 +307,7 @@ $(document).ready(function(){
$P.fnReset();
fn_securityModeToggle($("#securityMode--top").is(":checked")); //보안모드
if(MY_INFO.institute != "default"){
if(MY_INFO.institute != "ADMIN00"){
$("#btnAdd--${pageName}").attr("hidden","hidden");
}
});

@ -18,7 +18,7 @@
<select id="sggCd--${pageName}" name="sggCd" data-map="SGG_CD" class="form-select">
<option value="">전체</option>
<c:forEach items="${sggList}" var="item">
<c:if test="${item.SGG_CD ne 'default'}">
<c:if test="${item.SGG_CD ne 'ADMIN'}">
<option value="${item.SGG_CD}">${item.SGG_NM}</option>
</c:if>
</c:forEach>
@ -171,7 +171,7 @@ $(document).ready(function(){
$P.ntcControl.dataset.setData([ntcInfo]);
$("#sggCd--${pageName}").attr("disabled","disabled");
if(MY_INFO.institute != "default"){
if(MY_INFO.institute != "ADMIN00"){
$("#btnSave--${pageName}").attr("hidden","hidden");
$("#btnRemove--${pageName}").attr("hidden","hidden");
}

@ -232,7 +232,7 @@ pageObject["${pageName}"] = {};
$(document).ready(function(){
if(MY_INFO.institute != "default"){
if(MY_INFO.institute != "ADMIN00"){
$(".superadmin").attr("hidden","hidden");
}
@ -340,7 +340,7 @@ $(document).ready(function(){
$("#tabButtonContainer--${pageName}").html(tabs.join(""));
$("#tabContentContainer--${pageName}").html(contents.join(""));
if(MY_INFO.institute != "default"){
if(MY_INFO.institute != "ADMIN00"){
$(".superadmin").attr("hidden","hidden");
}

@ -334,7 +334,7 @@ $(document).ready(function(){
$P.fnReset();
fn_securityModeToggle($("#securityMode--top").is(":checked")); //보안모드
if(MY_INFO.institute == "default"){
if(MY_INFO.institute == "ADMIN00"){
$("#sggCd--${pageName}").removeAttr("disabled");
}
});

@ -344,7 +344,7 @@ $(document).ready(function(){
* 초기화
**************************************************************************/
if(MY_INFO.institute == 'default') {
if(MY_INFO.institute == 'ADMIN00') {
$("#forRootAdmin--${pageName}").removeAttr("hidden");
}

@ -7,7 +7,7 @@
<h1>시군구 선택</h1>
<div id="btnsGoToEditSgg--${pageName}">
<c:forEach items="${sggList}" var="item">
<c:if test="${item.SGG_CD ne 'default'}">
<c:if test="${item.SGG_CD ne 'ADMIN'}">
<button type="button" data-value="${item.SGG_CD}" class="w-px-200"
onclick="fnGoToEditSgg('${item.SGG_CD}')">
${item.SGG_NM}(${item.SGG_CD})

@ -309,8 +309,7 @@ function save(info){
function setOgdpCodeValues(institute, deptCode, sggCd){
$("#user-form [name='institute']").val(institute).trigger("change");
$("#user-form [name='deptCode']").val(deptCode).trigger("change");
$("#user-form [name='orgID']").val(sggCd);
$("#user-form [name='orgID']").val(sggCd).trigger("change");
}
$("#btnDuplicate").on("click", function(){

@ -55,7 +55,7 @@
<div class="input-group">
<select id="orgID" name="orgID" required title="시군구명" class="form-select mb-2 h-px-40 no-max-w">
<option value="">[기관 선택]</option>
<option value="default">시스템관리</option>
<option value="ADMIN">시스템관리</option>
<c:forEach items="${sggList}" var="item">
<option value="${item.SGG_CD}"
<c:if test="${item.USER_USE_YN == 'N'}"> disabled </c:if>
@ -119,10 +119,6 @@ function login() {
rememberCredentials: $("#remember").prop("checked")
};
if(params.orgID == "default"){
params.orgID = "";
}
json.post({
url:wctx.url("/login.do"),
data:params,

Loading…
Cancel
Save