wangyingyang

fix

...@@ -440,13 +440,6 @@ public class ClientCustomerServiceImpl implements ClientCustomerService { ...@@ -440,13 +440,6 @@ public class ClientCustomerServiceImpl implements ClientCustomerService {
440 notOrderedHisCustomers = currentCustomers.stream().filter(c -> !mappingHisCustomerIds.contains(c.getId())).collect( 440 notOrderedHisCustomers = currentCustomers.stream().filter(c -> !mappingHisCustomerIds.contains(c.getId())).collect(
441 Collectors.toList()); 441 Collectors.toList());
442 442
443 - if (customerIds.isEmpty()) {
444 - return TodayOrderDto.builder()
445 - .totalCurrentCustomerCount(0)
446 - .notOrderCustomers(new ArrayList<>())
447 - .build();
448 - }
449 -
450 final var operatorLoginInfo = LoginContextHolder.getLoginInfo(); 443 final var operatorLoginInfo = LoginContextHolder.getLoginInfo();
451 LocalDate today = LocalDate.now(); 444 LocalDate today = LocalDate.now();
452 LocalDateTime todayZero = today.atStartOfDay(); 445 LocalDateTime todayZero = today.atStartOfDay();
...@@ -461,7 +454,11 @@ public class ClientCustomerServiceImpl implements ClientCustomerService { ...@@ -461,7 +454,11 @@ public class ClientCustomerServiceImpl implements ClientCustomerService {
461 .shouldFilterMealTimeEnd(true) 454 .shouldFilterMealTimeEnd(true)
462 .mealTimeEnd(tomorrowZero) 455 .mealTimeEnd(tomorrowZero)
463 .build(); 456 .build();
464 - final var orderedResponseList = orderServiceRpcClient.getOrdersByCondition(queryOrderDto); 457 +
458 + List<SingleClientCustomerOrderRpcResponse> orderedResponseList = new ArrayList<>();
459 + if (!customerIds.isEmpty()) {
460 + orderedResponseList = orderServiceRpcClient.getOrdersByCondition(queryOrderDto);
461 + }
465 List<Integer> uniqueOrderedCustomerIds = orderedResponseList.stream().map( 462 List<Integer> uniqueOrderedCustomerIds = orderedResponseList.stream().map(
466 SingleClientCustomerOrderRpcResponse::getCustomerId).distinct() 463 SingleClientCustomerOrderRpcResponse::getCustomerId).distinct()
467 .collect(Collectors.toList()); 464 .collect(Collectors.toList());
......