<기능개선>

1. PMS NO : 7976
2. (주요)작업내용 
(1) Dao/MyBatis/Maps/Lect.xml
 - studyplacename 쿼리 수정
This commit is contained in:
jity7777 2023-06-02 04:05:00 +00:00
parent 26c40944f0
commit a6569f6120
1 changed files with 25 additions and 24 deletions

View File

@ -72,32 +72,33 @@
,row_number() over(order by <isNotNull property="orderby">$orderby$</isNotNull><isNull property="orderby">a.cdt desc</isNull>) rno
,count(a.cdt) over() pagetotalcount
, b.cshape, ifnull(e.scdtype, 1) as scdtype
, (case when e.scdtype is null then h.cname else g.cname end ) as studyplace
, (case when b.cshape=0 then '온라인' when b.cshape=1 then '교육장교육' else '온라인교육' end) cshapename
, a.edate
from lect a
left outer join payitem pi on pi.pino=a.pino
inner join cm b on b.cmno=a.cmno
left outer join comcode bc on bc.ccode=b.certgradecc
inner join cg cg on cg.cgno=b.cgno
inner join cg pcg on pcg.cgno=cg.pcgno
inner join term c on c.tmno=b.tmno
inner join users u on u.userno=a.userno
left outer join comcode uc on uc.ccode=u.ccposition
left outer join assign ua on ua.asno=u.asno
<!--, (case when e.scdtype is null then h.cname else g.cname end ) as studyplace-->
, g.cname as studyplace
, (case when b.cshape=0 then '온라인' when b.cshape=1 then '교육장교육' else '온라인교육' end) cshapename
, a.edate
from lect a
left outer join payitem pi on pi.pino=a.pino
inner join cm b on b.cmno=a.cmno
left outer join comcode bc on bc.ccode=b.certgradecc
inner join cg cg on cg.cgno=b.cgno
inner join cg pcg on pcg.cgno=cg.pcgno
inner join term c on c.tmno=b.tmno
inner join users u on u.userno=a.userno
left outer join comcode uc on uc.ccode=u.ccposition
left outer join assign ua on ua.asno=u.asno
left outer join (
select lectno,max(cmino) as cmino
from lectinning t
group by lectno
) d on a.lectno = d.lectno
left outer join cminning e on b.cmno = e.cmno and d.cmino = d.cmino and e.userno = a.userno
left outer join cminningscd f on a.cmisno = f.cmisno
left outer join comcode g on f.studyplace = g.ccode
left outer join comcode h on b.studyplace = h.ccode
left outer join (
select lectno,max(cmino) as cmino
from lectinning t
group by lectno
) d on a.lectno = d.lectno
left outer join cminning e on b.cmno = e.cmno and d.cmino = d.cmino and e.userno = a.userno
left outer join cminningscd f on a.cmisno = f.cmisno
left outer join comcode g on f.studyplace = g.ccode
left outer join comcode h on b.studyplace = h.ccode
where a.ischanged=0
<isNotNull property="lectno">and a.lectno=#lectno#</isNotNull>
where a.ischanged=0
<isNotNull property="lectno">and a.lectno=#lectno#</isNotNull>
<isNotNull property="userno">and a.userno=#userno#</isNotNull>
) a
<include refid="sql.pagedynamic"></include>