Skip to content

Commit

Permalink
Fix block quote indentation in ProductController
Browse files Browse the repository at this point in the history
  • Loading branch information
anotheroneofthese committed Aug 21, 2024
1 parent fd50650 commit 9a3f5c2
Showing 1 changed file with 23 additions and 19 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,23 +20,25 @@ import org.springframework.web.bind.annotation.RestController
class ProductController(val productService: ProductService) {
@Operation(
summary = "Register a product in the storage system",
description = """
Register data about the product in Hermes WLS and appropriate storage system,
so that the physical product can be placed in the physical storage.
NOTE: When registering new product quantity and location are set to default values (0.0 and null).
Hence you should not provide these values in the payload, or at least know they will be overwritten."""
description =
"" +
"Register data about the product in Hermes WLS and appropriate storage system,\n" +
"so that the physical product can be placed in the physical storage.\n" +
"NOTE: When registering new product quantity and location are set to default values (0.0 and null).\n" +
"Hence you should not provide these values in the payload, or at least know they will be overwritten."
)
@ApiResponses(
value = [
ApiResponse(
responseCode = "200",
description = """
Product with given 'hostName' and 'hostId' already exists in the system.
No new product was created, neither was the old product updated.
Existing product information is returned for inspection.
In rare cases the response body may be empty, that can happen if Hermes WLS
does not have the information about the product stored in its database and
is unable to retrieve the existing product information from the storage system.""",
description =
"" +
"Product with given 'hostName' and 'hostId' already exists in the system.\n" +
"No new product was created, neither was the old product updated.\n" +
"Existing product information is returned for inspection.\n" +
"In rare cases the response body may be empty, that can happen if Hermes WLS\n" +
"does not have the information about the product stored in its database and\n" +
"is unable to retrieve the existing product information from the storage system.",
content = [
Content(
mediaType = "application/json",
Expand All @@ -46,10 +48,11 @@ class ProductController(val productService: ProductService) {
),
ApiResponse(
responseCode = "201",
description = """
Product payload is valid and the product information was registered successfully.
Product was created in the appropriate storage system.
New product information is returned for inspection.""",
description =
"" +
"Product payload is valid and the product information was registered successfully.\n" +
"Product was created in the appropriate storage system.\n" +
"New product information is returned for inspection.",
content = [
Content(
mediaType = "application/json",
Expand All @@ -59,9 +62,10 @@ class ProductController(val productService: ProductService) {
),
ApiResponse(
responseCode = "400",
description = """
Product payload is invalid and no new product was created.
Error message contains information about the invalid fields.""",
description =
"" +
"Product payload is invalid and no new product was created.\n" +
"Error message contains information about the invalid fields.",
content = [Content(schema = Schema())]
),
ApiResponse(
Expand Down

0 comments on commit 9a3f5c2

Please sign in to comment.