From a1454f4b28db363ca4c4a6ea182d3aab95dc9518 Mon Sep 17 00:00:00 2001
From: zss <zss@example.com>
Date: 星期五, 24 四月 2026 11:17:50 +0800
Subject: [PATCH] fix(sales): 修正新增销售订单下发生产计划

---
 src/main/java/com/ruoyi/sales/service/impl/SalesLedgerServiceImpl.java |   29 ++++++++++-------------------
 1 files changed, 10 insertions(+), 19 deletions(-)

diff --git a/src/main/java/com/ruoyi/sales/service/impl/SalesLedgerServiceImpl.java b/src/main/java/com/ruoyi/sales/service/impl/SalesLedgerServiceImpl.java
index 0ee10b7..32d6069 100644
--- a/src/main/java/com/ruoyi/sales/service/impl/SalesLedgerServiceImpl.java
+++ b/src/main/java/com/ruoyi/sales/service/impl/SalesLedgerServiceImpl.java
@@ -12,7 +12,6 @@
 import com.ruoyi.basic.dto.CustomerPrivatePoolDto;
 import com.ruoyi.basic.mapper.CustomerMapper;
 import com.ruoyi.basic.mapper.CustomerPrivatePoolMapper;
-import com.ruoyi.basic.mapper.ProductMapper;
 import com.ruoyi.basic.mapper.ProductModelMapper;
 import com.ruoyi.basic.pojo.Customer;
 import com.ruoyi.common.enums.FileNameType;
@@ -27,7 +26,9 @@
 import com.ruoyi.framework.web.domain.AjaxResult;
 import com.ruoyi.other.mapper.TempFileMapper;
 import com.ruoyi.other.pojo.TempFile;
-import com.ruoyi.production.mapper.*;
+import com.ruoyi.production.mapper.ProductionProductInputMapper;
+import com.ruoyi.production.mapper.ProductionProductMainMapper;
+import com.ruoyi.production.mapper.ProductionProductOutputMapper;
 import com.ruoyi.production.service.ProductionProductMainService;
 import com.ruoyi.project.system.domain.SysDept;
 import com.ruoyi.project.system.domain.SysUser;
@@ -45,7 +46,6 @@
 import org.apache.commons.io.FilenameUtils;
 import org.jetbrains.annotations.Nullable;
 import org.springframework.beans.BeanUtils;
-import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.beans.factory.annotation.Value;
 import org.springframework.data.redis.core.RedisTemplate;
 import org.springframework.data.redis.core.script.DefaultRedisScript;
@@ -102,24 +102,15 @@
     private final ProductionProductOutputMapper productionProductOutputMapper;
     private final ProductionProductInputMapper productionProductInputMapper;
     private final QualityInspectMapper qualityInspectMapper;
+    private final ProductModelMapper productModelMapper;
     private final RedisTemplate<String, String> redisTemplate;
-    @Autowired
-    private SysDeptMapper sysDeptMapper;
+    private final SysDeptMapper sysDeptMapper;
     @Value("${file.upload-dir}")
     private String uploadDir;
-    @Autowired
-    private ProductModelMapper productModelMapper;
-
-    @Autowired
-    private ProductMapper productMapper;
-    @Autowired
-    private ProductionProductMainService productionProductMainService;
-    @Autowired
-    private PurchaseReturnOrderProductsMapper purchaseReturnOrderProductsMapper;
-    @Autowired
-    private SysUserMapper sysUserMapper;
-    @Autowired
-    private CustomerPrivatePoolMapper customerPrivatePoolMapper;
+    private final ProductionProductMainService productionProductMainService;
+    private final PurchaseReturnOrderProductsMapper purchaseReturnOrderProductsMapper;
+    private final SysUserMapper sysUserMapper;
+    private final CustomerPrivatePoolMapper customerPrivatePoolMapper;
 
     @Override
     public List<SalesLedger> selectSalesLedgerList(SalesLedgerDto salesLedgerDto) {
@@ -529,7 +520,7 @@
         List<Long> productIds = products.stream()
                 .map(SalesLedgerProduct::getId)
                 .collect(Collectors.toList());
-        //鍒犻櫎鐢熶骇鏁版嵁
+        //鍒犻櫎鐢熶骇璁″垝
         salesLedgerProductServiceImpl.deleteProductionData(productIds);
 
         // 鎵归噺鍒犻櫎浜у搧瀛愯〃

--
Gitblit v1.9.3