OSDN Git Service

f37ff7eaaa3988dc4e2e6468f461f4f16857ff53
[bytom/vapor.git] / vendor / github.com / jinzhu / gorm / model.go
1 package gorm
2
3 import "time"
4
5 // Model base model definition, including fields `ID`, `CreatedAt`, `UpdatedAt`, `DeletedAt`, which could be embedded in your models
6 //    type User struct {
7 //      gorm.Model
8 //    }
9 type Model struct {
10         ID        uint `gorm:"primary_key"`
11         CreatedAt time.Time
12         UpdatedAt time.Time
13         DeletedAt *time.Time `sql:"index"`
14 }