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 } }