feat: 세션정보 추가-시스템코드(orgnztId - sysCode), 조직코드(pstinstCode - insttCode)

main
minuk926 2 years ago
parent aa99ccffad
commit bb38940c2e

@ -41,7 +41,9 @@ public class XitLoginVO implements Serializable{
private String passwordCnsr;
/** 사용자구분 */
private String userSe;
/** 조직ID */
/**
* ID - (sysCode)
* */
private String orgnztId;
/** 조직명 */
private String orgnztNm;
@ -53,8 +55,15 @@ public class XitLoginVO implements Serializable{
private String ip;
/** GPKI인증 DN */
private String dn;
/** 그룹 ID */
/**
* ID
* */
private String groupId;
/**
* - (instt_code)
*/
private String pstinstCode;
/** 업무 데이터 권한 */
private String jobDataAuthor;
/** 사용자 관리 권한 */
@ -91,6 +100,7 @@ public class XitLoginVO implements Serializable{
this.orgnztId = "-";
this.orgnztNm = "-";
this.groupId = vo.getGroupId();
this.pstinstCode = "-";
this.uniqId = vo.getEsntlId();
this.jobDataAuthor = "-";
this.userManageAuthor = "-";
@ -109,6 +119,7 @@ public class XitLoginVO implements Serializable{
this.orgnztId = "-";
this.orgnztNm = "-";
this.groupId = vo.getGroupId();
this.pstinstCode = "-";
this.uniqId = vo.getEsntlId();
this.jobDataAuthor = "-";
this.userManageAuthor = "-";
@ -127,6 +138,7 @@ public class XitLoginVO implements Serializable{
this.orgnztId = vo.getOrgnztId();
this.orgnztNm = vo.getOrgnztNm();
this.groupId = vo.getGroupId();
this.pstinstCode = vo.getPstinstCode();
this.uniqId = vo.getEsntlId();
this.jobDataAuthor = vo.getJobDataAuthor();
this.userManageAuthor = vo.getUserManageAuthor();

@ -1,6 +1,11 @@
package kr.xit.framework.biz.cmm.model;
import kr.xit.framework.core.model.BaseVO;
import lombok.AllArgsConstructor;
import lombok.EqualsAndHashCode;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;
import lombok.ToString;
/**
*
@ -12,7 +17,13 @@ import kr.xit.framework.core.model.BaseVO;
* @since 2002. 2. 2.
* @version 1.0 Copyright(c) XIT All rights reserved.
*/
public class XitOrgnztInfoVO extends BaseVO {
@Getter
@Setter
@AllArgsConstructor
@NoArgsConstructor
@EqualsAndHashCode
@ToString
public class XitOrgnztInfoVO {
/**
* serialVersionUID
@ -20,28 +31,8 @@ public class XitOrgnztInfoVO extends BaseVO {
private static final long serialVersionUID = 2971244133704702294L;
protected String orgnzt_id; //조직 id
protected String orgnzt_nm; //조직 명
protected String orgnzt_dc; //조직 설명
public String getOrgnzt_id() {
return orgnzt_id;
}
public void setOrgnzt_id(String orgnzt_id) {
this.orgnzt_id = orgnzt_id;
}
public String getOrgnzt_nm() {
return orgnzt_nm;
}
public void setOrgnzt_nm(String orgnzt_nm) {
this.orgnzt_nm = orgnzt_nm;
}
public String getOrgnzt_dc() {
return orgnzt_dc;
}
public void setOrgnzt_dc(String orgnzt_dc) {
this.orgnzt_dc = orgnzt_dc;
}
private String orgnztId; //조직 id
private String orgnztNm; //조직 명
private String orgnztDc; //조직 설명
}

@ -3248,7 +3248,7 @@ public class XitFrameCrudServiceImpl implements XitFrameCrudService{
*
*/
String emsg = null;
if(XitCmmnUtil.isEmpty(vo.getOrgnzt_id()))
if(XitCmmnUtil.isEmpty(vo.getOrgnztId()))
emsg = String.format("(%s)조직ID(은)는 필수조건 입니다.", table);
if(emsg!=null){
logger.error(emsg);
@ -3279,7 +3279,7 @@ public class XitFrameCrudServiceImpl implements XitFrameCrudService{
*
*/
String emsg = null;
if(XitCmmnUtil.isEmpty(vo.getOrgnzt_id()))
if(XitCmmnUtil.isEmpty(vo.getOrgnztId()))
emsg = String.format("(%s)조직ID(은)는 필수조건 입니다.", table);
if(emsg!=null){
logger.error(emsg);
@ -3312,7 +3312,7 @@ public class XitFrameCrudServiceImpl implements XitFrameCrudService{
*
*/
String emsg = null;
if(XitCmmnUtil.isEmpty(vo.getOrgnzt_id()))
if(XitCmmnUtil.isEmpty(vo.getOrgnztId()))
emsg = String.format("(%s)조직ID(은)는 필수조건 입니다.", table);
if(emsg!=null){
logger.error(emsg);
@ -3345,7 +3345,7 @@ public class XitFrameCrudServiceImpl implements XitFrameCrudService{
*
*/
String emsg = null;
if(XitCmmnUtil.isEmpty(vo.getOrgnzt_id()))
if(XitCmmnUtil.isEmpty(vo.getOrgnztId()))
emsg = String.format("(%s)조직ID(은)는 필수조건 입니다.", table);
if(emsg!=null){
logger.error(emsg);

@ -121,10 +121,10 @@ public class XitFrameUnitServiceImpl implements XitFrameUnitService {
loginVO.convertToLoginVO(userUsrVO);
// 조직id명 설정
XitOrgnztInfoVO orgnztInfoVO = new XitOrgnztInfoVO();
orgnztInfoVO.setOrgnzt_id(userUsrVO.getOrgnztId());
orgnztInfoVO.setOrgnztId(userUsrVO.getOrgnztId());
orgnztInfoVO = xitFrameCrudService.findXitOrgnztInfo(orgnztInfoVO);
if (XitCmmnUtil.notEmpty(orgnztInfoVO))
loginVO.setOrgnztNm(orgnztInfoVO.getOrgnzt_nm());
loginVO.setOrgnztNm(orgnztInfoVO.getOrgnztNm());
}
break;
default:

@ -52,6 +52,8 @@ public class XitSessionMapping extends EgovUsersByUsernameMapping {
String strUserSe = rs.getString("user_se");
String strUserEmail = rs.getString("user_email");
String strOrgnztId = rs.getString("orgnzt_id");
String strGroupId = rs.getString("group_id");
String strPstinstCode = rs.getString("pstinst_code");
String strOrgnztNm = rs.getString("orgnzt_nm");
String strUniqId = rs.getString("esntl_id");
String strJobDataAuthor = rs.getString("job_data_author");
@ -70,9 +72,11 @@ public class XitSessionMapping extends EgovUsersByUsernameMapping {
loginVO.setName(strUserNm); //이름
loginVO.setUserSe(strUserSe); //사용자구분
loginVO.setEmail(strUserEmail); //이메일주소
loginVO.setOrgnztId(strOrgnztId); //조직(부서)ID
loginVO.setOrgnztId(strOrgnztId); //조직(부서)ID - (시스템코드-sysCode)
loginVO.setOrgnztNm(strOrgnztNm); //조직(부서)ID 명
loginVO.setUniqId(strUniqId); //고유아이디
loginVO.setGroupId(strGroupId); //그룹
loginVO.setPstinstCode(strPstinstCode); //소속기관-업무그룹(instt_code)
loginVO.setJobDataAuthor(strJobDataAuthor); //업무 데이터 권한
loginVO.setUserManageAuthor(strUserManageAuthor); //사용자 관리 권한
loginVO.setElctrnsanctnUseAt(strElctrnsanctnUseAt); //전자결재 사용 여부

@ -51,8 +51,8 @@ public class XitUserInfoVO extends XitUserEtcOptionVO {
protected String emailAdres; //이메일 주소
protected String ofcpsNm; //직위 명
protected String houseMiddleTelno; //주택 중간 전화번호
protected String groupId; //그룹 id
protected String pstinstCode; //소속기관 코드
protected String groupId; //그룹 id - 업무그룹(instt_code)
protected String pstinstCode; //소속기관 코드 - 시스템코드(sysCode)
protected String userSttusCode; //사용자 상태 코드
protected String esntlId; //고유 id
protected String crtfcDnValue; //인증 dn 값

@ -106,6 +106,8 @@
, USER_SE
, ORGNZT_ID
, ESNTL_ID
, GROUP_ID
, PSTINST_CODE
, ORGNZT_NM
, JOB_DATA_AUTHOR
, USER_MANAGE_AUTHOR

@ -25,3 +25,67 @@ BEGIN
RETURN RTN_VAL;
END ;
CREATE DEFINER = root@`%` VIEW xit_vw_user_mastr AS
SELECT `xplatform`.`xit_gnrl_mber`.`ESNTL_ID` AS `ESNTL_ID`,
`xplatform`.`xit_gnrl_mber`.`MBER_ID` AS `USER_ID`,
`xplatform`.`xit_gnrl_mber`.`PASSWORD` AS `PASSWORD`,
`xplatform`.`xit_gnrl_mber`.`MBER_NM` AS `USER_NM`,
`xplatform`.`xit_gnrl_mber`.`ZIP` AS `USER_ZIP`,
`xplatform`.`xit_gnrl_mber`.`ADRES` AS `USER_ADRES`,
`xplatform`.`xit_gnrl_mber`.`MBER_EMAIL_ADRES` AS `USER_EMAIL`,
' ' AS `GROUP_ID`,
'GNR' AS `USER_SE`,
' ' AS `ORGNZT_ID`,
' ' AS `PSTINST_CODE`,
' ' AS `ORGNZT_NM`,
' ' AS `JOB_DATA_AUTHOR`,
' ' AS `USER_MANAGE_AUTHOR`,
' ' AS `ELCTRNSANCTN_USE_AT`,
' ' AS `JOB_CONFM_AUTHOR_AT`
FROM `xplatform`.`xit_gnrl_mber`
UNION ALL
SELECT `a`.`ESNTL_ID` AS `ESNTL_ID`,
`a`.`USER_ID` AS `USER_ID`,
`a`.`PASSWORD` AS `PASSWORD`,
`a`.`USER_NM` AS `USER_NM`,
`a`.`ZIP` AS `ZIP`,
`a`.`HOUSE_ADRES` AS `HOUSE_ADRES`,
`a`.`EMAIL_ADRES` AS `EMAIL_ADRES`,
`a`.`GROUP_ID` AS `GROUP_ID`,
'USR' AS `USER_SE`,
`a`.`orgnzt_id` AS `ORGNZT_ID`,
`a`.`pstinst_code` AS `PSTINST_CODE`,
(SELECT `sa`.`ORGNZT_NM`
FROM `xplatform`.`xit_orgnzt_info` `sa`
WHERE `sa`.`ORGNZT_ID` = `a`.`orgnzt_id`) AS `ORGNZT_NM`,
`b`.`JOB_DATA_AUTHOR` AS `JOB_DATA_AUTHOR`,
`b`.`USER_MANAGE_AUTHOR` AS `USER_MANAGE_AUTHOR`,
`b`.`ELCTRNSANCTN_USE_AT` AS `ELCTRNSANCTN_USE_AT`,
`b`.`JOB_CONFM_AUTHOR_AT` AS `JOB_CONFM_AUTHOR_AT`
FROM (`xplatform`.`xit_user_info` `a` LEFT JOIN `xplatform`.`xit_user_etc_option` `b`
ON (`a`.`USER_ID` = `b`.`USER_ID`))
UNION ALL
SELECT `xplatform`.`xit_entrprs_mber`.`ESNTL_ID` AS `ESNTL_ID`,
`xplatform`.`xit_entrprs_mber`.`ENTRPRS_MBER_ID` AS `USER_ID`,
`xplatform`.`xit_entrprs_mber`.`ENTRPRS_MBER_PASSWORD` AS `ENTRPRS_MBER_PASSWORD`,
`xplatform`.`xit_entrprs_mber`.`CMPNY_NM` AS `CMPNY_NM`,
`xplatform`.`xit_entrprs_mber`.`ZIP` AS `ZIP`,
`xplatform`.`xit_entrprs_mber`.`ADRES` AS `ADRES`,
`xplatform`.`xit_entrprs_mber`.`APPLCNT_EMAIL_ADRES` AS `APPLCNT_EMAIL_ADRES`,
' ' AS `GROUP_ID`,
'ENT' AS `USER_SE`,
' ' AS `ORGNZT_ID`,
' ' AS `PSTINST_CODE`,
' ' AS `ORGNZT_NM`,
' ' AS `JOB_DATA_AUTHOR`,
' ' AS `USER_MANAGE_AUTHOR`,
' ' AS `ELCTRNSANCTN_USE_AT`,
' ' AS `JOB_CONFM_AUTHOR_AT`
FROM `xplatform`.`xit_entrprs_mber`;

@ -1809,9 +1809,9 @@
,ORGNZT_DC
FROM XIT_ORGNZT_INFO
WHERE 1=1
<if test="@kr.xit.framework.core.utils.XitCmmnUtil@notEmpty(orgnzt_id)">AND ORGNZT_ID = #{orgnzt_id}</if>
<if test="@kr.xit.framework.core.utils.XitCmmnUtil@notEmpty(orgnzt_nm)">AND ORGNZT_NM = #{orgnzt_nm}</if>
<if test="@kr.xit.framework.core.utils.XitCmmnUtil@notEmpty(orgnzt_dc)">AND ORGNZT_DC = #{orgnzt_dc}</if>
<if test="@kr.xit.framework.core.utils.XitCmmnUtil@notEmpty(orgnztId)">AND ORGNZT_ID = #{orgnztId}</if>
<if test="@kr.xit.framework.core.utils.XitCmmnUtil@notEmpty(orgnztNm)">AND ORGNZT_NM = #{orgnztNm}</if>
<if test="@kr.xit.framework.core.utils.XitCmmnUtil@notEmpty(orgnztDc)">AND ORGNZT_DC = #{orgnztDc}</if>
</select>
<select id="findXitOrgnztInfo" resultType="kr.xit.framework.biz.cmm.model.XitOrgnztInfoVO">
/** findXitOrgnztInfo */
@ -1821,7 +1821,7 @@
,ORGNZT_DC
FROM XIT_ORGNZT_INFO
WHERE 1=1
AND ORGNZT_ID = #{orgnzt_id}
AND ORGNZT_ID = #{orgnztId}
</select>
<insert id="addXitOrgnztInfo">
/** addXitOrgnztInfo */
@ -1841,17 +1841,17 @@
/** 조직정보 수정 */
UPDATE XIT_ORGNZT_INFO
SET
ORGNZT_NM = IFNULL(#{orgnzt_nm}, ORGNZT_NM)
<if test="@kr.xit.framework.core.utils.XitCmmnUtil@notBlank(orgnzt_dc)">,ORGNZT_DC = #{orgnzt_dc}</if>
ORGNZT_NM = IFNULL(#{orgnztNm}, ORGNZT_NM)
<if test="@kr.xit.framework.core.utils.XitCmmnUtil@notBlank(orgnztDc)">,ORGNZT_DC = #{orgnztDc}</if>
WHERE 1=1
AND ORGNZT_ID = #{orgnzt_id}
AND ORGNZT_ID = #{orgnztId}
</update>
<delete id="removeXitOrgnztInfo">
/** removeXitOrgnztInfo */
/** 조직정보 삭제 */
DELETE FROM XIT_ORGNZT_INFO
WHERE 1=1
AND ORGNZT_ID = #{orgnzt_id}
AND ORGNZT_ID = #{orgnztId}
</delete>

Loading…
Cancel
Save