Files
atahango/internal/models/knowledge.go
Beyhan Oğur bbbf76b184 first commit
2026-04-26 21:35:24 +03:00

24 lines
665 B
Go

package models
import (
"time"
"github.com/google/uuid"
)
// Knowledge model structure
// Represents a resume knowledge entry.
type Knowledge struct {
ID uuid.UUID `gorm:"type:uuid;default:gen_random_uuid();primaryKey" json:"id"`
Title string `gorm:"type:varchar(100);not null" json:"title"`
ResumeID *uuid.UUID `gorm:"type:uuid" json:"resume_id,omitempty"`
IsActive bool `gorm:"default:false" json:"is_active"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
}
// TableName overrides the table name used by Knowledge to `knowledges`
func (Knowledge) TableName() string {
return "knowledges"
}