-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
2f27385
commit a949160
Showing
5 changed files
with
71 additions
and
38 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,11 +2,22 @@ package hermes_forms | |
|
||
type SendMailFormRequest struct { | ||
// required: true | ||
// type: string | ||
Code string `json:"code" binding:"required"` | ||
// required: true | ||
Recipients []string `json:"recipients" binding:"required"` | ||
PlaceHolder map[string]string `json:"placeholder" binding:"required"` | ||
Subject string `json:"subject"` | ||
// type: array | ||
// items: | ||
// type: string | ||
// example: ["[email protected]", "[email protected]"] | ||
Recipients []string `json:"recipients" binding:"required"` | ||
// required: false | ||
// type: object | ||
Placeholder map[string]string `json:"placeholder" binding:"required"` | ||
// required: false | ||
// type: string | ||
// extensions: | ||
// x-note: All key must be capital the first character | ||
Subject string `json:"subject"` | ||
} | ||
|
||
// swagger:parameters SendMail | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
package feedback | ||
|
||
import "TSS-microservices/core/models" | ||
|
||
// swagger:response GetManyResponse | ||
type GetManyResponse struct { | ||
// in: body | ||
Body GetManyResponseBody `json:"body"` | ||
} | ||
|
||
type GetManyResponseBody struct { | ||
Limit int `json:"limit"` | ||
Offset int `json:"offset"` | ||
Data []models.Feedback `json:"data"` | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -64,24 +64,7 @@ | |
], | ||
"responses": { | ||
"200": { | ||
"description": "list of feedback", | ||
"schema": { | ||
"type": "object", | ||
"properties": { | ||
"data": { | ||
"type": "array", | ||
"items": { | ||
"$ref": "#/definitions/FeedbackModel" | ||
} | ||
}, | ||
"limit": { | ||
"type": "integer" | ||
}, | ||
"offset": { | ||
"type": "integer" | ||
} | ||
} | ||
} | ||
"$ref": "#/responses/GetManyResponse" | ||
} | ||
} | ||
}, | ||
|
@@ -417,6 +400,29 @@ | |
"x-go-name": "Feedback", | ||
"x-go-package": "TSS-microservices/core/models" | ||
}, | ||
"GetManyResponseBody": { | ||
"type": "object", | ||
"properties": { | ||
"data": { | ||
"type": "array", | ||
"items": { | ||
"$ref": "#/definitions/FeedbackModel" | ||
}, | ||
"x-go-name": "Data" | ||
}, | ||
"limit": { | ||
"type": "integer", | ||
"format": "int64", | ||
"x-go-name": "Limit" | ||
}, | ||
"offset": { | ||
"type": "integer", | ||
"format": "int64", | ||
"x-go-name": "Offset" | ||
} | ||
}, | ||
"x-go-package": "TSS-microservices/core/http/responses/feedback" | ||
}, | ||
"NullTime": { | ||
"description": "NullTime implements the [Scanner] interface so\nit can be used as a scan destination, similar to [NullString].", | ||
"type": "object", | ||
|
@@ -462,18 +468,23 @@ | |
"additionalProperties": { | ||
"type": "string" | ||
}, | ||
"x-go-name": "PlaceHolder" | ||
"x-go-name": "Placeholder" | ||
}, | ||
"recipients": { | ||
"type": "array", | ||
"items": { | ||
"type": "string" | ||
}, | ||
"x-go-name": "Recipients" | ||
"x-go-name": "Recipients", | ||
"example": [ | ||
"[email protected]", | ||
"[email protected]" | ||
] | ||
}, | ||
"subject": { | ||
"type": "string", | ||
"x-go-name": "Subject" | ||
"x-go-name": "Subject", | ||
"x-note": "All key must be capital the first character" | ||
} | ||
}, | ||
"x-go-package": "TSS-microservices/core/http/requests/hermes-forms" | ||
|
@@ -532,6 +543,12 @@ | |
} | ||
}, | ||
"responses": { | ||
"GetManyResponse": { | ||
"description": "", | ||
"schema": { | ||
"$ref": "#/definitions/GetManyResponseBody" | ||
} | ||
}, | ||
"ValidationError": { | ||
"description": "A ValidationError is an error that is used when the required input fails validation.", | ||
"schema": { | ||
|