Documentation ¶
Index ¶
- Variables
- func NewAuthRepo(data *Data, logger log.Logger) biz.AuthRepo
- func NewDB(conf *conf.Data) *gorm.DB
- func NewPartnerRepo(data *Data, logger log.Logger) biz.PartnerRepo
- func NewRecovery(d *Data) biz.Recovery
- func NewRedSync(conf *conf.Data) *redsync.Mutex
- func NewRedis(conf *conf.Data) redis.Cmdable
- func NewSession(data *conf.Data, constant *conf.UserConstant) *redistore.RediStore
- func NewTransaction(d *Data) biz.Transaction
- func NewUserRepo(data *Data, logger log.Logger) biz.UserRepo
- type Data
- func (d *Data) DB(ctx context.Context) *gorm.DB
- func (d *Data) ExecTx(ctx context.Context, fn func(ctx context.Context) error) error
- func (d *Data) GroupRecover(ctx context.Context, fn func(ctx context.Context) error) func() error
- func (d *Data) Recover(ctx context.Context, fn func(ctx context.Context)) func()
- type Team
- type User
- type UserTeam
Constants ¶
This section is empty.
Variables ¶
View Source
var ProviderSet = wire.NewSet(NewData, NewDB, NewTransaction, NewRedis, NewRecovery, NewUserRepo, NewAuthRepo, NewPartnerRepo, NewSession, NewRedSync)
Functions ¶
func NewPartnerRepo ¶
func NewPartnerRepo(data *Data, logger log.Logger) biz.PartnerRepo
func NewRecovery ¶
func NewSession ¶
func NewSession(data *conf.Data, constant *conf.UserConstant) *redistore.RediStore
NewSession 初始化session
func NewTransaction ¶
func NewTransaction(d *Data) biz.Transaction
Types ¶
type Data ¶
type Data struct {
// contains filtered or unexported fields
}
func (*Data) GroupRecover ¶
type Team ¶
type Team struct { Id int32 Name string Description string MaxNum int32 `gorm:"column:maxNum"` ExpireTime time.Time `gorm:"column:expireTime"` UserId int32 `gorm:"column:userId"` Status int32 Password string CreateTime time.Time `gorm:"column:createTime"` UpdateTime time.Time `gorm:"column :updateTime"` IsDelete int32 `gorm:"column:isDelete"` }
type User ¶
type User struct { Id int32 UserName string `gorm:"column:username"` UserAccount string `gorm:"column:userAccount"` AvatarUrl string `gorm:"column:avatarUrl"` Gender int32 UserPassword string `gorm:"column:userPassword"` Phone string Email string UserStatus int32 `gorm:"column:userStatus"` CreateTime time.Time `gorm:"column:createTime"` UpdateTime time.Time `gorm:"column:updateTime"` IsDelete int32 `gorm:"column:isDelete"` Role int32 Tags string Profile string }
func (User) MarshalEasyJSON ¶
MarshalEasyJSON supports easyjson.Marshaler interface
func (User) MarshalJSON ¶
MarshalJSON supports json.Marshaler interface
func (*User) UnmarshalEasyJSON ¶
UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (*User) UnmarshalJSON ¶
UnmarshalJSON supports json.Unmarshaler interface
Click to show internal directories.
Click to hide internal directories.