견문통계(분야별통계), 견문제출현황(견문삭제,검색)

master
Hyung Geun 2022-04-15 15:20:51 +09:00
parent 66172bfc74
commit 2fca65e742
5 changed files with 46 additions and 46 deletions

View File

@ -401,17 +401,17 @@ public class ReportJudgeServiceImpl extends EgovAbstractServiceImpl implements R
HashMap<String, String> ttt = new HashMap<String, String>(); HashMap<String, String> ttt = new HashMap<String, String>();
for (String mapKey : newMap.keySet()) { for (String mapKey : newMap.keySet()) {
if (!mapKey.equals("TOTAL") && !mapKey.equals("PLACENAME") && !mapKey.equals("PLACECODE")) { if (!mapKey.equals("total") && !mapKey.equals("placename") && !mapKey.equals("placecode")) {
ttt.put(mapKey + "_1", newMap.get(mapKey)); ttt.put(mapKey + "_1", newMap.get(mapKey));
} }
} }
ttt.put("PLACENAME", newMap.get("PLACENAME")); ttt.put("placename", newMap.get("placename"));
if (cateMap.size() > idx && cateMap.get(idx) != null) { if (cateMap.size() > idx && cateMap.get(idx) != null) {
cateMap.get(idx).putAll(ttt); cateMap.get(idx).putAll(ttt);
cateMap.get(idx).put("TOTAL", String.valueOf(Integer.parseInt(cateMap.get(idx).get("TOTAL").toString()) + Integer.parseInt(newMap.get("TOTAL").toString()))); cateMap.get(idx).put("total", String.valueOf(Integer.parseInt(cateMap.get(idx).get("total").toString()) + Integer.parseInt(newMap.get("total").toString())));
} else { } else {
ttt.put("TOTAL", newMap.get("TOTAL")); ttt.put("total", newMap.get("total"));
cateMap.add(idx, ttt); cateMap.add(idx, ttt);
} }
idx++; idx++;
@ -427,17 +427,17 @@ public class ReportJudgeServiceImpl extends EgovAbstractServiceImpl implements R
HashMap<String, String> ttt = new HashMap<String, String>(); HashMap<String, String> ttt = new HashMap<String, String>();
for (String mapKey : newMap.keySet()) { for (String mapKey : newMap.keySet()) {
if (!mapKey.equals("TOTAL") && !mapKey.equals("PLACENAME") && !mapKey.equals("PLACECODE")) { if (!mapKey.equals("total") && !mapKey.equals("placename") && !mapKey.equals("placecode")) {
ttt.put(mapKey + "_2", newMap.get(mapKey)); ttt.put(mapKey + "_2", newMap.get(mapKey));
} }
ttt.put("PLACENAME", newMap.get("PLACENAME")); ttt.put("placename", newMap.get("placename"));
} }
if (cateMap.size() > idx && cateMap.get(idx) != null) { if (cateMap.size() > idx && cateMap.get(idx) != null) {
cateMap.get(idx).putAll(ttt); cateMap.get(idx).putAll(ttt);
cateMap.get(idx).put("TOTAL", String.valueOf(Integer.parseInt(cateMap.get(idx).get("TOTAL").toString()) + Integer.parseInt(newMap.get("TOTAL").toString()))); cateMap.get(idx).put("total", String.valueOf((Integer.parseInt(String.valueOf(cateMap.get(idx).get("total"))) + Integer.parseInt(String.valueOf(newMap.get("total"))))));
} else { } else {
ttt.put("TOTAL", newMap.get("TOTAL")); ttt.put("total", newMap.get("total"));
cateMap.add(idx, ttt); cateMap.add(idx, ttt);
} }
idx++; idx++;
@ -452,17 +452,17 @@ public class ReportJudgeServiceImpl extends EgovAbstractServiceImpl implements R
HashMap<String, String> ttt = new HashMap<String, String>(); HashMap<String, String> ttt = new HashMap<String, String>();
for (String mapKey : newMap.keySet()) { for (String mapKey : newMap.keySet()) {
if (!mapKey.equals("TOTAL") && !mapKey.equals("PLACENAME") && !mapKey.equals("PLACECODE")) { if (!mapKey.equals("total") && !mapKey.equals("placename") && !mapKey.equals("placecode")) {
ttt.put(mapKey + "_3", newMap.get(mapKey)); ttt.put(mapKey + "_3", newMap.get(mapKey));
} }
ttt.put("PLACENAME", newMap.get("PLACENAME")); ttt.put("placename", newMap.get("placename"));
} }
if (cateMap.size() > idx && cateMap.get(idx) != null) { if (cateMap.size() > idx && cateMap.get(idx) != null) {
cateMap.get(idx).putAll(ttt); cateMap.get(idx).putAll(ttt);
cateMap.get(idx).put("TOTAL", String.valueOf(Integer.parseInt(cateMap.get(idx).get("TOTAL").toString()) + Integer.parseInt(newMap.get("TOTAL").toString()))); cateMap.get(idx).put("total", String.valueOf(Integer.parseInt(String.valueOf(cateMap.get(idx).get("total"))) + Integer.parseInt(String.valueOf(newMap.get("total")))));
} else { } else {
ttt.put("TOTAL", newMap.get("TOTAL")); ttt.put("total", newMap.get("total"));
cateMap.add(idx, ttt); cateMap.add(idx, ttt);
} }
idx++; idx++;
@ -477,17 +477,17 @@ public class ReportJudgeServiceImpl extends EgovAbstractServiceImpl implements R
HashMap<String, String> ttt = new HashMap<String, String>(); HashMap<String, String> ttt = new HashMap<String, String>();
for (String mapKey : newMap.keySet()) { for (String mapKey : newMap.keySet()) {
if (!mapKey.equals("TOTAL") && !mapKey.equals("PLACENAME") && !mapKey.equals("PLACECODE")) { if (!mapKey.equals("total") && !mapKey.equals("placename") && !mapKey.equals("placecode")) {
ttt.put(mapKey + "_4", newMap.get(mapKey)); ttt.put(mapKey + "_4", newMap.get(mapKey));
} }
ttt.put("PLACENAME", newMap.get("PLACENAME")); ttt.put("placename", newMap.get("placename"));
} }
if (cateMap.size() > idx && cateMap.get(idx) != null) { if (cateMap.size() > idx && cateMap.get(idx) != null) {
cateMap.get(idx).putAll(ttt); cateMap.get(idx).putAll(ttt);
cateMap.get(idx).put("TOTAL", String.valueOf(Integer.parseInt(cateMap.get(idx).get("TOTAL").toString()) + Integer.parseInt(newMap.get("TOTAL").toString()))); cateMap.get(idx).put("total", String.valueOf(Integer.parseInt(String.valueOf(cateMap.get(idx).get("total"))) + Integer.parseInt(String.valueOf(newMap.get("total")))));
} else { } else {
ttt.put("TOTAL", newMap.get("TOTAL")); ttt.put("total", newMap.get("total"));
cateMap.add(idx, ttt); cateMap.add(idx, ttt);
} }
idx++; idx++;
@ -496,15 +496,15 @@ public class ReportJudgeServiceImpl extends EgovAbstractServiceImpl implements R
if (cateMap.size() > 0) { if (cateMap.size() > 0) {
HashMap<String, String> totalMap = new HashMap<String, String>(); HashMap<String, String> totalMap = new HashMap<String, String>();
totalMap.put("PLACENAME", "누계"); totalMap.put("placename", "누계");
for (String key : cateMap.get(0).keySet()) { for (String key : cateMap.get(0).keySet()) {
if (key.equals("PLACENAME")) { if (key.equals("placename")) {
continue; continue;
} }
int tt = 0; int tt = 0;
for (HashMap<String, String> hashMap : cateMap) { for (HashMap<String, String> hashMap : cateMap) {
tt = tt + Integer.parseInt(hashMap.get(key)); tt = tt + Integer.parseInt(String.valueOf(hashMap.get(key)));
} }
totalMap.put(key, String.valueOf(tt)); totalMap.put(key, String.valueOf(tt));
} }
@ -520,11 +520,11 @@ public class ReportJudgeServiceImpl extends EgovAbstractServiceImpl implements R
List<HashMap<String, String>> list = reportJudgeMapper.statsJudge(reportSearchVO); List<HashMap<String, String>> list = reportJudgeMapper.statsJudge(reportSearchVO);
HashMap<String, String> map = new HashMap<String, String>(); HashMap<String, String> map = new HashMap<String, String>();
map.put("PLACENAME", "누계"); map.put("placename", "누계");
if (list.size() > 0) { if (list.size() > 0) {
for (String key : list.get(0).keySet()) { for (String key : list.get(0).keySet()) {
if (key.equals("PLACENAME")) { if (key.equals("placename")) {
continue; continue;
} }
int total = 0; int total = 0;

View File

@ -1211,7 +1211,7 @@
</if> </if>
) T ) T
) ) AS LIST
WHERE WHERE
RNUM > #{firstIndex} AND RNUM > #{firstIndex} AND
RNUM &lt;= #{firstIndex} + #{recordCountPerPage} RNUM &lt;= #{firstIndex} + #{recordCountPerPage}

View File

@ -30,9 +30,9 @@
UPDATE UPDATE
RPT_FILE_STORAGE RPT_FILE_STORAGE
SET SET
FS_FILE_COUNT = FS_FILE_COUNT + #{cnt} FS_FILE_COUNT = FS_FILE_COUNT + #{cnt}::int
WHERE WHERE
FS_SEQ = #{fsseq} FS_SEQ = #{fsseq}::int
]]> ]]>
</update> </update>

