package com.itheima.controller;

import com.itheima.domain.UserInfo;
import com.itheima.util.Result;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/*****
 * @Author: http://www.itheima.com
 * @Description: com.itheima.controller.RestUserController
 ****/
@RestController
@RequestMapping(value = "/api")
public class RestUserController {

    @GetMapping(value = "/userinfo/one")
    public Result<UserInfo> one(){
        UserInfo userInfo = new UserInfo("王五",
                "man",
                "wangwu",
                1,
                25);
        return new Result<UserInfo>(200,"查询成功！",userInfo);
    }
}
