팝업관리 오류 수정
@b16a718c8d0802bf637f79c16e1d094bd66b0708
--- src/main/java/kcc/com/uss/ion/pwm/web/EgovPopupManageController.java
+++ src/main/java/kcc/com/uss/ion/pwm/web/EgovPopupManageController.java
... | ... | @@ -156,11 +156,16 @@ |
| 156 | 156 |
int reusltListSize = reusltList.size(); |
| 157 | 157 |
|
| 158 | 158 |
|
| 159 |
+ |
|
| 159 | 160 |
for(int i = 0 ; i < reusltListSize ; i ++) {
|
| 160 | 161 |
//EgovMap 형변환 |
| 161 | 162 |
EgovMap tmpMap = reusltList.get(i); |
| 162 | 163 |
// String nttCn = (String)tmpMap.get("nttCn");
|
| 163 |
- String nttCn = convertClobToString((Clob)tmpMap.get("nttCn"));
|
|
| 164 |
+// String nttCn = convertClobToString((Clob)tmpMap.get("nttCn"));
|
|
| 165 |
+ |
|
| 166 |
+ Object nttObj = tmpMap.get("nttCn");
|
|
| 167 |
+ String nttCn = toStringContent(nttObj); |
|
| 168 |
+ |
|
| 164 | 169 |
nttCn = nttCn.replace(" ", "");
|
| 165 | 170 |
//width, height 문자열 포함 여부 |
| 166 | 171 |
if(nttCn.contains("width") && nttCn.contains("height")) {
|
... | ... | @@ -181,6 +186,7 @@ |
| 181 | 186 |
} |
| 182 | 187 |
} |
| 183 | 188 |
|
| 189 |
+ |
|
| 184 | 190 |
model.addAttribute("resultList", reusltList);
|
| 185 | 191 |
|
| 186 | 192 |
model.addAttribute("searchKeyword", commandMap.get("searchKeyword") == null ? "" : (String) commandMap.get("searchKeyword"));
|
... | ... | @@ -194,6 +200,28 @@ |
| 194 | 200 |
return "uss/ion/pwm/EgovPopupList"; |
| 195 | 201 |
} |
| 196 | 202 |
|
| 203 |
+ private String toStringContent(Object obj) throws Exception {
|
|
| 204 |
+ if(obj == null) return ""; |
|
| 205 |
+ |
|
| 206 |
+ if(obj instanceof String) {
|
|
| 207 |
+ return (String)obj; |
|
| 208 |
+ } |
|
| 209 |
+ |
|
| 210 |
+ if(obj instanceof Clob) {
|
|
| 211 |
+ Clob clob = (Clob)obj; |
|
| 212 |
+ return clob.getSubString(1, (int)clob.length()); |
|
| 213 |
+ } |
|
| 214 |
+ |
|
| 215 |
+ if(obj instanceof byte[]) {
|
|
| 216 |
+ // ntt_cn이 longblob이라면 보통 byte[]로 옴 (문자데이터 저장한 경우) |
|
| 217 |
+ return new String((byte[])obj, "UTF-8"); |
|
| 218 |
+ } |
|
| 219 |
+ |
|
| 220 |
+ // 혹시 다른 타입이면 일단 문자열로 |
|
| 221 |
+ return String.valueOf(obj); |
|
| 222 |
+ } |
|
| 223 |
+ |
|
| 224 |
+ |
|
| 197 | 225 |
/** |
| 198 | 226 |
* 통합링크관리 목록을 상세조회 조회한다. |
| 199 | 227 |
* @param popupManageVO |
Add a comment
Delete comment
Once you delete this comment, you won't be able to recover it. Are you sure you want to delete this comment?