When using both ‘@RequestParam’ and ‘@ApiImplicitParam’ at the same time, it will generate duplicate parameters in swagger.json
zhangying930920 opened this issue · 1 comments
for instance:
@ApiImplicitParams({
@ApiImplicitParam(name = "appId", value = " appId ", dataType = "String", paramType = "query", required = true),
@ApiImplicitParam(name = "deptId", value = " deptId ", dataType = "String", paramType = "query", required = true)
})
@responsebody
public Response getLocalApplication(@RequestParam(value = "appId") String appId,
@RequestParam(value = "deptId", required = false) String deptId)
swagger.json:
"parameters" : [ {
"name" : "appId",
"in" : "query",
"required" : true,
"type" : "string"
}, {
"name" : "deptId",
"in" : "query",
"required" : false,
"type" : "string"
}, {
"name" : "appId",
"in" : "query",
"description" : " appId ",
"required" : true,
"type" : "String"
}, {
"name" : "deptId",
"in" : "query",
"description" : " deptId ",
"required" : true,
"type" : "String"
} ],