yumeng 5 tahun lalu
induk
melakukan
2549685f24

+ 2 - 2
jeecg-boot-module-system/src/main/resources/application-test.yml

@@ -130,8 +130,8 @@ mybatis-plus:
       id-type: 4
       # 默认数据库表下划线命名
       table-underline: true
-  configuration:
-    map-underscore-to-camel-case: false
+ # configuration:
+  #  map-underscore-to-camel-case: false
   #分页pageHelper
 pagehelper:
   helper-dialect: mysql

+ 12 - 15
module-common/src/main/java/cn/com/ctop/common/module/service/impl/MaterialInfoServiceImpl.java

@@ -364,20 +364,6 @@ public class MaterialInfoServiceImpl extends ServiceImpl<MaterialInfoMapper, Mat
                         materialParameter.setHeight(height);
 
 
-                        Thread thread = new Thread() {
-                            @Override
-                            public void run() {
-                                try {
-                                    log.info("开始抽帧");
-                                    materialCutFrameService.getCutFrame(url, materialInfo.getCode(), secondDuration, height, width);
-                                } catch (Exception e) {
-                                    e.printStackTrace();
-                                }
-                            }
-                        };
-                        thread.start();
-
-
                         fis = new FileInputStream(file);
                         FileChannel fc = fis.getChannel();
                         BigDecimal fileSize = new BigDecimal(fc.size());
@@ -391,8 +377,19 @@ public class MaterialInfoServiceImpl extends ServiceImpl<MaterialInfoMapper, Mat
                         int insert = materialParameterMapper.insert(materialParameter);
                         if (insert > 0) {
                             log.info("素材基本信息入库完成,用时:{} s", (System.currentTimeMillis() - l) / 1000);
-
                         }
+                        Thread thread = new Thread() {
+                            @Override
+                            public void run() {
+                                try {
+                                    log.info("开始抽帧");
+                                    materialCutFrameService.getCutFrame(url, materialInfo.getCode(), secondDuration, height, width);
+                                } catch (Exception e) {
+                                    e.printStackTrace();
+                                }
+                            }
+                        };
+                        thread.start();
                     } catch (FileNotFoundException e) {
                         e.printStackTrace();
                     } catch (IOException e) {