From 26f5900865e39d3cbd03cf86916643ee19cba3c8 Mon Sep 17 00:00:00 2001 From: WeiRan <2392355487@qq.com> Date: Fri, 9 Aug 2024 14:33:25 +0800 Subject: [PATCH] =?UTF-8?q?feat():=E7=9B=91=E5=90=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pay/service/impl/OrderPayCustomerServiceImpl.java | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/cloud-pay-server/src/main/java/com/muyu/cloud/pay/service/impl/OrderPayCustomerServiceImpl.java b/cloud-pay-server/src/main/java/com/muyu/cloud/pay/service/impl/OrderPayCustomerServiceImpl.java index 50d89d7..f2bda16 100644 --- a/cloud-pay-server/src/main/java/com/muyu/cloud/pay/service/impl/OrderPayCustomerServiceImpl.java +++ b/cloud-pay-server/src/main/java/com/muyu/cloud/pay/service/impl/OrderPayCustomerServiceImpl.java @@ -1,5 +1,6 @@ package com.muyu.cloud.pay.service.impl; +import com.alibaba.fastjson2.JSONObject; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import com.dtflys.forest.Forest; @@ -73,13 +74,17 @@ public class OrderPayCustomerServiceImpl extends ServiceImpl getCustomerAllList() { List nacosServerAllList = nacosServerService.nacosServerAllList(); + log.info("数据库查询数据 nacosServerAllList ---> {}" ,JSONObject.toJSONString(nacosServerAllList)); LambdaQueryWrapper queryWrapper = new LambdaQueryWrapper<>(); queryWrapper.select(OrderPayCustomer::getAppCode); List orderPayCustomerList = this.list(queryWrapper); + log.info("数据库查询数据 orderPayCustomerList ---> {}" , JSONObject.toJSONString(orderPayCustomerList)); Set customerSet = orderPayCustomerList.stream().map(OrderPayCustomer::getAppCode).collect(Collectors.toSet()); - return nacosServerAllList.stream() - .filter(nacosServer->customerSet.contains(nacosServer)) + List list = nacosServerAllList.stream() + .filter(nacosServer -> customerSet.contains(nacosServer)) .toList(); + log.info("数据库查询数据 List ---> {}",JSONObject.toJSONString(list)); + return list; } }