Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
S
sts网站
Project
Project
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
liyang
sts网站
Commits
eb9f3d37
Commit
eb9f3d37
authored
Jul 12, 2022
by
RuoYi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改验证码开关变量名
parent
1a617904
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
706 additions
and
706 deletions
+706
-706
CaptchaController.java
...va/com/ruoyi/web/controller/common/CaptchaController.java
+3
-3
SysLoginService.java
...java/com/ruoyi/framework/web/service/SysLoginService.java
+2
-2
SysRegisterService.java
...a/com/ruoyi/framework/web/service/SysRegisterService.java
+2
-2
ISysConfigService.java
...main/java/com/ruoyi/system/service/ISysConfigService.java
+1
-1
SysConfigServiceImpl.java
...a/com/ruoyi/system/service/impl/SysConfigServiceImpl.java
+4
-4
login.vue
ruoyi-ui/src/views/login.vue
+5
-5
resetPwd.vue
ruoyi-ui/src/views/system/user/profile/resetPwd.vue
+1
-1
ry_20220712.sql
sql/ry_20220712.sql
+688
-688
No files found.
ruoyi-admin/src/main/java/com/ruoyi/web/controller/common/CaptchaController.java
View file @
eb9f3d37
...
@@ -46,9 +46,9 @@ public class CaptchaController
...
@@ -46,9 +46,9 @@ public class CaptchaController
public
AjaxResult
getCode
(
HttpServletResponse
response
)
throws
IOException
public
AjaxResult
getCode
(
HttpServletResponse
response
)
throws
IOException
{
{
AjaxResult
ajax
=
AjaxResult
.
success
();
AjaxResult
ajax
=
AjaxResult
.
success
();
boolean
captcha
OnOff
=
configService
.
selectCaptchaOnOff
();
boolean
captcha
Enabled
=
configService
.
selectCaptchaEnabled
();
ajax
.
put
(
"captcha
OnOff"
,
captchaOnOff
);
ajax
.
put
(
"captcha
Enabled"
,
captchaEnabled
);
if
(!
captcha
OnOff
)
if
(!
captcha
Enabled
)
{
{
return
ajax
;
return
ajax
;
}
}
...
...
ruoyi-framework/src/main/java/com/ruoyi/framework/web/service/SysLoginService.java
View file @
eb9f3d37
...
@@ -60,9 +60,9 @@ public class SysLoginService
...
@@ -60,9 +60,9 @@ public class SysLoginService
*/
*/
public
String
login
(
String
username
,
String
password
,
String
code
,
String
uuid
)
public
String
login
(
String
username
,
String
password
,
String
code
,
String
uuid
)
{
{
boolean
captcha
OnOff
=
configService
.
selectCaptchaOnOff
();
boolean
captcha
Enabled
=
configService
.
selectCaptchaEnabled
();
// 验证码开关
// 验证码开关
if
(
captcha
OnOff
)
if
(
captcha
Enabled
)
{
{
validateCaptcha
(
username
,
code
,
uuid
);
validateCaptcha
(
username
,
code
,
uuid
);
}
}
...
...
ruoyi-framework/src/main/java/com/ruoyi/framework/web/service/SysRegisterService.java
View file @
eb9f3d37
...
@@ -42,9 +42,9 @@ public class SysRegisterService
...
@@ -42,9 +42,9 @@ public class SysRegisterService
{
{
String
msg
=
""
,
username
=
registerBody
.
getUsername
(),
password
=
registerBody
.
getPassword
();
String
msg
=
""
,
username
=
registerBody
.
getUsername
(),
password
=
registerBody
.
getPassword
();
boolean
captcha
OnOff
=
configService
.
selectCaptchaOnOff
();
boolean
captcha
Enabled
=
configService
.
selectCaptchaEnabled
();
// 验证码开关
// 验证码开关
if
(
captcha
OnOff
)
if
(
captcha
Enabled
)
{
{
validateCaptcha
(
username
,
registerBody
.
getCode
(),
registerBody
.
getUuid
());
validateCaptcha
(
username
,
registerBody
.
getCode
(),
registerBody
.
getUuid
());
}
}
...
...
ruoyi-system/src/main/java/com/ruoyi/system/service/ISysConfigService.java
View file @
eb9f3d37
...
@@ -31,7 +31,7 @@ public interface ISysConfigService
...
@@ -31,7 +31,7 @@ public interface ISysConfigService
*
*
* @return true开启,false关闭
* @return true开启,false关闭
*/
*/
public
boolean
selectCaptcha
OnOff
();
public
boolean
selectCaptcha
Enabled
();
/**
/**
* 查询参数配置列表
* 查询参数配置列表
...
...
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/SysConfigServiceImpl.java
View file @
eb9f3d37
...
@@ -86,14 +86,14 @@ public class SysConfigServiceImpl implements ISysConfigService
...
@@ -86,14 +86,14 @@ public class SysConfigServiceImpl implements ISysConfigService
* @return true开启,false关闭
* @return true开启,false关闭
*/
*/
@Override
@Override
public
boolean
selectCaptcha
OnOff
()
public
boolean
selectCaptcha
Enabled
()
{
{
String
captcha
OnOff
=
selectConfigByKey
(
"sys.account.captchaOnOff
"
);
String
captcha
Enabled
=
selectConfigByKey
(
"sys.account.captchaEnabled
"
);
if
(
StringUtils
.
isEmpty
(
captcha
OnOff
))
if
(
StringUtils
.
isEmpty
(
captcha
Enabled
))
{
{
return
true
;
return
true
;
}
}
return
Convert
.
toBool
(
captcha
OnOff
);
return
Convert
.
toBool
(
captcha
Enabled
);
}
}
/**
/**
...
...
ruoyi-ui/src/views/login.vue
View file @
eb9f3d37
...
@@ -23,7 +23,7 @@
...
@@ -23,7 +23,7 @@
<svg-icon
slot=
"prefix"
icon-class=
"password"
class=
"el-input__icon input-icon"
/>
<svg-icon
slot=
"prefix"
icon-class=
"password"
class=
"el-input__icon input-icon"
/>
</el-input>
</el-input>
</el-form-item>
</el-form-item>
<el-form-item
prop=
"code"
v-if=
"captcha
OnOff
"
>
<el-form-item
prop=
"code"
v-if=
"captcha
Enabled
"
>
<el-input
<el-input
v-model=
"loginForm.code"
v-model=
"loginForm.code"
auto-complete=
"off"
auto-complete=
"off"
...
@@ -89,7 +89,7 @@ export default {
...
@@ -89,7 +89,7 @@ export default {
},
},
loading
:
false
,
loading
:
false
,
// 验证码开关
// 验证码开关
captcha
OnOff
:
true
,
captcha
Enabled
:
true
,
// 注册开关
// 注册开关
register
:
false
,
register
:
false
,
redirect
:
undefined
redirect
:
undefined
...
@@ -110,8 +110,8 @@ export default {
...
@@ -110,8 +110,8 @@ export default {
methods
:
{
methods
:
{
getCode
()
{
getCode
()
{
getCodeImg
().
then
(
res
=>
{
getCodeImg
().
then
(
res
=>
{
this
.
captcha
OnOff
=
res
.
captchaOnOff
===
undefined
?
true
:
res
.
captchaOnOff
;
this
.
captcha
Enabled
=
res
.
captchaEnabled
===
undefined
?
true
:
res
.
captchaEnabled
;
if
(
this
.
captcha
OnOff
)
{
if
(
this
.
captcha
Enabled
)
{
this
.
codeUrl
=
"data:image/gif;base64,"
+
res
.
img
;
this
.
codeUrl
=
"data:image/gif;base64,"
+
res
.
img
;
this
.
loginForm
.
uuid
=
res
.
uuid
;
this
.
loginForm
.
uuid
=
res
.
uuid
;
}
}
...
@@ -144,7 +144,7 @@ export default {
...
@@ -144,7 +144,7 @@ export default {
this
.
$router
.
push
({
path
:
this
.
redirect
||
"/"
}).
catch
(()
=>
{});
this
.
$router
.
push
({
path
:
this
.
redirect
||
"/"
}).
catch
(()
=>
{});
}).
catch
(()
=>
{
}).
catch
(()
=>
{
this
.
loading
=
false
;
this
.
loading
=
false
;
if
(
this
.
captcha
OnOff
)
{
if
(
this
.
captcha
Enabled
)
{
this
.
getCode
();
this
.
getCode
();
}
}
});
});
...
...
ruoyi-ui/src/views/system/user/profile/resetPwd.vue
View file @
eb9f3d37
...
@@ -7,7 +7,7 @@
...
@@ -7,7 +7,7 @@
<el-input
v-model=
"user.newPassword"
placeholder=
"请输入新密码"
type=
"password"
show-password
/>
<el-input
v-model=
"user.newPassword"
placeholder=
"请输入新密码"
type=
"password"
show-password
/>
</el-form-item>
</el-form-item>
<el-form-item
label=
"确认密码"
prop=
"confirmPassword"
>
<el-form-item
label=
"确认密码"
prop=
"confirmPassword"
>
<el-input
v-model=
"user.confirmPassword"
placeholder=
"请确认密码"
type=
"password"
show-password
/>
<el-input
v-model=
"user.confirmPassword"
placeholder=
"请确认
新
密码"
type=
"password"
show-password
/>
</el-form-item>
</el-form-item>
<el-form-item>
<el-form-item>
<el-button
type=
"primary"
size=
"mini"
@
click=
"submit"
>
保存
</el-button>
<el-button
type=
"primary"
size=
"mini"
@
click=
"submit"
>
保存
</el-button>
...
...
sql/ry_20220
625
.sql
→
sql/ry_20220
712
.sql
View file @
eb9f3d37
This source diff could not be displayed because it is too large. You can
view the blob
instead.
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