xiangpei
2024-06-18 88c0cc9f05ba986fd2fb3fe7b1643f80f2de1201
src/main/java/com/ycl/jxkg/config/spring/exception/ExceptionHandle.java
@@ -51,6 +51,20 @@
    }
    /**
     * Handler rest response.
     *
     * @param e the e
     * @return the rest response
     */
    @ExceptionHandler(RuntimeException.class)
    @ResponseBody
    public Result handler(RuntimeException e, HttpServletRequest request) {
        String errMsg = String.format("系统异常-%s", e.getMessage());
        this.printExceptionLocation(e, request, errMsg);
        return new Result<>(SystemCode.InnerError.getCode(), e.getMessage());
    }
    /**
     * JSON传参数据校验异常
     *
     * @param e