diff --git a/src/main/java/com/kiisoo/ic/customer/service/CustomerViewService.java b/src/main/java/com/kiisoo/ic/customer/service/CustomerViewService.java index 3784969..b03fd4a 100644 --- a/src/main/java/com/kiisoo/ic/customer/service/CustomerViewService.java +++ b/src/main/java/com/kiisoo/ic/customer/service/CustomerViewService.java @@ -260,6 +260,10 @@ public class CustomerViewService { int tmpCount = shopIdCountMap.get(shopId) == null ? 0 : Math.toIntExact(shopIdCountMap.get(shopId)); newCustomerCount.updateAndGet(v -> v + tmpCount); }); + //平均 + if(companyShopList.size() > 0){ + newCustomerCount.updateAndGet(v -> Math.round(v / (float)companyShopList.size())); + } orgViewDO.setNewCustomerCount(newCustomerCount.get()); tmpList.add(orgViewDO); });