update
This commit is contained in:
@ -13,8 +13,12 @@ type BrandRunwayImage struct {
|
||||
BrandID uint32 `gorm:"column:brand_id" json:"brand_id"`
|
||||
Name string `gorm:"column:name" json:"name"`
|
||||
SortOrder uint32 `gorm:"column:sort_order" json:"sort_order"` // 拖拽排序用,由迁移脚本新增
|
||||
LookIndex uint32 `gorm:"column:look_index" json:"look_index"` // 细节图归属的主图序号(主图=该 look;细节图=所属主图的 look)
|
||||
IsDetail uint8 `gorm:"column:is_detail" json:"is_detail"` // 0=主图/look 图(默认展示) 1=细节图
|
||||
IsDetail uint8 `gorm:"column:is_detail" json:"is_detail"` // 0=主图 1=细节图
|
||||
|
||||
// 主副图分组(列由 db/migrations/2026-09-24-01-runway-parent-image-id.sql 添加):
|
||||
// 与 street_snap_images 同构——is_detail=0 为主图(parent_image_id=0);
|
||||
// =1 为细节图,parent_image_id 指向同 runway 内主图的行 id。Look 序号对产品无意义,已移除。
|
||||
ParentImageID uint32 `gorm:"column:parent_image_id;not null;default:0" json:"parent_image_id"`
|
||||
|
||||
// 去重字段(近重复 + 语义 embedding 留痕):
|
||||
// phash 为 dHash 的 pgvector 二进制向量(vector(64)),NULL 表示无法解码(如 webp),不参与检索;
|
||||
|
||||
@ -8,7 +8,8 @@ import "database/sql"
|
||||
// 与 brand_runways 双表同构,但**无 brand_id**(街拍不关联品牌,模块自治)。
|
||||
type StreetSnap struct {
|
||||
ID uint32 `gorm:"primaryKey;column:id" json:"id"`
|
||||
Title string `gorm:"column:title" json:"title"`
|
||||
Title string `gorm:"column:title" json:"title"` // 英文标题(既有源,改动前唯一标题列)
|
||||
TitleCn string `gorm:"column:title_cn" json:"title_cn"` // 中文标题:后台人工翻译;为空时前端/接口回落英文
|
||||
Year uint16 `gorm:"column:year" json:"year"`
|
||||
City string `gorm:"column:city" json:"city"` // 地区/城市(从 title 第一段 \t 解析回填),'' 表示未归类
|
||||
Cover string `gorm:"column:cover" json:"cover"`
|
||||
|
||||
Reference in New Issue
Block a user