优化参数绑定

This commit is contained in:
tanghc
2019-07-26 12:20:46 +08:00
parent c40ff46da1
commit a863c00d3f
6 changed files with 108 additions and 33 deletions

View File

@@ -64,6 +64,13 @@ public class AlipayController {
return story;
}
// 忽略验证
@ApiMapping(value = "story.get", version = "2.1", ignoreValidate = true)
public Story getStory21(Story story) {
story.setName(story.getName() + ", story.get2.1, ignoreValidate = true");
return story;
}
// http://localhost:2222/getStory2
// 遗留接口具备开放平台能力
@ApiAbility

View File

@@ -45,7 +45,7 @@ public class TraditionalWebappController {
}
// http://localhost:8081/rest/food/getFoodByObj?id=2
@ApiMapping(value = "ggetFoodByObj", method = RequestMethod.GET)
@ApiMapping(value = "getFoodByObj", method = RequestMethod.GET)
public Food getFoodByObj(Food food) {
return food;
}