Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetUser ¶
GetUser @Summary 获取用户资料 @Description 获取一个用户公开的详细资料 @Tags 用户模块 @Accept json @Produce json @Param x-token header string false "token" @Param id path int true "用户ID" @Success 200 {object} response.GetUserA "是否成功,返回信息,用户名" @Router /users/{id} [get]
func Login ¶
Login @Summary 用户登录 @Description 根据用户邮箱和密码等生成token,并将token返回给用户 @Tags 登录模块 @Accept json @Produce json @Param data body response.LoginQ true "用户名,密码" @Success 200 {object} response.LoginA "是否成功,返回信息,Token" @Router /login [post]
func Register ¶
Register @Summary 注册 @Description 注册新用户 @Tags 登录模块 @Accept json @Produce json @Param data body response.RegisterQ true "用户名,密码" @Success 200 {object} response.CommonA "是否成功,返回信息,Token" @Router /register [post]
func UploadFile ¶
UploadFile @Summary 上传文件 @Description 上传一个文件测试 @Tags 其他模块 @Accept multipart/form-data @Produce json @Param file formData file true "文件" @Param name formData string true "name" @Success 200 {object} response.UploadFileA "是否成功,返回信息" @Router /resource/upload [post]
Types ¶
This section is empty.