Skip to content

Commit

Permalink
api
Browse files Browse the repository at this point in the history
  • Loading branch information
snowxwolf committed Mar 26, 2018
1 parent 934e446 commit 106e396
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/main/java/com/xwolf/boot/config/SwaggerConfig.java
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
@Configuration
@EnableSwagger2
public class SwaggerConfig {

@Bean
public Docket createRestApi() {
return new Docket(DocumentationType.SWAGGER_2)
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/xwolf/boot/controller/ApiController.java
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ public String postUser(@RequestBody User user) {
public User getUser(@PathVariable Integer id) {
return users.get(id);
}

@Override
@PutMapping(value="/{id:\\d+}")
public String putUser(@PathVariable Integer id, @RequestBody User user) {
Expand Down

0 comments on commit 106e396

Please sign in to comment.