diff --git a/model/gmodel/fs_admin_menu_gen.go b/model/gmodel/fs_admin_menu_gen.go index c26f3ee5..d1b20aab 100644 --- a/model/gmodel/fs_admin_menu_gen.go +++ b/model/gmodel/fs_admin_menu_gen.go @@ -23,6 +23,14 @@ type FsAdminMenu struct { DeleteUid *int64 `gorm:"default:0;" json:"delete_uid"` // 删除人 IsDel *int64 `gorm:"default:0;" json:"is_del"` // 是否删除:1=是 0=否 Status *int64 `gorm:"default:2;" json:"status"` // 状态:1=启用,2=停用 + Type *int64 `gorm:"default:0;" json:"type"` // 类型:1=菜单,2=iframe,3=外链,4=按钮 + Alias *string `gorm:"default:'';" json:"alias"` // + Icon *string `gorm:"default:'';" json:"icon"` // + Redirect *string `gorm:"default:'';" json:"redirect"` // + Highlight *string `gorm:"default:'';" json:"highlight"` // + View *string `gorm:"default:'';" json:"view"` // + Colour *string `gorm:"default:'';" json:"colour"` // + Label *int64 `gorm:"default:0;" json:"label"` // 整页路由:1=是,0=否 } type FsAdminMenuModel struct { db *gorm.DB diff --git a/model/gmodel/fs_resource_gen.go b/model/gmodel/fs_resource_gen.go index 783cc547..8671c7fe 100644 --- a/model/gmodel/fs_resource_gen.go +++ b/model/gmodel/fs_resource_gen.go @@ -14,8 +14,7 @@ type FsResource struct { ResourceUrl *string `gorm:"default:'';" json:"resource_url"` // 资源 URL Version *string `gorm:"index;default:'0';" json:"version"` // 版本信息 UploadedAt *time.Time `gorm:"index;default:'0000-00-00 00:00:00';" json:"uploaded_at"` // - Metadata *string `gorm:"default:'';" json:"metadata"` // 元数据,json格式,存储图像分率 - MetaKey1 *string `gorm:"default:'';" json:"meta_key1"` // 需要关键信息查询的自定义属性1,可以动态增加 + Metadata *[]byte `gorm:"default:'';" json:"metadata"` // ApiType *int64 `gorm:"default:1;" json:"api_type"` // 调用类型:1=对外,2=对内 BucketName *string `gorm:"default:'';" json:"bucket_name"` // 存储桶名: 1=持久 2=缓存 Source *string `gorm:"default:'';" json:"source"` // 来源 diff --git a/server/product-template-tag/internal/logic/getproducttemplatetagslogic.go b/server/product-template-tag/internal/logic/getproducttemplatetagslogic.go index b3f9fd90..184de958 100644 --- a/server/product-template-tag/internal/logic/getproducttemplatetagslogic.go +++ b/server/product-template-tag/internal/logic/getproducttemplatetagslogic.go @@ -114,7 +114,7 @@ func (l *GetProductTemplateTagsLogic) GetProductTemplateTags(req *types.GetProdu for _, v := range resourceMetadataList { var metadata map[string]interface{} if v.Metadata != nil { - _ = json.Unmarshal([]byte(*v.Metadata), &metadata) + _ = json.Unmarshal(*v.Metadata, &metadata) } mapResourceMetadata[*v.ResourceUrl] = metadata } diff --git a/server/product/internal/logic/getrecommandproductlistlogic.go b/server/product/internal/logic/getrecommandproductlistlogic.go index 1adbd72a..339064f1 100644 --- a/server/product/internal/logic/getrecommandproductlistlogic.go +++ b/server/product/internal/logic/getrecommandproductlistlogic.go @@ -144,7 +144,7 @@ func (l *GetRecommandProductListLogic) GetRecommandProductList(req *types.GetRec for _, v := range resourceMetadataList { var metadata map[string]interface{} if v.Metadata != nil { - _ = json.Unmarshal([]byte(*v.Metadata), &metadata) + _ = json.Unmarshal(*v.Metadata, &metadata) } mapResourceMetadata[*v.ResourceUrl] = metadata } diff --git a/server/product/internal/logic/gettagproductlistlogic.go b/server/product/internal/logic/gettagproductlistlogic.go index dd376605..1213c414 100644 --- a/server/product/internal/logic/gettagproductlistlogic.go +++ b/server/product/internal/logic/gettagproductlistlogic.go @@ -217,7 +217,7 @@ func (l *GetTagProductListLogic) getProductRelationInfo(req getProductRelationIn for _, v := range resourceMetadataList { var metadata map[string]interface{} if v.Metadata != nil { - _ = json.Unmarshal([]byte(*v.Metadata), &metadata) + _ = json.Unmarshal(*v.Metadata, &metadata) } req.MapResourceMetadata[*v.ResourceUrl] = metadata } diff --git a/server/product/internal/logic/homepagerecommendproductlistlogic.go b/server/product/internal/logic/homepagerecommendproductlistlogic.go index 10c3ca44..9f5df115 100644 --- a/server/product/internal/logic/homepagerecommendproductlistlogic.go +++ b/server/product/internal/logic/homepagerecommendproductlistlogic.go @@ -177,7 +177,7 @@ func (l *HomePageRecommendProductListLogic) HomePageRecommendProductList(req *ty for _, v := range resourceMetadataList { var metadata map[string]interface{} if v.Metadata != nil { - _ = json.Unmarshal([]byte(*v.Metadata), &metadata) + _ = json.Unmarshal(*v.Metadata, &metadata) } mapResourceMetadata[*v.ResourceUrl] = metadata }