iris/_examples/database/orm/reform/models/person.go
Gerasimos (Makis) Maropoulos acf058b006
add database/orm/reform example
2020-08-01 03:46:51 +03:00

14 lines
366 B
Go

//go:generate reform
package models
import "time"
//reform:people
type Person struct {
ID int32 `reform:"id,pk" json:"id"`
Name string `reform:"name" json:"name"`
Email *string `reform:"email" json:"email"`
CreatedAt time.Time `reform:"created_at" json:"created_at"`
UpdatedAt *time.Time `reform:"updated_at" json:"updated_at"`
}