mirror of
https://github.com/3ybactuk/marketplace-go-service-project.git
synced 2025-10-30 14:03:45 +03:00
[hw-8] add: comment service
This commit is contained in:
@@ -27,7 +27,7 @@
|
||||
"paths": {
|
||||
"/comment/add": {
|
||||
"post": {
|
||||
"operationId": "Comments_Add",
|
||||
"operationId": "Comments_CommentAdd",
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "A successful response.",
|
||||
@@ -59,12 +59,13 @@
|
||||
},
|
||||
"/comment/edit": {
|
||||
"post": {
|
||||
"operationId": "Comments_Edit",
|
||||
"operationId": "Comments_CommentEdit",
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "A successful response.",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/UpdateCommentResponse"
|
||||
"type": "object",
|
||||
"properties": {}
|
||||
}
|
||||
},
|
||||
"default": {
|
||||
@@ -80,7 +81,7 @@
|
||||
"in": "body",
|
||||
"required": true,
|
||||
"schema": {
|
||||
"$ref": "#/definitions/UpdateCommentRequest"
|
||||
"$ref": "#/definitions/EditCommentRequest"
|
||||
}
|
||||
}
|
||||
],
|
||||
@@ -91,7 +92,7 @@
|
||||
},
|
||||
"/comment/get-by-id": {
|
||||
"post": {
|
||||
"operationId": "Comments_GetById",
|
||||
"operationId": "Comments_CommentGetByID",
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "A successful response.",
|
||||
@@ -123,7 +124,7 @@
|
||||
},
|
||||
"/comment/list-by-sku": {
|
||||
"post": {
|
||||
"operationId": "Comments_ListBySku",
|
||||
"operationId": "Comments_CommentListBySKU",
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "A successful response.",
|
||||
@@ -155,7 +156,7 @@
|
||||
},
|
||||
"/comment/list-by-user": {
|
||||
"post": {
|
||||
"operationId": "Comments_ListByUser",
|
||||
"operationId": "Comments_CommentListByUser",
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "A successful response.",
|
||||
@@ -207,7 +208,7 @@
|
||||
},
|
||||
"createdAt": {
|
||||
"type": "string",
|
||||
"title": "RFC3339 with ms"
|
||||
"format": "date-time"
|
||||
}
|
||||
}
|
||||
},
|
||||
@@ -222,7 +223,7 @@
|
||||
"type": "string",
|
||||
"format": "int64"
|
||||
},
|
||||
"text": {
|
||||
"comment": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
@@ -230,8 +231,25 @@
|
||||
"CreateCommentResponse": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"comment": {
|
||||
"$ref": "#/definitions/Comment"
|
||||
"id": {
|
||||
"type": "string",
|
||||
"format": "int64"
|
||||
}
|
||||
}
|
||||
},
|
||||
"EditCommentRequest": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"userId": {
|
||||
"type": "string",
|
||||
"format": "int64"
|
||||
},
|
||||
"commentId": {
|
||||
"type": "string",
|
||||
"format": "int64"
|
||||
},
|
||||
"newComment": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
},
|
||||
@@ -294,30 +312,6 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"UpdateCommentRequest": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"id": {
|
||||
"type": "string",
|
||||
"format": "int64"
|
||||
},
|
||||
"userId": {
|
||||
"type": "string",
|
||||
"format": "int64"
|
||||
},
|
||||
"text": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
},
|
||||
"UpdateCommentResponse": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"comment": {
|
||||
"$ref": "#/definitions/Comment"
|
||||
}
|
||||
}
|
||||
},
|
||||
"protobufAny": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
|
||||
Reference in New Issue
Block a user