From 7bfaaf883858c9569dd0106d02cf877c1ec0d83a Mon Sep 17 00:00:00 2001
From: xiaoQQya <xiaoQQya@126.com>
Date: 星期一, 20 三月 2023 13:22:01 +0800
Subject: [PATCH] fix(国标设备): 修复设备列表云台类型不显示的问题
---
src/main/java/com/genersoft/iot/vmp/conf/GlobalExceptionHandler.java | 11 +++++++++++
1 files changed, 11 insertions(+), 0 deletions(-)
diff --git a/src/main/java/com/genersoft/iot/vmp/conf/GlobalExceptionHandler.java b/src/main/java/com/genersoft/iot/vmp/conf/GlobalExceptionHandler.java
index 728afb9..dbea741 100644
--- a/src/main/java/com/genersoft/iot/vmp/conf/GlobalExceptionHandler.java
+++ b/src/main/java/com/genersoft/iot/vmp/conf/GlobalExceptionHandler.java
@@ -32,6 +32,17 @@
return WVPResult.fail(ErrorCode.ERROR500.getCode(), e.getMessage());
}
+ /**
+ * 榛樿寮傚父澶勭悊
+ * @param e 寮傚父
+ * @return 缁熶竴杩斿洖缁撴灉
+ */
+ @ExceptionHandler(IllegalStateException.class)
+ @ResponseStatus(HttpStatus.BAD_REQUEST)
+ public WVPResult<String> exceptionHandler(IllegalStateException e) {
+ return WVPResult.fail(ErrorCode.ERROR400);
+ }
+
/**
* 鑷畾涔夊紓甯稿鐞嗭紝 澶勭悊controller涓繑鍥炵殑閿欒
--
Gitblit v1.8.0