Merge remote-tracking branch 'origin/dev' into dev
commit
f7f24f0769
@ -1,139 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="kr.xit.framework.biz.mng.auth.mapper.AuthMgtMapper">
|
||||
<!-- SQL 페이징 코드 -->
|
||||
<sql id="pageBefore">
|
||||
SELECT * FROM
|
||||
(SELECT LIST.*, ROWNUM AS "RN" FROM(
|
||||
</sql>
|
||||
|
||||
<sql id="pageAfter">
|
||||
) LIST
|
||||
) WHERE RN BETWEEN #{firstIndex} + 1 AND #{firstIndex} + #{recordCountPerPage}
|
||||
</sql>
|
||||
|
||||
|
||||
<sql id="findList_SELECT">
|
||||
SELECT A.AUTHOR_CODE AS "authorCode"
|
||||
,A.AUTHOR_NM AS "authorNm"
|
||||
,A.AUTHOR_DC AS "authorDc"
|
||||
,A.AUTHOR_CREAT_DE AS "authorCreatDe"
|
||||
</sql>
|
||||
<sql id="findList_FROM">
|
||||
FROM XIT_AUTHOR_INFO A
|
||||
</sql>
|
||||
<sql id="findList_WHERE">
|
||||
<if test="'1'.toString() == searchCondition">
|
||||
AND A.AUTHOR_NM LIKE '%'||#{searchKeyword}||'%'
|
||||
</if>
|
||||
</sql>
|
||||
|
||||
|
||||
|
||||
<select id="findList" resultType="kr.xit.framework.biz.mng.auth.model.XitAuthRegMngVO">
|
||||
/** XitAuthRegMngMapper.findList */
|
||||
/** 권한관리 목록 조회 */
|
||||
<if test="searchGubun == 'list'">
|
||||
<include refid="pageBefore" />
|
||||
</if>
|
||||
|
||||
<include refid="findList_SELECT"/>
|
||||
<include refid="findList_FROM"/>
|
||||
WHERE 1=1
|
||||
<include refid="findList_WHERE"/>
|
||||
ORDER BY A.AUTHOR_CREAT_DE DESC
|
||||
|
||||
<if test="searchGubun == 'list'">
|
||||
<include refid="pageAfter" />
|
||||
</if>
|
||||
</select>
|
||||
|
||||
|
||||
|
||||
<select id="findListTotCnt" resultType="int">
|
||||
/** XitAuthRegMngMapper.findListTotCnt */
|
||||
/** 권한관리 목록 총건수 조회 */
|
||||
SELECT COUNT(1) AS "CNT"
|
||||
<include refid="findList_FROM"/>
|
||||
WHERE 1=1
|
||||
<include refid="findList_WHERE"/>
|
||||
</select>
|
||||
|
||||
|
||||
|
||||
<select id="findView" resultType="kr.xit.framework.biz.mng.auth.model.XitAuthRegMngVO">
|
||||
/** XitAuthRegMngMapper.findView */
|
||||
/** 권한관리 상세정보 조회 */
|
||||
<include refid="findList_SELECT"/>
|
||||
<include refid="findList_FROM"/>
|
||||
WHERE A.AUTHOR_CODE=#{authorCode}
|
||||
</select>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<select id="findListAuthorRole" resultType="java.util.Map">
|
||||
/** XitAuthRegMngMapper.findListAuthorRole */
|
||||
/** 권한롤관리 목록 조회 */
|
||||
<if test="searchGubun == 'list'">
|
||||
<include refid="pageBefore"/>
|
||||
</if>
|
||||
|
||||
<include refid="findListAuthorRole_SELECT"/>
|
||||
<include refid="findListAuthorRole_FROM"/>
|
||||
WHERE 1 = 1
|
||||
<include refid="findListAuthorRole_WHERE"/>
|
||||
ORDER BY A.ROLE_CODE
|
||||
|
||||
<if test="searchGubun == 'list'">
|
||||
<include refid="pageAfter"/>
|
||||
</if>
|
||||
</select>
|
||||
<select id="findListAuthorRoleTotCnt" resultType="int">
|
||||
/** XitAuthRegMngMapper.findListAuthorRoleTotCnt */
|
||||
/** 권한롤관리 목록 조회 총 건수 */
|
||||
SELECT COUNT(1) AS "CNT"
|
||||
<include refid="findListAuthorRole_FROM"/>
|
||||
WHERE 1 = 1
|
||||
<include refid="findListAuthorRole_WHERE"/>
|
||||
</select>
|
||||
<sql id="findListAuthorRole_SELECT">
|
||||
SELECT A.ROLE_CODE AS "roleCode"
|
||||
,A.ROLE_NM AS "roleNm"
|
||||
,A.ROLE_PTTRN AS "rolePtn"
|
||||
,A.ROLE_DC AS "roleDc"
|
||||
,A.ROLE_TY AS "roleTyp"
|
||||
,A.ROLE_SORT AS "roleSort"
|
||||
,B.AUTHOR_CODE AS "authorCode"
|
||||
,B.CREAT_DT AS "creatDt"
|
||||
,(CASE WHEN B.ROLE_CODE IS NULL THEN 'N' ELSE 'Y' END) AS "regYn"
|
||||
</sql>
|
||||
<sql id="findListAuthorRole_FROM">
|
||||
FROM XIT_ROLE_INFO A
|
||||
LEFT OUTER JOIN ( SELECT AUTHOR_CODE, ROLE_CODE, CREAT_DT
|
||||
FROM XIT_AUTHOR_ROLE_RELATE
|
||||
WHERE AUTHOR_CODE = #{searchKeyword}
|
||||
) B ON A.ROLE_CODE = B.ROLE_CODE
|
||||
</sql>
|
||||
<sql id="findListAuthorRole_WHERE">
|
||||
</sql>
|
||||
|
||||
|
||||
|
||||
</mapper>
|
@ -0,0 +1,231 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="kr.xit.framework.biz.mng.auth.mapper.AuthAuthorMgtMapper">
|
||||
|
||||
<!-- *************************************************************************************************************
|
||||
* xit_author_info : 권한 정보
|
||||
************************************************************************************************************** -->
|
||||
<select id="selectAuthorInfos" parameterType="map" resultType="kr.xit.framework.biz.cmm.model.XitAuthorInfoVO">
|
||||
/* auth-author-mysql-mapper|selectAuthorInfos-권한 목록 조회|julim */
|
||||
SELECT author_code
|
||||
, author_nm
|
||||
, author_dc
|
||||
, author_creat_de
|
||||
FROM xit_author_info
|
||||
<where>
|
||||
<if test="@kr.xit.framework.core.utils.XitCmmnUtil@notEmpty(authorCode)">
|
||||
AND author_code = #{authorCode}
|
||||
</if>
|
||||
<if test="@kr.xit.framework.core.utils.XitCmmnUtil@notEmpty(authorNm)">
|
||||
AND INSTR(author_nm, #{authorNm}) > 0
|
||||
</if>
|
||||
<if test="@kr.xit.framework.core.utils.XitCmmnUtil@notEmpty(authorDc)">
|
||||
AND INSTR(author_dc, #{authorDc}) > 0
|
||||
</if>
|
||||
</where>
|
||||
ORDER BY author_creat_de DESC
|
||||
</select>
|
||||
|
||||
<select id="selectAuthorInfo" parameterType="string" resultType="kr.xit.framework.biz.cmm.model.XitAuthorInfoVO">
|
||||
/* auth-author-mysql-mapper|selectAuthorInfo-권한 정보 조회|julim */
|
||||
SELECT author_code
|
||||
, author_nm
|
||||
, author_dc
|
||||
, author_creat_de
|
||||
FROM xit_author_info
|
||||
WHERE author_code = #{authorCode}
|
||||
</select>
|
||||
|
||||
<insert id="insertAuthorInfo" parameterType="kr.xit.framework.biz.cmm.model.XitAuthorInfoVO">
|
||||
/* auth-author-mysql-mapper|insertAuthorInfo-권한 정보 등록|julim */
|
||||
INSERT INTO xit_author_info (
|
||||
author_code
|
||||
, author_nm
|
||||
, author_dc
|
||||
, author_creat_de
|
||||
) VALUES (
|
||||
#{authorCode}
|
||||
,#{authorNm}
|
||||
,#{authorDc}
|
||||
,DATE_FORMAT(NOW(), '%Y%m%d%H%i%s')
|
||||
)
|
||||
</insert>
|
||||
|
||||
<update id="updateAuthorInfo" parameterType="kr.xit.framework.biz.cmm.model.XitAuthorInfoVO">
|
||||
/* auth-author-mysql-mapper|selectAuthorInfos-권한 목록 조회|julim */
|
||||
UPDATE xit_author_info
|
||||
SET author_nm = IF(author_nm = #{authorNm}, author_nm, #{authorNm})
|
||||
, author_dc = IF(author_dc = #{authorDc}, author_dc, #{authorDc})
|
||||
WHERE author_code = #{authorCode}
|
||||
</update>
|
||||
|
||||
<delete id="deleteAuthorInfo" parameterType="kr.xit.framework.biz.cmm.model.XitAuthorInfoVO">
|
||||
/* auth-author-mysql-mapper|selectAuthorInfos-권한 목록 조회|julim */
|
||||
DELETE
|
||||
FROM xit_author_info
|
||||
WHERE author_code = #{authorCode}
|
||||
</delete>
|
||||
|
||||
|
||||
<select id="selectAuthRoleGrantList" resultType="kr.xit.framework.biz.cmm.model.XitRoleInfoVO">
|
||||
/* auth-author-mysql-mapper|selectAuthRoleGrantList- 권한별 롤 조회|julim */
|
||||
SELECT xri.role_code
|
||||
, xri.role_nm
|
||||
, xri.role_pttrn
|
||||
, xri.role_dc
|
||||
, xri.role_ty
|
||||
, xri.role_sort
|
||||
, DATE_FORMAT(arr.creat_dt, '%Y%m%d%H%i%s') AS creatDt
|
||||
, IF(arr.role_code IS NULL, 'N', 'N') AS "regYn"
|
||||
FROM xit_role_info xri
|
||||
LEFT OUTER JOIN ( SELECT author_code
|
||||
, role_code
|
||||
, creat_dt
|
||||
FROM xit_author_role_relate
|
||||
WHERE author_code = #{authorCode}
|
||||
) arr
|
||||
ON xri.role_code = arr.role_code
|
||||
ORDER BY arr.role_code DESC, xri.role_sort
|
||||
</select>
|
||||
|
||||
<delete id="deleteRoleGrant" parameterType="map">
|
||||
/* auth-author-mysql-mapper|deleteRoleGrant-권한 롤 삭제|julim */
|
||||
DELETE
|
||||
FROM xit_author_role_relate
|
||||
WHERE author_code = #{authorCode}
|
||||
AND role_code = #{roleCode}
|
||||
</delete>
|
||||
|
||||
<delete id="saveRoleGrant" parameterType="map">
|
||||
/* auth-author-mysql-mapper|saveRoleGrant-권한 롤 등록|julim */
|
||||
INSERT INTO xit_author_role_relate (
|
||||
author_code
|
||||
, role_code
|
||||
, creat_dt
|
||||
) VALUES (
|
||||
#{authorCode}
|
||||
, #{roleCode}
|
||||
, NOW()
|
||||
)
|
||||
ON DUPLICATE KEY UPDATE
|
||||
creat_dt = NOW()
|
||||
</delete>
|
||||
|
||||
<!-- *************************************************************************************************************
|
||||
* xit_role_sclsrt_rescue : 역할 계층 정보
|
||||
************************************************************************************************************** -->
|
||||
<select id="selectRoleSclsrtRescues" parameterType="kr.xit.framework.biz.cmm.model.XitRoleSclsrtRescueVO" resultType="kr.xit.framework.biz.cmm.model.XitRoleSclsrtRescueVO">
|
||||
/* auth-author-mysql-mapper|selectRoleSclsrtRescues-역할계층 조회|julim */
|
||||
SELECT parnts_role
|
||||
, chldrn_role
|
||||
FROM xit_role_sclsrt_rescue
|
||||
<where>
|
||||
<if test="@kr.xit.framework.core.utils.XitCmmnUtil@notEmpty(parntsRole)">
|
||||
AND parnts_role = #{parntsRole}
|
||||
</if>
|
||||
<if test="@kr.xit.framework.core.utils.XitCmmnUtil@notEmpty(chldrnRole)">
|
||||
AND chldrn_role = #{chldrnRole}
|
||||
</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectRoleSclsrtRescue" parameterType="kr.xit.framework.biz.cmm.model.XitRoleSclsrtRescueVO" resultType="kr.xit.framework.biz.cmm.model.XitRoleSclsrtRescueVO">
|
||||
/* auth-author-mysql-mapper|selectRoleSclsrtRescue-역할계층 정보 조회|julim */
|
||||
SELECT parnts_role
|
||||
, chldrn_role
|
||||
FROM xit_role_sclsrt_rescue
|
||||
WHERE parnts_role = #{parntsRole}
|
||||
AND chldrn_role = #{chldrnRole}
|
||||
</select>
|
||||
<insert id="insertRoleSclsrtRescue" parameterType="kr.xit.framework.biz.cmm.model.XitRoleSclsrtRescueVO">
|
||||
/* auth-author-mysql-mapper|insertRoleSclsrtRescue-역할계층 정보 등록|julim */
|
||||
INSERT
|
||||
INTO xit_role_sclsrt_rescue(
|
||||
parnts_role
|
||||
, chldrn_role
|
||||
)VALUES(
|
||||
#{parntsRole}
|
||||
, #{chldrnRole}
|
||||
)
|
||||
</insert>
|
||||
|
||||
<delete id="deleteRoleSclsrtRescue" parameterType="kr.xit.framework.biz.cmm.model.XitRoleSclsrtRescueVO">
|
||||
/* auth-author-mysql-mapper|deleteRoleSclsrtRescue-역할계층 삭제 조회|julim */
|
||||
DELETE
|
||||
FROM xit_role_sclsrt_rescue
|
||||
<where>
|
||||
<if test="@kr.xit.framework.core.utils.XitCmmnUtil@notEmpty(parntsRole)">
|
||||
AND parnts_role = #{parntsRole}
|
||||
</if>
|
||||
<if test="@kr.xit.framework.core.utils.XitCmmnUtil@notEmpty(chldrnRole)">
|
||||
AND chldrn_role = #{chldrnRole}
|
||||
</if>
|
||||
</where>
|
||||
</delete>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<select id="findListAuthorRole" resultType="java.util.Map">
|
||||
/** XitAuthRegMngMapper.findListAuthorRole */
|
||||
/** 권한롤관리 목록 조회 */
|
||||
|
||||
|
||||
<include refid="findListAuthorRole_SELECT"/>
|
||||
<include refid="findListAuthorRole_FROM"/>
|
||||
WHERE 1 = 1
|
||||
<include refid="findListAuthorRole_WHERE"/>
|
||||
ORDER BY A.ROLE_CODE
|
||||
|
||||
|
||||
</select>
|
||||
<select id="findListAuthorRoleTotCnt" resultType="int">
|
||||
/** XitAuthRegMngMapper.findListAuthorRoleTotCnt */
|
||||
/** 권한롤관리 목록 조회 총 건수 */
|
||||
SELECT COUNT(1) AS "CNT"
|
||||
<include refid="findListAuthorRole_FROM"/>
|
||||
WHERE 1 = 1
|
||||
<include refid="findListAuthorRole_WHERE"/>
|
||||
</select>
|
||||
<sql id="findListAuthorRole_SELECT">
|
||||
SELECT A.ROLE_CODE AS "roleCode"
|
||||
,A.ROLE_NM AS "roleNm"
|
||||
,A.ROLE_PTTRN AS "rolePtn"
|
||||
,A.ROLE_DC AS "roleDc"
|
||||
,A.ROLE_TY AS "roleTyp"
|
||||
,A.ROLE_SORT AS "roleSort"
|
||||
,B.AUTHOR_CODE AS "authorCode"
|
||||
,B.CREAT_DT AS "creatDt"
|
||||
,(CASE WHEN B.ROLE_CODE IS NULL THEN 'N' ELSE 'Y' END) AS "regYn"
|
||||
</sql>
|
||||
<sql id="findListAuthorRole_FROM">
|
||||
FROM XIT_ROLE_INFO A
|
||||
LEFT OUTER JOIN ( SELECT AUTHOR_CODE, ROLE_CODE, CREAT_DT
|
||||
FROM XIT_AUTHOR_ROLE_RELATE
|
||||
WHERE AUTHOR_CODE = #{searchKeyword}
|
||||
) B ON A.ROLE_CODE = B.ROLE_CODE
|
||||
</sql>
|
||||
<sql id="findListAuthorRole_WHERE">
|
||||
</sql>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</mapper>
|
@ -1,207 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="kr.xit.framework.biz.mng.auth.mapper.AuthMgtMapper">
|
||||
|
||||
<!-- *************************************************************************************************************
|
||||
* xit_user_info : 업무사용자 정보
|
||||
************************************************************************************************************** -->
|
||||
<select id="findXitAuthorInfos" resultType="kr.xit.framework.biz.cmm.model.XitAuthorInfoVO">
|
||||
/** findXitAuthorInfos */
|
||||
/** 권한정보 다건 조회 */
|
||||
SELECT AUTHOR_CODE
|
||||
,AUTHOR_NM
|
||||
,AUTHOR_DC
|
||||
,AUTHOR_CREAT_DE
|
||||
FROM XIT_AUTHOR_INFO
|
||||
WHERE 1=1
|
||||
<if test="@kr.xit.framework.core.utils.XitCmmnUtil@notEmpty(author_code )">AND AUTHOR_CODE = #{author_code }</if>
|
||||
<if test="@kr.xit.framework.core.utils.XitCmmnUtil@notEmpty(author_nm )">AND AUTHOR_NM = #{author_nm }</if>
|
||||
<if test="@kr.xit.framework.core.utils.XitCmmnUtil@notEmpty(author_dc )">AND AUTHOR_DC = #{author_dc }</if>
|
||||
<if test="@kr.xit.framework.core.utils.XitCmmnUtil@notEmpty(author_creat_de)">AND AUTHOR_CREAT_DE = #{author_creat_de}</if>
|
||||
</select>
|
||||
<select id="findXitAuthorInfo" resultType="kr.xit.framework.biz.cmm.model.XitAuthorInfoVO">
|
||||
/** findXitAuthorInfo */
|
||||
/** 권한정보 조회 */
|
||||
SELECT AUTHOR_CODE
|
||||
,AUTHOR_NM
|
||||
,AUTHOR_DC
|
||||
,AUTHOR_CREAT_DE
|
||||
FROM XIT_AUTHOR_INFO
|
||||
WHERE 1=1
|
||||
AND AUTHOR_CODE = #{author_code}
|
||||
</select>
|
||||
<insert id="addXitAuthorInfo">
|
||||
/** addXitAuthorInfo */
|
||||
/** 권한정보 등록 */
|
||||
INSERT INTO XIT_AUTHOR_INFO(
|
||||
AUTHOR_CODE
|
||||
<if test="@kr.xit.framework.core.utils.XitCmmnUtil@notEmpty(author_nm)">,AUTHOR_NM</if>
|
||||
<if test="@kr.xit.framework.core.utils.XitCmmnUtil@notEmpty(author_dc)">,AUTHOR_DC</if>
|
||||
,AUTHOR_CREAT_DE
|
||||
)VALUES(
|
||||
#{author_code }
|
||||
<if test="@kr.xit.framework.core.utils.XitCmmnUtil@notEmpty(author_nm)">,#{author_nm }</if>
|
||||
<if test="@kr.xit.framework.core.utils.XitCmmnUtil@notEmpty(author_dc)">,#{author_dc }</if>
|
||||
,DATE_FORMAT(NOW(), '%Y%m%d%H%i%s')
|
||||
)
|
||||
</insert>
|
||||
<update id="modifyXitAuthorInfo">
|
||||
/** modifyXitAuthorInfo */
|
||||
/** 권한정보 수정 */
|
||||
UPDATE XIT_AUTHOR_INFO
|
||||
SET
|
||||
AUTHOR_CREAT_DE = AUTHOR_CREAT_DE
|
||||
<if test="@kr.xit.framework.core.utils.XitCmmnUtil@notBlank(author_nm)">,AUTHOR_NM = #{author_nm}</if>
|
||||
<if test="@kr.xit.framework.core.utils.XitCmmnUtil@notBlank(author_dc)">,AUTHOR_DC = #{author_dc}</if>
|
||||
WHERE 1=1
|
||||
AND AUTHOR_CODE = #{author_code}
|
||||
</update>
|
||||
<delete id="removeXitAuthorInfo">
|
||||
/** removeXitAuthorInfo */
|
||||
/** 권한정보 삭제 */
|
||||
DELETE FROM XIT_AUTHOR_INFO
|
||||
WHERE 1=1
|
||||
AND AUTHOR_CODE = #{author_code}
|
||||
</delete>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<!-- SQL 페이징 코드 -->
|
||||
<sql id="pageBefore">
|
||||
SELECT LIST.* FROM(
|
||||
</sql>
|
||||
|
||||
<sql id="pageAfter">
|
||||
) LIST LIMIT #{firstIndex}, #{recordCountPerPage}
|
||||
</sql>
|
||||
|
||||
|
||||
<sql id="findList_SELECT">
|
||||
SELECT A.AUTHOR_CODE AS "authorCode"
|
||||
,A.AUTHOR_NM AS "authorNm"
|
||||
,A.AUTHOR_DC AS "authorDc"
|
||||
,A.AUTHOR_CREAT_DE AS "authorCreatDe"
|
||||
</sql>
|
||||
<sql id="findList_FROM">
|
||||
FROM XIT_AUTHOR_INFO A
|
||||
</sql>
|
||||
<sql id="findList_WHERE">
|
||||
<if test="'1'.toString() == searchCondition">
|
||||
AND A.AUTHOR_NM LIKE CONCAT('%',#{searchKeyword},'%')
|
||||
</if>
|
||||
</sql>
|
||||
|
||||
|
||||
|
||||
<select id="findList" resultType="kr.xit.framework.biz.mng.auth.model.XitAuthRegMngVO">
|
||||
/** XitAuthRegMngMapper.findList */
|
||||
/** 권한관리 목록 조회 */
|
||||
<if test="searchGubun == 'list'">
|
||||
<include refid="pageBefore" />
|
||||
</if>
|
||||
|
||||
<include refid="findList_SELECT"/>
|
||||
<include refid="findList_FROM"/>
|
||||
WHERE 1=1
|
||||
<include refid="findList_WHERE"/>
|
||||
ORDER BY A.AUTHOR_CREAT_DE DESC
|
||||
|
||||
<if test="searchGubun == 'list'">
|
||||
<include refid="pageAfter" />
|
||||
</if>
|
||||
</select>
|
||||
|
||||
|
||||
|
||||
<select id="findListTotCnt" resultType="int">
|
||||
/** XitAuthRegMngMapper.findListTotCnt */
|
||||
/** 권한관리 목록 총건수 조회 */
|
||||
SELECT COUNT(1) AS "CNT"
|
||||
<include refid="findList_FROM"/>
|
||||
WHERE 1=1
|
||||
<include refid="findList_WHERE"/>
|
||||
</select>
|
||||
|
||||
|
||||
|
||||
<select id="findView" resultType="kr.xit.framework.biz.mng.auth.model.XitAuthRegMngVO">
|
||||
/** XitAuthRegMngMapper.findView */
|
||||
/** 권한관리 상세정보 조회 */
|
||||
<include refid="findList_SELECT"/>
|
||||
<include refid="findList_FROM"/>
|
||||
WHERE A.AUTHOR_CODE=#{authorCode}
|
||||
</select>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<select id="findListAuthorRole" resultType="java.util.Map">
|
||||
/** XitAuthRegMngMapper.findListAuthorRole */
|
||||
/** 권한롤관리 목록 조회 */
|
||||
<if test="searchGubun == 'list'">
|
||||
<include refid="pageBefore"/>
|
||||
</if>
|
||||
|
||||
<include refid="findListAuthorRole_SELECT"/>
|
||||
<include refid="findListAuthorRole_FROM"/>
|
||||
WHERE 1 = 1
|
||||
<include refid="findListAuthorRole_WHERE"/>
|
||||
ORDER BY A.ROLE_CODE
|
||||
|
||||
<if test="searchGubun == 'list'">
|
||||
<include refid="pageAfter"/>
|
||||
</if>
|
||||
</select>
|
||||
<select id="findListAuthorRoleTotCnt" resultType="int">
|
||||
/** XitAuthRegMngMapper.findListAuthorRoleTotCnt */
|
||||
/** 권한롤관리 목록 조회 총 건수 */
|
||||
SELECT COUNT(1) AS "CNT"
|
||||
<include refid="findListAuthorRole_FROM"/>
|
||||
WHERE 1 = 1
|
||||
<include refid="findListAuthorRole_WHERE"/>
|
||||
</select>
|
||||
<sql id="findListAuthorRole_SELECT">
|
||||
SELECT A.ROLE_CODE AS "roleCode"
|
||||
,A.ROLE_NM AS "roleNm"
|
||||
,A.ROLE_PTTRN AS "rolePtn"
|
||||
,A.ROLE_DC AS "roleDc"
|
||||
,A.ROLE_TY AS "roleTyp"
|
||||
,A.ROLE_SORT AS "roleSort"
|
||||
,B.AUTHOR_CODE AS "authorCode"
|
||||
,B.CREAT_DT AS "creatDt"
|
||||
,(CASE WHEN B.ROLE_CODE IS NULL THEN 'N' ELSE 'Y' END) AS "regYn"
|
||||
</sql>
|
||||
<sql id="findListAuthorRole_FROM">
|
||||
FROM XIT_ROLE_INFO A
|
||||
LEFT OUTER JOIN ( SELECT AUTHOR_CODE, ROLE_CODE, CREAT_DT
|
||||
FROM XIT_AUTHOR_ROLE_RELATE
|
||||
WHERE AUTHOR_CODE = #{searchKeyword}
|
||||
) B ON A.ROLE_CODE = B.ROLE_CODE
|
||||
</sql>
|
||||
<sql id="findListAuthorRole_WHERE">
|
||||
</sql>
|
||||
|
||||
|
||||
|
||||
</mapper>
|
@ -0,0 +1,21 @@
|
||||
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
|
||||
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
|
||||
<%-- TODO: 완료후 comment 삭제
|
||||
아래와 같이 isUpdate 정의 필요
|
||||
<c:set var="isUpdate" value="${!empty authorInfoVO.authorCode}"/>
|
||||
--%>
|
||||
<!-- popup button -->
|
||||
<div class="popup_btn">
|
||||
<span class="flr">
|
||||
<c:choose>
|
||||
<c:when test="${isUpdate}">
|
||||
<a href="#" class="btn blue" id="btnModify">변경</a>
|
||||
<a href="#" class="btn red" id="btnRemove">삭제</a>
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<a href="#" class="btn blue" id="btnRegist">등록</a>
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
<a href="#" class="btn lightgray" onclick="window.close()">닫기</a>
|
||||
</span>
|
||||
</div>
|
@ -0,0 +1,20 @@
|
||||
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
|
||||
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
|
||||
|
||||
<%-- TODO: 완료후 comment 삭제
|
||||
아래와 같이 isUpdate 정의 필요
|
||||
<c:set var="isUpdate" value="${!empty authorInfoVO.authorCode}"/>
|
||||
<c:set var="bizName" value="권한그룹"/>
|
||||
--%>
|
||||
<!-- popup title -->
|
||||
<p class="pop_title">
|
||||
<c:choose>
|
||||
<c:when test="${isUpdate}">
|
||||
<c:out value="${bizName}"/> 변경
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<c:out value="${bizName}"/> 등록
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
</p>
|
||||
|
@ -0,0 +1,129 @@
|
||||
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
|
||||
<%@ include file="/WEB-INF/jsp/framework/taglibs.jsp" %>
|
||||
|
||||
<c:set var="isUpdate" value="${!empty authorInfoVO.authorCode}"/>
|
||||
<c:set var="bizName" value="권한"/>
|
||||
|
||||
<form>
|
||||
|
||||
<div class="popup" style="min-width: 400px;">
|
||||
<div class="popup_inner" style="max-width: 400px;">
|
||||
<%@include file="/WEB-INF/jsp/framework/biz-popup-title.jsp"%>
|
||||
|
||||
<table class="tbl03">
|
||||
<caption><c:out value="${bizName}"/> <spring:message code="title.update"/> / <spring:message code="title.create"/></caption>
|
||||
<colgroup>
|
||||
<col style="width: 20%;"/>
|
||||
<col/>
|
||||
</colgroup>
|
||||
<tr>
|
||||
<th class="required" scope="row" nowrap="nowrap">
|
||||
<label>권한코드</label>
|
||||
</th>
|
||||
<td nowrap="nowrap">
|
||||
<input name="authorCode" id="authorCode" type="text" value="<c:out value='${authorInfoVO.authorCode}'/>" readonly="isUpdate" size="40" title="권한코드" />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th class="required" scope="row" nowrap="nowrap">
|
||||
<label>권한명</label>
|
||||
</th>
|
||||
<td nowrap="nowrap">
|
||||
<input name="authorNm" id="authorNm" type="text" value="<c:out value='${authorInfoVO.authorNm}'/>" maxLength="50" size="40" title="권한명" />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row" nowrap="nowrap">
|
||||
<label>설명</label>
|
||||
</th>
|
||||
<td nowrap="nowrap">
|
||||
<input name="authorDc" id="authorDc" type="text" value="<c:out value='${authorInfoVO.authorDc}'/>" maxLength="50" size="50" title="설명" />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row" nowrap="nowrap">
|
||||
<label>등록일자</label>
|
||||
</th>
|
||||
<td nowrap="nowrap">
|
||||
<input name="authorCreatDe" id="authorCreatDe" type="text" value="<c:out value='${authorInfoVO.authorCreatDe}'/>" maxLength="50" size="20" readonly="readonly" title="등록일자"/>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<%@include file="/WEB-INF/jsp/framework/biz-popup-btn.jsp"%>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<!-- //popup -->
|
||||
</form>
|
||||
|
||||
|
||||
<script type="text/javaScript">
|
||||
/**************************************************************************
|
||||
* Global Variable
|
||||
**************************************************************************/
|
||||
|
||||
/* *******************************
|
||||
* Biz function
|
||||
******************************* */
|
||||
const fnBiz = {
|
||||
add: () => {
|
||||
if(!fnBiz.validate()) return;
|
||||
|
||||
cmmBizAjax('add', {
|
||||
url: '<c:url value="/framework/biz/mng/auth/addAuthAuthor.do"/>'
|
||||
,data: $("form").serialize()
|
||||
//,contentType: 'x-www-form-url-encoded'
|
||||
})
|
||||
}
|
||||
|
||||
,modify: () => {
|
||||
if(!fnBiz.validate()) return;
|
||||
|
||||
cmmBizAjax('modify', {
|
||||
url: '<c:url value="/framework/biz/mng/auth/modifyAuthAuthor.do"/>'
|
||||
,data: $("form").serialize()
|
||||
});
|
||||
}
|
||||
|
||||
, remove: () => {
|
||||
cmmBizAjax('remove', {
|
||||
url: '<c:url value="/framework/biz/mng/auth/removeAuthAuthor.do"/>'
|
||||
,data: {authorCode: $('#authorCode').val()}
|
||||
});
|
||||
}
|
||||
|
||||
,validate: () => {
|
||||
if($('#authorCode').val() === ''){
|
||||
alert('[권한코드]는 필수 입니다.');
|
||||
$('#authorCode').focus();
|
||||
return false;
|
||||
}
|
||||
if($('#authorNm').val() === ''){
|
||||
alert('[권한명]은 필수 입니다.');
|
||||
$('#authorNm').focus();
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
};
|
||||
|
||||
/**************************************************************************
|
||||
* event
|
||||
**************************************************************************/
|
||||
$(() => {
|
||||
$('#btnRegist').on('click', () => fnBiz.add());
|
||||
|
||||
$('#btnModify').on('click', () => fnBiz.modify());
|
||||
|
||||
$('#btnRemove').on('click', () => fnBiz.remove());
|
||||
});
|
||||
|
||||
/**************************************************************************
|
||||
* initialize
|
||||
**************************************************************************/
|
||||
$(document).ready(function(){
|
||||
$('#authorCreatDe').val(setDateTimeFmt('<c:out value="${authorInfoVO.authorCreatDe}"/>'));
|
||||
});
|
||||
|
||||
</script>
|
@ -1,171 +0,0 @@
|
||||
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
|
||||
<%@ include file="/WEB-INF/jsp/framework/taglibs.jsp" %>
|
||||
<%@ taglib prefix="validator" uri="http://www.springmodules.org/tags/commons-validator" %>
|
||||
|
||||
|
||||
<c:set var="registerFlag" value="${empty authorManageVO.authorCode ? 'INSERT' : 'UPDATE'}"/>
|
||||
<c:set var="registerFlagName" value="${empty authorManageVO.authorCode ? '권한 등록' : '권한 수정'}"/>
|
||||
<!-- 검색 필드 박스 시작 -->
|
||||
|
||||
<script type="text/javascript" src="<c:url value="/framework/util/validator.do"/>"></script>
|
||||
<validator:javascript formName="authorManage" staticJavascript="false" xhtml="true" cdata="false"/>
|
||||
<form:form commandName="authorManage" method="post" >
|
||||
|
||||
<div class="popup" style="min-width: 400px;">
|
||||
<div class="popup_inner" style="max-width: 400px;">
|
||||
<p class="pop_title">권한 등록</p>
|
||||
<table class="tbl03">
|
||||
<caption>권한 등록</caption>
|
||||
<tr>
|
||||
<th class="required" width="20%" scope="row" nowrap="nowrap">권한 코드
|
||||
<img src="<c:url value='/'/>resourcesimages/required.gif" width="15" height="15" alt="필수" />
|
||||
</th>
|
||||
<td nowrap="nowrap"><input name="authorCode" id="authorCode" type="text" value="<c:out value='${authorManage.authorCode}'/>" size="40" title="권한코드" /> <form:errors path="authorCode" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th class="required" width="20%" scope="row" nowrap="nowrap">권한 명
|
||||
<img src="<c:url value='/'/>resourcesimages/required.gif" width="15" height="15" alt="필수" />
|
||||
</th>
|
||||
<td nowrap="nowrap"><input name="authorNm" id="authorNm" type="text" value="<c:out value='${authorManage.authorNm}'/>" maxLength="50" size="40" title="권한명" /> <form:errors path="authorNm" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th class="required" width="20%" scope="row" nowrap="nowrap">설명</th>
|
||||
<td nowrap="nowrap"><input name="authorDc" id="authorDc" type="text" value="<c:out value='${authorManage.authorDc}'/>" maxLength="50" size="50" title="설명" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th class="required" width="20%" scope="row" nowrap="nowrap">등록일자</th>
|
||||
<td nowrap="nowrap"><input name="authorCreatDe" id="authorCreatDe" type="text" value="<c:out value='${authorManage.authorCreatDe}'/>" maxLength="50" size="20" readonly="readonly" title="등록일자"/></td>
|
||||
</tr>
|
||||
</table>
|
||||
<div class="popup_btn">
|
||||
<span class="flr" colspan="4">
|
||||
<c:if test="${registerFlag == 'INSERT'}">
|
||||
<a href="#LINK" class="btn blue" id="btnSave">저장</a>
|
||||
</c:if>
|
||||
<c:if test="${registerFlag == 'UPDATE'}">
|
||||
<a href="#LINK" class="btn blue" id="update_btn">변경</a>
|
||||
<a href="#LINK" class="btn red" id="delete_btn">삭제</a>
|
||||
</c:if>
|
||||
<a href="#" class="btn lightgray" id="btnClose">닫기</a>
|
||||
</span>
|
||||
</div>
|
||||
<!-- //등록버튼 -->
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<!-- //popup -->
|
||||
</form:form>
|
||||
|
||||
|
||||
<script type="text/javaScript">
|
||||
|
||||
$(document).ready(function(){
|
||||
XitAuthRegMng_edit.init();
|
||||
});
|
||||
/* *******************************
|
||||
* 권한관리 수정화면 Functions
|
||||
******************************* */
|
||||
var XitAuthRegMng_edit = {
|
||||
init : function(){
|
||||
//닫기 버튼 Event
|
||||
$("#btnClose").click(function() {
|
||||
window.close();
|
||||
});
|
||||
//저장 버튼 Event 설정
|
||||
$('#btnSave').on({
|
||||
click: function(){
|
||||
XitAuthRegMng_edit.addData();
|
||||
}
|
||||
});
|
||||
$('#update_btn').on({
|
||||
click: function(){
|
||||
XitAuthRegMng_edit.modifyData();
|
||||
}
|
||||
});
|
||||
$('#delete_btn').on({
|
||||
click: function(){
|
||||
XitAuthRegMng_edit.removeData();
|
||||
}
|
||||
});
|
||||
$(".popup").css("position","absolute");
|
||||
$(".content_header").css("display","none");
|
||||
$("#cur_loc").css("display","none");
|
||||
},
|
||||
/* ========================
|
||||
* 데이터 등록
|
||||
======================== */
|
||||
addData : function(){
|
||||
if(!validateAuthorManage(document.getElementById("authorManage")))
|
||||
return;
|
||||
|
||||
var varFrom = document.getElementById("authorManage");
|
||||
if(confirm("저장 하시겠습니까?")){
|
||||
var param = $(varFrom).serialize();
|
||||
$.ajax({
|
||||
url : "/framework/biz/mng/auth/AuthRegMng_insert_proc.do",
|
||||
data : param,
|
||||
type : "post",
|
||||
dataType : "json",
|
||||
success : function(data) {
|
||||
alert(data.resp.message);
|
||||
window.opener.XitAuthRegMng_list.findData();
|
||||
window.close();
|
||||
},
|
||||
error: function(){
|
||||
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
/* ========================
|
||||
* 데이터 수정
|
||||
======================== */
|
||||
,modifyData : function(){
|
||||
if(!validateAuthorManage(document.getElementById("authorManage")))
|
||||
return;
|
||||
|
||||
var varFrom = document.getElementById("authorManage");
|
||||
if(confirm("수정 하시겠습니까?")){
|
||||
var param = $(varFrom).serialize();
|
||||
$.ajax({
|
||||
url : "/framework/biz/mng/auth/AuthRegMng_update_proc.do",
|
||||
data : param,
|
||||
type : "post",
|
||||
dataType : "json",
|
||||
success : function(data) {
|
||||
alert(data.resp.message);
|
||||
window.opener.XitAuthRegMng_list.findData();
|
||||
window.close();
|
||||
},
|
||||
error: function(){
|
||||
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
/* ========================
|
||||
* 데이터 삭제
|
||||
======================== */
|
||||
,removeData : function(){
|
||||
var varFrom = document.getElementById("authorManage");
|
||||
if(confirm("삭제 하시겠습니까?")){
|
||||
var param = $(varFrom).serialize();
|
||||
$.ajax({
|
||||
url : "/framework/biz/mng/auth/AuthRegMng_delete_proc.do",
|
||||
data : param,
|
||||
type : "post",
|
||||
dataType : "json",
|
||||
success : function(data) {
|
||||
alert(data.resp.message);
|
||||
window.opener.XitAuthRegMng_list.findData();
|
||||
window.close();
|
||||
},
|
||||
error: function(){
|
||||
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
</script>
|
@ -0,0 +1,255 @@
|
||||
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
|
||||
<%@ include file="/WEB-INF/jsp/framework/taglibs.jsp" %>
|
||||
|
||||
|
||||
|
||||
<title>권한별 롤 목록</title>
|
||||
<div class="popup" style="min-width: 400px;">
|
||||
<div class="popup_inner">
|
||||
<p class="pop_title">권한별 롤 목록</p>
|
||||
|
||||
<form name="frmSearch" id="frmSearch">
|
||||
<div class="search r2">
|
||||
<table>
|
||||
<caption>검색조건</caption>
|
||||
<colgroup>
|
||||
<col style="width: 8%;"/>
|
||||
<col style="width: 20%;"/>
|
||||
<col style="width: 8%;"/>
|
||||
<col/>
|
||||
<col style="width: 8%;"/>
|
||||
<col/>
|
||||
<col style="width: 7%;"/>
|
||||
</colgroup>
|
||||
<tbody>
|
||||
<tr>
|
||||
<th>권한코드 : </th>
|
||||
<td colspan="6">
|
||||
<input id="authorCode" name="authorCode" type="text" size="30" value="<c:out value='${authorRoleManageVO.roleCode}'/>" title="검색" readonly="readonly" />
|
||||
</td>
|
||||
<td>
|
||||
<input type="button" id="btnSearch" class="btn_search" title="검색" value="검색" />
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</form>
|
||||
<!-- 데이터 출력 -->
|
||||
<div id="grid"></div>
|
||||
<div class="popup_btn">
|
||||
<span class="fll">
|
||||
<div class="list clearfix" id="totCnt">전체 ㅣ <span></span></div>
|
||||
</span>
|
||||
<span class="flr">
|
||||
<a href="#" class="btn blue" id="btnRegist" title="저장">저장</a>
|
||||
<a href="#" class="btn lightgray" onclick="window.close()">닫기</a>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<script type="text/javascript">
|
||||
/**************************************************************************
|
||||
* Global Variable
|
||||
**************************************************************************/
|
||||
let GRID = null;
|
||||
const REG_YN = [
|
||||
{code: 'Y', codeNm: '등록'},
|
||||
{code: 'N', codeNm: '미등록'},
|
||||
]
|
||||
|
||||
/* *******************************
|
||||
* Biz function
|
||||
******************************* */
|
||||
const fnBiz = {
|
||||
search: () => {
|
||||
GRID.reloadData();
|
||||
}
|
||||
,add: () => {
|
||||
var dataSet = GRID.getData(); //Grid에 출력된 DataSet
|
||||
const arrChecks = GRID.getCheckedRows();
|
||||
|
||||
if(arrChecks.length==0) {
|
||||
alert("등록[변경]할 목록을 선택하세요.");
|
||||
return false;
|
||||
}
|
||||
|
||||
const arrDatas = [];
|
||||
arrChecks.forEach((row) => {
|
||||
arrDatas.push({roleCode: row.roleCode, regYn: row.regYn})
|
||||
});
|
||||
|
||||
const data = {
|
||||
authorCode: $('#authorCode').val()
|
||||
,grantData: arrDatas
|
||||
}
|
||||
|
||||
if(confirm("등록 하시겠습니까?")) {
|
||||
cmmAjax({
|
||||
url: '<c:url value="/framework/biz/mng/auth/saveAuthRoleGrantList.do"/>'
|
||||
,data: JSON.stringify(data)
|
||||
,contentType: 'application/json; charset=utf-8'
|
||||
,success: () => {
|
||||
fnBiz.search();
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**************************************************************************
|
||||
* event
|
||||
**************************************************************************/
|
||||
$(() => {
|
||||
$('#btnSearch').bind('click', () => fnBiz.search());
|
||||
|
||||
$('#btnRegist').bind('click', () => {
|
||||
fnBiz.add();
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
/* *******************************
|
||||
* Grid
|
||||
******************************* */
|
||||
const initGrid = () => {
|
||||
const gridColumns = [
|
||||
{
|
||||
header: '롤 ID',
|
||||
name: 'roleCode',
|
||||
width: 150,
|
||||
sortingType: 'asc',
|
||||
sortable: true,
|
||||
filter: 'select' //fiter 옵션(select/text/number/date/.. 등이 있으며 설정방법은 상이하므로 사이트 참조)
|
||||
// filter: { type: 'text', showApplyBtn: true, showClearBtn: true },
|
||||
},
|
||||
{
|
||||
header: '롤 명',
|
||||
name: 'roleNm',
|
||||
width: 150,
|
||||
sortingType: 'desc',
|
||||
sortable: true,
|
||||
filter: 'select' //fiter 옵션(select/text/number/date/.. 등이 있으며 설정방법은 상이하므로 사이트 참조)
|
||||
},
|
||||
{
|
||||
header: '등록여부',
|
||||
name: 'regYn',
|
||||
// copyOptions: {
|
||||
// useListItemText: true
|
||||
// },
|
||||
width: 60,
|
||||
align: 'center',
|
||||
sortable: true,
|
||||
/* 에디터 적용 */
|
||||
formatter: 'listItemText',
|
||||
editor: {
|
||||
type: 'radio', //select, radio, checkbox, text
|
||||
options: {
|
||||
listItems: [
|
||||
<c:forTokens var="row" items="Y,N" delims="," varStatus="status">
|
||||
<c:choose>
|
||||
<c:when test="${status.first}">
|
||||
{value: '${row}', text: '${"Y" eq row ? "등록" : "미등록"}' }
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
,{value: '${row}', text: '${"Y" eq row ? "등록" : "미등록"}' }
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
</c:forTokens>
|
||||
]
|
||||
}
|
||||
},
|
||||
onBeforeChange: function(ev) { //변경 전(ev.value)/후(ev.nextValue)
|
||||
// console.log('Grade before change:' + ev);
|
||||
},
|
||||
onAfterChange: function(ev) { //변경 전(ev.prevValue)/후(ev.value)
|
||||
// console.log('Grade after change:' + ev);
|
||||
}
|
||||
/* //에디터 적용 */
|
||||
},
|
||||
{
|
||||
header: '롤 패턴',
|
||||
name: 'rolePttrn',
|
||||
minWidth: 150,
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
header: '롤 설명',
|
||||
name: 'roleDc',
|
||||
minWidth: 150,
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
header: '롤 타입',
|
||||
name: 'roleTy',
|
||||
width: 50,
|
||||
sortingType: 'desc',
|
||||
sortable: true,
|
||||
align: 'center',
|
||||
filter: 'select' //fiter 옵션(select/text/number/date/.. 등이 있으며 text/date 설정방법은 상이하므로 사이트 참조)
|
||||
},
|
||||
{
|
||||
header: '정렬순서',
|
||||
name: 'roleSort',
|
||||
width: 50,
|
||||
sortable: true,
|
||||
align: 'center'
|
||||
},
|
||||
{
|
||||
header: '등록일시',
|
||||
name: 'creatDt',
|
||||
width: 100,
|
||||
align: 'center',
|
||||
sortable: true,
|
||||
formatter({value}){
|
||||
return setDateTimeFmt(value);
|
||||
}
|
||||
}
|
||||
];
|
||||
|
||||
const gridOptions = {
|
||||
el: 'grid',
|
||||
rowHeaders: ['rowNum', 'checkbox'],
|
||||
columns: gridColumns,
|
||||
pageOptions: {
|
||||
useClient: true,
|
||||
perPage: 100
|
||||
},
|
||||
columnOptions: {
|
||||
frozenCount: 3
|
||||
},
|
||||
bodyHeight: 400
|
||||
};
|
||||
|
||||
const gridDatasource = { //DataSource
|
||||
/* -----------------------
|
||||
* DataSource API Setting
|
||||
----------------------- */
|
||||
initialRequest: true, // 화면 load시 조회 안함 - default
|
||||
api: {
|
||||
readData: {
|
||||
url: '<c:url value="/framework/biz/mng/auth/findAuthRoleGrantList.do"/>'
|
||||
, initParams: {authorCode: $('#authorCode').val()}
|
||||
,serializer: (params) => fnAddPageInfo(document.frmSearch, params)
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
GRID = TuiGrid.of(gridOptions, gridDatasource, (res) => {
|
||||
});
|
||||
}
|
||||
|
||||
/**************************************************************************
|
||||
* initialize
|
||||
**************************************************************************/
|
||||
$(document).ready(function(){
|
||||
initGrid();
|
||||
});
|
||||
</script>
|
||||
|
||||
|
Loading…
Reference in New Issue