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

使用@PathVariable参数时,doc调试中无法正确加载响应 #583

Closed
storyxc opened this issue May 29, 2023 · 0 comments
Closed

使用@PathVariable参数时,doc调试中无法正确加载响应 #583

storyxc opened this issue May 29, 2023 · 0 comments

Comments

@storyxc
Copy link

storyxc commented May 29, 2023

Describe the bug
当使用@PathVariable接收参数时,在knife4j页面无法正确加载响应内容,响应内容tab会显示下载文件。参考了demo中的示例,尝试在参数列表中加入@RequestBody参数,就能正确展示响应结果。

Expected behavior
单独使用@PathVariable接收参数时也能正确展示响应结果

Screenshots

  • 单独使用@PathVariable
    Snipaste_2023-05-29_17-31-08
    Snipaste_2023-05-29_17-31-45
    Snipaste_2023-05-29_17-25-03

  • 加入@RequestBody
    Snipaste_2023-05-29_17-33-19
    Snipaste_2023-05-29_17-33-32

Snipaste_2023-05-29_17-27-51

Knife4j Version (please complete the following information):
springboot version: 2.7.11
knife4j-openapi3-spring-boot-starter version: 4.1.0

@storyxc storyxc closed this as completed Jun 6, 2023
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