From 714ec3cc8e9c0ab12660c1371e832b7dc5532964 Mon Sep 17 00:00:00 2001
From: liyong <18434998025@163.com>
Date: 星期一, 25 五月 2026 15:44:00 +0800
Subject: [PATCH] feat(approve): 添加销售审批功能并优化相关服务
---
src/main/java/com/ruoyi/projectManagement/service/impl/InfoServiceImpl.java | 13 ++++++++-----
1 files changed, 8 insertions(+), 5 deletions(-)
diff --git a/src/main/java/com/ruoyi/projectManagement/service/impl/InfoServiceImpl.java b/src/main/java/com/ruoyi/projectManagement/service/impl/InfoServiceImpl.java
index 2c21be4..871de3a 100644
--- a/src/main/java/com/ruoyi/projectManagement/service/impl/InfoServiceImpl.java
+++ b/src/main/java/com/ruoyi/projectManagement/service/impl/InfoServiceImpl.java
@@ -56,7 +56,7 @@
contractInfoHandleService.save(infoId, saveInfoVo.getContractInfo());
}
if(saveInfoVo.getSalesLedgerProductList() != null){
- salesLedgerService.handleSalesLedgerProducts(infoId, saveInfoVo.getSalesLedgerProductList(), SaleEnum.MANAGEMENT);
+ salesLedgerService.handleSalesLedgerProducts(infoId, saveInfoVo.getSalesLedgerProductList(), SaleEnum.MANAGEMENT,"");
}
}
@@ -103,24 +103,27 @@
CompletableFuture<SaveInfoDto> infoFuture = CompletableFuture.supplyAsync(() -> infoHandleService.getInfoById(id));
CompletableFuture<ContractInfoDto> contractFuture = CompletableFuture.supplyAsync(() -> contractInfoHandleService.getByInfoId(id));
CompletableFuture<ShippingAddressDto> shippingFuture = CompletableFuture.supplyAsync(() -> shippingAddressHandleService.getByInfoId(id));
+ // 鍟嗗搧
CompletableFuture<List<SalesLedgerProduct>> listCompletableFuture = CompletableFuture.supplyAsync(() -> salesLedgerService.getSalesLedgerProductListByRelateId(id,SaleEnum.MANAGEMENT));
- // 鍟嗗搧
+ // 涓嬬骇椤圭洰淇℃伅
+ CompletableFuture<List<SaveInfoDto>> subordinateInfoListFuture = CompletableFuture.supplyAsync(() -> infoHandleService.getSubordinateInfo(id));
+
// 绛夊緟鎵�鏈夊紓姝ュ畬鎴�
- CompletableFuture.allOf(infoFuture, contractFuture, shippingFuture).join();
+ CompletableFuture.allOf(infoFuture, contractFuture, shippingFuture,listCompletableFuture,subordinateInfoListFuture).join();
SaveInfoDto info = infoFuture.get();
ContractInfoDto contract = contractFuture.get();
ShippingAddressDto shippingAddress = shippingFuture.get();
List<SalesLedgerProduct> salesLedgerProductList = listCompletableFuture.get();
-
+ List<SaveInfoDto> saveInfoDtos = subordinateInfoListFuture.get();
InfoVo vo = new InfoVo();
vo.setInfo(info);
vo.setContractInfo(contract);
vo.setShippingAddress(shippingAddress);
vo.setSalesLedgerProductList(salesLedgerProductList);
-
+ vo.setSubordinateInfoList(saveInfoDtos);
return vo;
}
--
Gitblit v1.9.3