mirror of https://gitee.com/xiaonuobase/snowy
【更新】修改登录相关代码格式
parent
28b66269dd
commit
2518ebc4f6
|
@ -89,3 +89,31 @@ export function getCaptchaOpen (parameter) {
|
|||
params: parameter
|
||||
})
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取验证图片 以及token
|
||||
*
|
||||
* @author Jax
|
||||
* @date 2021/1/22 00:00
|
||||
*/
|
||||
export function reqGet(data) {
|
||||
return axios({
|
||||
url: '/captcha/get',
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
/**
|
||||
* 滑动或者点选验证
|
||||
*
|
||||
* @author Jax
|
||||
* @date 2021/1/22 00:00
|
||||
*/
|
||||
export function reqCheck(data) {
|
||||
return axios({
|
||||
url: '/captcha/check',
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
|
|
@ -58,10 +58,9 @@
|
|||
* VerifyPoints
|
||||
* @description 点选
|
||||
* */
|
||||
// _code_chars, _code_color1, _code_color2
|
||||
import { resetSize } from './../utils/util'
|
||||
import { aesEncrypt } from './../utils/ase'
|
||||
import { reqGet, reqCheck } from './../api/index'
|
||||
import { reqGet, reqCheck } from '@/api/modular/system/loginManage'
|
||||
|
||||
export default {
|
||||
name: 'VerifyPoints',
|
||||
|
|
|
@ -58,7 +58,7 @@
|
|||
* */
|
||||
import { aesEncrypt } from './../utils/ase'
|
||||
import { resetSize } from './../utils/util'
|
||||
import { reqGet, reqCheck } from './../api/index'
|
||||
import { reqGet, reqCheck } from '@/api/modular/system/loginManage'
|
||||
|
||||
// "captchaType":"blockPuzzle",
|
||||
export default {
|
||||
|
|
|
@ -1,22 +0,0 @@
|
|||
/**
|
||||
* 此处可直接引用自己项目封装好的 axios 配合后端联调
|
||||
*/
|
||||
import { axios } from '@/utils/request'
|
||||
|
||||
// 获取验证图片 以及token
|
||||
export function reqGet(data) {
|
||||
return axios({
|
||||
url: '/captcha/get',
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
// 滑动或者点选验证
|
||||
export function reqCheck(data) {
|
||||
return axios({
|
||||
url: '/captcha/check',
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
}
|
|
@ -118,23 +118,22 @@ public class SysLoginController {
|
|||
}
|
||||
|
||||
/**
|
||||
* @Description 获取验证码开关
|
||||
* @author Jax
|
||||
* @Date 2021/1/21 15:19
|
||||
* @return ResponseData
|
||||
**/
|
||||
* 获取验证码开关
|
||||
*
|
||||
* @author Jax
|
||||
* @date 2021/1/21 15:27
|
||||
*/
|
||||
@GetMapping("/getCaptchaOpen")
|
||||
public ResponseData getCaptchaOpen() {
|
||||
return new SuccessResponseData(ConstantContextHolder.getCaptchaOpenFlag());
|
||||
}
|
||||
|
||||
/**
|
||||
* @Description 校验验证码
|
||||
* @Date 2021/1/21 15:27
|
||||
* @author Jax
|
||||
* @param code
|
||||
* @return boolean
|
||||
**/
|
||||
* 校验验证码
|
||||
*
|
||||
* @author Jax
|
||||
* @date 2021/1/21 15:27
|
||||
*/
|
||||
private boolean verificationCode(String code) {
|
||||
CaptchaVO vo = new CaptchaVO();
|
||||
vo.setCaptchaVerification(code);
|
||||
|
|
Loading…
Reference in New Issue