update ApiImplicitParam paramType field for swagger
This commit is contained in:
@@ -36,7 +36,7 @@ public class UserController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@ApiOperation(value="获取用户详细信息", notes="根据url的id来获取用户详细信息")
|
@ApiOperation(value="获取用户详细信息", notes="根据url的id来获取用户详细信息")
|
||||||
@ApiImplicitParam(name = "id", value = "用户ID", required = true, dataType = "Long")
|
@ApiImplicitParam(name = "id", value = "用户ID", required = true, dataType = "Long", paramType = "path")
|
||||||
@RequestMapping(value="/{id}", method=RequestMethod.GET)
|
@RequestMapping(value="/{id}", method=RequestMethod.GET)
|
||||||
public User getUser(@PathVariable Long id) {
|
public User getUser(@PathVariable Long id) {
|
||||||
return users.get(id);
|
return users.get(id);
|
||||||
@@ -44,7 +44,7 @@ public class UserController {
|
|||||||
|
|
||||||
@ApiOperation(value="更新用户详细信息", notes="根据url的id来指定更新对象,并根据传过来的user信息来更新用户详细信息")
|
@ApiOperation(value="更新用户详细信息", notes="根据url的id来指定更新对象,并根据传过来的user信息来更新用户详细信息")
|
||||||
@ApiImplicitParams({
|
@ApiImplicitParams({
|
||||||
@ApiImplicitParam(name = "id", value = "用户ID", required = true, dataType = "Long"),
|
@ApiImplicitParam(name = "id", value = "用户ID", required = true, dataType = "Long", paramType = "path"),
|
||||||
@ApiImplicitParam(name = "user", value = "用户详细实体user", required = true, dataType = "User")
|
@ApiImplicitParam(name = "user", value = "用户详细实体user", required = true, dataType = "User")
|
||||||
})
|
})
|
||||||
@RequestMapping(value="/{id}", method=RequestMethod.PUT)
|
@RequestMapping(value="/{id}", method=RequestMethod.PUT)
|
||||||
@@ -57,7 +57,7 @@ public class UserController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@ApiOperation(value="删除用户", notes="根据url的id来指定删除对象")
|
@ApiOperation(value="删除用户", notes="根据url的id来指定删除对象")
|
||||||
@ApiImplicitParam(name = "id", value = "用户ID", required = true, dataType = "Long")
|
@ApiImplicitParam(name = "id", value = "用户ID", required = true, dataType = "Long", paramType = "path")
|
||||||
@RequestMapping(value="/{id}", method=RequestMethod.DELETE)
|
@RequestMapping(value="/{id}", method=RequestMethod.DELETE)
|
||||||
public String deleteUser(@PathVariable Long id) {
|
public String deleteUser(@PathVariable Long id) {
|
||||||
users.remove(id);
|
users.remove(id);
|
||||||
|
|||||||
Reference in New Issue
Block a user