Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
elearn
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
hqzhdj
elearn
Commits
afa369cd
Commit
afa369cd
authored
Jan 22, 2025
by
阳浪
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
管理端添加验证码
parent
35f20d67
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
0 deletions
+8
-0
cloud-system-api/src/main/java/com/yizhi/system/application/vo/LoginInfoVO.java
+6
-0
cloud-system/src/main/java/com/yizhi/system/application/controller/api/AuthController.java
+2
-0
No files found.
cloud-system-api/src/main/java/com/yizhi/system/application/vo/LoginInfoVO.java
View file @
afa369cd
...
@@ -37,4 +37,10 @@ public class LoginInfoVO {
...
@@ -37,4 +37,10 @@ public class LoginInfoVO {
@ApiModelProperty
(
"语种code"
)
@ApiModelProperty
(
"语种code"
)
private
String
languageCode
;
private
String
languageCode
;
@ApiModelProperty
(
value
=
"图形验证码Key"
)
private
String
captchaKey
;
@ApiModelProperty
(
value
=
"图形验证码"
)
private
String
captchaVal
;
}
}
cloud-system/src/main/java/com/yizhi/system/application/controller/api/AuthController.java
View file @
afa369cd
...
@@ -543,6 +543,8 @@ public class AuthController {
...
@@ -543,6 +543,8 @@ public class AuthController {
"application/json;charset=utf-8"
},
method
=
RequestMethod
.
POST
)
"application/json;charset=utf-8"
},
method
=
RequestMethod
.
POST
)
public
Response
<
String
>
loginManage
(
HttpServletRequest
request
,
HttpServletResponse
httpResponse
,
public
Response
<
String
>
loginManage
(
HttpServletRequest
request
,
HttpServletResponse
httpResponse
,
@ApiParam
(
name
=
"user"
)
@RequestBody
@Valid
LoginInfoVO
user
,
BindingResult
validResults
)
{
@ApiParam
(
name
=
"user"
)
@RequestBody
@Valid
LoginInfoVO
user
,
BindingResult
validResults
)
{
boolean
flag
=
accountService
.
validateCaptcha
(
user
.
getCaptchaKey
(),
user
.
getCaptchaVal
());
//图形码验证
if
(
validResults
.
hasFieldErrors
())
{
if
(
validResults
.
hasFieldErrors
())
{
String
error
=
ValidUtil
.
convertParamError
(
validResults
.
getFieldErrors
());
String
error
=
ValidUtil
.
convertParamError
(
validResults
.
getFieldErrors
());
logger
.
warn
(
"参数校验错误:{}"
+
error
);
logger
.
warn
(
"参数校验错误:{}"
+
error
);
...
...
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