25 lines
1.3 KiB
Go
25 lines
1.3 KiB
Go
package models
|
|
|
|
import "time"
|
|
|
|
// SsqHistory 双色球历史开奖数据
|
|
type SsqHistory struct {
|
|
ID int `gorm:"primaryKey;column:id" json:"id"`
|
|
IssueNumber string `gorm:"type:varchar(20);not null;index;column:issue_number" json:"issue_number"`
|
|
OpenDate *time.Time `gorm:"type:date;column:open_date" json:"open_date"`
|
|
RedBall1 int `gorm:"type:tinyint;not null;column:red_ball_1" json:"red_ball_1"`
|
|
RedBall2 int `gorm:"type:tinyint;not null;column:red_ball_2" json:"red_ball_2"`
|
|
RedBall3 int `gorm:"type:tinyint;not null;column:red_ball_3" json:"red_ball_3"`
|
|
RedBall4 int `gorm:"type:tinyint;not null;column:red_ball_4" json:"red_ball_4"`
|
|
RedBall5 int `gorm:"type:tinyint;not null;column:red_ball_5" json:"red_ball_5"`
|
|
RedBall6 int `gorm:"type:tinyint;not null;column:red_ball_6" json:"red_ball_6"`
|
|
BlueBall int `gorm:"type:tinyint;not null;column:blue_ball" json:"blue_ball"`
|
|
CreatedAt time.Time `gorm:"autoCreateTime:false;column:created_at" json:"created_at"` // 创建时间(由程序设置)
|
|
UpdatedAt time.Time `gorm:"autoUpdateTime:false;column:updated_at" json:"updated_at"` // 更新时间(由程序设置)
|
|
}
|
|
|
|
// TableName 指定表名
|
|
func (SsqHistory) TableName() string {
|
|
return "ssq_history"
|
|
}
|