Files
kontor/kontor-gin/internal/models/comics/issue.go
T
Thomas Peetz f0f1819a1f
Gitea Actions Demo / Explore-Gitea-Actions (push) Successful in 4s
umstellung auf Service und Repository Verwendung - WIP
2026-09-25 16:57:23 +02:00

27 lines
1.2 KiB
Go

package comics
import "time"
type Issue struct {
ID string `gorm:"type:string;primary_key;"`
CreatedAt time.Time `gorm:"column:created_date" json:"created_date"`
UpdatedAt time.Time `gorm:"column:last_modified_date" json:"last_modified_date"`
DeletedAt *time.Time `gorm:"column:deleted_date" json:"deleted_date"`
Version int `gorm:"default:0" json:"version"`
InStock bool `gorm:"column:in_stock" json:"in_stock"`
IsRead bool `gorm:"column:is_read" json:"is_read"`
IssueNumber string `gorm:"column:issue_number" json:"issue_number"`
Title string `gorm:"column:title" json:"title"`
PublishedOn time.Time `gorm:"column:published_on" json:"published_on"`
ComicID *string `gorm:"column:comic_id" json:"comic_id"`
Comic *Comic `gorm:"foreignKey:ComicID"`
StoryArcID *string `gorm:"column:story_arc_id" json:"story_arc_id"`
StoryArc *StoryArc `gorm:"foreignKey:StoryArcID"`
VolumeID *string `gorm:"column:volume_id" json:"volume_id"`
Volume *Volume `gorm:"foreignKey:VolumeID"`
}
func (issue *Issue) TableName() string {
return "issue"
}