vegapokerbot/internal/db/model/user.go

12 lines
267 B
Go
Raw Normal View History

2024-05-07 21:49:09 +03:00
package model
type User struct {
ID uint64 `gorm:"primary_key;auto_increment" json:"id"`
TelegramID uint64 `gorm:"not null" json:"telegram_id"`
Chats []Chat `gorm:"foreignKey:UserID" json:"chats"`
}
func (User) TableName() string {
return "user"
}