diff --git a/model/gmodel/fs_change_code_gen.go b/model/gmodel/fs_change_code_gen.go index 6a58a515..73f2ea66 100644 --- a/model/gmodel/fs_change_code_gen.go +++ b/model/gmodel/fs_change_code_gen.go @@ -11,6 +11,7 @@ type FsChangeCode struct { Code *string `gorm:"default:'';" json:"code"` // CreatedAt *int64 `gorm:"default:0;" json:"created_at"` // 创建时间 IsUse *int64 `gorm:"default:0;" json:"is_use"` // 是否使用 1已使用 0未使用 + Metadata *[]byte `gorm:"default:'';" json:"metadata"` // } type FsChangeCodeModel struct { db *gorm.DB diff --git a/model/gmodel/fs_product_gen.go b/model/gmodel/fs_product_gen.go index f2b22738..52b458ba 100644 --- a/model/gmodel/fs_product_gen.go +++ b/model/gmodel/fs_product_gen.go @@ -35,6 +35,7 @@ type FsProduct struct { RecommendProduct *string `gorm:"default:'';" json:"recommend_product"` // RecommendProductSort *string `gorm:"default:'';" json:"recommend_product_sort"` // SceneIds *string `gorm:"default:'';" json:"scene_ids"` // + IsCustomization *int64 `gorm:"default:0;" json:"is_customization"` // 是否可定制 } type FsProductModel struct { db *gorm.DB diff --git a/model/gmodel/fs_quotation_gen.go b/model/gmodel/fs_quotation_gen.go index 041bbb84..b766f060 100644 --- a/model/gmodel/fs_quotation_gen.go +++ b/model/gmodel/fs_quotation_gen.go @@ -14,6 +14,7 @@ type FsQuotation struct { PageNum *int64 `gorm:"default:0;" json:"page_num"` // 页数 ProductNum *int64 `gorm:"default:0;" json:"product_num"` // 产品数量 GiftNum *int64 `gorm:"default:0;" json:"gift_num"` // 赠品数 + SequenceNum *string `gorm:"default:'';" json:"sequence_num"` // Status *int64 `gorm:"default:0;" json:"status"` // 状态位 0停用 1待设计 2设计中 3待报价 4报价中 5完成 Ctime *int64 `gorm:"default:0;" json:"ctime"` // 添加时间 DesignId *int64 `gorm:"default:0;" json:"design_id"` // 设计人员 diff --git a/model/gmodel/fs_resource_gen.go b/model/gmodel/fs_resource_gen.go index 4edaddb9..8671c7fe 100644 --- a/model/gmodel/fs_resource_gen.go +++ b/model/gmodel/fs_resource_gen.go @@ -1,9 +1,8 @@ package gmodel import ( - "time" - "gorm.io/gorm" + "time" ) // fs_resource 资源表 diff --git a/server/product/internal/logic/getrecommandproductlistlogic.go b/server/product/internal/logic/getrecommandproductlistlogic.go index 339064f1..1f3d2326 100644 --- a/server/product/internal/logic/getrecommandproductlistlogic.go +++ b/server/product/internal/logic/getrecommandproductlistlogic.go @@ -193,6 +193,7 @@ func (l *GetRecommandProductListLogic) GetRecommandProductList(req *types.GetRec Intro: *v.Intro, IsRecommend: isRecommend, MinPrice: minPrice, + IsCustomization: *productInfo.IsCustomization, } if _, ok := mapTagProp[productInfo.Id]; ok { item.CoverDefault = mapTagProp[productInfo.Id] diff --git a/server/product/internal/logic/gettagproductlistlogic.go b/server/product/internal/logic/gettagproductlistlogic.go index 1213c414..f0538caf 100644 --- a/server/product/internal/logic/gettagproductlistlogic.go +++ b/server/product/internal/logic/gettagproductlistlogic.go @@ -444,6 +444,7 @@ func (l *GetTagProductListLogic) getTagProducts(req getTagProductsReq) (productL Recommended: *productInfo.IsRecommend > 0, Cover: *productInfo.Cover, CoverMetadata: req.MapResourceMetadata[*productInfo.Cover], + IsCustomization: *productInfo.IsCustomization, } if _, ok = req.MapTagProp[productInfo.Id]; ok { item.CoverDefault = req.MapTagProp[productInfo.Id] diff --git a/server/product/internal/logic/homepagerecommendproductlistlogic.go b/server/product/internal/logic/homepagerecommendproductlistlogic.go index 9f5df115..75d8963f 100644 --- a/server/product/internal/logic/homepagerecommendproductlistlogic.go +++ b/server/product/internal/logic/homepagerecommendproductlistlogic.go @@ -217,6 +217,7 @@ func (l *HomePageRecommendProductListLogic) HomePageRecommendProductList(req *ty SizeNum: uint32(sizeNum), MinPrice: minPrice, HaveOptionalFitting: haveOptionalFitting, + IsCustomization: *productInfo.IsCustomization, } if _, ok = mapTagProp[productInfo.Id]; ok { item.CoverDefault = mapTagProp[productInfo.Id] diff --git a/server/product/internal/types/types.go b/server/product/internal/types/types.go index ee0a001e..a7e2b48b 100644 --- a/server/product/internal/types/types.go +++ b/server/product/internal/types/types.go @@ -246,6 +246,7 @@ type GetRecommandProductListRsp struct { Intro string `json:"intro"` IsRecommend int64 `json:"is_recommend"` MinPrice int64 `json:"min_price"` + IsCustomization int64 `json:"is_customization"` } type GetTagProductListReq struct { @@ -281,6 +282,7 @@ type TagProduct struct { CoverDefault []CoverDefaultItem `json:"cover_default"` HaveOptionalFitting bool `json:"have_optional_fitting"` Recommended bool `json:"recommended"` + IsCustomization int64 `json:"is_customization"` } type CoverDefaultItem struct { @@ -409,6 +411,7 @@ type HomePageRecommendProductListRsp struct { MinPrice int64 `json:"min_price"` CoverDefault []CoverDefaultItem `json:"cover_default"` HaveOptionalFitting bool `json:"have_optional_fitting"` + IsCustomization int64 `json:"is_customization"` } type Request struct { diff --git a/server_api/product.api b/server_api/product.api index bb95a9d9..b309c6dd 100644 --- a/server_api/product.api +++ b/server_api/product.api @@ -298,6 +298,7 @@ type GetRecommandProductListRsp { Intro string `json:"intro"` IsRecommend int64 `json:"is_recommend"` MinPrice int64 `json:"min_price"` + IsCustomization int64 `json:"is_customization"` } //获取分类产品列表 type GetTagProductListReq { @@ -331,6 +332,7 @@ type TagProduct { CoverDefault []CoverDefaultItem `json:"cover_default"` HaveOptionalFitting bool `json:"have_optional_fitting"` Recommended bool `json:"recommended"` + IsCustomization int64 `json:"is_customization"` } type CoverDefaultItem { TemplateTag string `json:"template_tag"` @@ -451,4 +453,5 @@ type HomePageRecommendProductListRsp { MinPrice int64 `json:"min_price"` CoverDefault []CoverDefaultItem `json:"cover_default"` HaveOptionalFitting bool `json:"have_optional_fitting"` + IsCustomization int64 `json:"is_customization"` } \ No newline at end of file