13 lines
468 B
Go
13 lines
468 B
Go
|
|
package entity
|
||
|
|
|
||
|
|
import "time"
|
||
|
|
|
||
|
|
type RegistrationOtps struct {
|
||
|
|
ID uint `json:"id" gorm:"primaryKey;type:int4;autoIncrement"`
|
||
|
|
Email string `json:"email" gorm:"type:varchar"`
|
||
|
|
OtpCode string `json:"otp_code" gorm:"type:varchar"`
|
||
|
|
ValidUntil time.Time `json:"valid_until" gorm:"default:(NOW() + INTERVAL '10 minutes')"`
|
||
|
|
IsActive bool `json:"is_active" gorm:"type:bool"`
|
||
|
|
CreatedAt time.Time `json:"created_at" gorm:"default:now()"`
|
||
|
|
}
|