春风项目四线(合箱线、总装线)
yyt
2024-02-21 220f7b818bb9399391830fbbb9fb2028a21b938f
批量数据采集方法更新
已修改1个文件
6 ■■■■ 文件已修改
jcdm-main/src/main/java/com/jcdm/main/da/opcuaconfig/cert/MethodName.java 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-main/src/main/java/com/jcdm/main/da/opcuaconfig/cert/MethodName.java
@@ -61,7 +61,7 @@
                    //保存PLC采集数据
//                  StopWatch stopWatch = new StopWatch();
//                  stopWatch.start();
                    List<DaParamCollection> DaParamCollectionlist = new ArrayList<>();
                    List<DaParamCollection> ParamCollectionlist = new ArrayList<>();
                    for(int i=0;i<nodeId.size();i++){
                        DaParamCollection ParamCollection = new DaParamCollection();
                        ParamCollection.setParamCode(nodeId.get(i).getIdentifier().toString().split("[.]")[2]);
@@ -69,9 +69,9 @@
                        ParamCollection.setParamValue(s.get(i).getValue().getValue().toString());
                        ParamCollection.setSfcCode(SNCode);
                        ParamCollection.setParamName(b.get(i).getGatherAddress());
                        DaParamCollectionlist.add(ParamCollection);
                        ParamCollectionlist.add(ParamCollection);
                    }
                    daParamCollectionService.saveBeachDaParamCollection(DaParamCollectionlist);
                    daParamCollectionService.saveBeachDaParamCollection(ParamCollectionlist);
//                  stopWatch.stop();
//                  System.out.println("使用sqlSessionFactory实现批量插入耗时:" + stopWatch.getTotalTimeMillis());
                }