Commit c35f1042 authored by liuzeheng's avatar liuzeheng

优化

parent 579c56d3
...@@ -273,7 +273,7 @@ public class ShipmentLoadExcelExportListener { ...@@ -273,7 +273,7 @@ public class ShipmentLoadExcelExportListener {
List<Integer> mergeCountList = new ArrayList(); List<Integer> mergeCountList = new ArrayList();
List<Integer> colorRowList = new ArrayList<>(); List<Integer> colorRowList = new ArrayList<>();
AtomicInteger colorRowNum = new AtomicInteger(8); AtomicInteger colorRowNum = new AtomicInteger(5);
Map<String,Integer> colorMap = new HashMap<>(); Map<String,Integer> colorMap = new HashMap<>();
Map<String,Integer> mergePkgCountMap = new LinkedHashMap<>(); Map<String,Integer> mergePkgCountMap = new LinkedHashMap<>();
int colorIndex = 0; int colorIndex = 0;
...@@ -301,37 +301,27 @@ public class ShipmentLoadExcelExportListener { ...@@ -301,37 +301,27 @@ public class ShipmentLoadExcelExportListener {
colorRowList.add(andIncrement);//这里加1是为了设置颜色时过滤掉入仓记录那条 colorRowList.add(andIncrement);//这里加1是为了设置颜色时过滤掉入仓记录那条
} }
} }
// int mergeCount = 1; int mergeCount = 1;
// if (StringUtils.isNotBlank(item.getOrderWarehouseInDetails())) { if (StringUtils.isNotBlank(item.getOrderWarehouseInDetails())) {
// item.setOrderWarehouseInDetailsVOList(JsonUtils.parseArray(item.getOrderWarehouseInDetails(), OrderWarehouseInDetailsVO.class)); item.setOrderWarehouseInDetailsVOList(JsonUtils.parseArray(item.getOrderWarehouseInDetails(), OrderWarehouseInDetailsVO.class));
// } }
// if (CollectionUtil.isNotEmpty(item.getOrderWarehouseInDetailsVOList())) { if (CollectionUtil.isNotEmpty(item.getOrderWarehouseInDetailsVOList())) {
// mergeCount = mergeCount + item.getOrderWarehouseInDetailsVOList().size(); mergeCount = mergeCount + item.getOrderWarehouseInDetailsVOList().size();
// List<OrderWarehouseInDetailsVO> orderWarehouseInDetailsVOList = List<OrderWarehouseInDetailsVO> orderWarehouseInDetailsVOList =
// item.getOrderWarehouseInDetailsVOList(); item.getOrderWarehouseInDetailsVOList();
// for (int j = 0; j < orderWarehouseInDetailsVOList.size(); j++) { for (int j = 0; j < orderWarehouseInDetailsVOList.size(); j++) {
// int andIncrement1 = colorRowNum.getAndIncrement(); int andIncrement1 = colorRowNum.getAndIncrement();
// colorMap.put(String.valueOf(andIncrement1),colorList.get(colorIndex)); colorMap.put(String.valueOf(andIncrement1),colorList.get(colorIndex));
// colorRowList.add(andIncrement1); colorRowList.add(andIncrement1);
// } }
// } }
// mergeCountList.add(mergeCount); mergeCountList.add(mergeCount);
if (colorIndex == 7) { if (colorIndex == 7) {
colorIndex = 0; colorIndex = 0;
} else { } else {
colorIndex ++; colorIndex ++;
} }
//合包那几个列合并单元格计算
// if (pkgId.longValue() != 0L) {
// if (mergePkgCountMap.get(String.valueOf(pkgId)) == null) {
// mergePkgCountMap.put(String.valueOf(pkgId),mergeCount);
// } else {
// Integer sumMergePkgCount = mergePkgCountMap.get(String.valueOf(pkgId)) + mergeCount;
// mergePkgCountMap.put(String.valueOf(pkgId),sumMergePkgCount);
// }
// } else {
// mergePkgCountMap.put(String.valueOf(item.getId()),mergeCount);
// }
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment