update
This commit is contained in:
29
internal/model/models.go
Normal file
29
internal/model/models.go
Normal file
@ -0,0 +1,29 @@
|
||||
package model
|
||||
|
||||
// AppBrand 品牌数据表模型
|
||||
type AppBrand struct {
|
||||
ID int64 `gorm:"primaryKey;column:id"`
|
||||
Name string `gorm:"column:name"`
|
||||
SpiderOrigin string `gorm:"column:spider_origin"`
|
||||
}
|
||||
|
||||
func (AppBrand) TableName() string {
|
||||
return "app_brands" // 根据实际表名调整
|
||||
}
|
||||
|
||||
// Article 文章/发布会数据表模型
|
||||
type Article struct {
|
||||
ID int64 `gorm:"primaryKey;column:id"`
|
||||
Title string `gorm:"column:title"`
|
||||
Images string `gorm:"column:images"`
|
||||
Platform string `gorm:"column:platform"`
|
||||
Brand int64 `gorm:"column:brand"`
|
||||
Module int `gorm:"column:module"`
|
||||
Year int `gorm:"column:year"`
|
||||
SourceURL string `gorm:"column:source_url"`
|
||||
Cover string `gorm:"column:cover"`
|
||||
}
|
||||
|
||||
func (Article) TableName() string {
|
||||
return "articles" // 根据实际表名调整
|
||||
}
|
||||
Reference in New Issue
Block a user