From e94917a9d248e29bb6846c6f889f0d23e87e7a75 Mon Sep 17 00:00:00 2001 From: momo <1012651275@qq.com> Date: Wed, 18 Oct 2023 14:01:46 +0800 Subject: [PATCH] =?UTF-8?q?feat:=E5=90=88=E5=9B=BE=E6=96=B0=E5=A2=9Edebug?= =?UTF-8?q?=E6=A8=A1=E5=9D=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- server/upload/internal/logic/uploadlogologic.go | 1 + service/repositories/image_handle.go | 9 +++++++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/server/upload/internal/logic/uploadlogologic.go b/server/upload/internal/logic/uploadlogologic.go index 05d5b0be..7a2759ad 100644 --- a/server/upload/internal/logic/uploadlogologic.go +++ b/server/upload/internal/logic/uploadlogologic.go @@ -174,6 +174,7 @@ func (l *UploadLogoLogic) UploadLogo(req *types.UploadLogoReq, userinfo *auth.Us resLogoStandard, err := l.svcCtx.Repositories.ImageHandle.LogoInfoSet(l.ctx, &repositories.LogoInfoSetReq{ LogoUrl: logoUrl, Version: l.svcCtx.Config.BLMService.Version, + Debug: userinfo.Debug, }) if err != nil { diff --git a/service/repositories/image_handle.go b/service/repositories/image_handle.go index bde815fa..0090dd50 100644 --- a/service/repositories/image_handle.go +++ b/service/repositories/image_handle.go @@ -68,8 +68,9 @@ type ( /* logo信息 */ type ( LogoInfoSetReq struct { - LogoUrl string `json:"logo_url"` - Version string `json:"version"` + LogoUrl string `json:"logo_url"` + Version string `json:"version"` + Debug *auth.Debug `json:"debug"` } LogoInfoSetRes struct { Res string `json:"res"` @@ -90,6 +91,10 @@ func (l *defaultImageHandle) LogoInfoSet(ctx context.Context, in *LogoInfoSetReq postMap["logo_url"] = in.LogoUrl postMap["version"] = in.Version + if in.Debug != nil && in.Debug.IsAllTemplateTag == 1 { + postMap["is_all_template"] = "1" + } + logc.Infof(ctx, "算法请求--LOGO基础信息--开始时间:%v", time.Now().UTC()) err := curl.NewClient(ctx, &curl.Config{ BaseUrl: bLMServicePort,