Skip to content

Commit

Permalink
fix(swagger): update is mandatory to true (chaos-mesh#3743)
Browse files Browse the repository at this point in the history
* fix(swagger): update `is mandatory` to true

Signed-off-by: Yue Yang <[email protected]>

* chore: update changelog

Signed-off-by: Yue Yang <[email protected]>

Signed-off-by: Yue Yang <[email protected]>
  • Loading branch information
g1eny0ung authored Nov 3, 2022
1 parent ce876cf commit 8b13f5a
Show file tree
Hide file tree
Showing 5 changed files with 21 additions and 17 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ For more information and how-to, see [RFC: Keep A Changelog](https://github.com/
- Fix typo in controller error message [#3704](https://github.com/chaos-mesh/chaos-mesh/pull/3704)
- Fix panic when logging, log kvs as pair [#3716](https://github.com/chaos-mesh/chaos-mesh/pull/3716)
- Fix timechaos not injected into the child process [#3725](https://github.com/chaos-mesh/chaos-mesh/pull/3725)
- Update `is mandatory` to true in a swagger comment [#3743](https://github.com/chaos-mesh/chaos-mesh/pull/3743)

### Security

Expand Down
2 changes: 1 addition & 1 deletion pkg/dashboard/apiserver/event/event.go
Original file line number Diff line number Diff line change
Expand Up @@ -120,8 +120,8 @@ func (s *Service) list(c *gin.Context) {
// @Description list all events for Workflow and related WorkflowNode.
// @Tags events
// @Produce json
// @Param uid path string true "The UID of the Workflow"
// @Param namespace query string false "The namespace of the object"
// @Param uid path string false "The UID of the Workflow"
// @Param limit query number false "The max length of events list"
// @Success 200 {array} core.Event
// @Failure 500 {object} u.APIError
Expand Down
13 changes: 7 additions & 6 deletions pkg/dashboard/swaggerdocs/docs.go
Original file line number Diff line number Diff line change
Expand Up @@ -944,15 +944,16 @@ const docTemplate = `{
"parameters": [
{
"type": "string",
"description": "The namespace of the object",
"name": "namespace",
"in": "query"
"description": "The UID of the Workflow",
"name": "uid",
"in": "path",
"required": true
},
{
"type": "string",
"description": "The UID of the Workflow",
"name": "uid",
"in": "path"
"description": "The namespace of the object",
"name": "namespace",
"in": "query"
},
{
"type": "number",
Expand Down
13 changes: 7 additions & 6 deletions pkg/dashboard/swaggerdocs/swagger.json
Original file line number Diff line number Diff line change
Expand Up @@ -936,15 +936,16 @@
"parameters": [
{
"type": "string",
"description": "The namespace of the object",
"name": "namespace",
"in": "query"
"description": "The UID of the Workflow",
"name": "uid",
"in": "path",
"required": true
},
{
"type": "string",
"description": "The UID of the Workflow",
"name": "uid",
"in": "path"
"description": "The namespace of the object",
"name": "namespace",
"in": "query"
},
{
"type": "number",
Expand Down
9 changes: 5 additions & 4 deletions pkg/dashboard/swaggerdocs/swagger.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6952,13 +6952,14 @@ paths:
get:
description: list all events for Workflow and related WorkflowNode.
parameters:
- description: The namespace of the object
in: query
name: namespace
type: string
- description: The UID of the Workflow
in: path
name: uid
required: true
type: string
- description: The namespace of the object
in: query
name: namespace
type: string
- description: The max length of events list
in: query
Expand Down

0 comments on commit 8b13f5a

Please sign in to comment.