This repository has been archived on 2025-03-16. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
boilerplate/internal/models/models.go

18 lines
432 B
Go

package models
var Entities = []any{
&Post{}, &Author{},
}
type Post struct {
Id uint `gorm:"primaryKey" displayName:"Номер"`
Text string `displayName:"Текст" displayName:"Текст поста"`
CreatedAt int64 `gorm:"autoCreateTime" displayName:"Дата публикации" cellType:"timestamp"`
}
// Author A sample of comment
type Author struct {
Id uint `gorm:"primaryKey"`
Name string
}