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

[BUG]In the open-api.json file of swagger (OpenApi), the "summary" tag in the specification routing definition is generated as a method #2841

Closed
alaywn opened this issue Aug 4, 2023 · 2 comments
Labels
bug It is confirmed a bug, but don't worry, we'll handle it. done This issue is done, which may be release in next version.

Comments

@alaywn
Copy link
Contributor

alaywn commented Aug 4, 2023

1. What version of Go and system type/arch are you using?

go version go1.20.6 darwin/arm64

2. What version of GoFrame are you using?

GoFrame CLI Tool v2.5.1, https://goframe.org
GoFrame Version: v2.5.1 in current go.mod
CLI Installed At: /opt/homebrew/bin/gf
CLI Built Detail:
Go Version: go1.20.4
GF Version: v2.5.1
Git Commit: 2023-07-26 21:27:58 e0e0043
Build Time: 2023-07-26 21:32:56

3. Can this issue be re-produced with the latest release?

YES

4. What did you do?

例如:当规范路由的 CreateReq 结构体定义中带有summary标签,并且有值的时候:

type CreateReq struct {
g.Meta path:"/User/Create" method:"post" summary:"some value" tags:"User"
Master string json:"master"
}

生成的open-api.json文件如下:

{
"paths": {
"/User/Create": {
"post": {.....},
"summary": "some value" //---这个不应该出现,这是错误的。如果去掉summary标签,或者将summary标签的内容设置为"",则没问题
}
}
}

5. What did you expect to see?

6. What did you see instead?

@Issues-translate-bot Issues-translate-bot changed the title [BUG]swagger(OpenApi)的open-api.json文件中,将规范路由定义中的"summary"标签生成了方法 [BUG]In the open-api.json file of swagger (OpenApi), the "summary" tag in the specification routing definition is generated as a method Aug 4, 2023
@WankkoRee
Copy link
Contributor

已经在 #2823 中修复。

@Issues-translate-bot
Copy link

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


Fixed in #2823.

@hailaz hailaz added bug It is confirmed a bug, but don't worry, we'll handle it. done This issue is done, which may be release in next version. labels Aug 10, 2023
@hailaz hailaz closed this as completed Aug 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug It is confirmed a bug, but don't worry, we'll handle it. done This issue is done, which may be release in next version.
Projects
None yet
Development

No branches or pull requests

4 participants