nezha/model/common.go
2021-01-16 00:45:49 +08:00

21 lines
408 B
Go

package model
import "time"
const CtxKeyAuthorizedUser = "ckau"
const CtxKeyOauth2State = "cko2s"
type Common struct {
ID uint64 `gorm:"primary_key"`
CreatedAt time.Time
UpdatedAt time.Time
DeletedAt *time.Time `sql:"index"`
}
type Response struct {
Code uint64 `json:"code,omitempty"`
Message string `json:"message,omitempty"`
Result interface{} `json:"result,omitempty"`
}