Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Account ¶
type Account struct {
ID uint64 `gorm:"->;column:id;primaryKey;type:INT;autoIncrement" json:"id"`
Name string `gorm:";column:name;type:VARCHAR(100);not null;comment:名字" json:"name"`
PublicKey string `gorm:";column:publicKey;type:VARCHAR(100);not null;comment:用户公钥base64格式" json:"publicKey"`
CreatedAt time.Time `gorm:"->;column:createdAt;not null;type:DATETIME(6);default:CURRENT_TIMESTAMP(6)" json:"-"`
UpdatedAt time.Time `gorm:"->;column:updatedAt;not null;type:DATETIME(6) ON UPDATE CURRENT_TIMESTAMP(6);default:CURRENT_TIMESTAMP(6)" json:"-"`
DeletedAt *time.Time `gorm:"->;column:deletedAt;type:DATETIME(6);default:NULL" json:"-"`
}
type Data ¶
type Data struct {
ID int64 `gorm:"->;column:id;primaryKey;type:INT;autoIncrement" json:"id"`
AccountId int64 `gorm:"column:accountId;type:INT" json:"accountId"`
Name string `gorm:"column:name;type:VARCHAR(100);not null" json:"name"`
Data string `gorm:"column:data;type:TEXT(65535)" json:"data"`
CreatedAt time.Time `gorm:"->;column:createdAt;not null;type:DATETIME(6);default:CURRENT_TIMESTAMP(6)" json:"createdAt"`
UpdatedAt time.Time `gorm:"->;column:updatedAt;not null;type:DATETIME(6) ON UPDATE CURRENT_TIMESTAMP(6);default:CURRENT_TIMESTAMP(6)" json:"-"`
DeletedAt *time.Time `gorm:"column:deletedAt;type:DATETIME(6);default:NULL" json:"-"`
}
Source Files
¶
- account.go
- data.go
Click to show internal directories.
Click to hide internal directories.