init project
This commit is contained in:
1 parent
d63cc8d9f5
commit
ee07869839
39 files changed
+1560
-622
No files matched your search
@@ -1,8 +1,10 @@
|
||||
package model
|
||||
|
||||
import "gorm.io/plugin/soft_delete"
|
||||
|
||||
type BaseModel struct {
|
||||
Id int64 `json:"id" xorm:"pk autoincr 'id'"`
|
||||
CreatedAt int64 `json:"created_at" xorm:"created"`
|
||||
UpdatedAt int64 `json:"updated_at" xorm:"updated"`
|
||||
DeletedAt int64 `json:"deleted_at" xorm:"deleted notnull"`
|
||||
ID int64 `json:"id" gorm:"primaryKey;autoIncrement"`
|
||||
CreatedAt int64 `json:"created_at" gorm:"autoCreateTime"`
|
||||
UpdatedAt int64 `json:"updated_at" gorm:"autoUpdateTime"`
|
||||
DeletedAt soft_delete.DeletedAt `json:"deleted_at" gorm:"softDelete:second;not null;default:0;index"`
|
||||
}
|
||||
Reference in new issue
Block a user