活动排名问题修复

This commit is contained in:
tianfeng 2025-11-07 15:15:01 +08:00
parent c9e791160f
commit 71b40bbb50

View File

@ -84,7 +84,7 @@ public interface RankingActivityRecordRepository extends MongoRepository<Ranking
*
* 用途计算用户排名 = count(quantity > userQuantity) + 1
*/
@Query("{'sysOrigin': ?0, 'activityType': ?1, 'cycleType': ?2, 'cycleKey': ?3, 'userSex': ?4, 'deleted': ?5, 'quantity': {'$gt': ?6}}")
@Query(value = "{'sysOrigin': ?0, 'activityType': ?1, 'cycleType': ?2, 'cycleKey': ?3, 'userSex': ?4, 'deleted': ?5, 'quantity': {'$gt': ?6}}", count = true)
Long countByQuantityGreaterThan(
String sysOrigin,
RankingActivityType activityType,
@ -98,7 +98,8 @@ public interface RankingActivityRecordRepository extends MongoRepository<Ranking
/**
* 统计指定活动和周期中数量大于指定值的记录数不限性别
*/
@Query("{'sysOrigin': ?0, 'activityType': ?1, 'cycleType': ?2, 'cycleKey': ?3, 'deleted': ?4, 'quantity': {'$gt': ?5}}")
@Query(value ="{'sysOrigin': ?0, 'activityType': ?1, 'cycleType': ?2, 'cycleKey': ?3, 'deleted': ?4, 'quantity': {'$gt': ?5}}",
count = true)
Long countByQuantityGreaterThanWithoutSex(
String sysOrigin,
RankingActivityType activityType,