View File

@ -119,28 +119,28 @@
SELECT SELECT
]]> ]]>
<if test="categoryType.equals(1)"> <if test="categoryType.equals(1)">
<foreach collection="category1" item="cate" separator=""><![CDATA[ <foreach collection="category1" item="cate" separator="">
TO_CHAR(MAX(DECODE(CATEGORYCODE, #{cate}, TOTAL))) AS "${cate}", MAX(CASE CATEGORYCODE WHEN #{cate} THEN TOTAL::int end) AS "${cate}",
]]></foreach> </foreach>
</if> </if>
<if test="categoryType.equals(2)"> <if test="categoryType.equals(2)">
<foreach collection="category2" item="cate" ><![CDATA[ <foreach collection="category2" item="cate" >
TO_CHAR(MAX(DECODE(CATEGORYCODE, #{cate}, TOTAL))) AS "${cate}", MAX(CASE CATEGORYCODE WHEN #{cate} THEN TOTAL::int end) AS "${cate}",
]]></foreach> </foreach>
</if> </if>
<if test="categoryType.equals(3)"> <if test="categoryType.equals(3)">
<foreach collection="category3" item="cate" ><![CDATA[ <foreach collection="category3" item="cate" >
TO_CHAR(MAX(DECODE(CATEGORYCODE, #{cate}, TOTAL))) AS "${cate}", MAX(CASE CATEGORYCODE WHEN #{cate} THEN TOTAL::int end) AS "${cate}",
]]></foreach> </foreach>
</if> </if>
<if test="categoryType.equals(4)"> <if test="categoryType.equals(4)">
<foreach collection="category4" item="cate" ><![CDATA[ <foreach collection="category4" item="cate" >
TO_CHAR(MAX(DECODE(CATEGORYCODE, #{cate}, TOTAL))) AS "${cate}", MAX(CASE CATEGORYCODE WHEN #{cate} THEN TOTAL::int end) AS "${cate}",
]]></foreach> </foreach>
</if> </if>
<![CDATA[ <![CDATA[
PLACENAME, PLACECODE, PLACENAME, PLACECODE,
TO_CHAR(SUM(TOTAL)) AS TOTAL SUM(TOTAL) AS TOTAL
FROM FROM
( (
SELECT SELECT
@ -164,10 +164,10 @@
</choose> </choose>
<if test="dateStart != null and dateStart != ''"><![CDATA[ <if test="dateStart != null and dateStart != ''"><![CDATA[
AND IN_INFODATE >= #{dateStart} AND IN_INFODATE >= #{dateStart}::date
]]></if> ]]></if>
<if test="dateEnd != null and dateEnd != ''"><![CDATA[ <if test="dateEnd != null and dateEnd != ''"><![CDATA[
AND IN_INFODATE <= #{dateEnd} AND IN_INFODATE <= #{dateEnd}::date
]]></if> ]]></if>
<if test="subject != null and subject != ''"><![CDATA[ <if test="subject != null and subject != ''"><![CDATA[
AND IN_SUBJECT LIKE '%'||#{subject}||'%' AND IN_SUBJECT LIKE '%'||#{subject}||'%'
@ -277,8 +277,8 @@
WHERE WHERE
IN_COMPLETE = '1' IN_COMPLETE = '1'
AND IN_STATE_CODE <> '99' AND IN_STATE_CODE <> '99'
AND IN_INFODATE >= #{dateStart} AND IN_INFODATE >= #{dateStart}::date
AND IN_INFODATE <= #{dateEnd} AND IN_INFODATE <= #{dateEnd}::date
]]> ]]>
<if test="policeType != null and policeType.length > 0"> <if test="policeType != null and policeType.length > 0">
AND IN_TYPE IN AND IN_TYPE IN

View File

@ -200,9 +200,9 @@
<c:forEach var="stats" items="${statistics}" varStatus="status"> <c:forEach var="stats" items="${statistics}" varStatus="status">
<tr> <tr>
<c:if test="${status.last}"><td align="center" style="font-weight:bold;"><c:out value="${stats.PLACENAME}"/></td></c:if> <c:if test="${status.last}"><td align="center" style="font-weight:bold;"><c:out value="${stats.placename}"/></td></c:if>
<c:if test="${!status.last}"><td align="left"><c:out value="${stats.PLACENAME}"/></td></c:if> <c:if test="${!status.last}"><td align="left"><c:out value="${stats.placename}"/></td></c:if>
<td align="center"><c:out value="${stats.TOTAL}"/></td> <td align="center"><c:out value="${stats.total}"/></td>
<c:if test="${reportSearchVO.searchCate1}"> <c:if test="${reportSearchVO.searchCate1}">
<c:forEach var="item" items="${searchVO.category1}"> <c:forEach var="item" items="${searchVO.category1}">
@ -264,8 +264,8 @@
<c:forEach var="stats" items="${statistics}" varStatus="status"> <c:forEach var="stats" items="${statistics}" varStatus="status">
<tr> <tr>
<c:if test="${status.last}"><td align="center"><c:out value="${stats.PLACENAME}"/></td></c:if> <c:if test="${status.last}"><td align="center"><c:out value="${stats.placename}"/></td></c:if>
<c:if test="${!status.last}"><td align="left"><c:out value="${stats.PLACENAME}"/></td></c:if> <c:if test="${!status.last}"><td align="left"><c:out value="${stats.placename}"/></td></c:if>
<td align="center"><c:out value="${stats.REPORT1}"/></td> <td align="center"><c:out value="${stats.REPORT1}"/></td>
<td align="center"><c:out value="${stats.REPORT2}"/></td> <td align="center"><c:out value="${stats.REPORT2}"/></td>