Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Task ¶
type Task struct { ID uint `gorm:"primaryKey" json:"id"` Title string `gorm:"type:varchar(100);not null;unique_index" json:"title"` Description string `json:"description" json:"description"` Done bool `gorm:"default:false" json:"done"` UserID uint `json:"user_id"` CreatedAt time.Time `gorm:"autoCreateTime" json:"createdAt"` UpdatedAt time.Time `gorm:"autoUpdateTime" json:"updatedAt"` DeletedAt gorm.DeletedAt `json:"deletedAt"` }
type User ¶
type User struct { ID uint `gorm:"primaryKey" json:"id"` FirstName string `gorm:"not null" json:"first_name"` LastName string `gorm:"not null" json:"last_name"` Email string `gorm:"not null;unique_index" json:"email"` Tasks []Task `json:"tasks"` CreatedAt time.Time `gorm:"autoCreateTime" json:"createdAt"` UpdatedAt time.Time `gorm:"autoUpdateTime" json:"updatedAt"` DeletedAt gorm.DeletedAt `json:"deletedAt"` }
Click to show internal directories.
Click to hide internal directories.