Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
smart_gov_platform
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
赵啸非
smart_gov_platform
Commits
1b00f31a
Commit
1b00f31a
authored
Oct 09, 2024
by
赵啸非
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
提交配置校验
parent
bc7dde3f
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
9 additions
and
5 deletions
+9
-5
base-manager/src/main/java/com/mortals/xhx/base/framework/exception/ExceptionHandle.java
...mortals/xhx/base/framework/exception/ExceptionHandle.java
+4
-4
base-manager/src/test/java/com/mortals/httpclient/app/AppController.http
...c/test/java/com/mortals/httpclient/app/AppController.http
+1
-1
portal-manager/src/test/java/com/mortals/httpclient/system.http
...-manager/src/test/java/com/mortals/httpclient/system.http
+4
-0
No files found.
base-manager/src/main/java/com/mortals/xhx/base/framework/exception/ExceptionHandle.java
View file @
1b00f31a
...
...
@@ -7,6 +7,7 @@ import org.slf4j.Logger;
import
org.slf4j.LoggerFactory
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.http.converter.HttpMessageNotReadableException
;
import
org.springframework.messaging.handler.annotation.support.MethodArgumentTypeMismatchException
;
import
org.springframework.web.bind.annotation.ControllerAdvice
;
import
org.springframework.web.bind.annotation.ExceptionHandler
;
import
org.springframework.web.bind.annotation.ResponseBody
;
...
...
@@ -46,14 +47,13 @@ public class ExceptionHandle {
stack
.
getClassName
(),
stack
.
getMethodName
(),
stack
.
getLineNumber
(),
e
.
getClass
().
getName
());
AppException
ex
=
(
AppException
)
e
;
ret
.
put
(
KEY_RESULT_MSG
,
ex
.
getMessage
());
}
if
(
e
instanceof
HttpMessageNotReadableException
)
{
}
else
if
(
e
instanceof
HttpMessageNotReadableException
||
e
instanceof
MethodArgumentTypeMismatchException
)
{
log
.
error
(
"[system error]"
,
e
);
response
.
setStatus
(
HttpStatus
.
HTTP_BAD_REQUEST
);
ret
.
put
(
KEY_RESULT_MSG
,
"参数错误,"
+
StrUtil
.
subBefore
(
e
.
getMessage
(),
";"
,
false
));
ret
.
put
(
KEY_RESULT_MSG
,
"参数错误,"
+
StrUtil
.
subBefore
(
e
.
getMessage
(),
";"
,
false
));
}
else
{
log
.
error
(
"[system error]"
,
e
);
response
.
setStatus
(
HttpStatus
.
HTTP_
INTERNAL_ERROR
);
response
.
setStatus
(
HttpStatus
.
HTTP_
BAD_REQUEST
);
ret
.
put
(
KEY_RESULT_MSG
,
"未知错误!"
+
e
.
getMessage
());
}
return
ret
.
toJSONString
();
...
...
base-manager/src/test/java/com/mortals/httpclient/app/AppController.http
View file @
1b00f31a
...
...
@@ -92,7 +92,7 @@ client.global.set("App_id", JSON.parse(response.body).data.id);
%}
###自助终端应用查看
GET {{baseUrl}}/app/in
fo?id=1
GET {{baseUrl}}/app/in
terinfo?id=19999999999999999999999
Accept: application/json
###自助终端应用编辑
...
...
portal-manager/src/test/java/com/mortals/httpclient/system.http
View file @
1b00f31a
...
...
@@ -59,6 +59,10 @@ Accept: application/json
GET {{baseUrl}}/cipher/check
Accept: application/json
###license check1
GET http://192.168.0.250:11078/zwfw/cipher/check
Accept: application/json
### 测试
GET http://192.168.0.98:11072/zwfw_api/admin/statistic/ages?selected=1& substr(user,1,1) = 'a'
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment