lyhzzz 7 月之前
父节点
当前提交
575e2bd3b2

+ 1 - 1
src/main/java/com/fdkankan/fusion/service/impl/ModelServiceImpl.java

@@ -358,7 +358,7 @@ public class ModelServiceImpl extends ServiceImpl<IModelMapper, Model> implement
     public Model getByUploadSuccess(String fileMd5) {
         LambdaQueryWrapper<Model> wrapper = new LambdaQueryWrapper<>();
         wrapper.eq(Model::getFileMd5,fileMd5);
-       // wrapper.eq(Model::getCreateStatus,1);
+        wrapper.eq(Model::getCreateStatus,1);
         List<Model> list = this.list(wrapper);
         if(list.isEmpty()){
             return null;

+ 3 - 1
src/main/java/com/fdkankan/fusion/service/impl/UploadChunkServiceImpl.java

@@ -90,13 +90,15 @@ public class UploadChunkServiceImpl extends ServiceImpl<IUploadChunkMapper, Uplo
                 return;
         }
     }
+    @Autowired
+    UploadToOssUtil uploadToOssUtil;
 
     public void toModel(UploadChunk uploadChunk) {
 
         Model model = modelService.getByUPloadId(uploadChunk.getId());
         if(model == null){
             model = modelService.getByUploadSuccess(uploadChunk.getFileMd5());
-            if(model != null){
+            if(model != null && uploadToOssUtil.existKey(model.getModelGlbUrl())){
                 modelService.copyModel(model,uploadChunk);
                 return;
             }

+ 2 - 2
src/main/resources/mapper/fusion/ScenePlusMapper.xml

@@ -4,7 +4,7 @@
 
 
     <select id="groupByCameraId" resultType="com.fdkankan.fusion.response.DataGroupVo">
-        select camera_id as groupKey ,count(1) as dataCount from t_scene_plus where rec_status = 'A'
+        select camera_id as groupKey ,count(1) as dataCount from t_scene_plus where rec_status = 'A' and other_type is null
         and  camera_id in
         <foreach item="cameraId" collection="cameraIds" open="(" separator="," close=")">
          #{cameraId}
@@ -20,7 +20,7 @@
     </select>
 
     <select id="groupByType" resultType="com.fdkankan.fusion.response.DataGroupVo">
-        select scene_source as groupKey ,count(1) as dataCount from t_scene_plus where rec_status = 'A'
+        select scene_source as groupKey ,count(1) as dataCount from t_scene_plus where rec_status = 'A' and other_type is null
         and  camera_id in
         <foreach item="cameraId" collection="cameraIds" open="(" separator="," close=")">
             #{cameraId}