fix
This commit is contained in:
parent
389794500f
commit
bdef106f09
|
@ -96,13 +96,13 @@ func (w *wsConnectItem) renderImage(data []byte) {
|
|||
//logx.Info("消费渲染数据:", string(data))
|
||||
var renderImageData websocket_data.RenderImageReqMsg
|
||||
if err := json.Unmarshal(data, &renderImageData); err != nil {
|
||||
w.renderErrResponse("", "", "", "数据格式错误", 0, 0, 0, 0, 0, 0, 0)
|
||||
w.renderErrResponse(renderImageData.RenderId, renderImageData.RenderData.TemplateTag, "", "数据格式错误", renderImageData.RenderData.ProductId, w.userId, w.guestId, 0, 0, 0, 0)
|
||||
logx.Error("invalid format of websocket render image message", err)
|
||||
return
|
||||
}
|
||||
lenColor := len(renderImageData.RenderData.TemplateTagColor.Color)
|
||||
if renderImageData.RenderData.TemplateTagColor.SelectedIndex >= lenColor || lenColor == 0 {
|
||||
w.renderErrResponse("", "", "", "请传入模板标签选择的颜色", 0, 0, 0, 0, 0, 0, 0)
|
||||
w.renderErrResponse(renderImageData.RenderId, renderImageData.RenderData.TemplateTag, "", "请传入模板标签选择的颜色", renderImageData.RenderData.ProductId, w.userId, w.guestId, 0, 0, 0, 0)
|
||||
return
|
||||
}
|
||||
//获取产品信息(部分字段)
|
||||
|
|
Loading…
Reference in New Issue
Block a user