diff --git a/src/main/java/kr/xit/framework/support/exception/resolver/AjaxExceptionViewResolver.java b/src/main/java/kr/xit/framework/support/exception/resolver/AjaxExceptionViewResolver.java index 6f19aeca..0e6bac64 100644 --- a/src/main/java/kr/xit/framework/support/exception/resolver/AjaxExceptionViewResolver.java +++ b/src/main/java/kr/xit/framework/support/exception/resolver/AjaxExceptionViewResolver.java @@ -40,6 +40,7 @@ public class AjaxExceptionViewResolver extends AbstractExceptionViewResolver { String stackTraceString = ""; if(Globals.IS_SP_ALERT_MSG) stackTraceString = out.toString(); Map tempMap = AjaxMessageMapRenderer.error(errorCode, errorArguments); + tempMap.put("result", false); if(Globals.IS_SP_ALERT_MSG) tempMap.put("message", tempMap.get("message")+"\n"+stackTraceString); else tempMap.put("message", tempMap.get("message")); return new ModelAndView(getView(), tempMap); diff --git a/src/main/java/kr/xit/framework/support/util/constants/Globals.java b/src/main/java/kr/xit/framework/support/util/constants/Globals.java index e589e692..40db23b4 100644 --- a/src/main/java/kr/xit/framework/support/util/constants/Globals.java +++ b/src/main/java/kr/xit/framework/support/util/constants/Globals.java @@ -4,7 +4,7 @@ import kr.xit.framework.support.util.PropertyHelper; public class Globals { //public static final boolean IS_SP_ALERT_MSG = PropertyHelper.getBoolean("Globals.error.isAlert"); - public static final boolean IS_SP_ALERT_MSG = false; + public static final boolean IS_SP_ALERT_MSG = true; public static final String JSON_RESULT_CODE= "code"; public static final String JSON_RESULT_MESSAGE= "message"; diff --git a/src/main/webapp/WEB-INF/jsp/framework/biz/mng/usr/mngUserRegMgtForm.jsp b/src/main/webapp/WEB-INF/jsp/framework/biz/mng/usr/mngUserRegMgtForm.jsp index 7b23b0a3..999d5435 100644 --- a/src/main/webapp/WEB-INF/jsp/framework/biz/mng/usr/mngUserRegMgtForm.jsp +++ b/src/main/webapp/WEB-INF/jsp/framework/biz/mng/usr/mngUserRegMgtForm.jsp @@ -199,6 +199,19 @@ ======================== */ findData : function(){ console.log($('#frmSearch').serialize()) + + + + + + + + + + + // grid 에러 발생 처리 + + GRID.reloadData(); }, /* ======================== diff --git a/src/main/webapp/resources/js/framework/cmmn/xit-tui-grid.js b/src/main/webapp/resources/js/framework/cmmn/xit-tui-grid.js index 1898c918..7eef36aa 100644 --- a/src/main/webapp/resources/js/framework/cmmn/xit-tui-grid.js +++ b/src/main/webapp/resources/js/framework/cmmn/xit-tui-grid.js @@ -157,11 +157,13 @@ const TuiGrid = { console.log(`failResponse >>>>>>>>>>>>>>>>>> `,ev); try { var msg = JSON.parse(ev.xhr.response).message; //tui-grid 기본 format 메시지 - if(fnIsEmpty(msg)) + if(!msg) { msg = JSON.parse(ev.xhr.response).resp.message; - if(!fnIsEmpty(msg)) + }else { alert(msg); + } } catch (e) { + console.error('TuiGrid::failResponse parsing error', e) } }); // 오류가 발생한 경우 @@ -169,11 +171,13 @@ const TuiGrid = { console.log(`errorResponse >>>>>>>>>>>>>>>>>> `,ev); try { var msg = JSON.parse(ev.xhr.response).message; //tui-grid 기본 format 메시지 - if(fnIsEmpty(msg)) + if(!msg) { msg = JSON.parse(ev.xhr.response).resp.message; - if(!fnIsEmpty(msg)) + }else { alert(msg); + } } catch (e) { + console.error('TuiGrid::errorResponse parsing error', e) } });