From 3fbb0b4c54bb1418a83976ac272fa0e95c7946cf Mon Sep 17 00:00:00 2001 From: YunaiV Date: Fri, 11 Nov 2022 20:47:45 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E6=BB=91=E5=9D=97=E9=AA=8C?= =?UTF-8?q?=E8=AF=81=E7=A0=81=EF=BC=8C=E5=AD=98=E5=9C=A8=E5=A4=B1=E8=B4=A5?= =?UTF-8?q?=E7=9A=84=E6=83=85=E5=86=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../admin/captcha/CaptchaController.java | 7 +++++-- .../main/resources/admin-ui/static/js/2.js | 2 +- .../main/resources/admin-ui/static/js/2.js.gz | Bin 89847 -> 89852 bytes .../src/main/resources/application.yaml | 4 ++-- .../verifition/verifyPoint/verifyPoint.vue | 4 ++-- .../verifition/verifySlider/verifySlider.vue | 4 ++-- .../components/Verifition/src/api/index.ts | 4 ++-- .../src/components/Verifition/api/index.js | 4 ++-- 8 files changed, 16 insertions(+), 13 deletions(-) diff --git a/yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/controller/admin/captcha/CaptchaController.java b/yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/controller/admin/captcha/CaptchaController.java index db2bc0cd4..8fbb7c0ca 100644 --- a/yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/controller/admin/captcha/CaptchaController.java +++ b/yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/controller/admin/captcha/CaptchaController.java @@ -1,5 +1,6 @@ package cn.iocoder.yudao.module.system.controller.admin.captcha; +import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; import com.anji.captcha.model.common.ResponseModel; import com.anji.captcha.model.vo.CaptchaVO; import io.swagger.annotations.Api; @@ -22,19 +23,21 @@ import javax.servlet.http.HttpServletRequest; */ @Api(tags = "管理后台 - 验证码") @RestController("adminCaptchaController") -@RequestMapping("/captcha") +@RequestMapping("/system/captcha") public class CaptchaController extends com.anji.captcha.controller.CaptchaController { @PostMapping({"/get"}) @ApiOperation("获得验证码") @PermitAll + @OperateLog(enable = false) // 避免 Post 请求被记录操作日志 public ResponseModel get(@RequestBody CaptchaVO data, HttpServletRequest request) { return super.get(data, request); } - @PostMapping({"/check"}) + @PostMapping("/check") @ApiOperation("校验验证码") @PermitAll + @OperateLog(enable = false) // 避免 Post 请求被记录操作日志 public ResponseModel check(@RequestBody CaptchaVO data, HttpServletRequest request) { return super.check(data, request); } diff --git a/yudao-server/src/main/resources/admin-ui/static/js/2.js b/yudao-server/src/main/resources/admin-ui/static/js/2.js index aebaf825d..d262d33f0 100644 --- a/yudao-server/src/main/resources/admin-ui/static/js/2.js +++ b/yudao-server/src/main/resources/admin-ui/static/js/2.js @@ -673,7 +673,7 @@ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _nod /***/ (function(module, exports, __webpack_require__) { "use strict"; -eval("\n\nvar _interopRequireDefault = __webpack_require__(/*! ./node_modules/@babel/runtime/helpers/interopRequireDefault.js */ \"./node_modules/@babel/runtime/helpers/interopRequireDefault.js\").default;\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.reqCheck = reqCheck;\nexports.reqGet = reqGet;\nvar _axios = _interopRequireDefault(__webpack_require__(/*! ./../utils/axios */ \"./src/components/Verifition/utils/axios.js\"));\n/**\n * 此处可直接引用自己项目封装好的 axios 配合后端联调\n */\n\n// 组件内部封装的axios\n// import request from \"@/api/axios.js\" //调用项目封装的axios\n\n// 获取验证图片 以及token\nfunction reqGet(data) {\n return (0, _axios.default)({\n // url: '/captcha/get',\n url: '/admin-api/captcha/get',\n // 使用项目自定义的 /admin-api/ 前缀\n method: 'post',\n data: data\n });\n}\n\n// 滑动或者点选验证\nfunction reqCheck(data) {\n return (0, _axios.default)({\n // url: '/captcha/check',\n url: '/admin-api/captcha/check',\n // 使用项目自定义的 /admin-api/ 前缀\n method: 'post',\n data: data\n });\n}\n\n//# sourceURL=webpack:///./src/components/Verifition/api/index.js?"); +eval("\n\nvar _interopRequireDefault = __webpack_require__(/*! ./node_modules/@babel/runtime/helpers/interopRequireDefault.js */ \"./node_modules/@babel/runtime/helpers/interopRequireDefault.js\").default;\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.reqCheck = reqCheck;\nexports.reqGet = reqGet;\nvar _axios = _interopRequireDefault(__webpack_require__(/*! ./../utils/axios */ \"./src/components/Verifition/utils/axios.js\"));\n/**\n * 此处可直接引用自己项目封装好的 axios 配合后端联调\n */\n\n// 组件内部封装的axios\n// import request from \"@/api/axios.js\" //调用项目封装的axios\n\n// 获取验证图片 以及token\nfunction reqGet(data) {\n return (0, _axios.default)({\n // url: '/captcha/get',\n url: '/admin-api/system/captcha/get',\n // 使用项目自定义的 /admin-api/ 前缀\n method: 'post',\n data: data\n });\n}\n\n// 滑动或者点选验证\nfunction reqCheck(data) {\n return (0, _axios.default)({\n // url: '/captcha/check',\n url: '/admin-api/system/captcha/check',\n // 使用项目自定义的 /admin-api/ 前缀\n method: 'post',\n data: data\n });\n}\n\n//# sourceURL=webpack:///./src/components/Verifition/api/index.js?"); /***/ }), diff --git a/yudao-server/src/main/resources/admin-ui/static/js/2.js.gz b/yudao-server/src/main/resources/admin-ui/static/js/2.js.gz index 2933a8b8621e63ca5536507a0adb471cc3bb05f7..3fe7ecdc03c72946ef567b02875a258507845fcc 100644 GIT binary patch delta 1579 zcmV+`2GsfYy#@Te1%R{x=~#cys~l*?n_dO&{Qckk*UOPK2>!*N{r%tkL4(vQ4YZ#B z!5@9`x4(O;6FG&S*r12z>lPOcHPC-@ESuktT=@ApCVutH|M~eJ{?)Jk>A(2$cYprH z|MWM%{@p(~VdXjsj@$IFBuv839-Kp(JJ~L< zn(Vx{@_COe8eUIDRJ>+0es=+H6u;Kz%q`~xz3aL(-zQsS?&~{DU1FS@}r}MI;ZEJ04n@eeH^8R8s@UE-r)4fL7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kc={0eD$$>9{e65W;;`nN-FE@58xUYfZ7h-ZNz;A}*YYpGf-V315P1Fn8 z9Fg(K6&b&La_aPxt1^Gt+j*@QD&X?TMXeVg9s53oB}aRAO-cQv^SFgPZlRA`*yC3B zaSMOkA|AKM$1UnH@FzY3h1nEVQ`k-6G=VgO%XK3x+ykI5jI8C6me4|O_4Um zwkfiv$eW^Qin1woO|fr^LsL{uQ8xwM6iidFP0?!#t||IWF=&cmQ}9hOY6_t##!WG4 zifL1bO)+ZY^8<)F z4JYq8R#v4A3SRtj{S7X@^2Yfu-+p*{hwgtf#{z_XV^Z&D{^Yj1v*MItp=l|hCpiI;(TOQyY=Ji51YVxFXV%8 zV%f6^=gS@Dqff7Nbku<77`_bWo!EM+6fXJn=s!F>hv(5{z1*?#*QvO_R?9h!*0FD_ zN^|q4=Wjf0+CN{FJa-}h(SUHhT&sV%|CD2ybKf8}Y#UJHrZ>T(r?ZWf6PHt%myXIM zV1NZrR diff --git a/yudao-server/src/main/resources/application.yaml b/yudao-server/src/main/resources/application.yaml index b1a1b7510..a9d638ae2 100644 --- a/yudao-server/src/main/resources/application.yaml +++ b/yudao-server/src/main/resources/application.yaml @@ -109,8 +109,8 @@ yudao: enable: true ignore-urls: - /admin-api/system/tenant/get-id-by-name # 基于名字获取租户,不许带租户编号 - - /admin-api/captcha/get # 获取图片验证码,和租户无关 - - /admin-api/captcha/check # 校验图片验证码,和租户无关 + - /admin-api/system/captcha/get # 获取图片验证码,和租户无关 + - /admin-api/system/captcha/check # 校验图片验证码,和租户无关 - /admin-api/infra/file/*/get/** # 获取图片,和租户无关 - /admin-api/system/sms/callback/* # 短信回调接口,无法带上租户编号 - /app-api/pay/order/notify/* # 支付回调通知,不携带租户编号 diff --git a/yudao-ui-admin-uniapp/components/verifition/verifyPoint/verifyPoint.vue b/yudao-ui-admin-uniapp/components/verifition/verifyPoint/verifyPoint.vue index c7f65f757..57d7d033d 100644 --- a/yudao-ui-admin-uniapp/components/verifition/verifyPoint/verifyPoint.vue +++ b/yudao-ui-admin-uniapp/components/verifition/verifyPoint/verifyPoint.vue @@ -142,7 +142,7 @@ } myRequest({ // url: `/captcha/check`, - url: '/admin-api/captcha/check', // 使用项目自定义的 /admin-api/ 前缀 + url: '/admin-api/system/captcha/check', // 使用项目自定义的 /admin-api/ 前缀 data, method:"POST", }).then(result => { @@ -213,7 +213,7 @@ } myRequest({ // url: "/captcha/get", //仅为示例,并非真实接口地址。 - url: '/admin-api/captcha/get', // 使用项目自定义的 /admin-api/ 前缀 + url: '/admin-api/system/captcha/get', // 使用项目自定义的 /admin-api/ 前缀 data, method:"POST", }).then((result) => { diff --git a/yudao-ui-admin-uniapp/components/verifition/verifySlider/verifySlider.vue b/yudao-ui-admin-uniapp/components/verifition/verifySlider/verifySlider.vue index 98b9890dc..7c75e0e24 100644 --- a/yudao-ui-admin-uniapp/components/verifition/verifySlider/verifySlider.vue +++ b/yudao-ui-admin-uniapp/components/verifition/verifySlider/verifySlider.vue @@ -231,7 +231,7 @@ } myRequest({ // url: `/captcha/check`, - url: '/admin-api/captcha/check', // 使用项目自定义的 /admin-api/ 前缀 + url: '/admin-api/system/captcha/check', // 使用项目自定义的 /admin-api/ 前缀 data, method: "POST", }).then((result) => { @@ -319,7 +319,7 @@ } myRequest({ // url: '/captcha/get', //仅为示例,并非真实接口地址。 - url: '/admin-api/captcha/get', // 使用项目自定义的 /admin-api/ 前缀 + url: '/admin-api/system/captcha/get', // 使用项目自定义的 /admin-api/ 前缀 data, method: "POST", }).then((result) => { diff --git a/yudao-ui-admin-vue3/src/components/Verifition/src/api/index.ts b/yudao-ui-admin-vue3/src/components/Verifition/src/api/index.ts index cf18d8a37..78c7c335c 100644 --- a/yudao-ui-admin-vue3/src/components/Verifition/src/api/index.ts +++ b/yudao-ui-admin-vue3/src/components/Verifition/src/api/index.ts @@ -9,7 +9,7 @@ import request from './../utils/axios' //组件内部封装的axios export function reqGet(data) { return request({ // url: '/captcha/get', - url: '/admin-api/captcha/get', // 使用项目自定义的 /admin-api/ 前缀 + url: '/admin-api/system/captcha/get', // 使用项目自定义的 /admin-api/ 前缀 method: 'post', data }) @@ -19,7 +19,7 @@ export function reqGet(data) { export function reqCheck(data) { return request({ // url: '/captcha/check', - url: '/admin-api/captcha/check', // 使用项目自定义的 /admin-api/ 前缀 + url: '/admin-api/system/captcha/check', // 使用项目自定义的 /admin-api/ 前缀 method: 'post', data }) diff --git a/yudao-ui-admin/src/components/Verifition/api/index.js b/yudao-ui-admin/src/components/Verifition/api/index.js index f97f80c41..7c5a94094 100644 --- a/yudao-ui-admin/src/components/Verifition/api/index.js +++ b/yudao-ui-admin/src/components/Verifition/api/index.js @@ -9,7 +9,7 @@ import request from './../utils/axios' // 组件内部封装的axios export function reqGet(data) { return request({ // url: '/captcha/get', - url: '/admin-api/captcha/get', // 使用项目自定义的 /admin-api/ 前缀 + url: '/admin-api/system/captcha/get', // 使用项目自定义的 /admin-api/ 前缀 method: 'post', data }) @@ -19,7 +19,7 @@ export function reqGet(data) { export function reqCheck(data) { return request({ // url: '/captcha/check', - url: '/admin-api/captcha/check', // 使用项目自定义的 /admin-api/ 前缀 + url: '/admin-api/system/captcha/check', // 使用项目自定义的 /admin-api/ 前缀 method: 'post', data })