Merge remote-tracking branch 'origin/dev_third_stage' into dev_third_stage
This commit is contained in:
+18
@@ -8,8 +8,10 @@ public class SarFileCompareResultVO {
|
||||
private String infoId;
|
||||
private String serialNumberLeft;
|
||||
private String fileNameLeft;
|
||||
private String fileIdLeft;
|
||||
private String serialNumberRight;
|
||||
private String fileNameRight;
|
||||
private String fileIdRight;
|
||||
private List<SarFileCompareItemComVO> resList;
|
||||
private String comments;
|
||||
|
||||
@@ -78,4 +80,20 @@ public class SarFileCompareResultVO {
|
||||
public void setComments(String comments) {
|
||||
this.comments = comments;
|
||||
}
|
||||
|
||||
public String getFileIdLeft() {
|
||||
return fileIdLeft;
|
||||
}
|
||||
|
||||
public void setFileIdLeft(String fileIdLeft) {
|
||||
this.fileIdLeft = fileIdLeft;
|
||||
}
|
||||
|
||||
public String getFileIdRight() {
|
||||
return fileIdRight;
|
||||
}
|
||||
|
||||
public void setFileIdRight(String fileIdRight) {
|
||||
this.fileIdRight = fileIdRight;
|
||||
}
|
||||
}
|
||||
|
||||
+2
@@ -143,8 +143,10 @@ public class SarFileCompareItemCommentServiceImpl extends ServiceImpl<SarFileCom
|
||||
resultVO.setInfoId(infoId);
|
||||
resultVO.setSerialNumberLeft(sfcInfo.getSerialNumberLeft());
|
||||
resultVO.setFileNameLeft(sfcInfo.getFileNameLeft());
|
||||
resultVO.setFileIdLeft(sfcInfo.getFileIdLeft());
|
||||
resultVO.setSerialNumberRight(sfcInfo.getSerialNumberRight());
|
||||
resultVO.setFileNameRight(sfcInfo.getFileNameRight());
|
||||
resultVO.setFileIdRight(sfcInfo.getFileIdRight());
|
||||
resultVO.setComments(sfcInfo.getComments());
|
||||
|
||||
List<SarFileCompareItemComment> list = queryListByInfoId(infoId,comment);
|
||||
|
||||
+20
-1
@@ -3754,7 +3754,26 @@ public class FileSplitItemsEOServiceImpl extends ServiceImpl<FileSplitItemsEOMap
|
||||
|
||||
@Override
|
||||
public int insertForeach(List<SarFileSplitItemsEO> messageList) {
|
||||
return dao.insertForeach(messageList);
|
||||
// 解决一次批量插入太多 PacketTooBigException 异常
|
||||
int total = messageList.size();
|
||||
int count = 0;
|
||||
int pageSum = 1;
|
||||
if(total > 100) {
|
||||
pageSum = total / 100; // 总页数
|
||||
if ((total % 100) > 0) {
|
||||
pageSum += 1;
|
||||
}
|
||||
}
|
||||
List<SarFileSplitItemsEO> subList = new ArrayList<>();
|
||||
for(int i = 0; i < pageSum; i++) {
|
||||
int j = i*100+100;
|
||||
if (i == pageSum -1) {
|
||||
j = total;
|
||||
}
|
||||
subList = messageList.subList(i*100, j);
|
||||
count += dao.insertForeach(subList);
|
||||
}
|
||||
return count;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
+1
-1
@@ -1784,7 +1784,7 @@ public class FileSplitPdfService {
|
||||
if(StringUtils.isNotBlank(preName)) {
|
||||
List<String> nowStartList = fileSpiltService.getNewNowStart(preName);
|
||||
|
||||
List<String> subList1 = startDigitList.subList(preNameNum, startDigitList.size()-1);
|
||||
List<String> subList1 = startDigitList.subList(preNameNum, startDigitList.size());
|
||||
// 后文有一级以下的标题
|
||||
for (int i = nowStartList.size() - 1; i >= 1; i--) {
|
||||
int index1 = subList1.indexOf(nowStartList.get(i));
|
||||
|
||||
+21
-2
@@ -12,6 +12,7 @@ import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Propagation;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -79,8 +80,26 @@ public class SarFileSplitItemsValEOServiceImpl extends ServiceImpl<SarFileSplitI
|
||||
|
||||
@Override
|
||||
public int insertForeach(List<SarFileSplitItemsValEO> itemValList) {
|
||||
|
||||
return dao.insertForeach(itemValList);
|
||||
// 解决一次批量插入太多 PacketTooBigException 异常
|
||||
int total = itemValList.size();
|
||||
int count = 0;
|
||||
int pageSum = 1;
|
||||
if(total > 100) {
|
||||
pageSum = total / 100; // 总页数
|
||||
if ((total % 100) > 0) {
|
||||
pageSum += 1;
|
||||
}
|
||||
}
|
||||
List<SarFileSplitItemsValEO> subList = new ArrayList<>();
|
||||
for(int i = 0; i < pageSum; i++) {
|
||||
int j = i*100+100;
|
||||
if (i == pageSum -1) {
|
||||
j = total;
|
||||
}
|
||||
subList = itemValList.subList(i*100, j);
|
||||
count += dao.insertForeach(subList);
|
||||
}
|
||||
return count;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user