52 lines
1.8 KiB
Go
52 lines
1.8 KiB
Go
package request
|
|
|
|
import "git.echol.cn/loser/lckt/model/common/request"
|
|
|
|
type SendCodeReq struct {
|
|
Phone string `json:"phone" vd:"@:len($)>0; msg:'手机号码不能为空'"`
|
|
}
|
|
|
|
type CodeLoginReq struct {
|
|
Phone string `json:"phone" vd:"@:len($)>0; msg:'请输入手机号码'"`
|
|
Code string `json:"code" vd:"@:len($)>0; msg:'请输入短信验证码'"`
|
|
}
|
|
|
|
type InviteLoginReq struct {
|
|
Phone string `json:"phone" vd:"@:len($)>0; msg:'手机号码不能为空'"`
|
|
Code string `json:"code" vd:"@:len($)>0; msg:'验证码不能为空'"`
|
|
Type string `json:"type" vd:"@:len($)>0; msg:'邀请类型不能为空'"`
|
|
Token string `json:"token" vd:"@:len($)>0; msg:'token不能为空'"`
|
|
}
|
|
|
|
type WxLoginReq struct {
|
|
OpenId string `json:"openId" binding:"required"`
|
|
NickName string `json:"nickName"`
|
|
Gender int `json:"gender"`
|
|
UnionId string `json:"unionId" binding:"required"`
|
|
AvatarUrl string `json:"avatarUrl"`
|
|
Province string `json:"province"`
|
|
City string `json:"city"`
|
|
}
|
|
|
|
type BindWechatReq struct {
|
|
Id int `json:"id" vd:"@:len($)>0; msg:'id不能为空'"`
|
|
Openid string `json:"openid" vd:"@:len($)>0; msg:'OpenId不能为空'"`
|
|
UnionId string `json:"unionId" gorm:"type:varchar(64);comment:用户统一标识。针对一个微信开放平台帐号下的应用,同一用户的 unionid 是唯一的。"`
|
|
}
|
|
|
|
type BindPhoneReq struct {
|
|
Id int `json:"id" vd:"@:len($)>0; msg:'用户ID不能为空'"`
|
|
Phone string `json:"phone" vd:"@:len($)>0; msg:'手机号码不能为空'"`
|
|
}
|
|
|
|
type GetUserListReq struct {
|
|
request.PageInfo
|
|
Type int `json:"type"`
|
|
UserLabel string `json:"user_label" `
|
|
}
|
|
|
|
type SetBalanceReq struct {
|
|
Id int `json:"id" vd:"@:len($)>0; msg:'用户ID不能为空'"`
|
|
Balance float32 `json:"balance" vd:"@:len($)>0; msg:'余额不能为空'"`
|
|
}
|