From 002a61cd8b5a4239d357a2add1fda2c8c433cda6 Mon Sep 17 00:00:00 2001
From: zhanghl <253316343@qq.com>
Date: 星期四, 24 四月 2025 17:28:34 +0800
Subject: [PATCH] 钣金计划大表-导出功能调整

---
 aps-modules/aps-core/src/main/java/com/aps/core/service/impl/ApsPlateProcessShopStatServiceImpl.java |   48 ++++++++++++++++++++++++++++++++----------------
 1 files changed, 32 insertions(+), 16 deletions(-)

diff --git a/aps-modules/aps-core/src/main/java/com/aps/core/service/impl/ApsPlateProcessShopStatServiceImpl.java b/aps-modules/aps-core/src/main/java/com/aps/core/service/impl/ApsPlateProcessShopStatServiceImpl.java
index e665e38..0129a0a 100644
--- a/aps-modules/aps-core/src/main/java/com/aps/core/service/impl/ApsPlateProcessShopStatServiceImpl.java
+++ b/aps-modules/aps-core/src/main/java/com/aps/core/service/impl/ApsPlateProcessShopStatServiceImpl.java
@@ -192,7 +192,8 @@
         stat.setDelFlag("0");
         stat.setCreateBy(SecurityUtils.getUsername());
         stat.setCreateTime(DateUtils.getNowDate());
-
+        stat.setWorkCenter(plan.getWorkCenter());
+        stat.setProcessNumber(plan.getProcessNumber());
         try {
 
 
@@ -344,33 +345,41 @@
             workCenterTitle.setCellValue("褰撳墠宸ュ簭");
             workCenterTitle.setCellStyle(title);
 
-            SXSSFCell itemNumberTitle = rowTitle.createCell(6);
+            SXSSFCell departmentTitle = rowTitle.createCell(6);
+            departmentTitle.setCellValue("褰撳墠宸ュ簭璐熻矗浜�");
+            departmentTitle.setCellStyle(title);
+
+            SXSSFCell nextProcessDeparmentTitle = rowTitle.createCell(7);
+            nextProcessDeparmentTitle.setCellValue("涓嬩竴宸ュ簭璐熻矗浜�");
+            nextProcessDeparmentTitle.setCellStyle(title);
+
+            SXSSFCell itemNumberTitle = rowTitle.createCell(8);
             itemNumberTitle.setCellValue("鏂欏彿");
             itemNumberTitle.setCellStyle(title);
 
-            SXSSFCell drawingNoTitle = rowTitle.createCell(7);
+            SXSSFCell drawingNoTitle = rowTitle.createCell(9);
             drawingNoTitle.setCellValue("鍥惧彿");
             drawingNoTitle.setCellStyle(title);
 
-            SXSSFCell versionNumberTitle = rowTitle.createCell(8);
+            SXSSFCell versionNumberTitle = rowTitle.createCell(10);
             versionNumberTitle.setCellValue("鐗堟湰鍙�");
             versionNumberTitle.setCellStyle(title);
 
-            SXSSFCell productionQuantityTitle = rowTitle.createCell(9);
+            SXSSFCell productionQuantityTitle = rowTitle.createCell(11);
             productionQuantityTitle.setCellValue("鐢熶骇鏁伴噺");
             productionQuantityTitle.setCellStyle(title);
 
-            SXSSFCell planEndDayTitle = rowTitle.createCell(10);
+            SXSSFCell planEndDayTitle = rowTitle.createCell(12);
             planEndDayTitle.setCellValue("璁″垝瀹屽伐鏃�");
             planEndDayTitle.setCellStyle(title);
 
 
 
-
+            int i1 = 13;
             for (int i = 0; i < shopNames.size(); i++) {
                 String shopName = shopNames.get(i);
-                SXSSFCell beginDateCell = rowTitle.createCell(i * 2 + 11);
-                SXSSFCell endDateCell = rowTitle.createCell(i * 2 + 12);
+                SXSSFCell beginDateCell = rowTitle.createCell(i * 2 + i1);
+                SXSSFCell endDateCell = rowTitle.createCell(i * 2 + i1+1);
                 beginDateCell.setCellValue(shopName+"寮�宸ユ椂闂�");
                 endDateCell.setCellValue(shopName+"瀹屽伐鏃堕棿");
                 beginDateCell.setCellStyle(title);
@@ -407,30 +416,37 @@
                 workCenterCell.setCellValue(plan.getWorkCenter());
                // workCenterCell.setCellStyle(title);
 
-                SXSSFCell itemNumberCell = dataRow.createCell(6);
+                SXSSFCell departmentCell = dataRow.createCell(6);
+                departmentCell.setCellValue(plan.getDepartment());
+
+                SXSSFCell nextProcessDeparmentCell = dataRow.createCell(7);
+                nextProcessDeparmentCell.setCellValue(plan.getNextProcessDeparment());
+
+
+                SXSSFCell itemNumberCell = dataRow.createCell(8);
                 itemNumberCell.setCellValue(plan.getItemNumber());
                // itemNumberCell.setCellStyle(title);
 
-                SXSSFCell drawingNoCell = dataRow.createCell(7);
+                SXSSFCell drawingNoCell = dataRow.createCell(9);
                 drawingNoCell.setCellValue(plan.getDrawingNo());
                // drawingNoCell.setCellStyle(title);
 
-                SXSSFCell versionNumberCell = dataRow.createCell(8);
+                SXSSFCell versionNumberCell = dataRow.createCell(10);
                 versionNumberCell.setCellValue(plan.getVersionNumber());
               //  versionNumberCell.setCellStyle(title);
 
-                SXSSFCell productionQuantityCell = dataRow.createCell(9);
+                SXSSFCell productionQuantityCell = dataRow.createCell(11);
                 productionQuantityCell.setCellValue(plan.getProductionQuantity().toString());
               //  productionQuantityCell.setCellStyle(title);
 
-                SXSSFCell planEndDayCell = dataRow.createCell(10);
+                SXSSFCell planEndDayCell = dataRow.createCell(12);
                 planEndDayCell.setCellValue(dateFormat.format(plan.getPlanEndDay()));
               //  planEndDayCell.setCellStyle(title);
 
                 for (int j = 0; j< shopNames.size(); j++) {
                     String shopName = shopNames.get(j);
-                    SXSSFCell beginDateCell = dataRow.createCell(j * 2 + 11);
-                    SXSSFCell endDateCell = dataRow.createCell(j * 2 + 12);
+                    SXSSFCell beginDateCell = dataRow.createCell(j * 2 + i1);
+                    SXSSFCell endDateCell = dataRow.createCell(j * 2 + i1+1);
                     plan.getDeptPlans().stream().filter(x->x.getShopName().equals(shopName)).findFirst().ifPresent(x->{
                         beginDateCell.setCellValue(x.getPlanStartDate());
                         endDateCell.setCellValue(x.getPlanEndDate());

--
Gitblit v1.9.3