Browse Source

20250410_sun

15143018065 6 ngày trước cách đây
mục cha
commit
5a78e9350e

+ 12 - 1
ruoyi-modules/mz-gljt/src/main/java/com/ruoyi/gljt/service/impl/GljtPlzjServiceImpl.java

@@ -252,7 +252,18 @@ public class GljtPlzjServiceImpl implements IGljtPlzjService
                 in.setJfms("追加补发");
                 inList.add(in);
             });
-            gljtJfxxMapper.batchInsert(inList);
+            int listSize = inList.size();
+            int toIndex = 1000;
+            for (int i = 0; i < inList.size(); i += 1000) {
+                if (i + 1000 > listSize) {
+                    toIndex = listSize - i;
+                }
+                List<GljtJfxx> inList2 = inList.subList(i, i + toIndex);
+                if (org.apache.commons.collections4.CollectionUtils.isNotEmpty(inList2)) {
+                    gljtJfxxMapper.batchInsert(inList2);
+                }
+            }
+//            gljtJfxxMapper.batchInsert(inList);
         }
     }