Commit 7083d991fe2a99ebdd995992ceb4c21a5f1f9a9a
1 parent
b28baf0e
refactor: verify
Showing
8 changed files
with
24 additions
and
62 deletions
yudao-ui-admin/src/api/login.js
| @@ -126,5 +126,23 @@ export function authorize(responseType, clientId, redirectUri, state, | @@ -126,5 +126,23 @@ export function authorize(responseType, clientId, redirectUri, state, | ||
| 126 | }) | 126 | }) |
| 127 | } | 127 | } |
| 128 | 128 | ||
| 129 | +// 获取验证图片 以及token | ||
| 130 | +export function reqGet(data) { | ||
| 131 | + return request({ | ||
| 132 | + url: 'system/captcha/get', | ||
| 133 | + method: 'post', | ||
| 134 | + data | ||
| 135 | + }) | ||
| 136 | +} | ||
| 137 | + | ||
| 138 | +// 滑动或者点选验证 | ||
| 139 | +export function reqCheck(data) { | ||
| 140 | + return request({ | ||
| 141 | + url: '/system/captcha/check', | ||
| 142 | + method: 'post', | ||
| 143 | + data | ||
| 144 | + }) | ||
| 145 | +} | ||
| 146 | + | ||
| 129 | export class socialBindLogin { | 147 | export class socialBindLogin { |
| 130 | } | 148 | } |
yudao-ui-admin/src/components/RightToolbar/index.vue
| @@ -92,13 +92,13 @@ export default { | @@ -92,13 +92,13 @@ export default { | ||
| 92 | }; | 92 | }; |
| 93 | </script> | 93 | </script> |
| 94 | <style lang="scss" scoped> | 94 | <style lang="scss" scoped> |
| 95 | -::v-deep .el-transfer__button { | 95 | +:deep(.el-transfer__button) { |
| 96 | border-radius: 50%; | 96 | border-radius: 50%; |
| 97 | padding: 12px; | 97 | padding: 12px; |
| 98 | display: block; | 98 | display: block; |
| 99 | margin-left: 0px; | 99 | margin-left: 0px; |
| 100 | } | 100 | } |
| 101 | -::v-deep .el-transfer__button:first-child { | 101 | +:deep(.el-transfer__button:first-child) { |
| 102 | margin-bottom: 10px; | 102 | margin-bottom: 10px; |
| 103 | } | 103 | } |
| 104 | </style> | 104 | </style> |
yudao-ui-admin/src/components/Verifition/Verify/VerifyPoints.vue
| @@ -60,7 +60,7 @@ | @@ -60,7 +60,7 @@ | ||
| 60 | * */ | 60 | * */ |
| 61 | import { resetSize } from './../utils/util' | 61 | import { resetSize } from './../utils/util' |
| 62 | import { aesEncrypt } from '@/utils/ase' | 62 | import { aesEncrypt } from '@/utils/ase' |
| 63 | -import { reqGet, reqCheck } from './../api/index' | 63 | +import { reqGet, reqCheck } from '@/api/login' |
| 64 | 64 | ||
| 65 | export default { | 65 | export default { |
| 66 | name: 'VerifyPoints', | 66 | name: 'VerifyPoints', |
yudao-ui-admin/src/components/Verifition/Verify/VerifySlide.vue
| @@ -64,7 +64,7 @@ | @@ -64,7 +64,7 @@ | ||
| 64 | * */ | 64 | * */ |
| 65 | import { aesEncrypt } from '@/utils/ase' | 65 | import { aesEncrypt } from '@/utils/ase' |
| 66 | import { resetSize } from './../utils/util' | 66 | import { resetSize } from './../utils/util' |
| 67 | -import { reqGet, reqCheck } from './../api/index' | 67 | +import { reqGet, reqCheck } from '@/api/login' |
| 68 | 68 | ||
| 69 | // "captchaType":"blockPuzzle", | 69 | // "captchaType":"blockPuzzle", |
| 70 | export default { | 70 | export default { |
yudao-ui-admin/src/components/Verifition/api/index.js deleted
| 1 | -/** | ||
| 2 | - * 此处可直接引用自己项目封装好的 axios 配合后端联调 | ||
| 3 | - */ | ||
| 4 | - | ||
| 5 | -import request from './../utils/axios' // 组件内部封装的axios | ||
| 6 | -// import request from "@/api/axios.js" //调用项目封装的axios | ||
| 7 | - | ||
| 8 | -// 获取验证图片 以及token | ||
| 9 | -export function reqGet(data) { | ||
| 10 | - return request({ | ||
| 11 | - // url: '/captcha/get', | ||
| 12 | - url: '/admin-api/system/captcha/get', // 使用项目自定义的 /admin-api/ 前缀 | ||
| 13 | - method: 'post', | ||
| 14 | - data | ||
| 15 | - }) | ||
| 16 | -} | ||
| 17 | - | ||
| 18 | -// 滑动或者点选验证 | ||
| 19 | -export function reqCheck(data) { | ||
| 20 | - return request({ | ||
| 21 | - // url: '/captcha/check', | ||
| 22 | - url: '/admin-api/system/captcha/check', // 使用项目自定义的 /admin-api/ 前缀 | ||
| 23 | - method: 'post', | ||
| 24 | - data | ||
| 25 | - }) | ||
| 26 | -} | ||
| 27 | - |
yudao-ui-admin/src/components/Verifition/utils/axios.js deleted
| 1 | -import axios from 'axios' | ||
| 2 | - | ||
| 3 | -axios.defaults.baseURL = process.env.VUE_APP_BASE_API | ||
| 4 | - | ||
| 5 | -const service = axios.create({ | ||
| 6 | - timeout: 40000, | ||
| 7 | - headers: { | ||
| 8 | - 'X-Requested-With': 'XMLHttpRequest', | ||
| 9 | - 'Content-Type': 'application/json; charset=UTF-8' | ||
| 10 | - }, | ||
| 11 | -}) | ||
| 12 | -service.interceptors.request.use( | ||
| 13 | - config => { | ||
| 14 | - return config | ||
| 15 | - }, | ||
| 16 | - error => { | ||
| 17 | - Promise.reject(error) | ||
| 18 | - } | ||
| 19 | -) | ||
| 20 | - | ||
| 21 | -// response interceptor | ||
| 22 | -service.interceptors.response.use( | ||
| 23 | - response => { | ||
| 24 | - return response.data | ||
| 25 | - }, | ||
| 26 | - error => { | ||
| 27 | - } | ||
| 28 | -) | ||
| 29 | -export default service |
yudao-ui-admin/src/views/mall/trade/order/detail.vue
| @@ -244,7 +244,7 @@ export default { | @@ -244,7 +244,7 @@ export default { | ||
| 244 | </script> | 244 | </script> |
| 245 | 245 | ||
| 246 | <style lang="scss" scoped> | 246 | <style lang="scss" scoped> |
| 247 | - ::v-deep .el-descriptions{ | 247 | + :deep(.el-descriptions){ |
| 248 | &:not(:nth-child(1)) { | 248 | &:not(:nth-child(1)) { |
| 249 | margin-top: 20px; | 249 | margin-top: 20px; |
| 250 | } | 250 | } |
yudao-ui-admin/src/views/mall/trade/order/index.vue
| @@ -332,7 +332,7 @@ | @@ -332,7 +332,7 @@ | ||
| 332 | </script> | 332 | </script> |
| 333 | 333 | ||
| 334 | <style lang="scss" scoped> | 334 | <style lang="scss" scoped> |
| 335 | - ::v-deep .order-table{ | 335 | + :deep(.order-table){ |
| 336 | margin-top: 20px; | 336 | margin-top: 20px; |
| 337 | border-bottom: none; | 337 | border-bottom: none; |
| 338 | &::before{ | 338 | &::before{ |