@@ -0,0 +1,17 @@
|
||||
package sub
|
||||
|
||||
import (
|
||||
"time"
|
||||
)
|
||||
|
||||
// CodeBuySub représente un code de souscription associé à un utilisateur.
|
||||
type CodeBuySub struct {
|
||||
ID string `gorm:"type:uuid;primaryKey" json:"id"`
|
||||
Username string `gorm:"size:64;not null" json:"username"`
|
||||
CodeBuy string `gorm:"uniqueIndex;type:varchar(50);not null" json:"code_verif"`
|
||||
CreatedAt time.Time `gorm:"index;autoCreateTime" json:"created_at"`
|
||||
UpdatedAt time.Time `gorm:"autoUpdateTime" json:"updated_at"`
|
||||
}
|
||||
|
||||
// TableName définit explicitement le nom de la table.
|
||||
func (CodeBuySub) TableName() string { return "code_buy_subs" }
|
||||
Reference in New Issue
Block a user