Browse Source

更新!

TRX 1 year ago
parent
commit
5b6605a955

+ 4 - 3
FullCardServer/src/main/java/com/zhongshu/card/server/core/dao/org/impl/UserCountDaoImpl.java

@@ -13,15 +13,12 @@ import org.springframework.data.domain.Page;
 import org.springframework.data.domain.Pageable;
 import org.springframework.data.domain.Sort;
 import org.springframework.data.mongodb.core.MongoTemplate;
-import org.springframework.data.mongodb.core.aggregation.Aggregation;
-import org.springframework.data.mongodb.core.aggregation.AggregationOperation;
 import org.springframework.data.mongodb.core.query.Criteria;
 import org.springframework.data.mongodb.core.query.Query;
 import org.springframework.util.CollectionUtils;
 
 import java.util.ArrayList;
 import java.util.List;
-import java.util.Map;
 import java.util.regex.Pattern;
 
 /**
@@ -85,6 +82,10 @@ public class UserCountDaoImpl extends BaseImpl implements UserCountDaoExtend {
             criteria.and("userType").is(param.getUserType());
         }
 
+        if (param.getState() != null) {
+            criteria.and("state").is(param.getState());
+        }
+
         if (!CommonUtil.longIsEmpty(param.getStartTime()) && !CommonUtil.longIsEmpty(param.getEndTime())) {
             criteria.and("createTime").gte(param.getStartTime()).lte(param.getEndTime());
         }