This commit is contained in:
laodaming 2023-08-16 16:26:44 +08:00
parent 29b5d59b05
commit c8ff11b633

View File

@ -110,8 +110,11 @@ func (w *wsConnectItem) consumeRenderCache(data []byte) {
renderImageData.RenderData.UserId = w.userId renderImageData.RenderData.UserId = w.userId
renderImageData.RenderData.GuestId = w.guestId renderImageData.RenderData.GuestId = w.guestId
//生成任务id //生成任务id(需要把user_id,guest_id设为0)
taskId := hash.JsonHashKey(renderImageData.RenderData) hashVal := renderImageData.RenderData
hashVal.UserId = 0
hashVal.GuestId = 0
taskId := hash.JsonHashKey(hashVal)
//查询有没有缓存的资源,有就返回###################### //查询有没有缓存的资源,有就返回######################
resource, err := w.logic.svcCtx.AllModels.FsResource.FindOneById(w.logic.ctx, taskId) resource, err := w.logic.svcCtx.AllModels.FsResource.FindOneById(w.logic.ctx, taskId)
if err != nil { if err != nil {