Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ProviderSet = wire.NewSet(NewData, NewGreeterRepo, mysqlRepo.NewUserRepo)
ProviderSet is data providers.
Functions ¶
func NewGreeterRepo ¶
func NewGreeterRepo(data *Data, logger log.Logger) biz.GreeterRepo
NewGreeterRepo .
Types ¶
type User ¶
type User struct { // Standard object's metadata metadata.ObjectMeta `json:"metadata,omitempty"` Status int `json:"ID" ` // Required: true Nickname string `json:"nickname" gorm:"column:nickname" validate:"required,min=1,max=30"` // Required: true Password string `json:"password,omitempty" gorm:"column:password" validate:"required"` // Required: true Email string `json:"email" gorm:"column:email" validate:"required,email,min=1,max=100"` Phone string `json:"phone" gorm:"column:phone" validate:"omitempty"` IsAdmin int `json:"isAdmin,omitempty" gorm:"column:isAdmin" validate:"omitempty"` TotalPolicy int64 `json:"totalPolicy" gorm:"-" validate:"omitempty"` LoginedAt time.Time `json:"loginedAt,omitempty" gorm:"column:loginedAt"` }
User is a user model. It is also used as gorm model.
Click to show internal directories.
Click to hide internal directories.