Files
lti-api/tools/templates/model.tmpl
T
2025-09-30 16:48:05 +07:00

18 lines
367 B
Cheetah

{{define "model"}}package model
import (
"time"
)
type {{Pascal .Entity}} struct {
Id uint `gorm:"primaryKey"`
Name string `gorm:"not null"`
CreatedBy int64 `gorm:"not null"`
CreatedAt time.Time
UpdatedAt time.Time
DeletedAt gorm.DeletedAt `gorm:"index" json:"-"`
CreatedUser model.User `gorm:"foreignKey:CreatedBy;references:Id"`
}
{{end}}