Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

全局认证窗口 name 字段无法输入 #61

Open
zcoway opened this issue Apr 8, 2020 · 0 comments
Open

全局认证窗口 name 字段无法输入 #61

zcoway opened this issue Apr 8, 2020 · 0 comments

Comments

@zcoway
Copy link

zcoway commented Apr 8, 2020

swagger-spring-boot 版本: 2.1.5-RELEASE
问题描述:使用 [第十一篇: 一起来学SpringBoot 集成Swagger在线调试]的chapter10项目练习,swagger-spring-boot 版本,升级都 2.1.5-RELEASE,把配置了全局请求头author参数后,能正常访问在线文档,但在接口窗口中配置全局认证时无法输入name 字段值。

使用方法:
spring.swagger.base-package=com.battcn
spring.swagger.enabled=true
spring.swagger.globalOperationParameters[0].name=Authorization
spring.swagger.globalOperationParameters[0].description=Token信息,必填项
spring.swagger.globalOperationParameters[0].modelRef=string
spring.swagger.globalOperationParameters[0].parameterType=header
spring.swagger.globalOperationParameters[0].required=true

页面点击 authorie 按钮报一下错误:

authorizations.vue:52 Uncaught TypeError: Cannot read property 'name' of undefined at a._setAuthorizeVal (authorizations.vue:52) at n (vue.esm.js:190) at e (vue.esm.js:2004) at HTMLButtonElement.t._withTask.t._withTask (vue.esm.js:1802)

https://github.com/zcoway/spring-boot2-learning/blob/master/images/swagger-authorized-error.png
@djspys1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant