package v1

import (
	"github.com/gogf/gf/v2/frame/g"
)

type InfoReq struct {
	g.Meta `path:"/user/info" tags:"APP/User" method:"get" summary:"获取用户信息"`
}
type InfoRes struct {
	g.Meta         `mime:"application/json"`
	Id             int64  `json:"id" dc:"用户ID"`
	Username       string `json:"username" dc:"用户名"`
	Avatar         string `json:"avatar" dc:"头像URL"`
	Email          string `json:"email" dc:"邮箱"`
	Points         uint64 `json:"points" dc:"积分数量"`
	BackgroundUrl  string `json:"backgroundUrl" dc:"背景图片URL"`
	AttentionCount int    `json:"attentionCount" dc:"关注数量"`
	Role           string `json:"role" dc:"用户角色"`
	IsAuthor       bool   `json:"isAuthor" dc:"是否是作者"`
	AuthorStatus   int    `json:"authorStatus" dc:"作者申请状态：0=未申请，1=审核中，2=已通过，3=已拒绝"`
}

type DeleteReq struct {
	g.Meta   `path:"/user/delete" tags:"APP/User" method:"post" summary:"删除用户"`
	Password string `json:"password" v:"required" dc:"密码"`
}

type DeleteRes struct {
	Success bool `json:"success" dc:"是否成功"`
}

type LogoutReq struct {
	g.Meta `path:"/user/logout" tags:"APP/User" method:"post" summary:"登出"`
}
type LogoutRes struct {
	Success bool `json:"success" dc:"是否成功"`
}
