|
|
|
@ -351,14 +351,13 @@ public class RetailCompanyService {
|
|
|
|
|
//最初时间的总客户人数
|
|
|
|
|
QueryWrapper<OpSellerCustomerRelation> wrapper2 = new QueryWrapper<>();
|
|
|
|
|
wrapper2.in("user_id", userIds);
|
|
|
|
|
l = LocalDate.parse(startTime);
|
|
|
|
|
wrapper2.lt("create_time", l.plus(1,ChronoUnit.DAYS));
|
|
|
|
|
wrapper2.lt("create_time", startTime);
|
|
|
|
|
List<OpSellerCustomerRelation> opRelations = opSellerCustomerRelationDOMapper.selectList(wrapper2);
|
|
|
|
|
long count = opRelations.stream().map(OpSellerCustomerRelation::getCustomerId).distinct().count();
|
|
|
|
|
//最初时间的有效总客户人数
|
|
|
|
|
wrapper2.in("user_id", userIds);
|
|
|
|
|
wrapper2.eq("type", 1);
|
|
|
|
|
wrapper2.lt("create_time", l.plus(1,ChronoUnit.DAYS));
|
|
|
|
|
wrapper2.lt("create_time", startTime);
|
|
|
|
|
List<OpSellerCustomerRelation> opRelations2 = opSellerCustomerRelationDOMapper.selectList(wrapper2);
|
|
|
|
|
long count2 = opRelations2.stream().map(OpSellerCustomerRelation::getCustomerId).distinct().count();
|
|
|
|
|
//最后时间的总客户人数
|
|
|
|
|