models

package
v1.16.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 30, 2022 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Model

type Model struct {
	CreatedAt int64 `json:"created_at"`
	UpdatedAt int64 `json:"updated_at"`
}

type User

type User struct {
	Model
	UID          string `json:"uid"`
	Name         string `json:"name"`
	IdentityType string `gorm:"default:'unknown'" json:"identity_type"`
	Email        string `json:"email"`
	Phone        string `json:"phone"`
	Account      string `json:"account"`
	APIToken     string `gorm:"api_token" json:"api_token"`
}

func (User) TableName

func (User) TableName() string

TableName sets the insert table name for this struct type

type UserLogin

type UserLogin struct {
	Model
	UID           string `json:"uid"`
	Password      string `json:"password"`
	LastLoginTime int64  `json:"last_login_time"`
	LoginId       string `json:"login_id"`
	LoginType     int    `json:"login_type"`
}

func (UserLogin) TableName

func (UserLogin) TableName() string

TableName sets the insert table name for this struct type

type UserSetting added in v1.9.9

type UserSetting struct {
	ID           primitive.ObjectID `bson:"_id,omitempty"      json:"id,omitempty"`
	UID          string             `bson:"uid"                json:"uid"`
	Theme        string             `bson:"theme"              json:"theme"`
	LogBgColor   string             `bson:"log_bg_color"       json:"log_bg_color"`
	LogFontColor string             `bson:"log_font_color"     json:"log_font_color"`
}

func (UserSetting) TableName added in v1.9.9

func (UserSetting) TableName() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL