상단 관리자 메뉴 하위 페이지 오류 수정.
parent
3389346ca3
commit
6363358ab7
|
|
@ -25,83 +25,57 @@
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
<select id="Log.selectUserLog" parameterType="logSearchVO" resultType="logVO">
|
<select id="Log.selectUserLog" parameterType="logSearchVO" resultType="logVO">
|
||||||
<![CDATA[
|
select (ROW_NUMBER() OVER()) AS RNUM,
|
||||||
SELECT
|
LOG_LIST.*
|
||||||
LOG_LIST.*
|
FROM (SELECT LOG.UL_USERID AS USERID,
|
||||||
FROM
|
LOG.UL_NAME AS NAME,
|
||||||
(
|
LOG.UL_LOCATION1 AS LOCATION1,
|
||||||
SELECT
|
LOG.UL_LOCATION2 AS LOCATION2,
|
||||||
ROWNUM RNUM, LOG_LIST.*
|
LOG.UL_LOCATION3 AS LOCATION3,
|
||||||
FROM
|
TO_CHAR(LOG.UL_REGDATE, 'YYYY-MM-DD HH24:MI:SS') AS REGDATE,
|
||||||
( SELECT
|
LOG.UL_USER_IP AS IP,
|
||||||
LOG.UL_USERID AS USERID, LOG.UL_NAME AS NAME, LOG.UL_LOCATION1 AS LOCATION1, LOG.UL_LOCATION2 AS LOCATION2, LOG.UL_LOCATION3 AS LOCATION3,
|
LOG.UL_POSITION AS POSITION_CODE,
|
||||||
TO_CHAR(LOG.UL_REGDATE, 'YYYY-MM-DD HH24:MI:SS') AS REGDATE, LOG.UL_USER_IP AS IP, LOG.UL_POSITION AS POSITION_CODE, CODE.CODENM AS POSITION
|
CODE.CODENM AS POSITION
|
||||||
FROM
|
FROM H3_USER_LOG LOG
|
||||||
H3_USER_LOG LOG, TCODE CODE
|
inner join TCODE CODE on LOG.UL_POSITION = CODE.CODE2 and CODE.CODE1 = 'C002'
|
||||||
WHERE
|
<where>
|
||||||
LOG.UL_POSITION = CODE.CODE2
|
<if test="sdate != null and sdate != '' and edate != null and edate != ''">
|
||||||
AND CODE.CODE1 = 'C002' ]]>
|
AND UL_REGDATE >= (#{sdate} || ' 00:00:00')::date
|
||||||
<if test="sdate != null and sdate != '' and edate != null and edate != ''"><![CDATA[
|
AND UL_REGDATE <= (#{edate} || ' 23:59:59')::date
|
||||||
AND UL_REGDATE >= #{sdate} || ' 00:00:00'
|
</if>
|
||||||
AND UL_REGDATE <= #{edate} || ' 23:59:59' ]]>
|
<if test="place1 != null and place1 != ''">
|
||||||
</if>
|
AND UL_PLACE1 = #{place1}
|
||||||
<if test="place1 != null and place1 != ''">
|
</if>
|
||||||
AND UL_PLACE1 = #{place1}
|
</where>
|
||||||
</if>
|
ORDER BY UL_REGDATE <if test="order != 0">DESC</if>
|
||||||
<if test="name != null and name != ''">
|
limit #{recordCountPerPage} offset #{firstIndex}
|
||||||
AND UL_NAME LIKE '%' || #{name} || '%'
|
) LOG_LIST
|
||||||
</if>
|
|
||||||
<![CDATA[ ORDER BY
|
|
||||||
UL_REGDATE ]]> <if test="order != 0">DESC</if> <![CDATA[
|
|
||||||
) LOG_LIST
|
|
||||||
WHERE ROWNUM <= #{firstIndex} + #{recordCountPerPage}
|
|
||||||
) LOG_LIST
|
|
||||||
WHERE
|
|
||||||
RNUM > #{firstIndex}
|
|
||||||
]]>
|
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="Log.selectLoginoutLog" parameterType="logSearchVO" resultType="logVO">
|
<select id="Log.selectLoginoutLog" parameterType="logSearchVO" resultType="logVO">
|
||||||
<![CDATA[
|
SELECT (ROW_NUMBER() OVER()) AS RNUM,
|
||||||
SELECT
|
IO_USERID AS USERID,
|
||||||
LOG_LIST.*, CODE.CODENM AS POSITION
|
IO_NAME AS NAME,
|
||||||
FROM
|
TO_CHAR(IO_REGDATE, 'YYYY-MM-DD HH24:MI:SS') AS REGDATE,
|
||||||
(
|
IO_POSITION AS POSITION_CODE,
|
||||||
SELECT
|
IO_TYPE AS TYPE,
|
||||||
ROWNUM RNUM, LOG_LIST.*
|
CODE.CODENM AS POSITION
|
||||||
FROM
|
FROM H3_LOGINOUT_LOG log
|
||||||
( SELECT
|
inner join TCODE CODE on log.IO_POSITION = CODE.CODE2 AND CODE.CODE1 = 'C002'
|
||||||
IO_USERID AS USERID, IO_NAME AS NAME, TO_CHAR(IO_REGDATE, 'YYYY-MM-DD HH24:MI:SS') AS REGDATE, IO_POSITION AS POSITION_CODE, IO_TYPE AS TYPE
|
<where>
|
||||||
FROM
|
<if test="sdate != null and sdate != '' and edate != null and edate != ''">
|
||||||
H3_LOGINOUT_LOG
|
AND TO_CHAR(log.IO_REGDATE, 'yyyy-mm-dd') >= #{sdate}
|
||||||
WHERE
|
AND TO_CHAR(log.IO_REGDATE, 'yyyy-mm-dd') <= #{edate}
|
||||||
1 = 1
|
</if>
|
||||||
]]>
|
<if test="place1 != null and place1 != ''">
|
||||||
<if test="sdate != null and sdate != '' and edate != null and edate != ''"><![CDATA[
|
AND IO_PLACE1 = #{place1}
|
||||||
AND
|
</if>
|
||||||
TO_CHAR(IO_REGDATE, 'yyyy-mm-dd') >= #{sdate} AND
|
<if test="name != null and name != ''">
|
||||||
TO_CHAR(IO_REGDATE, 'yyyy-mm-dd') <= #{edate} ]]>
|
AND IO_NAME LIKE '%' || #{name} || '%'
|
||||||
</if>
|
</if>
|
||||||
<if test="place1 != null and place1 != ''">
|
</where>
|
||||||
AND IO_PLACE1 = #{place1}
|
ORDER BY IO_REGDATE <if test="order != 0">DESC</if>
|
||||||
</if>
|
limit #{recordCountPerPage} offset #{firstIndex}
|
||||||
<if test="name != null and name != ''">
|
|
||||||
AND IO_NAME LIKE '%' || #{name} || '%'
|
|
||||||
</if>
|
|
||||||
<![CDATA[ ORDER BY
|
|
||||||
IO_REGDATE ]]> <if test="order != 0">DESC</if> <![CDATA[
|
|
||||||
) LOG_LIST
|
|
||||||
) LOG_LIST,
|
|
||||||
TCODE CODE
|
|
||||||
|
|
||||||
WHERE
|
|
||||||
RNUM > #{firstIndex} AND
|
|
||||||
RNUM <= #{firstIndex} + #{recordCountPerPage} AND
|
|
||||||
LOG_LIST.POSITION_CODE = CODE.CODE2 AND
|
|
||||||
CODE.CODE1 = 'C002'
|
|
||||||
|
|
||||||
|
|
||||||
]]>
|
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="Log.selectLogListTotCnt" parameterType="logSearchVO" resultType="int">
|
<select id="Log.selectLogListTotCnt" parameterType="logSearchVO" resultType="int">
|
||||||
|
|
@ -150,18 +124,36 @@
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="Log.selectUrlInfo" parameterType="logVO" resultType="hashmap">
|
<select id="Log.selectUrlInfo" parameterType="logVO" resultType="hashmap">
|
||||||
<![CDATA[
|
with recursive menu_hierarchy (
|
||||||
SELECT
|
level,
|
||||||
LEVEL AS LV, MENU.*
|
id,
|
||||||
FROM
|
name,
|
||||||
T_MENU MENU
|
eng_name,
|
||||||
START WITH
|
parent,
|
||||||
MENU.URL = #{location2}
|
depth,
|
||||||
CONNECT BY PRIOR
|
url,
|
||||||
MENU.PARENT = MENU.ID
|
menu_position,
|
||||||
ORDER BY
|
visible,
|
||||||
LV DESC
|
url_group,
|
||||||
]]>
|
sub_visibel,
|
||||||
|
role_level,
|
||||||
|
url_query,
|
||||||
|
board_id,
|
||||||
|
window_target
|
||||||
|
) as (
|
||||||
|
select 1, a.*
|
||||||
|
from t_menu a
|
||||||
|
where url = #{location2}
|
||||||
|
|
||||||
|
union all
|
||||||
|
|
||||||
|
select b.level +1, a.*
|
||||||
|
from t_menu a
|
||||||
|
inner join menu_hierarchy b
|
||||||
|
on a.id = b.parent
|
||||||
|
)
|
||||||
|
select * from menu_hierarchy
|
||||||
|
order by level desc
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="Log.selectLogTotalCnt" parameterType="logSearchVO" resultType="int">
|
<select id="Log.selectLogTotalCnt" parameterType="logSearchVO" resultType="int">
|
||||||
|
|
|
||||||
|
|
@ -66,136 +66,54 @@
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="getFaListAll" parameterType="memberSearchVO" resultType="memberVO">
|
<select id="getFaListAll" parameterType="memberSearchVO" resultType="memberVO">
|
||||||
<![CDATA[
|
select (ROW_NUMBER() OVER()) AS RNUM,
|
||||||
SELECT
|
(aa.PLACE1STR || ' ' || aa.PLACE2STR) PLACE3STR,
|
||||||
*
|
TOTALEXCAREER_Y || '년 ' || TOTALEXCAREER_M || '개월' TOTALCAREER,
|
||||||
FROM (
|
aa.*
|
||||||
SELECT
|
from (select pl1.codenm place1str,
|
||||||
ROWNUM RNUM, MEMBER_LIST.*
|
pl2.codenm PLACE2STR,
|
||||||
FROM (
|
pst.codenm POSITIONSTR,
|
||||||
SELECT
|
jt.codenm JOBTYPESTR,
|
||||||
MEMBER_LIST.PLACE1STR || ' ' || MEMBER_LIST.PLACE2STR AS PLACE3STR, MEMBER_LIST.*, TOTALEXCAREER_Y || '년 ' || TOTALEXCAREER_M || '개월' TOTALCAREER
|
MOD((EXCAREER_M + EXCAREER1_M + EXCAREER2_M + EXCAREER3_M), 12) TOTALEXCAREER_M,
|
||||||
FROM
|
(EXCAREER_Y + EXCAREER1_Y + EXCAREER2_Y + EXCAREER3_Y) + FLOOR(MOD((EXCAREER_M + EXCAREER1_M + EXCAREER2_M + EXCAREER3_M), 12) / 12) TOTALEXCAREER_Y,
|
||||||
(
|
a.*
|
||||||
SELECT
|
from (select *,
|
||||||
B.CODENM AS PLACE2STR, A.*
|
split_part(EXCAREER, '-', 1)::int EXCAREER_Y,
|
||||||
FROM
|
split_part(EXCAREER, '-', 2)::int EXCAREER_M,
|
||||||
(SELECT
|
split_part(EXCAREER1, '-', 1)::int EXCAREER1_Y,
|
||||||
B.CODENM AS POSITIONSTR, A.*
|
split_part(EXCAREER1, '-', 2)::int EXCAREER1_M,
|
||||||
FROM
|
split_part(EXCAREER2, '-', 1)::int EXCAREER2_Y,
|
||||||
(SELECT
|
split_part(EXCAREER2, '-', 2)::int EXCAREER2_M,
|
||||||
B.CODENM AS PLACE1STR, A.*
|
split_part(EXCAREER3, '-', 1)::int EXCAREER3_Y,
|
||||||
FROM
|
split_part(EXCAREER3, '-', 2)::int EXCAREER3_M
|
||||||
(SELECT
|
from tagent
|
||||||
B.CODENM AS JOBTYPESTR, A.*
|
<where>
|
||||||
FROM
|
<if test="name != null and name != ''">
|
||||||
(
|
AND NAME LIKE '%' || #{name} || '%'
|
||||||
SELECT
|
</if>
|
||||||
TAGENT.*,
|
<if test="place1 != null and place1 != ''">
|
||||||
MOD((EXCAREER_M + EXCAREER1_M + EXCAREER2_M + EXCAREER3_M), 12) TOTALEXCAREER_M,
|
AND PLACE1 = #{place1}
|
||||||
(EXCAREER_Y + EXCAREER1_Y + EXCAREER2_Y + EXCAREER3_Y) + FLOOR(MOD((EXCAREER_M + EXCAREER1_M + EXCAREER2_M + EXCAREER3_M), 12) / 12) TOTALEXCAREER_Y
|
</if>
|
||||||
FROM (
|
</where>
|
||||||
SELECT
|
ORDER BY
|
||||||
TAGENT.*,
|
<if test="orderkey != null and orderkey != ''">
|
||||||
SUBSTR(EXCAREER, 1, INSTR(EXCAREER, '-', 1) - 1) EXCAREER_Y,
|
<choose>
|
||||||
SUBSTR(EXCAREER, INSTR(EXCAREER, '-', 1) + 1, 3) EXCAREER_M,
|
<when test="ordercode == 7">
|
||||||
SUBSTR(EXCAREER1, 1, INSTR(EXCAREER1, '-', 1) - 1) EXCAREER1_Y,
|
TOTALEXCAREER_Y <choose><when test="ordertype == 1">DESC</when><otherwise>ASC</otherwise></choose>,
|
||||||
SUBSTR(EXCAREER1, INSTR(EXCAREER1, '-', 1) + 1, 3) EXCAREER1_M,
|
TOTALEXCAREER_M <choose><when test="ordertype == 1">DESC</when><otherwise>ASC</otherwise></choose>,
|
||||||
SUBSTR(EXCAREER2, 1, INSTR(EXCAREER2, '-', 1) - 1) EXCAREER2_Y,
|
</when>
|
||||||
SUBSTR(EXCAREER2, INSTR(EXCAREER2, '-', 1) + 1, 3) EXCAREER2_M,
|
<otherwise>
|
||||||
SUBSTR(EXCAREER3, 1, INSTR(EXCAREER3, '-', 1) - 1) EXCAREER3_Y,
|
${orderkey} <choose><when test="ordertype == 1">DESC</when><otherwise>ASC</otherwise></choose>,
|
||||||
SUBSTR(EXCAREER3, INSTR(EXCAREER3, '-', 1) + 1, 3) EXCAREER3_M
|
</otherwise>
|
||||||
FROM
|
</choose>
|
||||||
TAGENT
|
</if>
|
||||||
) TAGENT
|
PLACE1, PLACE2, PLACE3, POSITION DESC, DUTIES, NAME
|
||||||
) A,
|
) a
|
||||||
TCODE B
|
inner join tcode pl1 on pl1.code1 = 'C001' and a.place1 = pl1.code2
|
||||||
WHERE
|
inner join tcode pl2 on a.place1 = pl2.code1 and a.place2 = pl2.code2
|
||||||
B.CODE1(+) = 'C003' AND
|
inner join tcode pst on pst.code1 = 'C002' and a.position = pst.code2
|
||||||
A.JOBTYPE = B.CODE2(+)) A,
|
inner join tcode jt on jt.code1 = 'C003' and a.jobtype = jt.code2
|
||||||
TCODE B
|
) aa
|
||||||
WHERE
|
|
||||||
A.PLACE1 = B.CODE2(+) AND
|
|
||||||
B.CODE1(+) = 'C001' ) A,
|
|
||||||
TCODE B
|
|
||||||
WHERE
|
|
||||||
A.POSITION = B.CODE2(+) AND
|
|
||||||
B.CODE1(+) = 'C002') A,
|
|
||||||
TCODE B
|
|
||||||
WHERE
|
|
||||||
A.PLACE1 = B.CODE1(+) AND
|
|
||||||
A.PLACE2 = B.CODE2(+)
|
|
||||||
ORDER BY ]]>
|
|
||||||
<if test="orderkey != null and orderkey != ''">
|
|
||||||
<choose>
|
|
||||||
<when test="ordercode == 7">
|
|
||||||
TOTALEXCAREER_Y <choose><when test="ordertype == 1">DESC</when><otherwise>ASC</otherwise></choose>,
|
|
||||||
TOTALEXCAREER_M <choose><when test="ordertype == 1">DESC</when><otherwise>ASC</otherwise></choose>,
|
|
||||||
</when>
|
|
||||||
<otherwise>
|
|
||||||
${orderkey} <choose><when test="ordertype == 1">DESC</when><otherwise>ASC</otherwise></choose>,
|
|
||||||
</otherwise>
|
|
||||||
</choose>
|
|
||||||
</if>
|
|
||||||
PLACE1,
|
|
||||||
PLACE2,
|
|
||||||
PLACE3,
|
|
||||||
POSITION DESC,
|
|
||||||
DUTIES,
|
|
||||||
NAME
|
|
||||||
<![CDATA[
|
|
||||||
) MEMBER_LIST
|
|
||||||
WHERE
|
|
||||||
1 = 1
|
|
||||||
]]>
|
|
||||||
<if test="place1 != null and place1 != ''">
|
|
||||||
AND PLACE1 = #{place1}
|
|
||||||
</if>
|
|
||||||
<if test="name != null and name != ''">
|
|
||||||
AND NAME LIKE '%' || #{name} || '%'
|
|
||||||
</if>
|
|
||||||
<![CDATA[
|
|
||||||
) MEMBER_LIST
|
|
||||||
) A
|
|
||||||
LEFT JOIN
|
|
||||||
(
|
|
||||||
SELECT
|
|
||||||
IO_USERID, TO_CHAR(MAX(IO_REGDATE), 'YYYY-MM-DD HH24:MI:SS') AS RECENTDATE
|
|
||||||
FROM
|
|
||||||
H3_LOGINOUT_LOG
|
|
||||||
GROUP BY
|
|
||||||
IO_USERID
|
|
||||||
) B
|
|
||||||
ON
|
|
||||||
A.USERID = B.IO_USERID
|
|
||||||
]]>
|
|
||||||
<!--
|
|
||||||
SELECT
|
|
||||||
P1.CODENM AS PLACE1STR, P2.CODENM AS PLACE2STR,
|
|
||||||
J.CODENM AS JOBTYPESTR, POS.CODENM AS POSITIONSTR, P1.CODENM || ' ' || P2.CODENM,
|
|
||||||
(경력계산)
|
|
||||||
A.*
|
|
||||||
FROM TAGENT A
|
|
||||||
LEFT JOIN TCODE J ON J.CODE1 = 'C003' AND A.JOBTYPE = J.CODE2
|
|
||||||
LEFT JOIN TCODE P1 ON P1.CODE1 = 'C001' AND A.PLACE1 = P1.CODE2
|
|
||||||
LEFT JOIN TCODE POS ON POS.CODE1 = 'C002' AND A.POSITION = POS.CODE2
|
|
||||||
LEFT JOIN TCODE P2 ON A.PLACE1 = P2.CODE1 AND A.PLACE2 = P2.CODE2
|
|
||||||
LEFT JOIN
|
|
||||||
(
|
|
||||||
SELECT
|
|
||||||
IO_USERID, TO_CHAR(MAX(IO_REGDATE), 'YYYY-MM-DD HH24:MI:SS') AS RECENTDATE
|
|
||||||
FROM
|
|
||||||
H3_LOGINOUT_LOG
|
|
||||||
GROUP BY
|
|
||||||
IO_USERID
|
|
||||||
) B
|
|
||||||
ON
|
|
||||||
A.USERID = B.IO_USERID
|
|
||||||
WHERE
|
|
||||||
A.PLACE1 = 'PS92'
|
|
||||||
ORDER BY
|
|
||||||
PLACE1, PLACE2, PLACE3, POSITION DESC, DUTIES, NAME
|
|
||||||
-->
|
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="Member.getMemberSearchResult" parameterType="memberSearchVO" resultType="memberVO">
|
<select id="Member.getMemberSearchResult" parameterType="memberSearchVO" resultType="memberVO">
|
||||||
|
|
@ -284,149 +202,88 @@
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="Member.getCmmnListAll" parameterType="memberSearchVO" resultType="memberVO">
|
<select id="Member.getCmmnListAll" parameterType="memberSearchVO" resultType="memberVO">
|
||||||
<![CDATA[
|
select (ROW_NUMBER() OVER()) AS RNUM,
|
||||||
SELECT
|
aa.*
|
||||||
*
|
from (select pl1.codenm place1str,
|
||||||
FROM (
|
b.recentdate,
|
||||||
SELECT
|
pl2.codenm PLACE2STR,
|
||||||
ROWNUM RNUM, MEMBER_LIST.*
|
pl3.codenm PLACE3STR,
|
||||||
FROM (
|
pst.codenm POSITIONSTR,
|
||||||
SELECT
|
jt.codenm JOBTYPESTR,
|
||||||
MEMBER_LIST.PLACE1STR || ' ' || MEMBER_LIST.PLACE2STR AS PLACE3STR, MEMBER_LIST.NAME, MEMBER_LIST.POSITIONSTR,
|
a.*
|
||||||
MEMBER_LIST.USERID, MEMBER_LIST.LOGINCHK, MEMBER_LIST.CHKCNT, MEMBER_LIST.IDNO
|
from tagent a
|
||||||
FROM
|
inner join tcode pl1 on pl1.code1 = 'C001' and a.place1 = pl1.code2
|
||||||
(
|
inner join tcode pl2 on a.place1 = pl2.code1 and a.place2 = pl2.code2
|
||||||
SELECT
|
inner join tcode pl3 on pl3.code1 = 'C009' and a.place3 = pl3.code2
|
||||||
B.CODENM AS PLACE2STR, A.*
|
inner join tcode pst on pst.code1 = 'C002' and a.position = pst.code2
|
||||||
FROM
|
inner join tcode jt on jt.code1 = 'C003' and a.jobtype = jt.code2
|
||||||
(SELECT
|
left outer join (SELECT IO_USERID, TO_CHAR(MAX(IO_REGDATE), 'YYYY-MM-DD HH24:MI:SS') AS RECENTDATE
|
||||||
B.CODENM AS POSITIONSTR, A.*
|
FROM H3_LOGINOUT_LOG
|
||||||
FROM
|
<where>
|
||||||
(SELECT
|
<if test="place1 != null and place1 != ''">
|
||||||
B.CODENM AS PLACE1STR, A.*
|
AND IO_PLACE1 = #{place1}
|
||||||
FROM
|
</if>
|
||||||
TUSER A,
|
<if test="name != null and name != ''">
|
||||||
TCODE B
|
AND IO_NAME LIKE '%' || #{name} || '%'
|
||||||
WHERE
|
</if>
|
||||||
A.PLACE1 = B.CODE2(+) AND
|
</where>
|
||||||
B.CODE1(+) = 'C001' ) A,
|
GROUP BY IO_USERID ) B ON A.USERID = B.IO_USERID
|
||||||
TCODE B
|
<where>
|
||||||
WHERE
|
<if test="place1 != null and place1 != ''">
|
||||||
A.POSITION = B.CODE2(+) AND
|
AND PLACE1 = #{place1}
|
||||||
B.CODE1(+) = 'C002') A,
|
</if>
|
||||||
TCODE B
|
<if test="name != null and name != ''">
|
||||||
WHERE
|
AND NAME LIKE '%' || #{name} || '%'
|
||||||
A.PLACE1 = B.CODE1(+) AND
|
</if>
|
||||||
B.CODE2(+) = A.PLACE2
|
</where>
|
||||||
ORDER BY]]>
|
ORDER BY
|
||||||
<if test="orderkey != null and orderkey != ''">
|
<if test="orderkey != null and orderkey != ''">
|
||||||
${orderkey} <choose><when test="ordertype == 1">DESC</when><otherwise>ASC</otherwise></choose>,
|
${orderkey} <choose><when test="ordertype == 1">DESC</when></choose>,
|
||||||
</if>
|
</if>
|
||||||
PLACE1,
|
PLACE1, PLACE2, POSITION DESC, NAME ) aa
|
||||||
PLACE2,
|
|
||||||
POSITION DESC,
|
|
||||||
NAME
|
|
||||||
<![CDATA[) MEMBER_LIST
|
|
||||||
WHERE
|
|
||||||
1 = 1
|
|
||||||
]]>
|
|
||||||
<if test="place1 != null and place1 != ''">
|
|
||||||
AND PLACE1 = #{place1}
|
|
||||||
</if>
|
|
||||||
<if test="name != null and name != ''">
|
|
||||||
AND NAME LIKE '%' || #{name} || '%'
|
|
||||||
</if>
|
|
||||||
<![CDATA[
|
|
||||||
) MEMBER_LIST
|
|
||||||
) A
|
|
||||||
LEFT JOIN
|
|
||||||
(
|
|
||||||
SELECT
|
|
||||||
IO_USERID, TO_CHAR(MAX(IO_REGDATE), 'YYYY-MM-DD HH24:MI:SS') AS RECENTDATE
|
|
||||||
FROM
|
|
||||||
H3_LOGINOUT_LOG
|
|
||||||
GROUP BY
|
|
||||||
IO_USERID
|
|
||||||
) B
|
|
||||||
ON
|
|
||||||
A.USERID = B.IO_USERID
|
|
||||||
]]>
|
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="Member.getCmmnMemberList" parameterType="memberSearchVO" resultType="memberVO">
|
<select id="Member.getCmmnMemberList" parameterType="memberSearchVO" resultType="memberVO">
|
||||||
<![CDATA[
|
select (ROW_NUMBER() OVER()) AS RNUM,
|
||||||
SELECT
|
aa.*
|
||||||
*
|
from (select pl1.codenm place1str,
|
||||||
FROM (
|
b.recentdate,
|
||||||
SELECT
|
pl2.codenm PLACE2STR,
|
||||||
ROWNUM RNUM, MEMBER_LIST.*
|
pl3.codenm PLACE3STR,
|
||||||
FROM (
|
pst.codenm POSITIONSTR,
|
||||||
SELECT
|
jt.codenm JOBTYPESTR,
|
||||||
MEMBER_LIST.PLACE1STR || ' ' || MEMBER_LIST.PLACE2STR AS PLACE3STR, MEMBER_LIST.NAME, MEMBER_LIST.POSITIONSTR,
|
a.*
|
||||||
MEMBER_LIST.USERID, MEMBER_LIST.LOGINCHK, MEMBER_LIST.CHKCNT, MEMBER_LIST.IDNO, MEMBER_LIST.PLACE1
|
from tagent a
|
||||||
FROM
|
inner join tcode pl1 on pl1.code1 = 'C001' and a.place1 = pl1.code2
|
||||||
(
|
inner join tcode pl2 on a.place1 = pl2.code1 and a.place2 = pl2.code2
|
||||||
SELECT
|
inner join tcode pl3 on pl3.code1 = 'C009' and a.place3 = pl3.code2
|
||||||
B.CODENM AS PLACE2STR, A.*
|
inner join tcode pst on pst.code1 = 'C002' and a.position = pst.code2
|
||||||
FROM
|
inner join tcode jt on jt.code1 = 'C003' and a.jobtype = jt.code2
|
||||||
(SELECT
|
left outer join (SELECT IO_USERID, TO_CHAR(MAX(IO_REGDATE), 'YYYY-MM-DD HH24:MI:SS') AS RECENTDATE
|
||||||
B.CODENM AS POSITIONSTR, A.*
|
FROM H3_LOGINOUT_LOG
|
||||||
FROM
|
<where>
|
||||||
(SELECT
|
<if test="place1 != null and place1 != ''">
|
||||||
B.CODENM AS PLACE1STR, A.*
|
AND IO_PLACE1 = #{place1}
|
||||||
FROM
|
</if>
|
||||||
TUSER A,
|
<if test="name != null and name != ''">
|
||||||
TCODE B
|
AND IO_NAME LIKE '%' || #{name} || '%'
|
||||||
WHERE
|
</if>
|
||||||
A.PLACE1 = B.CODE2(+) AND
|
</where>
|
||||||
B.CODE1(+) = 'C001' ) A,
|
GROUP BY IO_USERID ) B ON A.USERID = B.IO_USERID
|
||||||
TCODE B
|
<where>
|
||||||
WHERE
|
<if test="place1 != null and place1 != ''">
|
||||||
A.POSITION = B.CODE2(+) AND
|
AND PLACE1 = #{place1}
|
||||||
B.CODE1(+) = 'C002') A,
|
</if>
|
||||||
TCODE B
|
<if test="name != null and name != ''">
|
||||||
WHERE
|
AND NAME LIKE '%' || #{name} || '%'
|
||||||
A.PLACE1 = B.CODE1(+) AND
|
</if>
|
||||||
B.CODE2(+) = A.PLACE2
|
</where>
|
||||||
ORDER BY]]>
|
ORDER BY
|
||||||
<if test="orderkey != null and orderkey != ''">
|
<if test="orderkey != null and orderkey != ''">
|
||||||
${orderkey} <choose><when test="ordertype == 1">DESC</when><otherwise>ASC</otherwise></choose>,
|
${orderkey} <choose><when test="ordertype == 1">DESC</when><otherwise>ASC</otherwise></choose>,
|
||||||
</if>
|
</if>
|
||||||
PLACE1,
|
PLACE1, PLACE2, POSITION DESC, NAME
|
||||||
PLACE2,
|
limit #{recordCountPerPage} offset #{firstIndex} ) aa
|
||||||
POSITION DESC,
|
|
||||||
NAME
|
|
||||||
<![CDATA[) MEMBER_LIST
|
|
||||||
WHERE
|
|
||||||
1 = 1
|
|
||||||
]]>
|
|
||||||
<if test="place1 != null and place1 != ''">
|
|
||||||
AND PLACE1 = #{place1}
|
|
||||||
</if>
|
|
||||||
<if test="name != null and name != ''">
|
|
||||||
AND NAME LIKE '%' || #{name} || '%'
|
|
||||||
</if>
|
|
||||||
<![CDATA[
|
|
||||||
) MEMBER_LIST
|
|
||||||
) A
|
|
||||||
LEFT JOIN
|
|
||||||
(
|
|
||||||
SELECT
|
|
||||||
IO_USERID, TO_CHAR(MAX(IO_REGDATE), 'YYYY-MM-DD HH24:MI:SS') AS RECENTDATE
|
|
||||||
FROM
|
|
||||||
H3_LOGINOUT_LOG
|
|
||||||
GROUP BY
|
|
||||||
IO_USERID
|
|
||||||
) B
|
|
||||||
ON
|
|
||||||
A.USERID = B.IO_USERID
|
|
||||||
WHERE
|
|
||||||
RNUM > #{firstIndex} AND
|
|
||||||
RNUM <= #{firstIndex} + #{recordCountPerPage}
|
|
||||||
ORDER BY
|
|
||||||
RNUM
|
|
||||||
]]>
|
|
||||||
|
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -620,7 +477,6 @@
|
||||||
WHERE
|
WHERE
|
||||||
USERID = #{userid}
|
USERID = #{userid}
|
||||||
]]>
|
]]>
|
||||||
|
|
||||||
</update>
|
</update>
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -37,82 +37,27 @@
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="MemberAuth.getMemberListByPlace1" parameterType="memberSearchVO" resultType="loginUserVO">
|
<select id="MemberAuth.getMemberListByPlace1" parameterType="memberSearchVO" resultType="loginUserVO">
|
||||||
<![CDATA[
|
select (ROW_NUMBER() OVER()) AS RNUM,
|
||||||
SELECT
|
aa.*
|
||||||
*
|
from (select pl1.codenm place1str,
|
||||||
FROM (
|
pl2.codenm PLACE2STR,
|
||||||
SELECT
|
pl3.codenm PLACE3STR,
|
||||||
ROWNUM RNUM, MEMBER_LIST.*
|
pst.codenm POSITIONSTR,
|
||||||
FROM (
|
jt.codenm JOBTYPESTR,
|
||||||
SELECT
|
a.*
|
||||||
B.CODENM AS PLACE3STR, A.*
|
from tagent a
|
||||||
FROM
|
inner join tcode pl1 on pl1.code1 = 'C001' and a.place1 = pl1.code2
|
||||||
(
|
inner join tcode pl2 on a.place1 = pl2.code1 and a.place2 = pl2.code2
|
||||||
SELECT
|
inner join tcode pl3 on pl3.code1 = 'C009' and a.place3 = pl3.code2
|
||||||
B.CODENM AS PLACE2STR, A.*
|
inner join tcode pst on pst.code1 = 'C002' and a.position = pst.code2
|
||||||
FROM
|
inner join tcode jt on jt.code1 = 'C003' and a.jobtype = jt.code2
|
||||||
(SELECT
|
where PLACE1 =#{place1}
|
||||||
B.CODENM AS POSITIONSTR, A.*
|
ORDER BY
|
||||||
FROM
|
<if test="orderkey != null and orderkey != ''">
|
||||||
(SELECT
|
${orderkey} <choose><when test="ordertype == 1">DESC</when><otherwise>ASC</otherwise></choose>,
|
||||||
B.CODENM AS PLACE1STR, A.*
|
</if>
|
||||||
FROM
|
POSITION DESC, PLACE2, PLACE3, DUTIES, NAME
|
||||||
(SELECT
|
limit #{recordCountPerAuthPage} offset #{firstIndex} ) aa
|
||||||
B.CODENM AS DUTIESSTR, A.*
|
|
||||||
FROM
|
|
||||||
(SELECT
|
|
||||||
AGENT.USERID, AGENT.NAME, AGENT.PLACE1, AGENT.PLACE2, AGENT.PLACE3, AGENT.DUTIES, AGENT.POSITION, AGENT.USEGRADE,
|
|
||||||
PT_AUTH.AU_CODE AS AUTHCODE
|
|
||||||
FROM
|
|
||||||
( TAGENT AGENT
|
|
||||||
LEFT JOIN
|
|
||||||
RPT_AGENT_AUTH PT_AUTH
|
|
||||||
ON AGENT.USERID = PT_AUTH.AU_ID)
|
|
||||||
LEFT JOIN
|
|
||||||
H3_AGENT_AUTH ST_AUTH
|
|
||||||
ON
|
|
||||||
AGENT.USERID = ST_AUTH.AU_USERID
|
|
||||||
WHERE
|
|
||||||
PLACE1 = #{place1}
|
|
||||||
) A,
|
|
||||||
TCODE B
|
|
||||||
WHERE
|
|
||||||
B.CODE1 = 'C004' AND
|
|
||||||
A.DUTIES = B.CODE2) A,
|
|
||||||
TCODE B
|
|
||||||
WHERE
|
|
||||||
A.PLACE1 = B.CODE2 AND
|
|
||||||
B.CODE1 = 'C001' ) A,
|
|
||||||
TCODE B
|
|
||||||
WHERE
|
|
||||||
A.POSITION = B.CODE2 AND
|
|
||||||
B.CODE1 = 'C002') A,
|
|
||||||
TCODE B
|
|
||||||
WHERE
|
|
||||||
A.PLACE1 = B.CODE1(+) AND
|
|
||||||
B.CODE2(+) = A.PLACE2
|
|
||||||
ORDER BY
|
|
||||||
PLACE1,
|
|
||||||
PLACE2, PLACE3, POSITION DESC, DUTIES, NAME
|
|
||||||
) A,
|
|
||||||
TCODE B
|
|
||||||
WHERE
|
|
||||||
A.PLACE3 = B.CODE2(+) AND
|
|
||||||
CODE1(+) = 'C009'
|
|
||||||
ORDER BY]]>
|
|
||||||
<if test="orderkey != null and orderkey != ''">
|
|
||||||
${orderkey} <choose><when test="ordertype == 1">DESC</when><otherwise>ASC</otherwise></choose>,
|
|
||||||
</if>
|
|
||||||
POSITION DESC,
|
|
||||||
PLACE2, PLACE3, DUTIES, NAME
|
|
||||||
<![CDATA[) MEMBER_LIST
|
|
||||||
)
|
|
||||||
WHERE
|
|
||||||
RNUM > #{firstIndex} AND
|
|
||||||
RNUM <= #{firstIndex} + #{recordCountPerAuthPage}
|
|
||||||
ORDER BY
|
|
||||||
RNUM
|
|
||||||
]]>
|
|
||||||
</select>
|
</select>
|
||||||
<select id="MemberAuth.getMemberListByPlace1Cnt" parameterType="String" resultType="int">
|
<select id="MemberAuth.getMemberListByPlace1Cnt" parameterType="String" resultType="int">
|
||||||
<![CDATA[
|
<![CDATA[
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue