添加接口防抖

This commit is contained in:
韩鹏辉
2024-06-14 14:24:14 +08:00
parent 6ab2a32c9f
commit ada1dafe86
5 changed files with 305 additions and 285 deletions

View File

@@ -152,4 +152,17 @@ public class DefaultExceptionAdvice {
return new ResponseEntity<>(response, HttpStatus.OK);
}
/**
* 使用ExceptionHandler注解声明处理TestException异常
*
*/
@ResponseBody
@ExceptionHandler(MsgException.class)
public Result exception(MsgException e) {
// 控制台打印异常
e.printStackTrace();
// 返回错误格式信息
return Result.fail(e.getMessage());
}
}