package entity

import "time"

type MagazineFiles struct {
	ID            uint       `json:"id" gorm:"primaryKey;type:int4;autoIncrement"`
	Title         string     `json:"title" gorm:"type:varchar"`
	Description   string     `json:"description" gorm:"type:varchar"`
	MagazineId    uint       `json:"magazine_id" gorm:"type:int4"`
	DownloadCount *int       `json:"download_count" gorm:"type:int4"`
	StatusId      int        `json:"status_id" gorm:"type:int4"`
	IsPublish     *bool      `json:"is_publish" gorm:"type:bool"`
	FilePath      *string    `json:"file_path" gorm:"type:varchar"`
	FileUrl       *string    `json:"file_url" gorm:"type:varchar"`
	FileName      *string    `json:"file_name" gorm:"type:varchar"`
	FileAlt       *string    `json:"file_alt" gorm:"type:varchar"`
	WidthPixel    *string    `json:"width_pixel" gorm:"type:varchar"`
	HeightPixel   *string    `json:"height_pixel" gorm:"type:varchar"`
	Size          *string    `json:"size" gorm:"type:varchar"`
	PublishedAt   *time.Time `json:"published_at" gorm:"type:timestamp"`
	IsActive      bool       `json:"is_active" gorm:"type:bool"`
	CreatedAt     time.Time  `json:"created_at" gorm:"default:now()"`
	UpdatedAt     time.Time  `json:"updated_at" gorm:"default:now()"`
}
