mirror of
https://gitee.com/BTAJL/repchain.git
synced 2024-12-02 11:48:10 +08:00
swagger-ui的postTran接口补充可接受application/json的数据格式
This commit is contained in:
parent
00542995eb
commit
da76a41f08
@ -538,8 +538,9 @@ class TransactionService(ra: RestRouter)(implicit executionContext: ExecutionCon
|
|||||||
@POST
|
@POST
|
||||||
@Path("/postTran")
|
@Path("/postTran")
|
||||||
@Operation(tags = Array("transaction"), summary = "提交交易", description = "postTransaction", method = "POST",
|
@Operation(tags = Array("transaction"), summary = "提交交易", description = "postTransaction", method = "POST",
|
||||||
requestBody = new RequestBody(description = "描述交易的xml", required = true,
|
requestBody = new RequestBody(description = "描述交易的xml/json", required = true,
|
||||||
content = Array(new Content(mediaType = MediaType.APPLICATION_XML, schema = new Schema(implementation = classOf[CSpec], description = "描述交易的xml")))))
|
content = Array(new Content(mediaType = MediaType.APPLICATION_XML, schema = new Schema(implementation = classOf[CSpec], description = "描述交易的xml")),
|
||||||
|
new Content(mediaType = MediaType.APPLICATION_JSON, schema = new Schema(implementation = classOf[CSpec], description = "描述交易的json")))))
|
||||||
// @Parameters(Array(
|
// @Parameters(Array(
|
||||||
// new Parameter(name = "body", value = "交易内容", required = true,
|
// new Parameter(name = "body", value = "交易内容", required = true,
|
||||||
// dataTypeClass = classOf[CSpec], paramType = "body")))
|
// dataTypeClass = classOf[CSpec], paramType = "body")))
|
||||||
|
Loading…
Reference in New Issue
Block a user