19 lines
693 B
Go
19 lines
693 B
Go
package event
|
|
|
|
import "time"
|
|
|
|
type Event struct {
|
|
ID uint `gorm:"primaryKey" json:"id"`
|
|
UserID uint `gorm:"not null;index" json:"user_id"`
|
|
Name string `gorm:"not null" json:"name"`
|
|
EventDate time.Time `gorm:"not null;index" json:"event_date"`
|
|
EventType string `gorm:"not null" json:"event_type"`
|
|
Distance float64 `gorm:"default:0" json:"distance"`
|
|
Priority string `gorm:"default:'C'" json:"priority"`
|
|
Location string `gorm:"default:''" json:"location"`
|
|
Notes string `gorm:"default:''" json:"notes"`
|
|
URL string `gorm:"default:''" json:"url"`
|
|
CreatedAt time.Time `json:"created_at"`
|
|
UpdatedAt time.Time `json:"updated_at"`
|
|
}
|