Skip to content

A Q&A platform software for teams at any scales. Whether it's a community forum, help center, or knowledge management platform, you can always count on Apache Answer.

fix: swagger wrong request parameter

LinkinStarb2256a5d1b1d
diff --git a/docs/docs.go b/docs/docs.go
index 16ac77ca..1b81becf 100644
--- a/docs/docs.go
+++ b/docs/docs.go
@@ -588,17 +588,6 @@ const docTemplate = `{
"admin"
],
"summary": "get site interface",
- "parameters": [
- {
- "description": "general",
- "name": "data",
- "in": "body",
- "required": true,
- "schema": {
- "$ref": "#/definitions/schema.AddCommentReq"
- }
- }
- ],
"responses": {
"200": {
"description": "OK",
diff --git a/docs/swagger.json b/docs/swagger.json
index 8476352c..425eb948 100644
--- a/docs/swagger.json
+++ b/docs/swagger.json
@@ -576,17 +576,6 @@
"admin"
],
"summary": "get site interface",
- "parameters": [
- {
- "description": "general",
- "name": "data",
- "in": "body",
- "required": true,
- "schema": {
- "$ref": "#/definitions/schema.AddCommentReq"
- }
- }
- ],
"responses": {
"200": {
"description": "OK",
diff --git a/docs/swagger.yaml b/docs/swagger.yaml
index 81c96d96..c8db90c2 100644
--- a/docs/swagger.yaml
+++ b/docs/swagger.yaml
@@ -1725,13 +1725,6 @@ paths:
/answer/admin/api/siteinfo/interface:
get:
description: get site interface
- parameters:
- - description: general
- in: body
- name: data
- required: true
- schema:
- $ref: '#/definitions/schema.AddCommentReq'
produces:
- application/json
responses:
diff --git a/internal/controller_backyard/siteinfo_controller.go b/internal/controller_backyard/siteinfo_controller.go
index 821b517e..339765aa 100644
--- a/internal/controller_backyard/siteinfo_controller.go
+++ b/internal/controller_backyard/siteinfo_controller.go
@@ -39,7 +39,6 @@ func (sc *SiteInfoController) GetGeneral(ctx *gin.Context) {
// @Produce json
// @Success 200 {object} handler.RespBody{data=schema.SiteInterfaceResp}
// @Router /answer/admin/api/siteinfo/interface [get]
-// @Param data body schema.AddCommentReq true "general"
func (sc *SiteInfoController) GetInterface(ctx *gin.Context) {
resp, err := sc.siteInfoService.GetSiteInterface(ctx)
handler.HandleResponse(ctx, err, resp)