| | |
| | | package com.ruoyi.common.security.handler; |
| | | |
| | | import com.ruoyi.common.core.constant.HttpStatus; |
| | | import com.ruoyi.common.core.domain.R; |
| | | import com.ruoyi.common.core.exception.DemoModeException; |
| | | import com.ruoyi.common.core.exception.GlobalException; |
| | | import com.ruoyi.common.core.exception.InnerAuthException; |
| | |
| | | * 捕获全局自定义异常 |
| | | */ |
| | | @ExceptionHandler(GlobalException.class) |
| | | public AjaxResult globalExceptionHandler(GlobalException e) { |
| | | return AjaxResult.error(e.getMessage()); |
| | | public R<String> globalExceptionHandler(GlobalException e) { |
| | | return R.fail(e.getMessage()); |
| | | } |
| | | |
| | | } |