瀏覽代碼

feat:云教练评测视频上传

Joburgess 4 年之前
父節點
當前提交
63da1e9618
共有 1 個文件被更改,包括 5 次插入2 次删除
  1. 5 2
      mec-biz/src/main/java/com/ym/mec/biz/service/impl/SoundCompareHandler.java

+ 5 - 2
mec-biz/src/main/java/com/ym/mec/biz/service/impl/SoundCompareHandler.java

@@ -184,8 +184,11 @@ public class SoundCompareHandler implements WebSocketEventHandler {
                 }
                 break;
             case VIDEO_UPDATE:
-                if(bodyObject.containsKey("filePath")){
-                    SysMusicCompareRecord update = sysMusicCompareRecordService.get(userSoundInfoMap.get(phone).getRecordId());
+                SysMusicCompareRecord update = null;
+                if(bodyObject.containsKey("recordId")){
+                    update = sysMusicCompareRecordService.get(bodyObject.getLong("recordId"));
+                }
+                if(Objects.nonNull(update)&&bodyObject.containsKey("filePath")){
                     update.setVideoFilePath(bodyObject.getString("filePath"));
                     sysMusicCompareRecordService.update(update);
                 }