[Kotlin-Spring] fix arrays response api after generation (#16296)

* issues/16295 fix arrays response api after generation

* fix samples

* fix samples

---------

Co-authored-by: Lezenford <alex.v.plekhanov@gmail.com>
This commit is contained in:
Lezenford
2023-08-23 06:52:15 +04:00
committed by GitHub
parent 00de163655
commit 3e95001939
7 changed files with 12 additions and 12 deletions

View File

@@ -72,7 +72,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) {
operationId = "findPetsByStatus",
description = """Multiple status values can be provided with comma separated strings""",
responses = [
ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Pet::class))]),
ApiResponse(responseCode = "200", description = "successful operation", content = [Content(array = ArraySchema(schema = Schema(implementation = Pet::class)))]),
ApiResponse(responseCode = "400", description = "Invalid status value") ],
security = [ SecurityRequirement(name = "petstore_auth", scopes = [ "write:pets", "read:pets" ]) ]
)
@@ -90,7 +90,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) {
operationId = "findPetsByTags",
description = """Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.""",
responses = [
ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Pet::class))]),
ApiResponse(responseCode = "200", description = "successful operation", content = [Content(array = ArraySchema(schema = Schema(implementation = Pet::class)))]),
ApiResponse(responseCode = "400", description = "Invalid tag value") ],
security = [ SecurityRequirement(name = "petstore_auth", scopes = [ "write:pets", "read:pets" ]) ]
)