From 6d51ffc4ce13d0a9267698027c9d9d1a5f387c3b Mon Sep 17 00:00:00 2001 From: Lemon Date: Sat, 7 Jun 2025 13:15:39 +0800 Subject: [PATCH] =?UTF-8?q?update=20=20=E4=B8=B4=E6=97=B6=E5=88=86?= =?UTF-8?q?=E8=B4=A6=E6=8E=A5=E5=8F=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../api/uniapp/customer/TempController.java | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/jsowell-admin/src/main/java/com/jsowell/api/uniapp/customer/TempController.java b/jsowell-admin/src/main/java/com/jsowell/api/uniapp/customer/TempController.java index 3e7703584..615aa880b 100644 --- a/jsowell-admin/src/main/java/com/jsowell/api/uniapp/customer/TempController.java +++ b/jsowell-admin/src/main/java/com/jsowell/api/uniapp/customer/TempController.java @@ -351,12 +351,25 @@ public class TempController extends BaseController { logger.info("手动接口执行订单分账逻辑-param:{}", JSON.toJSONString(dto)); RestApiResponse response = null; try { + // 查询运营商列表 + List merchantIdList = dto.getMerchantIdList(); + if (CollectionUtils.isEmpty(merchantIdList)) { + List pileMerchantInfos = pileMerchantInfoService.selectPileMerchantInfoList(null); + merchantIdList = pileMerchantInfos.stream().map(x -> x.getId() + "").collect(Collectors.toList()); + } String startTime = dto.getStartTime(); String endTime = dto.getEndTime(); // 获取日期区间内所有日期 List dateList = DateUtils.getAllDatesInTheDateRange(startTime, endTime); for (String tradeDate : dateList) { - orderBasicInfoService.orderSplittingOperations(dto.getMerchantId(), tradeDate); + merchantIdList.parallelStream().forEach(merchantId -> { + try { + orderBasicInfoService.orderSplittingOperations(merchantId, tradeDate); + } catch (Exception e) { + logger.error("手动接口执行订单分账逻辑 error, merchantId:{}", merchantId, e); + } + }); + } response = new RestApiResponse<>(); } catch (BusinessException e) {