package model import "time" // Asset 素材数据模型,对应数据库表。 type Asset struct { ID uint `gorm:"primaryKey"` TaskID uint `gorm:"index;not null"` Key string `gorm:"size:255;not null"` // 七牛云对象键 URL string `gorm:"size:255;not null"` // CDN访问URL Format string `gorm:"size:20;not null"` // 文件格式 Metadata string `gorm:"type:text"` // 元数据(JSON格式) CreatedAt time.Time UpdatedAt time.Time } // AssetResponse 素材响应。 type AssetResponse struct { Key string `json:"key"` URL string `json:"url"` Format string `json:"format"` }