견문통계 개인실적 양식 변경.

master
강석 최 2023-04-14 17:16:21 +09:00
parent c4d14c5cd4
commit b3a8ba02b8
3 changed files with 35 additions and 67 deletions

View File

@ -22,23 +22,14 @@ public class PersonalAffairStatistics extends TypeStatistics {
@Transient
private String dicCode;
@Transient
private Integer r1Cnt;
private String title;
@Transient
private Integer r2Cnt;
private String affairType4;
@Transient
private Integer r3Cnt;
private String docNo;
@Transient
private Integer r4Cnt;
@Transient
private Integer r5Cnt;
@Transient
private Integer r6Cnt;
@Transient
private Integer r7Cnt;
@Transient
private Integer r8Cnt;
@Transient
private Integer totalCnt;
private String affairRate;
}

View File

@ -594,35 +594,24 @@
title_cd,
dic_code,
user_nm,
b.r1Cnt,
b.r2Cnt,
b.r3Cnt,
b.r4Cnt,
b.r5Cnt,
b.r6Cnt,
b.r7Cnt,
b.r8Cnt,
b.totalCnt
b.title,
b.affair_type4,
b.doc_no,
b.affair_rate
from user_info a
inner join
(
select aa.wrt_user_seq ,
sum(case when ab.affair_rate = 'AAR001' then 1 else 0 end) as r1Cnt,
sum(case when ab.affair_rate = 'AAR002' then 1 else 0 end) as r2Cnt,
sum(case when ab.affair_rate = 'AAR003' then 1 else 0 end) as r3Cnt,
sum(case when ab.affair_rate = 'AAR004' then 1 else 0 end) as r4Cnt,
sum(case when ab.affair_rate = 'AAR005' then 1 else 0 end) as r5Cnt,
sum(case when ab.affair_rate = 'AAR006' then 1 else 0 end) as r6Cnt,
sum(case when ab.affair_rate = 'AAR007' then 1 else 0 end) as r7Cnt,
sum(case when ab.affair_rate = 'AAR008' then 1 else 0 end) as r8Cnt,
count(*) as totalCnt
from affair_board aa
select aa.wrt_user_seq ,
aa.title,
aa.affair_type4,
aa.doc_no,
ab.affair_rate
from affair_board aa
inner join affair_rating ab
on aa.affair_key = ab.affair_key and ab.affair_rate is not null and ab.organ_up = 'F'
<include refid="selectPersonalStatisticsSubWhere"></include>
group by aa.wrt_user_seq
<include refid="selectPersonalStatisticsSubWhere"></include>
) b on a.user_seq = b.wrt_user_seq
<include refid="selectPersonalStatisticsWhere"></include>
order by og_cd, ofc_cd, title_cd
order by og_cd, ofc_cd, title_cd, user_nm
</select>
</mapper>

View File

@ -21,18 +21,20 @@
<div class="col-12">
<table class="table table-sm table-hover table-bordered" id="tableData">
<colgroup>
<col style="width: 5%">
<col style="width: 3%">
<col style="width: 7%">
<col style="width: 7%">
<col style="width: 7%">
<col style="width: 5%">
<col style="width: 12%">
<col style="width: 12%">
<col style="width: 7%">
<col style="width: 7%">
<th:block th:each="code:${session.commonCode.get('AAR')}">
<th:block th:if="${#lists.contains(searchParams.rating, code.itemCd)}">
<col style="width: 5%">
<col style="width: 3%">
</th:block>
</th:block>
<col style="width: 7%">
<col style="width: 7%">
<col style="width: 5%">
</colgroup>
<thead>
@ -49,7 +51,9 @@
<th th:text="${code.itemValue}"></th>
</th:block>
</th:block>
<th>합계</th>
<th>분야</th>
<th>관련근거</th>
<th>기본제출건수</th>
</tr>
</thead>
<tbody class="table-group-divider">
@ -79,33 +83,17 @@
<td th:text="${statistics.userNm}"></td>
<th:block th:each="code:${session.commonCode.get('AAR')}">
<th:block th:if="${#lists.contains(searchParams.rating, code.itemCd)}">
<th:block th:if="${code.itemCd eq 'AAR001'}">
<td th:text="${statistics.r1Cnt}"></td>
</th:block>
<th:block th:if="${code.itemCd eq 'AAR002'}">
<td th:text="${statistics.r2Cnt}"></td>
</th:block>
<th:block th:if="${code.itemCd eq 'AAR003'}">
<td th:text="${statistics.r3Cnt}"></td>
</th:block>
<th:block th:if="${code.itemCd eq 'AAR004'}">
<td th:text="${statistics.r4Cnt}"></td>
</th:block>
<th:block th:if="${code.itemCd eq 'AAR005'}">
<td th:text="${statistics.r5Cnt}"></td>
</th:block>
<th:block th:if="${code.itemCd eq 'AAR006'}">
<td th:text="${statistics.r6Cnt}"></td>
</th:block>
<th:block th:if="${code.itemCd eq 'AAR007'}">
<td th:text="${statistics.r7Cnt}"></td>
</th:block>
<th:block th:if="${code.itemCd eq 'AAR008'}">
<td th:text="${statistics.r8Cnt}"></td>
</th:block>
<td th:if="${code.itemCd eq statistics.affairRate}">O</td>
<td th:if="${code.itemCd ne statistics.affairRate}"></td>
</th:block>
</th:block>
<td th:text="${statistics.totalCnt}"></td>
<td>
<th:block th:each="code:${session.commonCode.get('DC04')}">
<th:block th:if="${code.itemCd eq statistics.affairType4}" th:text="${code.itemValue}"></th:block>
</th:block>
</td>
<td th:text="${statistics.docNo}"></td>
<td th:text="${statistics.userStatus eq 'USC003'?2:1}"></td>
</tr>
</tbody>
</table>