From f353ad524beea80e073d3e9db51a84bbd32f4d05 Mon Sep 17 00:00:00 2001 From: laodaming <11058467+laudamine@user.noreply.gitee.com> Date: Mon, 11 Sep 2023 14:41:35 +0800 Subject: [PATCH] fix --- server/websocket/internal/logic/ws_render_image.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/server/websocket/internal/logic/ws_render_image.go b/server/websocket/internal/logic/ws_render_image.go index 524d766c..619fa2fb 100644 --- a/server/websocket/internal/logic/ws_render_image.go +++ b/server/websocket/internal/logic/ws_render_image.go @@ -160,16 +160,16 @@ func (w *wsConnectItem) renderImage(data []byte) { w.renderErrResponse(renderImageData.RenderId, renderImageData.RenderData.TemplateTag, "", err.Error(), renderImageData.RenderData.ProductId, w.userId, w.guestId, productTemplate.Id, model3dInfo.Id, productSize.Id, *productTemplate.ElementModelId) return } - if renderImageData.RenderData.Website == "" { + if renderImageData.RenderData.Website == "" && templateSwitchInfo.MaterialData.Website.IfShow { renderImageData.RenderData.Website = templateSwitchInfo.MaterialData.Website.DefaultValue } - if renderImageData.RenderData.Phone == "" { + if renderImageData.RenderData.Phone == "" && templateSwitchInfo.MaterialData.Phone.IfShow { renderImageData.RenderData.Phone = templateSwitchInfo.MaterialData.Phone.DefaultValue } - if renderImageData.RenderData.Address == "" { + if renderImageData.RenderData.Address == "" && templateSwitchInfo.MaterialData.Address.IfShow { renderImageData.RenderData.Address = templateSwitchInfo.MaterialData.Address.DefaultValue } - if renderImageData.RenderData.Qrcode == "" { + if renderImageData.RenderData.Qrcode == "" && templateSwitchInfo.MaterialData.QRcode.IfShow { renderImageData.RenderData.Qrcode = templateSwitchInfo.MaterialData.QRcode.DefaultValue } }