Commit ac2eb0d4 authored by duanledexianxianxian's avatar duanledexianxianxian 😁

生成markdown api文档

parent 14f303d4
...@@ -2,15 +2,16 @@ package com.kim.apidoc.example.spring.advanced; ...@@ -2,15 +2,16 @@ package com.kim.apidoc.example.spring.advanced;
import com.kim.apidoc.example.annotation.KimController; import com.kim.apidoc.example.annotation.KimController;
import com.kim.apidoc.example.common.Query; import com.kim.apidoc.example.common.Query;
import com.kim.apidoc.example.common.ResultData;
import com.kim.apidoc.example.common.User; import com.kim.apidoc.example.common.User;
import com.kim.apidoc.example.common.ResultData;
import com.kim.apidoc.example.common.ResultData;
import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMapping;
/** /**
* kim接口 * The type Kim user controller.
* *
* @author duanledexianxianxian * @author duanledexianxianxian
* @version 1.0.0 * @version 1.0.0
...@@ -22,26 +23,25 @@ import org.springframework.web.bind.annotation.RequestMapping; ...@@ -22,26 +23,25 @@ import org.springframework.web.bind.annotation.RequestMapping;
@RequestMapping("/api/v1") @RequestMapping("/api/v1")
public class KimUserController { public class KimUserController {
/** /**
* 用户详情信息 * Detail user.
* 主动根据id获取用户的信息
* *
* @param id the id * @param id the id
* @param query the query * @param query the query
* @return result data * @return 用户对象 user
*/ */
@GetMapping(value = "/{id}") @GetMapping(value = "/{id}")
public ResultData<User> detail(@PathVariable String id, Query query) { public User detail(@PathVariable String id, Query query) {
User user = new User(); User user = new User();
return ResultData.ok(user); return user;
} }
/** /**
* Add integer. * Add integer.
* *
* @return the integer * @return integer integer
* @return
*/ */
@PostMapping @PostMapping
public Integer add() { public Integer add() {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment